Re: [PATCH v6] softirq: Preserve interrupt context during IRQ exit
From: Sebastian Andrzej Siewior
Date: Tue Oct 13 2026 - 15:11:10 EST
On 2026-10-11 08:07:42 [+0200], Karl Mehltretter wrote:
…
> Suggested-by: Peter Zijlstra <peterz@xxxxxxxxxxxxx>
> Link: https://lore.kernel.org/r/20260813130826.GW687043@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Assisted-by: LLM
> Signed-off-by: Karl Mehltretter <kmehltretter@xxxxxxxxx>
> ---
>
> Changes in v6:
> - Keep HARDIRQ_OFFSET through tick_irq_exit() and use
> hardirq_count() == HARDIRQ_OFFSET for its nesting check (Frederic).
> - Update entry.rst to document NOHZ handling before the final
> preemption-count decrement.
> - Test in_hardirq() directly in softirq_handle_begin() (Frederic).
> - Drop the in_nmi() test from the timer thread wakeup condition
> (Frederic). NMI entry adds HARDIRQ_OFFSET, so the equality check
> excludes IRQs nested in an NMI.
The NMI check is from
https://lore.kernel.org/all/20221208075604.811710-1-junxiao.chang@xxxxxxxxx/
and it seems it that it has not been required.
> - Drop the earlier Reviewed-by tags pending reconfirmation of the
> tick_irq_exit() behavior change.
I checked v5…v6 and it looks okay. The other bits I already looked at.
Reviewed-by: Sebastian Andrzej Siewior <bigeasy@xxxxxxxxxxxxx>
Sebastian