Ver Fonte

[fix] according to AAPCS64, the function lwp_mmu_switch will use x8 to save value, so the value saved in x8 will lose

SummerGift há 4 anos atrás
pai
commit
698b8bd6b3
1 ficheiros alterados com 2 adições e 2 exclusões
  1. 2 2
      libcpu/aarch64/common/context_gcc.S

+ 2 - 2
libcpu/aarch64/common/context_gcc.S

@@ -120,9 +120,9 @@ rt_hw_get_gtimer_frq:
     BL      lwp_check_exit
 
     BL      rt_thread_self
-    MOV     X8, X0
+    MOV     X19, X0
     BL      lwp_mmu_switch
-    MOV     X0, X8
+    MOV     X0, X19
     BL      lwp_user_setting_restore
 
     LDP     X2, X3, [SP], #0x10  /* SPSR and ELR. */