lkml.org 
[lkml]   [2011]   [Jun]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 10/19] OpenRISC: System calls
From
Date

On Sun, 2011-06-19 at 17:09 +0200, richard -rw- weinberger wrote:
> On Sun, Jun 19, 2011 at 1:43 PM, Jonas Bonn <jonas@southpole.se> wrote:
> > +asmlinkage int _sys_vfork(struct pt_regs *regs)
> > +{
> > + /* This doesn't seem to work */
> > +// return do_fork(CLONE_VFORK | CLONE_VM | SIGCHLD, regs->sp, regs, 0, NULL, NULL);
>
> Just being curious, why does that not work?

Something about the CLONE_VM flag is breaking things... not sure what,
at this point. I'm not sure how concerned to be about this... this
syscall is deprecated, so the code isn't really used anyway -- then
again, the fact that it causes userspace code to crash may be an
indication of an issue elsewhere.

>
> > + /* This works */
> > + return do_fork(SIGCHLD, regs->sp, regs, 0, NULL, NULL);
>
> This looks very odd.

vfork is replaced by fork (in libc) when the syscall doesn't exist so it
seemed reasonable to make vfork look like fork even when the syscall's
there. It's worked for us up until now...

/Jonas



\
 
 \ /
  Last update: 2011-06-19 17:53    [W:0.078 / U:2.484 seconds]
©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site