From: Vlastimil Babka <vbabka@suse.cz>
To: Axel Rasmussen <axelrasmussen@google.com>,
Andrew Morton <akpm@linux-foundation.org>,
Christoph Lameter <cl@linux.com>,
David Rientjes <rientjes@google.com>,
Hyeonggon Yoo <42.hyeyoo@gmail.com>,
Joonsoo Kim <iamjoonsoo.kim@lge.com>,
Pekka Enberg <penberg@kernel.org>,
Roman Gushchin <roman.gushchin@linux.dev>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH] mm, slub: print CPU id on slab OOM
Date: Fri, 9 Aug 2024 09:36:18 +0200 [thread overview]
Message-ID: <a94bc4af-6d78-4fe8-9837-6c7e5ce5d936@suse.cz> (raw)
In-Reply-To: <20240806232649.3258741-1-axelrasmussen@google.com>
On 8/7/24 01:26, Axel Rasmussen wrote:
> Depending on how remote_node_defrag_ratio is configured, allocations can
> end up in this path as a result of the local node being OOM, despite the
> allocation overall being unconstrained (node == -1).
>
> When we print a warning, printing the current CPU makes that situation
> more clear (i.e., you can immediately see which node's OOM status
> matters for the allocation at hand).
>
> Signed-off-by: Axel Rasmussen <axelrasmussen@google.com>
Added to slab/for-next, thanks.
> ---
> mm/slub.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/mm/slub.c b/mm/slub.c
> index c9d8a2497fd6..7148047998de 100644
> --- a/mm/slub.c
> +++ b/mm/slub.c
> @@ -3422,7 +3422,8 @@ slab_out_of_memory(struct kmem_cache *s, gfp_t gfpflags, int nid)
> if ((gfpflags & __GFP_NOWARN) || !__ratelimit(&slub_oom_rs))
> return;
>
> - pr_warn("SLUB: Unable to allocate memory on node %d, gfp=%#x(%pGg)\n",
> + pr_warn("SLUB: Unable to allocate memory for CPU %u on node %d, gfp=%#x(%pGg)\n",
> + preemptible() ? raw_smp_processor_id() : smp_processor_id(),
> nid, gfpflags, &gfpflags);
> pr_warn(" cache: %s, object size: %u, buffer size: %u, default order: %u, min order: %u\n",
> s->name, s->object_size, s->size, oo_order(s->oo),
next parent reply other threads:[~2024-08-09 7:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20240806232649.3258741-1-axelrasmussen@google.com>
2024-08-09 7:36 ` Vlastimil Babka [this message]
2024-08-10 23:52 ` David Rientjes
2024-08-11 20:16 ` Vlastimil Babka
2024-08-11 20:21 ` David Rientjes
2024-08-12 22:45 ` Axel Rasmussen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a94bc4af-6d78-4fe8-9837-6c7e5ce5d936@suse.cz \
--to=vbabka@suse.cz \
--cc=42.hyeyoo@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=axelrasmussen@google.com \
--cc=cl@linux.com \
--cc=iamjoonsoo.kim@lge.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=penberg@kernel.org \
--cc=rientjes@google.com \
--cc=roman.gushchin@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox