Messages in this thread | | | Date | Wed, 29 Nov 2017 19:08:17 +0100 | From | Peter Zijlstra <> | Subject | Re: [PATCH] x86/entry/64: Fix native_load_gs_index() SWAPGS handling with IRQ state tracing enabled |
| |
On Wed, Nov 29, 2017 at 09:57:43AM -0800, Andy Lutomirski wrote: > On Tue, Nov 28, 2017 at 11:09 PM, Ingo Molnar <mingo@kernel.org> wrote:
> > On a related note, we should definitely extend the 'intended GS state' annotation > > comments I did in this patch to all SWAPGS instances - this way code review has a > > much higher chance of finding discrepancies between intent and actual code. > > Agreed. I'll send a patch.
Alternatively we could do something like:
SWITCH_TO_KERNEL_GS SWITCH_TO_USER_GS
and have them do the SWAPGS with an (optional) assertion of the actual GS.
| |