[PATCH V2] Add C-SKY architecture support

Guo Ren guoren at kernel.org
Mon Mar 25 03:11:08 UTC 2019


Hi Dmitry,

Thx for the review.

On Sun, Mar 24, 2019 at 04:30:31PM +0300, Dmitry V. Levin wrote:
> On Sat, Mar 23, 2019 at 08:56:14AM +0800, guoren at kernel.org wrote:
> [...]
> > diff --git a/linux/csky/arch_regs.c b/linux/csky/arch_regs.c
> > new file mode 100644
> > index 0000000..8cd0f67
> > --- /dev/null
> > +++ b/linux/csky/arch_regs.c
> > @@ -0,0 +1,10 @@
> > +/*
> > + * SPDX-License-Identifier: LGPL-2.1-or-later
> > + */
> > +
> > +static struct pt_regs csky_regs;
> > +
> > +unsigned long *const csky_sp_ptr = &csky_regs.usp;
> > +
> > +#define ARCH_REGS_FOR_GETREGSET	csky_regs
> > +#define ARCH_PC_REG		csky_regs.pc
> 
> I must have missed this during the fist review:
> csky_sp_ptr is not used anywhere so there is no need to define it.
> 
> Consider defining
> #define ARCH_SP_REG		csky_regs.usp
> instead.
> 
> This is used by get_stack_pointer() to fetch the stack pointer
> used by get_rt_sigframe_addr() used by SYS_FUNC(rt_sigreturn).
> 
> I suppose rt_sigreturn test fails without this.
Yes, you are right. csky_sp_ptr is wroong for current version.

Best Regards
 Guo Ren


More information about the Strace-devel mailing list