[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen staging] xen/arm32: entry: Rename save_guest_regs()



commit df1259540c3dd541ae52a31ca80953ce6de8c49f
Author:     Julien Grall <julien.grall@xxxxxxx>
AuthorDate: Wed Oct 30 11:24:59 2019 +0000
Commit:     Julien Grall <julien.grall@xxxxxxx>
CommitDate: Fri Nov 1 14:29:57 2019 +0000

    xen/arm32: entry: Rename save_guest_regs()
    
    The function save_guest_regs() is doing more than saving guest
    registers. It also restore the vectors table and consume any pending
    SErrors generated by the guest. So rename the function to
    prepare_context_from_guest().
    
    Take the opportunity to use ENDPROC() for the benefits of static
    analizer and the reader.
    
    Signed-off-by: Julien Grall <julien.grall@xxxxxxx>
    Release-acked-by: Juergen Gross <jgross@xxxxxxxx>
---
 xen/arch/arm/arm32/entry.S | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/xen/arch/arm/arm32/entry.S b/xen/arch/arm/arm32/entry.S
index 5abff24e91..59a296a4ad 100644
--- a/xen/arch/arm/arm32/entry.S
+++ b/xen/arch/arm/arm32/entry.S
@@ -24,7 +24,11 @@
 #define RESTORE_BANKED(mode) \
         RESTORE_ONE_BANKED(SP_##mode) ; RESTORE_ONE_BANKED(LR_##mode) ; 
RESTORE_ONE_BANKED(SPSR_##mode)
 
-save_guest_regs:
+/*
+ * Actions that needs to be done after entering the hypervisor from the
+ * guest and before the interrupts are unmasked.
+ */
+prepare_context_from_guest:
 #ifdef CONFIG_ARM32_HARDEN_BRANCH_PREDICTOR
         /*
          * Restore vectors table to the default as it may have been
@@ -115,6 +119,7 @@ abort_guest_exit_end:
 
 skip_check:
         mov pc, lr
+ENDPROC(prepare_context_from_guest)
 
         /*
          * Macro to define a trap entry.
@@ -173,7 +178,7 @@ skip_check:
 
 1:
         /* Trap from the guest */
-        bl      save_guest_regs
+        bl      prepare_context_from_guest
         .if     \guest_iflags != n
         cpsie   \guest_iflags
         .endif
@@ -363,7 +368,7 @@ return_to_hypervisor:
          * HVBAR very late.
          *
          * Default vectors table will be restored on exit (see
-         * save_guest_regs).
+         * prepare_context_from_guest).
          */
         mov r9, #0                      /* vector tables = NULL */
         /*
--
generated by git-patchbot for /home/xen/git/xen.git#staging

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.