aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asm-x86/uaccess_64.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/include/asm-x86/uaccess_64.h b/include/asm-x86/uaccess_64.h
index 42a9769687e9..9139854d37b0 100644
--- a/include/asm-x86/uaccess_64.h
+++ b/include/asm-x86/uaccess_64.h
@@ -23,9 +23,6 @@ extern void __put_user_bad(void);
23 :"c" (ptr),"a" (x) \ 23 :"c" (ptr),"a" (x) \
24 :"ebx") 24 :"ebx")
25 25
26#define put_user(x, ptr) \
27 __put_user_check((__typeof__(*(ptr)))(x), (ptr), sizeof(*(ptr)))
28
29#define __get_user(x, ptr) \ 26#define __get_user(x, ptr) \
30 __get_user_nocheck((x), (ptr), sizeof(*(ptr))) 27 __get_user_nocheck((x), (ptr), sizeof(*(ptr)))
31#define __put_user(x, ptr) \ 28#define __put_user(x, ptr) \
@@ -34,11 +31,12 @@ extern void __put_user_bad(void);
34#define __get_user_unaligned __get_user 31#define __get_user_unaligned __get_user
35#define __put_user_unaligned __put_user 32#define __put_user_unaligned __put_user
36 33
37#define __put_user_check(x, ptr, size) \ 34#define put_user(x, ptr) \
38({ \ 35({ \
39 int __pu_err; \ 36 int __pu_err; \
40 typeof(*(ptr)) __user *__pu_addr = (ptr); \ 37 typeof(*(ptr)) __user *__pu_addr = (ptr); \
41 switch (size) { \ 38 __chk_user_ptr(ptr); \
39 switch (sizeof(*(ptr))) { \
42 case 1: \ 40 case 1: \
43 __put_user_x(1, __pu_err, x, __pu_addr); \ 41 __put_user_x(1, __pu_err, x, __pu_addr); \
44 break; \ 42 break; \