Print this page
11787 Kernel needs to be built with retpolines
11788 Kernel needs to generally use RSB stuffing
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Reviewed by: John Levon <john.levon@joyent.com>

*** 19,32 **** * CDDL HEADER END */ /* * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ - #pragma ident "%Z%%M% %I% %E% SMI" - #include <sys/asm_linkage.h> #include <sys/asm_misc.h> #include <sys/regset.h> #include <sys/psw.h> --- 19,31 ---- * CDDL HEADER END */ /* * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. + * Copyright 2019 Joyent, Inc. */ #include <sys/asm_linkage.h> #include <sys/asm_misc.h> #include <sys/regset.h> #include <sys/psw.h>
*** 99,109 **** #if defined(__amd64) .globl gethrtimef ENTRY_NP(get_hrtime) FAST_INTR_PUSH ! call *gethrtimef(%rip) movq %rax, %rdx shrq $32, %rdx /* high 32-bit in %edx */ FAST_INTR_POP FAST_INTR_RETURN SET_SIZE(get_hrtime) --- 98,109 ---- #if defined(__amd64) .globl gethrtimef ENTRY_NP(get_hrtime) FAST_INTR_PUSH ! movq gethrtimef(%rip), %rax ! INDIRECT_CALL_REG(rax) movq %rax, %rdx shrq $32, %rdx /* high 32-bit in %edx */ FAST_INTR_POP FAST_INTR_RETURN SET_SIZE(get_hrtime)
*** 125,135 **** .globl gethrestimef ENTRY_NP(get_hrestime) FAST_INTR_PUSH subq $TIMESPEC_SIZE, %rsp movq %rsp, %rdi ! call *gethrestimef(%rip) movl (%rsp), %eax movl CLONGSIZE(%rsp), %edx addq $TIMESPEC_SIZE, %rsp FAST_INTR_POP FAST_INTR_RETURN --- 125,136 ---- .globl gethrestimef ENTRY_NP(get_hrestime) FAST_INTR_PUSH subq $TIMESPEC_SIZE, %rsp movq %rsp, %rdi ! movq gethrestimef(%rip), %rax ! INDIRECT_CALL_REG(rax) movl (%rsp), %eax movl CLONGSIZE(%rsp), %edx addq $TIMESPEC_SIZE, %rsp FAST_INTR_POP FAST_INTR_RETURN