Re: Suspend 2 merge: 14/51: Disable page alloc failure message when suspending

Dave Hansen
2004-11-24T18:13:59Z

On Wed, 2004-11-24 at 04:57, Nigel Cunningham wrote:
> While eating memory, we will potentially trigger this a lot. We
> therefore disable the message when suspending.
>
> diff -ruN 503-disable-page-alloc-warnings-while-suspending-old/mm/page_alloc.c 503-disable-page-alloc-warnings-while-suspending-new/mm/page_alloc.c
> --- 503-disable-page-alloc-warnings-while-suspending-old/mm/page_alloc.c 2004-11-06 09:24:37.231308424 +1100
> +++ 503-disable-page-alloc-warnings-while-suspending-new/mm/page_alloc.c 2004-11-06 09:24:40.844759096 +1100
> @@ -725,7 +725,10 @@
> }
>
> nopage:
> - if (!(gfp_mask & __GFP_NOWARN) && printk_ratelimit()) {
> + if ((!(gfp_mask & __GFP_NOWARN)) &&
> + (!test_suspend_state(SUSPEND_RUNNING)) &&
> + printk_ratelimit()) {
> +
> printk(KERN_WARNING "%s: page allocation failure."
> " order:%d, mode:0x%x\n",
> p->comm, order, gfp_mask);

Following Documentation/SubmittingPatches, please submit patches made
with "diff -urp":

-p --show-c-function
Show which C function each change is in.

Otherwise, it's a lot harder to figure out what you're modifying.

-- Dave