Re: [PATCH] x86/smpboot: Mark native_play_dead() as __noreturn
From: Josh Poimboeuf
Date: Mon Oct 27 2025 - 16:32:55 EST
On Mon, Oct 27, 2025 at 08:56:18PM +0100, Thorsten Blum wrote:
> On 27. Oct 2025, at 20:28, Josh Poimboeuf wrote:
> > On Mon, Oct 27, 2025 at 04:51:02PM +0100, Thorsten Blum wrote:
> >> native_play_dead() ends by calling the non-returning function
> >> hlt_play_dead() and therefore also never returns.
> >>
> >> The !CONFIG_HOTPLUG_CPU stub version of native_play_dead()
> >> unconditionally calls BUG() and does not return either.
> >>
> >> Add the __noreturn attribute to both function definitions and their
> >> declaration to document this behavior and to potentially improve
> >> compiler optimizations.
> >>
> >> Remove the obsolete comment, and add native_play_dead() to the objtool's
> >> list of __noreturn functions.
> >>
> >> Signed-off-by: Thorsten Blum <thorsten.blum@xxxxxxxxx>
> >
> > Is there an objtool warning that this fixes? If so, it would be helpful
> > to put it in the description above.
>
> Not that I'm aware of.
Ok.
Acked-by: Josh Poimboeuf <jpoimboe@xxxxxxxxxx>
--
Josh