Suggested-by: Andrew Cooper <andrew.coop...@citrix.com>
Signed-off-by: Jane Malalane <jane.malal...@citrix.com>
---
CC: Jan Beulich <jbeul...@suse.com>
CC: Andrew Cooper <andrew.coop...@citrix.com>
CC: "Roger Pau Monné" <roger....@citrix.com>
CC: Wei Liu <w...@xen.org>
---
 xen/arch/x86/x86_64/entry.S | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)

diff --git a/xen/arch/x86/x86_64/entry.S b/xen/arch/x86/x86_64/entry.S
index 26bf2f1941..4ad25d9c90 100644
--- a/xen/arch/x86/x86_64/entry.S
+++ b/xen/arch/x86/x86_64/entry.S
@@ -140,6 +140,15 @@ process_trap:
         call create_bounce_frame
         jmp  test_all_events
 
+        .pushsection .init.text, "ax", @progbits
+        ENTRY(early_page_fault)
+        ENDBR64
+        movl  $TRAP_page_fault,4(%rsp)
+        SAVE_ALL
+        movq  %rsp,%rdi
+        call  do_early_page_fault
+        jmp   restore_all_xen
+
         .section .text.entry, "ax", @progbits
 
 /* %rbx: struct vcpu, interrupts disabled */
@@ -982,16 +991,6 @@ ENTRY(double_fault)
         call  do_double_fault
         BUG   /* do_double_fault() shouldn't return. */
 
-        .pushsection .init.text, "ax", @progbits
-ENTRY(early_page_fault)
-        ENDBR64
-        movl  $TRAP_page_fault,4(%rsp)
-        SAVE_ALL
-        movq  %rsp,%rdi
-        call  do_early_page_fault
-        jmp   restore_all_xen
-        .popsection
-
 ENTRY(nmi)
         ENDBR64
         pushq $0
-- 
2.11.0


Reply via email to