summaryrefslogtreecommitdiff
path: root/mm/gup.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/gup.c')
-rw-r--r--mm/gup.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/gup.c b/mm/gup.c
index ce14d4d28503..a8336b39d6b5 100644
--- a/mm/gup.c
+++ b/mm/gup.c
@@ -3080,7 +3080,7 @@ static int internal_get_user_pages_fast(unsigned long start,
start = untagged_addr(start) & PAGE_MASK;
len = nr_pages << PAGE_SHIFT;
if (check_add_overflow(start, len, &end))
- return 0;
+ return -EOVERFLOW;
if (end > TASK_SIZE_MAX)
return -EFAULT;
if (unlikely(!access_ok((void __user *)start, len)))