[PATCH v2 0/2] x86_64,entry: Clear NT on entry and speed up switch_to

2014-09-30 Thread Andy Lutomirski
Anish Bhatt noticed that user programs can set RFLAGS.NT before syscall or sysenter, and the kernel entry code doesn't filter out NT. This causes kernel C code and, depending on thread flags, the exit slow path to run with NT set. The former is a little bit scary (imagine calling into EFI with

[PATCH v2 0/2] x86_64,entry: Clear NT on entry and speed up switch_to

2014-09-30 Thread Andy Lutomirski
Anish Bhatt noticed that user programs can set RFLAGS.NT before syscall or sysenter, and the kernel entry code doesn't filter out NT. This causes kernel C code and, depending on thread flags, the exit slow path to run with NT set. The former is a little bit scary (imagine calling into EFI with