Skip to content

Commit

Permalink
[PATCH] s390: add ptr_to_compat()
Browse files Browse the repository at this point in the history
Add ptr_to_compat() to s390 - needed by the new robust-futex code.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>

untested. CHECKME: am i right about the 0x7fffffffUL masking?

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Ingo Molnar authored and Linus Torvalds committed Mar 27, 2006
1 parent 66e863a commit f267fa9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions include/asm-s390/compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,11 @@ static inline void __user *compat_ptr(compat_uptr_t uptr)
return (void __user *)(unsigned long)(uptr & 0x7fffffffUL);
}

static inline compat_uptr_t ptr_to_compat(void __user *uptr)
{
return (u32)(unsigned long)uptr;
}

static inline void __user *compat_alloc_user_space(long len)
{
unsigned long stack;
Expand Down

0 comments on commit f267fa9

Please sign in to comment.