[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen staging] Revert "x86: guard against straight-line speculation past RET"
commit 9cd905bae87fb06efa59c347ef1e96c5dc6cdb62 Author: Jan Beulich <jbeulich@xxxxxxxx> AuthorDate: Fri Apr 9 09:50:40 2021 +0200 Commit: Jan Beulich <jbeulich@xxxxxxxx> CommitDate: Fri Apr 9 09:53:53 2021 +0200 Revert "x86: guard against straight-line speculation past RET" This reverts commit 71b0b475d801ebeb83a6ba402425135c314fa2df, which has no real effect - the most recent version of the patch had lost the INT3 insn. --- xen/Makefile | 5 +---- xen/arch/x86/indirect-thunk.S | 3 --- xen/include/asm-x86/asm-defns.h | 16 ---------------- 3 files changed, 1 insertion(+), 23 deletions(-) diff --git a/xen/Makefile b/xen/Makefile index 3a8fb7ec7e..9f3be7766d 100644 --- a/xen/Makefile +++ b/xen/Makefile @@ -145,10 +145,7 @@ t2 = $(call as-insn,$(CC) -I$(BASEDIR)/include,".include \"asm-x86/asm-defns.h\" # https://bugs.llvm.org/show_bug.cgi?id=36110 t3 = $(call as-insn,$(CC),".macro FOO;.endm"$(close); asm volatile $(open)".macro FOO;.endm",-no-integrated-as) -# Check whether macros can override insn mnemonics in inline assembly. -t4 = $(call as-insn,$(CC),".macro ret; .error; .endm; .macro retq; .error; .endm",-no-integrated-as) - -CLANG_FLAGS += $(call or,$(t1),$(t2),$(t3),$(t4)) +CLANG_FLAGS += $(call or,$(t1),$(t2),$(t3)) endif CLANG_FLAGS += -Werror=unknown-warning-option diff --git a/xen/arch/x86/indirect-thunk.S b/xen/arch/x86/indirect-thunk.S index a090b35dcf..7cc22da0ef 100644 --- a/xen/arch/x86/indirect-thunk.S +++ b/xen/arch/x86/indirect-thunk.S @@ -11,9 +11,6 @@ #include <asm/asm_defns.h> -/* Don't transform the "ret" further down. */ -.purgem ret - .macro IND_THUNK_RETPOLINE reg:req call 2f 1: diff --git a/xen/include/asm-x86/asm-defns.h b/xen/include/asm-x86/asm-defns.h index e164437798..505f39ad5f 100644 --- a/xen/include/asm-x86/asm-defns.h +++ b/xen/include/asm-x86/asm-defns.h @@ -57,22 +57,6 @@ INDIRECT_BRANCH jmp \arg .endm -/* - * To guard against speculation past RET, insert a breakpoint insn - * immediately after them. - */ -.macro ret operand:vararg - retq \operand -.endm -.macro retq operand:vararg - .ifb \operand - .byte 0xc3 - .else - .byte 0xc2 - .word \operand - .endif -.endm - .macro guest_access_mask_ptr ptr:req, scratch1:req, scratch2:req #if defined(CONFIG_SPECULATIVE_HARDEN_GUEST_ACCESS) /* -- generated by git-patchbot for /home/xen/git/xen.git#staging
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |