]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - queue-4.4/mfd-twl-core-fix-section-annotations-on-un-protect_p.patch
drop perf-trace-support-multiple-vfs_getname-probes.patch from 4.4 and 4.9 queues
[thirdparty/kernel/stable-queue.git] / queue-4.4 / mfd-twl-core-fix-section-annotations-on-un-protect_p.patch
1 From 8bb69ecf0c15e9bdbe2d71d9f13e475f7a2dc965 Mon Sep 17 00:00:00 2001
2 From: Nathan Chancellor <natechancellor@gmail.com>
3 Date: Wed, 17 Oct 2018 10:13:23 -0700
4 Subject: mfd: twl-core: Fix section annotations on {,un}protect_pm_master
5
6 [ Upstream commit 8838555089f0345b87f4277fe5a8dd647dc65589 ]
7
8 When building the kernel with Clang, the following section mismatch
9 warning appears:
10
11 WARNING: vmlinux.o(.text+0x3d84a3b): Section mismatch in reference from
12 the function twl_probe() to the function
13 .init.text:unprotect_pm_master()
14 The function twl_probe() references
15 the function __init unprotect_pm_master().
16 This is often because twl_probe lacks a __init
17 annotation or the annotation of unprotect_pm_master is wrong.
18
19 Remove the __init annotation on the *protect_pm_master functions so
20 there is no more mismatch.
21
22 Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
23 Signed-off-by: Lee Jones <lee.jones@linaro.org>
24 Signed-off-by: Sasha Levin <sashal@kernel.org>
25 ---
26 drivers/mfd/twl-core.c | 4 ++--
27 1 file changed, 2 insertions(+), 2 deletions(-)
28
29 diff --git a/drivers/mfd/twl-core.c b/drivers/mfd/twl-core.c
30 index 831696ee2472b..90732a655d573 100644
31 --- a/drivers/mfd/twl-core.c
32 +++ b/drivers/mfd/twl-core.c
33 @@ -982,7 +982,7 @@ add_children(struct twl4030_platform_data *pdata, unsigned irq_base,
34 * letting it generate the right frequencies for USB, MADC, and
35 * other purposes.
36 */
37 -static inline int __init protect_pm_master(void)
38 +static inline int protect_pm_master(void)
39 {
40 int e = 0;
41
42 @@ -991,7 +991,7 @@ static inline int __init protect_pm_master(void)
43 return e;
44 }
45
46 -static inline int __init unprotect_pm_master(void)
47 +static inline int unprotect_pm_master(void)
48 {
49 int e = 0;
50
51 --
52 2.19.1
53