The patch titled Subject: mm-page_owner-clamp-read-count-to-page_size-fix has been added to the -mm tree. Its filename is mm-page_owner-clamp-read-count-to-page_size-fix.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/mm-page_owner-clamp-read-count-to-page_size-fix.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/mm-page_owner-clamp-read-count-to-page_size-fix.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> Subject: mm-page_owner-clamp-read-count-to-page_size-fix use min_t() Cc: Joe Perches <joe@xxxxxxxxxxx> Cc: Matthew Wilcox <willy@xxxxxxxxxxxxx> Cc: Michal Hocko <mhocko@xxxxxxxx> Cc: Miles Chen <miles.chen@xxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/page_owner.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/mm/page_owner.c~mm-page_owner-clamp-read-count-to-page_size-fix +++ a/mm/page_owner.c @@ -351,7 +351,7 @@ print_page_owner(char __user *buf, size_ .skip = 0 }; - count = count > PAGE_SIZE ? PAGE_SIZE : count; + count = min_t(size_t, count, PAGE_SIZE); kbuf = kmalloc(count, GFP_KERNEL); if (!kbuf) return -ENOMEM; _ Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are arm-arch-arm-include-asm-pageh-needs-personalityh.patch mm.patch mm-page_owner-clamp-read-count-to-page_size-fix.patch memory_hotplug-free-pages-as-higher-order-fix.patch ipc-allow-boot-time-extension-of-ipcmni-from-32k-to-8m-checkpatch-fixes.patch linux-next-rejects.patch linux-next-git-rejects.patch kernel-forkc-export-kernel_thread-to-modules.patch slab-leaks3-default-y.patch