mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
x86/entry: Adjustments to "reduce assembly code size of entry points"
Some retroactive review, for if I'd got to the patch in time.
* The new ASM-friendly BUILD_BUG_ON() should be in a header file.
* entry_int82() wants the movl->movb treatment too.
Fixes: c144b9e324 ("x86: Reduce assembly code size of entry points")
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
This commit is contained in:
1 parent
6f1b280876
commit
7d3c91377d
3 files changed
+9
-9
No files matched your search
@@ -82,6 +82,14 @@ register unsigned long current_stack_pointer asm("rsp");
|
||||
|
||||
#ifdef __ASSEMBLY__
|
||||
|
||||
.macro BUILD_BUG_ON condstr cond:vararg
|
||||
.if \cond
|
||||
.error "Condition \"\condstr\" not satisfied"
|
||||
.endif
|
||||
.endm
|
||||
/* preprocessor macro to make error message more user friendly */
|
||||
#define BUILD_BUG_ON(cond) BUILD_BUG_ON #cond cond
|
||||
|
||||
#ifdef HAVE_AS_QUOTED_SYM
|
||||
#define SUBSECTION_LBL(tag) \
|
||||
.ifndef .L.tag; \
|
||||
|
||||
@@ -15,7 +15,7 @@ FUNC(entry_int82)
|
||||
ENDBR64
|
||||
ALTERNATIVE "", clac, X86_FEATURE_XEN_SMAP
|
||||
pushq $0
|
||||
movl $HYPERCALL_VECTOR, 4(%rsp)
|
||||
movb $HYPERCALL_VECTOR, 4(%rsp)
|
||||
SAVE_ALL compat=1 /* DPL1 gate, restricted to 32bit PV guests only. */
|
||||
|
||||
SPEC_CTRL_ENTRY_FROM_PV /* Req: %rsp=regs/cpuinfo, %rdx=0, Clob: acd */
|
||||
|
||||
@@ -22,14 +22,6 @@
|
||||
#endif
|
||||
.endm
|
||||
|
||||
.macro BUILD_BUG_ON condstr cond:vararg
|
||||
.if \cond
|
||||
.error "Condition \"\condstr\" not satisfied"
|
||||
.endif
|
||||
.endm
|
||||
/* preprocessor macro to make error message more user friendly */
|
||||
#define BUILD_BUG_ON(cond) BUILD_BUG_ON #cond cond
|
||||
|
||||
#ifdef CONFIG_PV
|
||||
/* %rbx: struct vcpu */
|
||||
FUNC_LOCAL(switch_to_kernel)
|
||||
|
||||