kernel - Implement spectre mitigations part 3 (stabilization)
commit26c7e964f6a833dbc90ca58e29fc63bccecc0b55
authorMatthew Dillon <dillon@apollo.backplane.com>
Thu, 11 Jan 2018 20:48:18 +0000 (11 12:48 -0800)
committerMatthew Dillon <dillon@apollo.backplane.com>
Thu, 11 Jan 2018 20:51:25 +0000 (11 12:51 -0800)
tree77867ee70475f8ba65bd7553c9a5dce6fb357dc6
parente239b8303ccf1f7cdd718c9e94cc6c4d8a1d62f5
kernel - Implement spectre mitigations part 3 (stabilization)

* Fix a bug in the system call entry code.  The wrong stack pointer
  was being loaded for KMMUENTRY_SYSCALL and KMMUENTRY_SYSCALL was
  using an offset that did not exist in certain situations.

* Load the correct stack pointer, but also change KMMUENTRY_CORE
  to not use stack-relative loads and stores.  Instead it uses
  the trampframe directly via %gs:BLAH

Reported-by: zrj
sys/cpu/x86_64/include/asmacros.h
sys/platform/pc64/x86_64/exception.S