lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 21 Oct 2009 21:20:11 +0800
From:	Wu Zhangjin <wuzhangjin@...il.com>
To:	Sergei Shtylyov <sshtylyov@...mvista.com>
Cc:	rostedt@...dmis.org, Thomas Gleixner <tglx@...utronix.de>,
	Nicholas Mc Guire <der.herr@...r.at>,
	Ralf Baechle <ralf@...ux-mips.org>, linux-mips@...ux-mips.org,
	linux-kernel@...r.kernel.org
Subject: Re: ftrace for MIPS

On Wed, 2009-10-21 at 17:14 +0400, Sergei Shtylyov wrote:
> Hello.
> 
> Steven Rostedt wrote:
> 
> >>Need to check which registers is missing when saving/restoring for
> >>_mcount:
> 
> >>NESTED(ftrace_graph_caller, PT_SIZE, ra) 
> >>        MCOUNT_SAVE_REGS
> >>        PTR_S   v0, PT_R2(sp)
> >>
> >>        MCOUNT_SET_ARGS
> >>        jal     prepare_ftrace_return
> >>        nop
> >>
> >>        /* overwrite the parent as &return_to_handler: v0 -> $1(at) */
> >>        move    $1,     v0  
> 
> > I'm confused here? I'm not exactly sure what the above is doing. Is $1 a
> > register (AT)?
> 
>     Yes.

Have replaced it by AT, thanks!

> 
> > And how is this register used before calling mcount?
> 
> >>        PTR_L   v0, PT_R2(sp)
> >>        MCOUNT_RESTORE_REGS
> >>        RETURN_BACK
> >>        END(ftrace_graph_caller)
> 
> >>        .align  2
> >>        .globl  return_to_handler
> >>return_to_handler:
> >>        PTR_SUBU        sp, PT_SIZE
> >>        PTR_S   v0, PT_R2(sp)
> 
> > BTW, is v0 the only return register? I know x86 can return two different
> > registers depending on what it returns. What happens if a function
> > returns a 64 bit value on a 32bit box? Does it use two registers for
> > that?
> 
>     Yes, there's also v1 register.
> 

Thanks, added.

Regards,
	Wu Zhangjin

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ