Re: [PATCH 0/3] x86/mce: Fix more noinstr fun

From: Marco Elver
Date: Fri Feb 04 2022 - 06:24:17 EST


On Fri, 4 Feb 2022 at 09:30, Borislav Petkov <bp@xxxxxxxxx> wrote:
>
> From: Borislav Petkov <bp@xxxxxxx>
>
> Hi all,
>
> here's a second small set of fixes for objtool noinstr validation issues
> in the MCE code.
>
> It goes ontop of tip:locking/core where there are some more commits
> changing generic helpers to be always inlined.
>
> As always, comments and suggestions are appreciated.
>
> Thx.
>
> Borislav Petkov (3):
> cpumask: Add a x86-specific cpumask_clear_cpu() helper
> x86/ptrace: Always inline v8086_mode() for instrumentation
> x86/mce: Use arch atomic and bit helpers

I guess to solve noinstr "calling" something else the only solution is
to make the other function noinstr as well, or __always_inline.

Have you considered making some of these other functions 'noinstr' as
well? I guess __always_inline works, esp. if there's just 1 caller.
And by the looks of it you're getting a net .text reduction, so

Acked-by: Marco Elver <elver@xxxxxxxxxx>