diff mbox series

[1/7] tests/tcg/xtensa: fix build for cores without windowed registers

Message ID 20220427172140.1406059-2-jcmvbkbc@gmail.com
State New
Headers show
Series tests/tcg/xtensa: test fixes and improvements | expand

Commit Message

Max Filippov April 27, 2022, 5:21 p.m. UTC
Don't try to initialize windowbase/windowstart in crt.S if they don't
exist.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
---
 tests/tcg/xtensa/crt.S | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/tests/tcg/xtensa/crt.S b/tests/tcg/xtensa/crt.S
index d9846acace90..909872cd3853 100644
--- a/tests/tcg/xtensa/crt.S
+++ b/tests/tcg/xtensa/crt.S
@@ -8,10 +8,12 @@ 
 .text
 .global _start
 _start:
+#if XCHAL_HAVE_WINDOWED
     movi    a2, 1
     wsr     a2, windowstart
     movi    a2, 0
     wsr     a2, windowbase
+#endif
     movi    a1, _fstack
     movi    a2, 0x4000f
     wsr     a2, ps