summaryrefslogtreecommitdiffstats
path: root/arch/xtensa/platforms/iss/setup.c
diff options
context:
space:
mode:
authorMax Filippov <jcmvbkbc@gmail.com>2015-09-24 22:11:53 +0200
committerMax Filippov <jcmvbkbc@gmail.com>2015-11-02 16:02:47 +0100
commit5029615e25dc5040beb065f36743c127a8e51497 (patch)
tree8b77e020c58e01175587f5267ab9ab8b223c3652 /arch/xtensa/platforms/iss/setup.c
parentLinux 4.3 (diff)
downloadlinux-5029615e25dc5040beb065f36743c127a8e51497.tar.xz
linux-5029615e25dc5040beb065f36743c127a8e51497.zip
xtensa: fixes for configs without loop option
Build-time fixes: - make lbeg/lend/lcount save/restore conditional on kernel entry; - don't clear lcount in platform_restart functions unconditionally. Run-time fixes: - use correct end of range register in __endla paired with __loopt, not the unused temporary register. This fixes .bss zero-initialization. Update comments in asmmacro.h; - don't clobber a10 in the usercopy that leads to access to unmapped memory. Cc: <stable@vger.kernel.org> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Diffstat (limited to 'arch/xtensa/platforms/iss/setup.c')
-rw-r--r--arch/xtensa/platforms/iss/setup.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/xtensa/platforms/iss/setup.c b/arch/xtensa/platforms/iss/setup.c
index da7d18240866..391820539f0a 100644
--- a/arch/xtensa/platforms/iss/setup.c
+++ b/arch/xtensa/platforms/iss/setup.c
@@ -61,7 +61,9 @@ void platform_restart(void)
#if XCHAL_NUM_IBREAK > 0
"wsr a2, ibreakenable\n\t"
#endif
+#if XCHAL_HAVE_LOOPS
"wsr a2, lcount\n\t"
+#endif
"movi a2, 0x1f\n\t"
"wsr a2, ps\n\t"
"isync\n\t"