summaryrefslogtreecommitdiffstats
path: root/mm/mincore.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/mincore.c')
-rw-r--r--mm/mincore.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/mincore.c b/mm/mincore.c
index 566b6c2bae5f..8aca6f7167bb 100644
--- a/mm/mincore.c
+++ b/mm/mincore.c
@@ -142,7 +142,7 @@ asmlinkage long sys_mincore(unsigned long start, size_t len,
* the temporary buffer size.
*/
down_read(&current->mm->mmap_sem);
- retval = do_mincore(start, tmp, max(pages, PAGE_SIZE));
+ retval = do_mincore(start, tmp, min(pages, PAGE_SIZE));
up_read(&current->mm->mmap_sem);
if (retval <= 0)