Re: [PATCH v17 02/16] preempt: Track NMI nesting to separate per-CPU counter
From: Gary Guo
Date: Wed Feb 04 2026 - 07:34:53 EST
On Wed Feb 4, 2026 at 11:12 AM GMT, Peter Zijlstra wrote:
> On Tue, Feb 03, 2026 at 01:15:21PM +0100, Peter Zijlstra wrote:
>> But I'm really somewhat sad that 64bit can't do better than this.
>
> Here, the below builds and boots (albeit with warnings because printf
> format crap sucks).
Hi Peter,
I am not sure if it's worth the complexity to do this for the NMI code path.
I don't think NMI code path is hot enough that this is necessary?
Best,
Gary
>
> ---
> arch/x86/Kconfig | 1 +
> arch/x86/include/asm/preempt.h | 53 ++++++++++++++++++++++++++++++------------
> arch/x86/kernel/cpu/common.c | 2 +-
> include/linux/hardirq.h | 7 +++---
> include/linux/preempt.h | 52 ++++++++++++++++++++++++++++++++++-------
> init/main.c | 2 +-
> kernel/Kconfig.preempt | 4 ++++
> kernel/sched/core.c | 8 +++----
> kernel/softirq.c | 10 +++++++-
> kernel/time/timer.c | 2 +-
> lib/locking-selftest.c | 2 +-
> 11 files changed, 106 insertions(+), 37 deletions(-)