[Trusty SRU] Fix boot regression on ppc64el
Stefan Bader
stefan.bader at canonical.com
Tue Jun 7 10:34:10 UTC 2016
Trusty kernels fail to boot since 3.13.0-46 which we unfortunately
missed to notice. The following patch was tested on modoc and with
it applied I could boot a recent 3.13 again.
-Stefan
>From b8df8969362843787d357b09d49de38111790fb2 Mon Sep 17 00:00:00 2001
From: Stefan Bader <stefan.bader at canonical.com>
Date: Mon, 6 Jun 2016 18:22:40 +0200
Subject: [PATCH] powerpc/powernv: Fix incomplete backport of 8117ac6
The backport of commit 8117ac6 upstream
powerpc/powernv: Switch off MMU before entering nap/sleep/rvwinkle mode
missed some subtle change in the way a global label was declared which
will load the address of a symbol table instead of the function address
into a register and then uses that as a jump target.
However this requires one more adaptions due to the fact that the
_GLOBAL macro depending on config expands into a special combination
of symbol name and dot symbol name. And the dot symbol name is referred
to from arch/powerpc/kernel/exceptions-64s.S.
Many of those dot symbol references where removed (likely before 8117ac6)
in commit b1576fec7f4dd4657694fefc97fda4cf28ec68e9
Author: Anton Blanchard <anton at samba.org>
powerpc: No need to use dot symbols when branching to a function
So I remove the dot reference for that one instance as removing
the _GLOBAL macro also removes the implicit dot name and only
leaves a simple jump label.
BugLink: http://bugs.launchpad.net/bugs/1589910
Signed-off-by: Stefan Bader <stefan.bader at canonical.com>
---
arch/powerpc/kernel/exceptions-64s.S | 2 +-
arch/powerpc/kernel/idle_power7.S | 3 ++-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/kernel/exceptions-64s.S b/arch/powerpc/kernel/exceptions-64s.S
index 4c34c3c..a113575 100644
--- a/arch/powerpc/kernel/exceptions-64s.S
+++ b/arch/powerpc/kernel/exceptions-64s.S
@@ -1414,7 +1414,7 @@ machine_check_handle_early:
MACHINE_CHECK_HANDLER_WINDUP
GET_PACA(r13)
ld r1,PACAR1(r13)
- b .power7_enter_nap_mode
+ b power7_enter_nap_mode
4:
#endif
/*
diff --git a/arch/powerpc/kernel/idle_power7.S b/arch/powerpc/kernel/idle_power7.S
index e435445..6140e71 100644
--- a/arch/powerpc/kernel/idle_power7.S
+++ b/arch/powerpc/kernel/idle_power7.S
@@ -99,7 +99,8 @@ _GLOBAL(power7_nap)
mtspr SPRN_SRR1, r5
rfid
-_GLOBAL(power7_enter_nap_mode)
+ .globl power7_enter_nap_mode
+power7_enter_nap_mode:
#ifdef CONFIG_KVM_BOOK3S_HV_POSSIBLE
/* Tell KVM we're napping */
li r4,KVM_HWTHREAD_IN_NAP
--
1.9.1
More information about the kernel-team
mailing list