Re: [PATCH RFC 2/8] blackfin: implement syscall restart generically
From: Mike Frysinger <hidden>
Date: 2011-10-26 00:02:04
Also in:
lkml
From: Mike Frysinger <hidden>
Date: 2011-10-26 00:02:04
Also in:
lkml
On Sun, Oct 23, 2011 at 06:19, Jonas Bonn [off-list ref] wrote:
--- a/arch/blackfin/include/asm/syscall.h +++ b/arch/blackfin/include/asm/syscall.hstatic inline long syscall_get_nr(struct task_struct *task, struct pt_regs *regs) { - return regs->p0; + return regs->orig_p0; }
i'm not sure this is correct. we set the orig_p0 to -1 when forcing the syscall to go to restart. shouldn't syscall_get_nr() still return the right value ?
syscall_set_return_value(struct task_struct *task, struct pt_regs *regs,
int error, long val)
{
- regs->r0 = error ? -error : val;
+ regs->r0 = error ? error : val;
}this fix is unrelated (and unmentioned in the changelog). i also see a bunch of other arches doing this. so we should pull this change out into a dedicated patchset, and fix all the arches at the same time. -mike