lkml.org 
[lkml]   [2020]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [patch V4 part 4 08/24] x86/entry: Provide IDTENTRY_IST
Date
Andy Lutomirski <luto@kernel.org> writes:
> On Tue, May 5, 2020 at 7:16 AM Thomas Gleixner <tglx@linutronix.de> wrote:
>>
>> Same as IDTENTRY but for exceptions which run on Interrupt STacks (IST) on
>> 64bit. For 32bit this maps to IDTENTRY.
>>
>> There are 3 variants which will be used:
>> IDTENTRY_MCE
>> IDTENTRY_DB
>> IDTENTRY_NMI
>>
>> These map to IDTENTRY_IST, but only the MCE and DB variants are emitting
>> ASM code as the NMI entry needs hand crafted ASM still.
>>
>> The function defines do not contain any idtenter/exit calls as these
>> exceptions need special treatment.
>
> Okay I guess, but in the long run I'm guessing that we'll want to
> merge a bunch of this to DECLARE_IDTENTRY_NOASM and just manually emit
> the special cases in entry_32/64.S.

The ASM is still the paranoid muck which is emitted nicely.

But on the C side this needs a different treatment than the regular
exceptions which all use idtentry_enter() before and idtentry_exit()
after the handler function body.

Those need magic things before and after nmi_enter/exit(). That's why
the C function is directly called and does not have any automatically
emitted enter/exit stuff like the other IDTENTRY variants.

Thanks,

tglx


\
 
 \ /
  Last update: 2020-05-14 20:45    [W:0.110 / U:1.672 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site