lkml.org 
[lkml]   [2002]   [Aug]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] user-vm-unlock-2.5.31-A2
Ingo Molnar wrote:
> and here's a merged CLONE_VM_RELEASE patch against the previous
> clone-detached patch. (the sched.h reorganization broke it.)

I wonder if it makes more sense for the release word to be a futex --
then various ways of actually waiting for the stack are available.

It would be nice if the stored word were the exit() code, too. This
would remove the need for zombie threads even when an exit status is
desired.

> + /*
> + * Does the userspace VM want any unlock on mm_release()?
> + */
> + if (clone_flags & CLONE_RELEASE_VM) {
> + childregs->esp -= sizeof(0UL);
> + p->user_vm_lock = (long *) esp;

Is this correct? I would have expected this, given that stacks are
pre-decrement, and given that the value of `esp' is typically just after
the end of an mmaped region:

+ childregs->esp -= sizeof(0UL);
+ p->user_vm_lock = (long *) childregs->esp;

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

\
 
 \ /
  Last update: 2005-03-22 13:28    [W:0.161 / U:1.636 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site