]>
Commit | Line | Data |
---|---|---|
704fbcc2 GKH |
1 | From 7c97301285b62a41d6bceded7d964085fc8cc50f Mon Sep 17 00:00:00 2001 |
2 | From: Nathan Chancellor <natechancellor@gmail.com> | |
3 | Date: Wed, 17 Oct 2018 10:09:02 -0700 | |
4 | Subject: misc: atmel-ssc: Fix section annotation on atmel_ssc_get_driver_data | |
5 | ||
6 | From: Nathan Chancellor <natechancellor@gmail.com> | |
7 | ||
8 | commit 7c97301285b62a41d6bceded7d964085fc8cc50f upstream. | |
9 | ||
10 | After building the kernel with Clang, the following section mismatch | |
11 | warning appears: | |
12 | ||
13 | WARNING: vmlinux.o(.text+0x3bf19a6): Section mismatch in reference from | |
14 | the function ssc_probe() to the function | |
15 | .init.text:atmel_ssc_get_driver_data() | |
16 | The function ssc_probe() references | |
17 | the function __init atmel_ssc_get_driver_data(). | |
18 | This is often because ssc_probe lacks a __init | |
19 | annotation or the annotation of atmel_ssc_get_driver_data is wrong. | |
20 | ||
21 | Remove __init from atmel_ssc_get_driver_data to get rid of the mismatch. | |
22 | ||
23 | Signed-off-by: Nathan Chancellor <natechancellor@gmail.com> | |
24 | Cc: stable <stable@vger.kernel.org> | |
25 | Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | |
26 | ||
27 | --- | |
28 | drivers/misc/atmel-ssc.c | 2 +- | |
29 | 1 file changed, 1 insertion(+), 1 deletion(-) | |
30 | ||
31 | --- a/drivers/misc/atmel-ssc.c | |
32 | +++ b/drivers/misc/atmel-ssc.c | |
33 | @@ -129,7 +129,7 @@ static const struct of_device_id atmel_s | |
34 | MODULE_DEVICE_TABLE(of, atmel_ssc_dt_ids); | |
35 | #endif | |
36 | ||
37 | -static inline const struct atmel_ssc_platform_data * __init | |
38 | +static inline const struct atmel_ssc_platform_data * | |
39 | atmel_ssc_get_driver_data(struct platform_device *pdev) | |
40 | { | |
41 | if (pdev->dev.of_node) { |