Commit cc8f252b authored by Shawn Guo's avatar Shawn Guo

ARM: s3c64xx: use machine specific hook for late init

Cc: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: default avatarShawn Guo <shawn.guo@linaro.org>
Acked-by: default avatarKukjin Kim <kgene.kim@samsung.com>
parent a4b4674e
...@@ -384,3 +384,8 @@ void s3c64xx_restart(char mode, const char *cmd) ...@@ -384,3 +384,8 @@ void s3c64xx_restart(char mode, const char *cmd)
/* if all else fails, or mode was for soft, jump to 0 */ /* if all else fails, or mode was for soft, jump to 0 */
soft_restart(0); soft_restart(0);
} }
void __init s3c64xx_init_late(void)
{
s3c64xx_pm_late_initcall();
}
...@@ -24,6 +24,7 @@ void s3c64xx_register_clocks(unsigned long xtal, unsigned armclk_limit); ...@@ -24,6 +24,7 @@ void s3c64xx_register_clocks(unsigned long xtal, unsigned armclk_limit);
void s3c64xx_setup_clocks(void); void s3c64xx_setup_clocks(void);
void s3c64xx_restart(char mode, const char *cmd); void s3c64xx_restart(char mode, const char *cmd);
void s3c64xx_init_late(void);
#ifdef CONFIG_CPU_S3C6400 #ifdef CONFIG_CPU_S3C6400
...@@ -51,4 +52,10 @@ extern void s3c6410_init_clocks(int xtal); ...@@ -51,4 +52,10 @@ extern void s3c6410_init_clocks(int xtal);
#define s3c6410_init NULL #define s3c6410_init NULL
#endif #endif
#ifdef CONFIG_PM
int __init s3c64xx_pm_late_initcall(void);
#else
static inline int s3c64xx_pm_late_initcall(void) { return 0; }
#endif
#endif /* __ARCH_ARM_MACH_S3C64XX_COMMON_H */ #endif /* __ARCH_ARM_MACH_S3C64XX_COMMON_H */
...@@ -241,6 +241,7 @@ MACHINE_START(ANW6410, "A&W6410") ...@@ -241,6 +241,7 @@ MACHINE_START(ANW6410, "A&W6410")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = anw6410_map_io, .map_io = anw6410_map_io,
.init_machine = anw6410_machine_init, .init_machine = anw6410_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -811,6 +811,7 @@ MACHINE_START(WLF_CRAGG_6410, "Wolfson Cragganmore 6410") ...@@ -811,6 +811,7 @@ MACHINE_START(WLF_CRAGG_6410, "Wolfson Cragganmore 6410")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = crag6410_map_io, .map_io = crag6410_map_io,
.init_machine = crag6410_machine_init, .init_machine = crag6410_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -272,6 +272,7 @@ MACHINE_START(HMT, "Airgoo-HMT") ...@@ -272,6 +272,7 @@ MACHINE_START(HMT, "Airgoo-HMT")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = hmt_map_io, .map_io = hmt_map_io,
.init_machine = hmt_machine_init, .init_machine = hmt_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -350,6 +350,7 @@ MACHINE_START(MINI6410, "MINI6410") ...@@ -350,6 +350,7 @@ MACHINE_START(MINI6410, "MINI6410")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = mini6410_map_io, .map_io = mini6410_map_io,
.init_machine = mini6410_machine_init, .init_machine = mini6410_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -104,6 +104,7 @@ MACHINE_START(NCP, "NCP") ...@@ -104,6 +104,7 @@ MACHINE_START(NCP, "NCP")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = ncp_map_io, .map_io = ncp_map_io,
.init_machine = ncp_machine_init, .init_machine = ncp_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -331,6 +331,7 @@ MACHINE_START(REAL6410, "REAL6410") ...@@ -331,6 +331,7 @@ MACHINE_START(REAL6410, "REAL6410")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = real6410_map_io, .map_io = real6410_map_io,
.init_machine = real6410_machine_init, .init_machine = real6410_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -152,6 +152,7 @@ MACHINE_START(SMARTQ5, "SmartQ 5") ...@@ -152,6 +152,7 @@ MACHINE_START(SMARTQ5, "SmartQ 5")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = smartq_map_io, .map_io = smartq_map_io,
.init_machine = smartq5_machine_init, .init_machine = smartq5_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -168,6 +168,7 @@ MACHINE_START(SMARTQ7, "SmartQ 7") ...@@ -168,6 +168,7 @@ MACHINE_START(SMARTQ7, "SmartQ 7")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = smartq_map_io, .map_io = smartq_map_io,
.init_machine = smartq7_machine_init, .init_machine = smartq7_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -93,6 +93,7 @@ MACHINE_START(SMDK6400, "SMDK6400") ...@@ -93,6 +93,7 @@ MACHINE_START(SMDK6400, "SMDK6400")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = smdk6400_map_io, .map_io = smdk6400_map_io,
.init_machine = smdk6400_machine_init, .init_machine = smdk6400_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -709,6 +709,7 @@ MACHINE_START(SMDK6410, "SMDK6410") ...@@ -709,6 +709,7 @@ MACHINE_START(SMDK6410, "SMDK6410")
.handle_irq = vic_handle_irq, .handle_irq = vic_handle_irq,
.map_io = smdk6410_map_io, .map_io = smdk6410_map_io,
.init_machine = smdk6410_machine_init, .init_machine = smdk6410_machine_init,
.init_late = s3c64xx_init_late,
.timer = &s3c24xx_timer, .timer = &s3c24xx_timer,
.restart = s3c64xx_restart, .restart = s3c64xx_restart,
MACHINE_END MACHINE_END
...@@ -365,10 +365,9 @@ static __init int s3c64xx_pm_initcall(void) ...@@ -365,10 +365,9 @@ static __init int s3c64xx_pm_initcall(void)
} }
arch_initcall(s3c64xx_pm_initcall); arch_initcall(s3c64xx_pm_initcall);
static __init int s3c64xx_pm_late_initcall(void) int __init s3c64xx_pm_late_initcall(void)
{ {
pm_genpd_poweroff_unused(); pm_genpd_poweroff_unused();
return 0; return 0;
} }
late_initcall(s3c64xx_pm_late_initcall);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment