Patch "ARM: pxa: remove incorrect __init annotation on pxa27x_set_pwrmode" has been added to the 4.2-stable tree
Subsystems (4)
This is a note to let you know that I've just added the patch titled
ARM: pxa: remove incorrect __init annotation on pxa27x_set_pwrmode
to the 4.2-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
arm-pxa-remove-incorrect-__init-annotation-on-pxa27x_set_pwrmode.patch
and it can be found in the queue-4.2 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
54c09889bff6d99c8733eed4a26c9391b177c88bMon Sep 17 00:00:00 2001
From: Arnd Bergmann <[email protected]>
Date: Mon, 12 Oct 2015 15:46:08 +0200
Subject: ARM: pxa: remove incorrect __init annotation on pxa27x_set_pwrmode
From: Arnd Bergmann <[email protected]>
commit 54c09889bff6d99c8733eed4a26c9391b177c88b upstream.
The z2 machine calls pxa27x_set_pwrmode() in order to power off the machine, but this function gets discarded early at boot because it is marked __init, as pointed out by kbuild:
WARNING: vmlinux.o(.text+0x145c4): Section mismatch in reference from the function z2_power_off() to the function .init.text:pxa27x_set_pwrmode() The function z2_power_off() references
the function __init pxa27x_set_pwrmode().
This is often because z2_power_off lacks a __init
annotation or the annotation of pxa27x_set_pwrmode is wrong.
This removes the __init section modifier to fix rebooting and the build error.
--- arch/arm/mach-pxa/include/mach/pxa27x.h | 2 +- arch/arm/mach-pxa/pxa27x.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/mach-pxa/include/mach/pxa27x.h +1 -1
@@ -19,7 +19,7 @@#define ARB_CORE_PARK (1<<24)/* Be parked with core when idle */ #define ARB_LOCK_FLAG (1<<23)/* Only Locking masters gain access to the bus */ -extern int __init pxa27x_set_pwrmode (unsigned int mode); +extern int pxa27x_set_pwrmode (unsigned int mode);extern void pxa27x_cpu_pm_enter (suspend_state_t state);#endif /* __MACH_PXA27x_H */
arch/arm/mach-pxa/pxa27x.c +1 -1
@@ -84,7 +84,7 @@ EXPORT_SYMBOL_GPL(pxa27x_configure_ac97r*/ static unsigned int pwrmode =PWRMODE_SLEEP ; -int __init pxa27x_set_pwrmode (unsigned int mode) +int pxa27x_set_pwrmode (unsigned int mode) {switch (mode) {case PWRMODE_SLEEP :
Patches currently in stable-queue which might be from [email protected] are
queue-4.2/arm-pxa-remove-incorrect-__init-annotation-on-pxa27x_set_pwrmode.patch