aboutsummaryrefslogtreecommitdiffstats
path: root/arch/microblaze/kernel/entry.S
diff options
context:
space:
mode:
authorMichal Simek <monstr@monstr.eu>2010-02-22 07:24:43 -0500
committerMichal Simek <monstr@monstr.eu>2010-03-11 08:25:54 -0500
commit8633bebc63ba5752254925f8b49a19102df1a0ff (patch)
tree3b86a4b83255a33f6a12f00974e440c414c9b284 /arch/microblaze/kernel/entry.S
parentb1d70c62fff3e8b6224699801c610c244882685a (diff)
microblaze: Save current task directly
Signed-off-by: Michal Simek <monstr@monstr.eu>
Diffstat (limited to 'arch/microblaze/kernel/entry.S')
-rw-r--r--arch/microblaze/kernel/entry.S12
1 files changed, 4 insertions, 8 deletions
diff --git a/arch/microblaze/kernel/entry.S b/arch/microblaze/kernel/entry.S
index 772fe7415f82..cc9885d441d5 100644
--- a/arch/microblaze/kernel/entry.S
+++ b/arch/microblaze/kernel/entry.S
@@ -425,8 +425,7 @@ C_ENTRY(ret_from_trap):
425 lwi r4, r1, PTO + PT_R4; 425 lwi r4, r1, PTO + PT_R4;
426 426
427 swi r0, r0, PER_CPU(KM); /* Now officially in user state. */ 427 swi r0, r0, PER_CPU(KM); /* Now officially in user state. */
428 add r11, r0, CURRENT_TASK; /* Get current task ptr into r11 */ 428 swi CURRENT_TASK, r0, PER_CPU(CURRENT_SAVE); /* save current */
429 swi r11, r0, PER_CPU(CURRENT_SAVE); /* save current */
430 VM_OFF; 429 VM_OFF;
431 tophys(r1,r1); 430 tophys(r1,r1);
432 RESTORE_REGS; 431 RESTORE_REGS;
@@ -700,8 +699,7 @@ C_ENTRY(ret_from_exc):
700 699
701/* Finally, return to user state. */ 700/* Finally, return to user state. */
7021: swi r0, r0, PER_CPU(KM); /* Now officially in user state. */ 7011: swi r0, r0, PER_CPU(KM); /* Now officially in user state. */
703 add r11, r0, CURRENT_TASK; /* Get current task ptr into r11 */ 702 swi CURRENT_TASK, r0, PER_CPU(CURRENT_SAVE); /* save current */
704 swi r11, r0, PER_CPU(CURRENT_SAVE); /* save current */
705 VM_OFF; 703 VM_OFF;
706 tophys(r1,r1); 704 tophys(r1,r1);
707 705
@@ -828,8 +826,7 @@ no_intr_resched:
828 /* Disable interrupts, we are now committed to the state restore */ 826 /* Disable interrupts, we are now committed to the state restore */
829 disable_irq 827 disable_irq
830 swi r0, r0, PER_CPU(KM); /* MS: Now officially in user state. */ 828 swi r0, r0, PER_CPU(KM); /* MS: Now officially in user state. */
831 add r11, r0, CURRENT_TASK; 829 swi CURRENT_TASK, r0, PER_CPU(CURRENT_SAVE);
832 swi r11, r0, PER_CPU(CURRENT_SAVE);
833 VM_OFF; 830 VM_OFF;
834 tophys(r1,r1); 831 tophys(r1,r1);
835 lwi r3, r1, PTO + PT_R3; /* MS: restore saved r3, r4 registers */ 832 lwi r3, r1, PTO + PT_R3; /* MS: restore saved r3, r4 registers */
@@ -979,8 +976,7 @@ dbtrap_call: rtbd r11, 0;
979 976
980/* Finally, return to user state. */ 977/* Finally, return to user state. */
9811: swi r0, r0, PER_CPU(KM); /* Now officially in user state. */ 9781: swi r0, r0, PER_CPU(KM); /* Now officially in user state. */
982 add r11, r0, CURRENT_TASK; /* Get current task ptr into r11 */ 979 swi CURRENT_TASK, r0, PER_CPU(CURRENT_SAVE); /* save current */
983 swi r11, r0, PER_CPU(CURRENT_SAVE); /* save current */
984 VM_OFF; 980 VM_OFF;
985 tophys(r1,r1); 981 tophys(r1,r1);
986 982