misc: atmel-ssc: Fix section annotation on atmel_ssc_get_driver_data
authorNathan Chancellor <natechancellor@gmail.com>
Wed, 17 Oct 2018 17:09:02 +0000 (10:09 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 27 Nov 2018 15:09:41 +0000 (16:09 +0100)
commitf1b4d95e4d43c1582cd457240d3497e20ca523e5
tree37971044024aaca57b0ce61425d49150a8a59390
parent305a97a9db730b7f8dfc8357287a92ea73d01780
misc: atmel-ssc: Fix section annotation on atmel_ssc_get_driver_data

commit 7c97301285b62a41d6bceded7d964085fc8cc50f upstream.

After building the kernel with Clang, the following section mismatch
warning appears:

WARNING: vmlinux.o(.text+0x3bf19a6): Section mismatch in reference from
the function ssc_probe() to the function
.init.text:atmel_ssc_get_driver_data()
The function ssc_probe() references
the function __init atmel_ssc_get_driver_data().
This is often because ssc_probe lacks a __init
annotation or the annotation of atmel_ssc_get_driver_data is wrong.

Remove __init from atmel_ssc_get_driver_data to get rid of the mismatch.

Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/misc/atmel-ssc.c