mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-17 09:14:19 +08:00
Three small x86 fixes which did not make it into 6.1:
- Remove a superfluous noinline which prevents GCC-7.3 to optimize a stub function away. - Allow uprobes on REP NOP and do not treat them like word-sized branch instructions. - Make the VDSO symbol export of __vdso_sgx_enter_enclave() depend on CONFIG_X86_SGX to prevent build fails with newer LLVM versions which rightfully detect that there is no function behind the symbol. -----BEGIN PGP SIGNATURE----- iQJHBAABCgAxFiEEQp8+kY+LLUocC4bMphj1TA10mKEFAmOW+sQTHHRnbHhAbGlu dXRyb25peC5kZQAKCRCmGPVMDXSYoWH5EACPYcRw9PNBLMC6L0MF5G0qCFmLcjqn Fe8LxLywsKdyT6f1aAcOetIqkwDN/fuUyJHcioKqyqSkNlNeRV2hoZ9OlsBGJ7zC 6HH41ZCrY39liKzMM2JmfxU6XxT74zEt3Fly4G127d78HBi9DYwk8fT6GY8/BOk6 wkeWuczqRY1NNek1SBIciBn/FMZU8UShqjKzQsS1Bpj2Dm2ZvHdVh+P2okp2wl9Z gMbFN0Jq+8jRWOb4BF0Hx2Fg+WjXZPhT8msDXh8Vnr0u7bchWCljbLvvFST2hfpo +u/uKeOgOHm0XfUBOQa2WpEpev4M3ve1WFSkmP/0Qe3tcaRabMRDXGezZJSAdf1K dZV0tQu+4rygzZwEf4ppskxejG7LSvyzrLdebPvzUYFT14C5E22jRxp1+Mpswq28 ZPiw6yc3XXUqboNV3JVNs3PDPBVucSCHfQfUNEfjUayaMhb4w5jQyy93WIffOzVU 0KnXe9XX0MA3e5zVJMXExW4907Iks/K+qNgXtx/8fJnqaECIJInxZfbPmj74ZpfT 6b0sJVt04eFX4uYKoLPpFoP9LFUvzU5eR7e7yuoiSGFh3D3p9bimyR5xhBxNqs8Y j7XL2i0jY95w6v1kK3Kmgr2L+JCAN2v/JFJ+eIOYQAIb/VkhTfNq/MHL33bDJ1X3 2IrBEgo5tk7VNw== =oJ/K -----END PGP SIGNATURE----- Merge tag 'x86-urgent-2022-12-12' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip Pull x86 fixes from Thomas Gleixner: "Three small x86 fixes which did not make it into 6.1: - Remove a superfluous noinline which prevents GCC-7.3 to optimize a stub function away - Allow uprobes on REP NOP and do not treat them like word-sized branch instructions - Make the VDSO symbol export of __vdso_sgx_enter_enclave() depend on CONFIG_X86_SGX to prevent build failures with newer LLVM versions which rightfully detect that there is no function behind the symbol" * tag 'x86-urgent-2022-12-12' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/vdso: Conditionally export __vdso_sgx_enter_enclave() uprobes/x86: Allow to probe a NOP instruction with 0x66 prefix x86/alternative: Remove noinline from __ibt_endbr_seal[_end]() stubs
This commit is contained in:
commit
9c2b840a3b
@ -27,7 +27,9 @@ VERSION {
|
||||
__vdso_time;
|
||||
clock_getres;
|
||||
__vdso_clock_getres;
|
||||
#ifdef CONFIG_X86_SGX
|
||||
__vdso_sgx_enter_enclave;
|
||||
#endif
|
||||
local: *;
|
||||
};
|
||||
}
|
||||
|
@ -624,7 +624,7 @@ void __init_or_module noinline apply_ibt_endbr(s32 *start, s32 *end)
|
||||
|
||||
#else
|
||||
|
||||
void __init_or_module noinline apply_ibt_endbr(s32 *start, s32 *end) { }
|
||||
void __init_or_module apply_ibt_endbr(s32 *start, s32 *end) { }
|
||||
|
||||
#endif /* CONFIG_X86_KERNEL_IBT */
|
||||
|
||||
|
@ -722,8 +722,9 @@ static int branch_setup_xol_ops(struct arch_uprobe *auprobe, struct insn *insn)
|
||||
switch (opc1) {
|
||||
case 0xeb: /* jmp 8 */
|
||||
case 0xe9: /* jmp 32 */
|
||||
case 0x90: /* prefix* + nop; same as jmp with .offs = 0 */
|
||||
break;
|
||||
case 0x90: /* prefix* + nop; same as jmp with .offs = 0 */
|
||||
goto setup;
|
||||
|
||||
case 0xe8: /* call relative */
|
||||
branch_clear_offset(auprobe, insn);
|
||||
@ -753,6 +754,7 @@ static int branch_setup_xol_ops(struct arch_uprobe *auprobe, struct insn *insn)
|
||||
return -ENOTSUPP;
|
||||
}
|
||||
|
||||
setup:
|
||||
auprobe->branch.opc1 = opc1;
|
||||
auprobe->branch.ilen = insn->length;
|
||||
auprobe->branch.offs = insn->immediate.value;
|
||||
|
Loading…
Reference in New Issue
Block a user