xtensa_context.S: A1 should be restored by the caller not

xtensa_context_resotred. Here it was being restored twice.
Remove the one in xtensa_context_restore.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
This commit is contained in:
Abdelatif Guettouche 2022-03-11 16:23:57 +01:00 committed by Xiang Xiao
parent 5bd2e97a27
commit 2dcbf28f15
2 changed files with 1 additions and 2 deletions

View File

@ -279,7 +279,6 @@ _xtensa_context_restore:
l32i a3, a2, (4 * REG_SAR)
wsr a3, SAR
l32i sp, a2, (4 * REG_A1)
l32i a3, a2, (4 * REG_A3)
l32i a4, a2, (4 * REG_A4)
l32i a5, a2, (4 * REG_A5)

View File

@ -353,7 +353,7 @@ _xtensa_level1_handler:
l32i a0, a2, (4 * REG_PC) /* Retrieve interruptee's PC */
wsr a0, EPC_1
l32i a0, a2, (4 * REG_A0) /* Retrieve interruptee's A0 */
l32i sp, a2, (4 * REG_A1) /* Remove interrupt stack frame */
l32i sp, a2, (4 * REG_A1) /* Retrieve interrupt stack frame */
l32i a2, a2, (4 * REG_A2) /* Retrieve interruptee's A2 */
rsync /* Ensure PS and EPC written */