From: Peter Zijlstra <peterz@infradead.org>
To: Finn Thain <fthain@linux-m68k.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Will Deacon <will@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
Boqun Feng <boqun.feng@gmail.com>, Gary Guo <gary@garyguo.net>,
Mark Rutland <mark.rutland@arm.com>,
linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-m68k@lists.linux-m68k.org, Sasha Levin <sashal@kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
Dave Hansen <dave.hansen@linux.intel.com>,
x86@kernel.org, Ard Biesheuvel <ardb@kernel.org>,
"H. Peter Anvin" <hpa@zytor.com>,
linux-efi@vger.kernel.org
Subject: Re: [PATCH v6 3/4] atomic: Add alignment check to instrumented atomic operations
Date: Mon, 5 Jan 2026 17:06:34 +0100 [thread overview]
Message-ID: <20260105160634.GA2393663@noisy.programming.kicks-ass.net> (raw)
In-Reply-To: <f8cfe0d121be0849f5175495e73eafeeb85e1ad3.1767169542.git.fthain@linux-m68k.org>
On Wed, Dec 31, 2025 at 07:25:42PM +1100, Finn Thain wrote:
> From: Peter Zijlstra <peterz@infradead.org>
>
> Add a Kconfig option for debug builds which logs a warning when an
> instrumented atomic operation takes place that's misaligned.
> Some platforms don't trap for this.
>
> [fthain: added __DISABLE_BUG_TABLE macro.]
>
> Cc: Sasha Levin <sashal@kernel.org>
> Cc: Thomas Gleixner <tglx@linutronix.de>
> Cc: Ingo Molnar <mingo@redhat.com>
> Cc: Borislav Petkov <bp@alien8.de>
> Cc: Dave Hansen <dave.hansen@linux.intel.com>
> Cc: x86@kernel.org
> Cc: Ard Biesheuvel <ardb@kernel.org>
> Cc: "H. Peter Anvin" <hpa@zytor.com>
> Link: https://lore.kernel.org/lkml/20250901093600.GF4067720@noisy.programming.kicks-ass.net/
> Link: https://lore.kernel.org/linux-next/df9fbd22-a648-ada4-fee0-68fe4325ff82@linux-m68k.org/
> Signed-off-by: Finn Thain <fthain@linux-m68k.org>
> ---
> Checkpatch.pl says...
> ERROR: Missing Signed-off-by: line by nominal patch author 'Peter Ziljstra <peterz@infradead.org>'
> ---
> Changed since v5:
> - Add new __DISABLE_BUG_TABLE macro to prevent a build failure on those
> architectures which use atomics in pre-boot code like the EFI stub loader:
>
> x86_64-linux-gnu-ld: error: unplaced orphan section `__bug_table' from `arch/x86/boot/compressed/sev-handle-vc.o'
Urgh, so why not simply use __DISABLE_EXPORTS, that's typically (ab)used
for these things?
Also, unless __DISABLE_BUG_TABLE goes live inside asm/bug.h and kills
all __bug_table emissions, its a misnomer.
Furthermore, that SEV thing is broken and needs to be fixed anyway, this
isn't helping it much. noinstr code should not be using instrumented
things to begin with.
next prev parent reply other threads:[~2026-01-05 16:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-31 8:25 [PATCH v6 0/4] Align atomic storage Finn Thain
2025-12-31 8:25 ` [PATCH v6 4/4] atomic: Add option for weaker alignment check Finn Thain
2025-12-31 8:25 ` [PATCH v6 3/4] atomic: Add alignment check to instrumented atomic operations Finn Thain
2026-01-05 16:06 ` Peter Zijlstra [this message]
2026-01-05 21:22 ` Finn Thain
2025-12-31 8:25 ` [PATCH v6 1/4] bpf: Explicitly align bpf_res_spin_lock Finn Thain
2025-12-31 8:25 ` [PATCH v6 2/4] atomic: Specify alignment for atomic_t and atomic64_t Finn Thain
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=20260105160634.GA2393663@noisy.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=ardb@kernel.org \
--cc=arnd@arndb.de \
--cc=boqun.feng@gmail.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=fthain@linux-m68k.org \
--cc=gary@garyguo.net \
--cc=hpa@zytor.com \
--cc=linux-arch@vger.kernel.org \
--cc=linux-efi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-m68k@lists.linux-m68k.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=sashal@kernel.org \
--cc=tglx@linutronix.de \
--cc=will@kernel.org \
--cc=x86@kernel.org \
/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