Skip to content

Commit

Permalink
lib/stackdepot.c: use __GFP_NOWARN for stack allocations
Browse files Browse the repository at this point in the history
This (large, atomic) allocation attempt can fail.  We expect and handle
that, so avoid the scary warning.

Link: http://lkml.kernel.org/r/[email protected]
Cc: Andrey Ryabinin <[email protected]>
Cc: Alexander Potapenko <[email protected]>
Cc: Michal Hocko <[email protected]>
Cc: Rik van Riel <[email protected]>
Cc: David Rientjes <[email protected]>
Cc: Mel Gorman <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
kiryl authored and torvalds committed Jul 28, 2016
1 parent 80a9201 commit 87cc271
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/stackdepot.c
Original file line number Diff line number Diff line change
Expand Up @@ -242,6 +242,7 @@ depot_stack_handle_t depot_save_stack(struct stack_trace *trace,
*/
alloc_flags &= ~GFP_ZONEMASK;
alloc_flags &= (GFP_ATOMIC | GFP_KERNEL);
alloc_flags |= __GFP_NOWARN;
page = alloc_pages(alloc_flags, STACK_ALLOC_ORDER);
if (page)
prealloc = page_address(page);
Expand Down

0 comments on commit 87cc271

Please sign in to comment.