Subject: + ksm-remove-redundant-__gfp_zero-from-kcalloc.patch added to -mm tree To: joe@xxxxxxxxxxx,liwanp@xxxxxxxxxxxxxxxxxx From: akpm@xxxxxxxxxxxxxxxxxxxx Date: Fri, 13 Sep 2013 14:48:03 -0700 The patch titled Subject: ksm: Remove redundant __GFP_ZERO from kcalloc has been added to the -mm tree. Its filename is ksm-remove-redundant-__gfp_zero-from-kcalloc.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/ksm-remove-redundant-__gfp_zero-from-kcalloc.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/ksm-remove-redundant-__gfp_zero-from-kcalloc.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/SubmitChecklist when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Joe Perches <joe@xxxxxxxxxxx> Subject: ksm: Remove redundant __GFP_ZERO from kcalloc kcalloc returns zeroed memory. There's no need to use this flag. Signed-off-by: Joe Perches <joe@xxxxxxxxxxx> Reviewed-by: Wanpeng Li <liwanp@xxxxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/ksm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff -puN mm/ksm.c~ksm-remove-redundant-__gfp_zero-from-kcalloc mm/ksm.c --- a/mm/ksm.c~ksm-remove-redundant-__gfp_zero-from-kcalloc +++ a/mm/ksm.c @@ -2309,8 +2309,8 @@ static ssize_t merge_across_nodes_store( * Allocate stable and unstable together: * MAXSMP NODES_SHIFT 10 will use 16kB. */ - buf = kcalloc(nr_node_ids + nr_node_ids, - sizeof(*buf), GFP_KERNEL | __GFP_ZERO); + buf = kcalloc(nr_node_ids + nr_node_ids, sizeof(*buf), + GFP_KERNEL); /* Let us assume that RB_ROOT is NULL is zero */ if (!buf) err = -ENOMEM; _ Patches currently in -mm which might be from joe@xxxxxxxxxxx are origin.patch kernel-timerc-convert-kmalloc_nodegfp_zero-to-kzalloc_node.patch ksm-remove-redundant-__gfp_zero-from-kcalloc.patch linux-next.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html