diff options
-rw-r--r-- | mm/slub.c | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -2281,11 +2281,11 @@ new_slab: | |||
2281 | } | 2281 | } |
2282 | 2282 | ||
2283 | page = c->page; | 2283 | page = c->page; |
2284 | if (likely(!kmem_cache_debug(s))) | 2284 | if (likely(!kmem_cache_debug(s) && pfmemalloc_match(page, gfpflags))) |
2285 | goto load_freelist; | 2285 | goto load_freelist; |
2286 | 2286 | ||
2287 | /* Only entered in the debug case */ | 2287 | /* Only entered in the debug case */ |
2288 | if (!alloc_debug_processing(s, page, freelist, addr)) | 2288 | if (kmem_cache_debug(s) && !alloc_debug_processing(s, page, freelist, addr)) |
2289 | goto new_slab; /* Slab failed checks. Next slab needed */ | 2289 | goto new_slab; /* Slab failed checks. Next slab needed */ |
2290 | 2290 | ||
2291 | deactivate_slab(s, page, get_freepointer(s, freelist)); | 2291 | deactivate_slab(s, page, get_freepointer(s, freelist)); |
@@ -2337,8 +2337,7 @@ redo: | |||
2337 | 2337 | ||
2338 | object = c->freelist; | 2338 | object = c->freelist; |
2339 | page = c->page; | 2339 | page = c->page; |
2340 | if (unlikely(!object || !node_match(page, node) || | 2340 | if (unlikely(!object || !node_match(page, node))) |
2341 | !pfmemalloc_match(page, gfpflags))) | ||
2342 | object = __slab_alloc(s, gfpflags, node, addr, c); | 2341 | object = __slab_alloc(s, gfpflags, node, addr, c); |
2343 | 2342 | ||
2344 | else { | 2343 | else { |