Fix objtool: missing int3 after ret warning

Resolve straight-line speculation warnings reported by objtool
for x86_64 assembly on Linux when CONFIG_SLS is set.  See the
following LWN article for the complete details.

https://lwn.net/Articles/877845/

Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #13528
Closes #13575
This commit is contained in:
Brian Behlendorf
2022-06-20 23:36:21 +00:00
parent b9d862f2db
commit 69ad0bd769
8 changed files with 34 additions and 22 deletions
@@ -1201,7 +1201,7 @@ aesni_gcm_encrypt:
.align 32
clear_fpu_regs_avx:
vzeroall
ret
RET
.size clear_fpu_regs_avx,.-clear_fpu_regs_avx
/*
@@ -1219,7 +1219,7 @@ gcm_xor_avx:
movdqu (%rsi), %xmm1
pxor %xmm1, %xmm0
movdqu %xmm0, (%rsi)
ret
RET
.size gcm_xor_avx,.-gcm_xor_avx
/*
@@ -1236,7 +1236,7 @@ atomic_toggle_boolean_nv:
jz 1f
movl $1, %eax
1:
ret
RET
.size atomic_toggle_boolean_nv,.-atomic_toggle_boolean_nv
.align 64