diff options
author | Max Filippov <jcmvbkbc@gmail.com> | 2015-09-24 23:11:53 +0300 |
---|---|---|
committer | Max Filippov <jcmvbkbc@gmail.com> | 2015-11-02 18:02:47 +0300 |
commit | 5029615e25dc5040beb065f36743c127a8e51497 (patch) | |
tree | 8b77e020c58e01175587f5267ab9ab8b223c3652 /arch/xtensa/lib | |
parent | 6a13feb9c82803e2b815eca72fa7a9f5561d7861 (diff) | |
download | op-kernel-dev-5029615e25dc5040beb065f36743c127a8e51497.zip op-kernel-dev-5029615e25dc5040beb065f36743c127a8e51497.tar.gz |
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/lib')
-rw-r--r-- | arch/xtensa/lib/usercopy.S | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/xtensa/lib/usercopy.S b/arch/xtensa/lib/usercopy.S index ace1892..7ea4dd6 100644 --- a/arch/xtensa/lib/usercopy.S +++ b/arch/xtensa/lib/usercopy.S @@ -222,8 +222,8 @@ __xtensa_copy_user: loopnez a7, .Loop2done #else /* !XCHAL_HAVE_LOOPS */ beqz a7, .Loop2done - slli a10, a7, 4 - add a10, a10, a3 # a10 = end of last 16B source chunk + slli a12, a7, 4 + add a12, a12, a3 # a12 = end of last 16B source chunk #endif /* !XCHAL_HAVE_LOOPS */ .Loop2: EX(l32i, a7, a3, 4, l_fixup) @@ -241,7 +241,7 @@ __xtensa_copy_user: EX(s32i, a9, a5, 12, s_fixup) addi a5, a5, 16 #if !XCHAL_HAVE_LOOPS - blt a3, a10, .Loop2 + blt a3, a12, .Loop2 #endif /* !XCHAL_HAVE_LOOPS */ .Loop2done: bbci.l a4, 3, .L12 |