#include <linux/thread_info.h>
#include <linux/prefetch.h>
#include <linux/string.h>
+#include <linux/lockdep.h>
+#include <linux/sched.h>
#include <asm/asm.h>
#include <asm/page.h>
int __ret_gu; \
unsigned long __val_gu; \
__chk_user_ptr(ptr); \
+ might_sleep(); \
+ if (current->mm) \
+ might_lock_read(¤t->mm->mmap_sem); \
switch (sizeof(*(ptr))) { \
case 1: \
__get_user_x(1, __ret_gu, __val_gu, ptr); \
int __ret_pu; \
__typeof__(*(ptr)) __pu_val; \
__chk_user_ptr(ptr); \
+ might_sleep(); \
+ if (current->mm) \
+ might_lock_read(¤t->mm->mmap_sem); \
__pu_val = x; \
switch (sizeof(*(ptr))) { \
case 1: \
#define __put_user_size(x, ptr, size, retval, errret) \
do { \
retval = 0; \
+ might_sleep(); \
+ if (current->mm) \
+ might_lock_read(¤t->mm->mmap_sem); \
__chk_user_ptr(ptr); \
switch (size) { \
case 1: \
#define __get_user_size(x, ptr, size, retval, errret) \
do { \
retval = 0; \
+ might_sleep(); \
+ if (current->mm) \
+ might_lock_read(¤t->mm->mmap_sem); \
__chk_user_ptr(ptr); \
switch (size) { \
case 1: \