aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64/kernel/winfixup.S
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sparc64/kernel/winfixup.S')
-rw-r--r--arch/sparc64/kernel/winfixup.S21
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/sparc64/kernel/winfixup.S b/arch/sparc64/kernel/winfixup.S
index 74a06bef748b6..ca9891a8dad82 100644
--- a/arch/sparc64/kernel/winfixup.S
+++ b/arch/sparc64/kernel/winfixup.S
@@ -93,6 +93,13 @@ fill_fixup:
wrpr %l1, (PSTATE_IE | PSTATE_AG | PSTATE_RMO), %pstate
mov %o7, %g6
ldx [%g6 + TI_TASK], %g4
+#ifdef CONFIG_SMP
+ ldub [%g6 + TI_CPU], %g1
+ sethi %hi(__per_cpu_offset), %g2
+ or %g2, %lo(__per_cpu_offset), %g2
+ sllx %g1, 3, %g1
+ ldx [%g2 + %g1], %g5
+#endif
/* This is the same as below, except we handle this a bit special
* since we must preserve %l5 and %l6, see comment above.
@@ -213,6 +220,13 @@ fill_fixup_mna:
wrpr %l1, (PSTATE_IE | PSTATE_AG | PSTATE_RMO), %pstate
mov %o7, %g6 ! Get current back.
ldx [%g6 + TI_TASK], %g4 ! Finish it.
+#ifdef CONFIG_SMP
+ ldub [%g6 + TI_CPU], %g1
+ sethi %hi(__per_cpu_offset), %g2
+ or %g2, %lo(__per_cpu_offset), %g2
+ sllx %g1, 3, %g1
+ ldx [%g2 + %g1], %g5
+#endif
call mem_address_unaligned
add %sp, PTREGS_OFF, %o0
@@ -318,6 +332,13 @@ fill_fixup_dax:
wrpr %l1, (PSTATE_IE | PSTATE_AG | PSTATE_RMO), %pstate
mov %o7, %g6 ! Get current back.
ldx [%g6 + TI_TASK], %g4 ! Finish it.
+#ifdef CONFIG_SMP
+ ldub [%g6 + TI_CPU], %g1
+ sethi %hi(__per_cpu_offset), %g2
+ or %g2, %lo(__per_cpu_offset), %g2
+ sllx %g1, 3, %g1
+ ldx [%g2 + %g1], %g5
+#endif
call data_access_exception
add %sp, PTREGS_OFF, %o0