Skip to content

Commit

Permalink
xtensa_macros.S: fix tab/space mismatches
Browse files Browse the repository at this point in the history
  • Loading branch information
yamt committed Sep 26, 2024
1 parent d9b95c5 commit 8753d21
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions arch/xtensa/src/common/xtensa_macros.S
Original file line number Diff line number Diff line change
Expand Up @@ -42,32 +42,32 @@
****************************************************************************/

#if !defined(CONFIG_SMP) && CONFIG_ARCH_INTERRUPTSTACK > 15
.macro setintstack tmp1 tmp2
.macro setintstack tmp1 tmp2

/* Load g_intstacktop (the start of the interrupt stack) */

movi \tmp1, g_intstacktop

/* If a1 < g_intstackalloc (outside the interrupt stack boundary),
/* If a1 < g_intstackalloc (outside the interrupt stack boundary),
* set a1 (sp) to g_intstacktop (switch to the interrupt stack).
*/

movi \tmp2, g_intstackalloc /* Load the end (low address) of the interrupt stack */
sub \tmp2, a1, \tmp2
movltz a1, \tmp1, \tmp2
sub \tmp2, a1, \tmp2
movltz a1, \tmp1, \tmp2

/* If a1 >= g_intstacktop, sp is outside the interrupt stack boundaries */
/* If a1 >= g_intstacktop, sp is outside the interrupt stack boundaries */

movi \tmp2, g_intstacktop /* Load the start (high address) of the interrupt stack */
sub \tmp2, a1, \tmp2
movgez a1, \tmp1, \tmp2
sub \tmp2, a1, \tmp2
movgez a1, \tmp1, \tmp2

/* If neither movltz and movgez moved g_intstacktop (on /tmp1) to a1,
* it means that the stack pointer was already pointing to the interrupt
* stack and no action is required.
*/

.endm
.endm
#endif

/****************************************************************************
Expand Down

0 comments on commit 8753d21

Please sign in to comment.