]> git.karo-electronics.de Git - linux-beck.git/commitdiff
ARM: at91: sam9: set arm_pm_idle from sam9_dt_device_init
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>
Thu, 15 Jan 2015 21:58:08 +0000 (22:58 +0100)
committerNicolas Ferre <nicolas.ferre@atmel.com>
Mon, 26 Jan 2015 12:43:34 +0000 (13:43 +0100)
As all sam9 SoCs are setting arm_pm_idle to at91sam9_idle(), do it from
sam9_dt_device_init().

Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Suggested-by: Arnd Bergmann <arnd@arndb.de>
[nicolas.ferre@atmel.com: adapt patch to newer series]
Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
arch/arm/mach-at91/at91sam9260.c
arch/arm/mach-at91/at91sam9261.c
arch/arm/mach-at91/at91sam9263.c
arch/arm/mach-at91/at91sam9g45.c
arch/arm/mach-at91/at91sam9n12.c
arch/arm/mach-at91/at91sam9rl.c
arch/arm/mach-at91/at91sam9x5.c
arch/arm/mach-at91/board-dt-sam9.c

index ab9841c8b0d5d544b9caae7009edd6cc4fb25d56..37b7ce4c6a3b182ea3c8f5d673cb320983edbd1b 100644 (file)
  *  AT91SAM9260 processor initialization
  * -------------------------------------------------------------------- */
 
-static void __init at91sam9260_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
-
 AT91_SOC_START(at91sam9260)
-       .init = at91sam9260_initialize,
 AT91_SOC_END
index 2029096b93fa925b1c8508e3c44eb5762a88c82d..aebbf76b6038110b5c93fa1cd1b1761abe293c24 100644 (file)
  *  AT91SAM9261 processor initialization
  * -------------------------------------------------------------------- */
 
-static void __init at91sam9261_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
-
 AT91_SOC_START(at91sam9261)
-       .init = at91sam9261_initialize,
 AT91_SOC_END
index 1fe672a055139ac757d605177178cd4551a52145..dca29457d9cc9f61533f79f76817735804b447c6 100644 (file)
  *  AT91SAM9263 processor initialization
  * -------------------------------------------------------------------- */
 
-static void __init at91sam9263_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
-
 AT91_SOC_START(at91sam9263)
-       .init = at91sam9263_initialize,
 AT91_SOC_END
index d0493df40a13b64654410a03587ef32d1215e85a..4957a9ef748a11bf956ece36347d6d3426d72547 100644 (file)
 /* --------------------------------------------------------------------
  *  AT91SAM9G45 processor initialization
  * -------------------------------------------------------------------- */
-static void __init at91sam9g45_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
 
 AT91_SOC_START(at91sam9g45)
-       .init = at91sam9g45_initialize,
 AT91_SOC_END
index 276b8f0e4183d2def0e95430e4b978161cc20b30..b5ea69a3eaf6c2ce2555f325fa35dfed584bbe3e 100644 (file)
 /* --------------------------------------------------------------------
  *  AT91SAM9N12 processor initialization
  * -------------------------------------------------------------------- */
-static void __init at91sam9n12_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
 
 AT91_SOC_START(at91sam9n12)
-       .init = at91sam9n12_initialize,
 AT91_SOC_END
index 33acae30bb0bdbafeba960299c31769cbdf55737..6cb40e4ec20f3565295d0652870ca188fe8fb0e4 100644 (file)
  *  AT91SAM9RL processor initialization
  * -------------------------------------------------------------------- */
 
-static void __init at91sam9rl_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
-
 AT91_SOC_START(at91sam9rl)
-       .init = at91sam9rl_initialize,
 AT91_SOC_END
index 7b6fb1bca5053c92cbfaab32800aff88a850bdaa..7b60a529db0180109ea5fd3a22e9e9ca7edff665 100644 (file)
  *  AT91SAM9x5 processor initialization
  * -------------------------------------------------------------------- */
 
-static void __init at91sam9x5_initialize(void)
-{
-       arm_pm_idle = at91sam9_idle;
-}
-
 AT91_SOC_START(at91sam9x5)
-       .init = at91sam9x5_initialize,
 AT91_SOC_END
index a648d090d74a709957545d1d6e5443bebd4d2f69..8391b9558c2249f2da0ca7a5fcab0b7d220577ef 100644 (file)
@@ -16,6 +16,7 @@
 #include <linux/of_platform.h>
 #include <linux/clk-provider.h>
 
+#include <asm/system_misc.h>
 #include <asm/setup.h>
 #include <asm/irq.h>
 #include <asm/mach/arch.h>
@@ -26,7 +27,9 @@
 
 static void __init sam9_dt_device_init(void)
 {
+       arm_pm_idle = at91sam9_idle;
        at91_sam9260_pm_init();
+
        of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
@@ -45,7 +48,9 @@ MACHINE_END
 
 static void __init sam9g45_dt_device_init(void)
 {
+       arm_pm_idle = at91sam9_idle;
        at91_sam9g45_pm_init();
+
        of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
@@ -64,7 +69,9 @@ MACHINE_END
 
 static void __init sam9x5_dt_device_init(void)
 {
+       arm_pm_idle = at91sam9_idle;
        at91_sam9x5_pm_init();
+
        of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }