Re: [PATCH] x86/asm/entry/32: Restore %ss before SYSRETL if necessary

From: Linus Torvalds
Date: Thu Apr 23 2015 - 12:13:40 EST


On Thu, Apr 23, 2015 at 9:06 AM, Brian Gerst <brgerst@xxxxxxxxx> wrote:
>
> So you are saying we should save and conditionally restore the
> kernel's %ss during context switch? That shouldn't be too bad. Half
> of the time you would be loading the null selector which is fast (no
> GDT access, no validation).

I'd almost prefer something along those lines, yes. Who knows *what*
leaks? If the present bit state leaks, then likely so does the limit
value etc etc..

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/