ARM: davinci: don't mark da850_register_cpufreq as __init
authorArnd Bergmann <arnd@arndb.de>
Mon, 30 Apr 2012 14:00:15 +0000 (14:00 +0000)
committerArnd Bergmann <arnd@arndb.de>
Sun, 7 Oct 2012 08:33:08 +0000 (10:33 +0200)
The mityomapl138_cpufreq_init and read_factory_config function in
board-mityomapl138.c are not __init functions and might be called
at a later stage, so da850_register_cpufreq must not be __init either.

Without this patch, building da8xx_omapl_defconfig results in:

WARNING: arch/arm/mach-davinci/built-in.o(.text+0x2eb4): Section mismatch in reference from the function read_factory_config() to the function .init.text:da850_register_cpufreq()
The function read_factory_config() references
the function __init da850_register_cpufreq().
This is often because read_factory_config lacks a __init
annotation or the annotation of da850_register_cpufreq is wrong.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Sekhar Nori <nsekhar@ti.com>
Cc: Kevin Hilman <khilman@ti.com>
arch/arm/mach-davinci/da850.c

index b44dc844e15e0c2ce8c404486c75494749dfec51..8329e5b81cf5b6d8b77b0d10be24b0bf064ea4af 100644 (file)
@@ -939,7 +939,7 @@ static struct platform_device da850_cpufreq_device = {
 
 unsigned int da850_max_speed = 300000;
 
-int __init da850_register_cpufreq(char *async_clk)
+int da850_register_cpufreq(char *async_clk)
 {
        int i;