From: Pekka Enberg Date: Thu, 11 Jun 2009 13:18:09 +0000 (+0300) Subject: SLUB: Don't print out OOM warning for __GFP_NOFAIL X-Git-Tag: v2.6.31-rc1~290^2~1^5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=95f8598931bd86a5775073db2fa2004b892dd3d0;p=profile%2Fivi%2Fkernel-x86-ivi.git SLUB: Don't print out OOM warning for __GFP_NOFAIL We must check for __GFP_NOFAIL like the page allocator does; otherwise we end up with false positives. While at it, add the printk_ratelimit() check in SLUB as well. Cc: Alexander Beregalov Signed-off-by: Pekka Enberg --- diff --git a/mm/slub.c b/mm/slub.c index 9fb892b..0996b3b 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -1631,7 +1631,8 @@ new_slab: c->page = new; goto load_freelist; } - slab_out_of_memory(s, gfpflags, node); + if (!(gfpflags & __GFP_NOWARN) && printk_ratelimit()) + slab_out_of_memory(s, gfpflags, node); return NULL; debug: if (!alloc_debug_processing(s, c->page, object, addr))