From: Vladimir Davydov Date: Wed, 4 Jun 2014 23:07:04 +0000 (-0700) Subject: slab: document kmalloc_order X-Git-Tag: v5.15~17789^2~16^2~209 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=cea371f4f39ced101d27264eddb8cf8c749fdd00;p=platform%2Fkernel%2Flinux-starfive.git slab: document kmalloc_order Signed-off-by: Vladimir Davydov Cc: Christoph Lameter Cc: Pekka Enberg Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/slab_common.c b/mm/slab_common.c index 1950c8f..2834bc2 100644 --- a/mm/slab_common.c +++ b/mm/slab_common.c @@ -582,6 +582,11 @@ void __init create_kmalloc_caches(unsigned long flags) } #endif /* !CONFIG_SLOB */ +/* + * To avoid unnecessary overhead, we pass through large allocation requests + * directly to the page allocator. We use __GFP_COMP, because we will need to + * know the allocation order to free the pages properly in kfree. + */ void *kmalloc_order(size_t size, gfp_t flags, unsigned int order) { void *ret;