Commit cd7e4a91 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] add_to_swap(): suppress oom message

Page allocation failures are expected when add_to_swap() tries to allocate
radix-tree nodes without PF_MEMALLOC.  Kill the __alloc_pages() warnings.
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 3e9e3e71
......@@ -171,7 +171,7 @@ int add_to_swap(struct page * page)
/*
* Add it to the swap cache and mark it dirty
*/
err = __add_to_swap_cache(page, entry, GFP_ATOMIC);
err = __add_to_swap_cache(page, entry, GFP_ATOMIC|__GFP_NOWARN);
if (pf_flags & PF_MEMALLOC)
current->flags |= PF_MEMALLOC;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment