diff options
author | Luiz Souza <luiz@netgate.com> | 2018-02-23 19:44:33 -0300 |
---|---|---|
committer | Luiz Souza <luiz@netgate.com> | 2018-02-23 19:44:33 -0300 |
commit | 2eec73396569fbb21ec9fa2a0590ed94dfa3b8a4 (patch) | |
tree | b4f4ee73e5e8c54eae5d77612fb72dfe8991123e /sys/amd64/ia32/ia32_exception.S | |
parent | 61381ad9e72c5503ff876f702a7ee9b75cc82031 (diff) | |
download | FreeBSD-src-2eec73396569fbb21ec9fa2a0590ed94dfa3b8a4.zip FreeBSD-src-2eec73396569fbb21ec9fa2a0590ed94dfa3b8a4.tar.gz |
Revert "Revert "MFC r328083,328096,328116,328119,328120,328128,328135,328153,328157,""
This reverts commit d3d59b01294138e59995b31d2bcbbbdf45e26a3c.
Diffstat (limited to 'sys/amd64/ia32/ia32_exception.S')
-rw-r--r-- | sys/amd64/ia32/ia32_exception.S | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/sys/amd64/ia32/ia32_exception.S b/sys/amd64/ia32/ia32_exception.S index fe1a676..1f09764 100644 --- a/sys/amd64/ia32/ia32_exception.S +++ b/sys/amd64/ia32/ia32_exception.S @@ -40,24 +40,27 @@ * that it originated in supervisor mode and skip the swapgs. */ SUPERALIGN_TEXT +IDTVEC(int0x80_syscall_pti) + PTI_UENTRY has_err=0 + jmp int0x80_syscall_common + SUPERALIGN_TEXT IDTVEC(int0x80_syscall) swapgs +int0x80_syscall_common: pushq $2 /* sizeof "int 0x80" */ subq $TF_ERR,%rsp /* skip over tf_trapno */ movq %rdi,TF_RDI(%rsp) movq PCPU(CURPCB),%rdi andl $~PCB_FULL_IRET,PCB_FLAGS(%rdi) - movw %fs,TF_FS(%rsp) - movw %gs,TF_GS(%rsp) - movw %es,TF_ES(%rsp) - movw %ds,TF_DS(%rsp) - sti - movq %rsi,TF_RSI(%rsp) + SAVE_SEGS + movq %rax,TF_RAX(%rsp) movq %rdx,TF_RDX(%rsp) movq %rcx,TF_RCX(%rsp) + call handle_ibrs_entry + sti + movq %rsi,TF_RSI(%rsp) movq %r8,TF_R8(%rsp) movq %r9,TF_R9(%rsp) - movq %rax,TF_RAX(%rsp) movq %rbx,TF_RBX(%rsp) movq %rbp,TF_RBP(%rsp) movq %r10,TF_R10(%rsp) |