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>

*** 586,596 **** testl %eax, %eax /* check for non-zero probe */ jz 1f pushq %rbp /* align stack properly */ movq %rsp, %rbp movl %eax, %edi ! call *lockstat_probe leave /* unwind stack */ 1: movq %gs:CPU_THREAD, %rdx /* reload thread ptr */ decb T_LOCKSTAT(%rdx) /* curthread->t_lockstat-- */ movl $1, %eax /* return success if tryenter */ --- 586,597 ---- testl %eax, %eax /* check for non-zero probe */ jz 1f pushq %rbp /* align stack properly */ movq %rsp, %rbp movl %eax, %edi ! movq lockstat_probe, %rax ! INDIRECT_CALL_REG(rax) leave /* unwind stack */ 1: movq %gs:CPU_THREAD, %rdx /* reload thread ptr */ decb T_LOCKSTAT(%rdx) /* curthread->t_lockstat-- */ movl $1, %eax /* return success if tryenter */
*** 608,618 **** testl %eax, %eax /* check for non-zero probe */ jz 1f pushq %rbp /* align stack properly */ movq %rsp, %rbp movl %eax, %edi ! call *lockstat_probe leave /* unwind stack */ 1: movq %gs:CPU_THREAD, %rdx /* reload thread ptr */ decb T_LOCKSTAT(%rdx) /* curthread->t_lockstat-- */ movl $1, %eax /* return success if tryenter */ --- 609,620 ---- testl %eax, %eax /* check for non-zero probe */ jz 1f pushq %rbp /* align stack properly */ movq %rsp, %rbp movl %eax, %edi ! movq lockstat_probe, %rax ! INDIRECT_CALL_REG(rax) leave /* unwind stack */ 1: movq %gs:CPU_THREAD, %rdx /* reload thread ptr */ decb T_LOCKSTAT(%rdx) /* curthread->t_lockstat-- */ movl $1, %eax /* return success if tryenter */