diff options
Diffstat (limited to 'mm/util.c')
-rw-r--r-- | mm/util.c | 7 |
1 files changed, 1 insertions, 6 deletions
@@ -156,12 +156,7 @@ void *memdup_user(const void __user *src, size_t len) | |||
156 | { | 156 | { |
157 | void *p; | 157 | void *p; |
158 | 158 | ||
159 | /* | 159 | p = kmalloc_track_caller(len, GFP_USER); |
160 | * Always use GFP_KERNEL, since copy_from_user() can sleep and | ||
161 | * cause pagefault, which makes it pointless to use GFP_NOFS | ||
162 | * or GFP_ATOMIC. | ||
163 | */ | ||
164 | p = kmalloc_track_caller(len, GFP_KERNEL); | ||
165 | if (!p) | 160 | if (!p) |
166 | return ERR_PTR(-ENOMEM); | 161 | return ERR_PTR(-ENOMEM); |
167 | 162 | ||