[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <57bca164-4e63-496d-9074-79fd89feb835@app.fastmail.com>
Date: Mon, 15 Sep 2025 13:20:18 +0200
From: "Arnd Bergmann" <arnd@...db.de>
To: "Finn Thain" <fthain@...ux-m68k.org>,
"Peter Zijlstra" <peterz@...radead.org>
Cc: "Will Deacon" <will@...nel.org>,
"Andrew Morton" <akpm@...ux-foundation.org>,
"Boqun Feng" <boqun.feng@...il.com>, "Jonathan Corbet" <corbet@....net>,
"Mark Rutland" <mark.rutland@....com>, linux-kernel@...r.kernel.org,
Linux-Arch <linux-arch@...r.kernel.org>,
"Geert Uytterhoeven" <geert@...ux-m68k.org>, linux-m68k@...r.kernel.org
Subject: Re: [RFC v2 3/3] atomic: Add alignment check to instrumented atomic operations
On Mon, Sep 15, 2025, at 12:37, Finn Thain wrote:
> On Mon, 15 Sep 2025, Peter Zijlstra wrote:
>>
>> > When you do atomic operations on atomic_t or atomic64_t, (sizeof(long)
>> > - 1) probably doesn't make much sense. But atomic operations get used on
>> > scalar types (aside from atomic_t and atomic64_t) that don't have natural
>> > alignment. Please refer to the other thread about this:
>> > https://lore.kernel.org/all/ed1e0896-fd85-5101-e136-e4a5a37ca5ff@linux-m68k.org/
>>
>> Perhaps set ARCH_SLAB_MINALIGN ?
>>
>
> That's not going to help much. The 850 byte offset of task_works into
> struct task_struct and the 418 byte offset of exit_state in struct
> task_struct are already misaligned.
Has there been any progress on building m68k kernels with -mint-align?
IIRC there are only a small number of uapi structures that need
__packed annotations to maintain the existing syscall ABI.
Arnd
Powered by blists - more mailing lists