microblaze: Separate GP registers from MSR handling
authorMichal Simek <michal.simek@xilinx.com>
Wed, 24 Feb 2016 10:31:14 +0000 (11:31 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Thu, 22 Jun 2017 13:36:59 +0000 (15:36 +0200)
Separate general purpose register restoring from MSR handling.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
arch/microblaze/kernel/entry.S

index ef548510b951b306d7b70cb941d08dc0dec3e4dd..285e8880e274df8ecfd209bf101cff1cbc5ff1f7 100644 (file)
@@ -208,9 +208,7 @@ syscall_debug_table:
        mfs     r11, rmsr;              /* save MSR */                  \
        swi     r11, r1, PT_MSR;
 
-#define RESTORE_REGS \
-       lwi     r11, r1, PT_MSR;                                        \
-       mts     rmsr , r11;                                             \
+#define RESTORE_REGS_GP \
        lwi     r2, r1, PT_R2;  /* restore SDA */               \
        lwi     r3, r1, PT_R3;                                  \
        lwi     r4, r1, PT_R4;                                  \
@@ -242,6 +240,11 @@ syscall_debug_table:
        lwi     r30, r1, PT_R30;                                        \
        lwi     r31, r1, PT_R31;        /* Restore cur task reg */
 
+#define RESTORE_REGS \
+       lwi     r11, r1, PT_MSR;                                        \
+       mts     rmsr , r11;                                             \
+       RESTORE_REGS_GP
+
 #define SAVE_STATE     \
        swi     r1, r0, TOPHYS(PER_CPU(ENTRY_SP)); /* save stack */     \
        /* See if already in kernel mode.*/                             \