From: Geert Uytterhoeven <[email protected]>
To: "Christoph Lameter (Ampere)" <[email protected]>
Cc: Vlastimil Babka <[email protected]>,
Pekka Enberg <[email protected]>,
David Rientjes <[email protected]>,
Joonsoo Kim <[email protected]>,
Andrew Morton <[email protected]>,
Roman Gushchin <[email protected]>,
Hyeonggon Yoo <[email protected]>,
Jens Axboe <[email protected]>,
Pavel Begunkov <[email protected]>,
Mike Rapoport <[email protected]>,
Christian Brauner <[email protected]>,
Guenter Roeck <[email protected]>,
Kees Cook <[email protected]>, Jann Horn <[email protected]>,
[email protected], [email protected],
[email protected], [email protected]
Subject: Re: [PATCH] slab: Fix too strict alignment check in create_cache()
Date: Thu, 21 Nov 2024 09:15:37 +0100 [thread overview]
Message-ID: <CAMuHMdWQisrjqaPPd0xLgtSAxRwnxCPdsqnWSncMiPYLnre2MA@mail.gmail.com> (raw)
In-Reply-To: <[email protected]>
Hi Christoph,
On Wed, Nov 20, 2024 at 6:50 PM Christoph Lameter (Ampere)
<[email protected]> wrote:
> On Wed, 20 Nov 2024, Vlastimil Babka wrote:
> > > Fixes: aaa736b186239b7d ("io_uring: specify freeptr usage for SLAB_TYPESAFE_BY_RCU io_kiocb cache")
> > > Fixes: d345bd2e9834e2da ("mm: add kmem_cache_create_rcu()")
> > > Reported-by: Guenter Roeck <[email protected]>
> > > Closes: https://lore.kernel.org/[email protected]
> > > Signed-off-by: Geert Uytterhoeven <[email protected]>
> >
> > Thanks, will add it to slab pull for 6.13.
>
> Note that there are widespread assumptions in kernel code that the
> alignment of scalars is the "natural alignment". Other portions of the
> kernel may break. The compiler actually goes along with this??
Linux has supported m68k since last century.
Any new such assumptions are fixed quickly (at least in the kernel).
If you need a specific alignment, make sure to use __aligned and/or
appropriate padding in structures.
And yes, the compiler knows, and provides __alignof__.
> How do you deal with torn reads/writes in such a scenario? Is this UP
> only?
Linux does not support (rate) SMP m68k machines.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
next prev parent reply other threads:[~2024-11-21 8:15 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-20 12:46 [PATCH] slab: Fix too strict alignment check in create_cache() Geert Uytterhoeven
2024-11-20 12:49 ` Geert Uytterhoeven
2024-11-20 15:00 ` Guenter Roeck
2024-11-20 15:01 ` Jens Axboe
2024-11-20 15:03 ` Vlastimil Babka
2024-11-20 15:14 ` Guenter Roeck
2024-11-20 15:44 ` Vlastimil Babka
2024-11-20 15:50 ` Geert Uytterhoeven
2024-11-20 17:50 ` Christoph Lameter (Ampere)
2024-11-21 3:51 ` Matthew Wilcox
2024-11-21 8:15 ` Geert Uytterhoeven [this message]
2024-11-21 10:19 ` Christian Brauner
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=CAMuHMdWQisrjqaPPd0xLgtSAxRwnxCPdsqnWSncMiPYLnre2MA@mail.gmail.com \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
/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