Messages in this thread | | | Date | Thu, 31 May 2012 12:27:40 -0700 | From | "H. Peter Anvin" <> | Subject | Re: [PATCH 4/5] x86: Allow nesting of the debug stack IDT setting |
| |
On 05/31/2012 12:25 PM, Steven Rostedt wrote: >> void debug_stack_set_zero(void) >> { >> if (this_cpu_inc_return(debug_stack_use_ctr) == 1) > > If an NMI comes in here, it will not update the IDT and will corrupt the > stack. The load_idt() must happen for all calls. There's only two static > IDT tables. It's either one or the other. Thus, if it loads it twice, it > will just set it to the same value. The counter is to know when to set > it back. >
Now I'm really confused. Why would it have to set it if it is already set?
-hpa
-- H. Peter Anvin, Intel Open Source Technology Center I work for Intel. I don't speak on their behalf.
| |