提交 825c9a35 编写于 作者: S steve@digidescorp.com 提交者: Michal Simek

microblaze: nommu: Don't clobber R11 on syscalls

The noMMU syscall trap has a bug that causes R11 to be zero on return to
userland. Remove the extra "save" of R11 responsible for the bug.

Remove reloading of mode indicator because r11 already contains it.
Signed-off-by: NSteven J. Magnani <steve@digidescorp.com>
Signed-off-by: NMichal Simek <monstr@monstr.eu>
上级 233eb921
...@@ -208,8 +208,6 @@ ENTRY(_user_exception) ...@@ -208,8 +208,6 @@ ENTRY(_user_exception)
lwi r1, r1, TS_THREAD_INFO /* get the thread info */ lwi r1, r1, TS_THREAD_INFO /* get the thread info */
/* calculate kernel stack pointer */ /* calculate kernel stack pointer */
addik r1, r1, THREAD_SIZE - PT_SIZE addik r1, r1, THREAD_SIZE - PT_SIZE
swi r11, r0, PER_CPU(R11_SAVE) /* temporarily save r11 */
lwi r11, r0, PER_CPU(KM) /* load mode indicator */
2: 2:
swi r11, r1, PT_MODE /* store the mode */ swi r11, r1, PT_MODE /* store the mode */
lwi r11, r0, PER_CPU(R11_SAVE) /* reload r11 */ lwi r11, r0, PER_CPU(R11_SAVE) /* reload r11 */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册