linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Shakeel Butt <shakeel.butt@linux.dev>
To: Guenter Roeck <linux@roeck-us.net>
Cc: JP Kobryn <inwardvessel@gmail.com>,
	tj@kernel.org, klarasmodin@gmail.com,  yosryahmed@google.com,
	mkoutny@suse.com, hannes@cmpxchg.org,  akpm@linux-foundation.org,
	linux-mm@kvack.org, cgroups@vger.kernel.org,
	 kernel-team@meta.com
Subject: Re: [PATCH cgroup/for-6.16] cgroup: avoid per-cpu allocation of size zero rstat cpu locks
Date: Mon, 2 Jun 2025 21:10:33 -0700	[thread overview]
Message-ID: <CAGj-7pV8-S_b7Bw5uhvdjN-uNRL=gsyyQTMf+36TTzhJXpT3CA@mail.gmail.com> (raw)
In-Reply-To: <b9824a99-cca6-43d3-81db-14f4366c5fef@roeck-us.net>

On Mon, Jun 2, 2025 at 8:38 PM Guenter Roeck <linux@roeck-us.net> wrote:
>
> On Wed, May 21, 2025 at 06:32:02PM -0700, JP Kobryn wrote:
> > Subsystem rstat locks are dynamically allocated per-cpu. It was discovered
> > that a panic can occur during this allocation when the lock size is zero.
> > This is the case on non-smp systems, since arch_spinlock_t is defined as an
> > empty struct. Prevent this allocation when !CONFIG_SMP by adding a
> > pre-processor conditional around the affected block.
> >
>
> It may be defined as empty struct, but it is still dereferenced. This patch
> is causing crashes on non-SMP systems such as xtensa, m68k, or with x86
> non-SMP builds.
>

Does this still happen with the following patch?

https://lore.kernel.org/20250528235130.200966-1-inwardvessel@gmail.com/


  reply	other threads:[~2025-06-03  4:11 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-22  1:32 JP Kobryn
2025-05-22  1:55 ` Tejun Heo
2025-05-22 13:22 ` Klara Modin
2025-06-03  3:38 ` Guenter Roeck
2025-06-03  4:10   ` Shakeel Butt [this message]
2025-06-03  4:26     ` Guenter Roeck

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='CAGj-7pV8-S_b7Bw5uhvdjN-uNRL=gsyyQTMf+36TTzhJXpT3CA@mail.gmail.com' \
    --to=shakeel.butt@linux.dev \
    --cc=akpm@linux-foundation.org \
    --cc=cgroups@vger.kernel.org \
    --cc=hannes@cmpxchg.org \
    --cc=inwardvessel@gmail.com \
    --cc=kernel-team@meta.com \
    --cc=klarasmodin@gmail.com \
    --cc=linux-mm@kvack.org \
    --cc=linux@roeck-us.net \
    --cc=mkoutny@suse.com \
    --cc=tj@kernel.org \
    --cc=yosryahmed@google.com \
    /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