提交 f267fa9f 编写于 作者: I Ingo Molnar 提交者: Linus Torvalds

[PATCH] s390: add ptr_to_compat()

Add ptr_to_compat() to s390 - needed by the new robust-futex code.
Signed-off-by: NIngo 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: NAndrew Morton <akpm@osdl.org>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 66e863ac
...@@ -128,6 +128,11 @@ static inline void __user *compat_ptr(compat_uptr_t uptr) ...@@ -128,6 +128,11 @@ static inline void __user *compat_ptr(compat_uptr_t uptr)
return (void __user *)(unsigned long)(uptr & 0x7fffffffUL); 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) static inline void __user *compat_alloc_user_space(long len)
{ {
unsigned long stack; unsigned long stack;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册