[GIT pull] final futex fixes for 2.6.31

From: Thomas Gleixner
Date: Thu Jun 25 2009 - 14:15:54 EST


Linus,

I'm truly embarrassed to ask you to pull the latest futexes-for-linus
git tree from:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git futexes-for-linus

I did not just copy your suggestion blindly, I even wondered and
looked up the prototype in mm.h which has the 4th argument "int len"
and said to myself "hey, Linus is right as usual" while in reality
"len" is number of pages.

As I'm running out of brown paperbags I'm declaring all futex bugs
fixed by definition. Futex bugs which will be discovered from now on
are going to be automatically converted to documented features.

Thanks,

tglx

------------------>
Thomas Gleixner (1):
futex: request only one page from get_user_pages()


kernel/futex.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/futex.c b/kernel/futex.c
index 1c33711..794c862 100644
--- a/kernel/futex.c
+++ b/kernel/futex.c
@@ -299,7 +299,7 @@ void put_futex_key(int fshared, union futex_key *key)
static int fault_in_user_writeable(u32 __user *uaddr)
{
int ret = get_user_pages(current, current->mm, (unsigned long)uaddr,
- sizeof(*uaddr), 1, 0, NULL, NULL);
+ 1, 1, 0, NULL, NULL);
return ret < 0 ? ret : 0;
}

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