Skip to content

Commit

Permalink
ARM: exynos: use machine specific hook for late init
Browse files Browse the repository at this point in the history
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Acked-by: Kukjin Kim <kgene.kim@samsung.com>
  • Loading branch information
Shawn Guo committed May 8, 2012
1 parent c914283 commit bb13fab
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 2 deletions.
5 changes: 5 additions & 0 deletions arch/arm/mach-exynos/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,11 @@ void exynos5_restart(char mode, const char *cmd)
__raw_writel(0x1, EXYNOS_SWRESET);
}

void __init exynos_init_late(void)
{
exynos_pm_late_initcall();
}

/*
* exynos_map_io
*
Expand Down
7 changes: 7 additions & 0 deletions arch/arm/mach-exynos/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,13 @@ void exynos4_init_irq(void);
void exynos5_init_irq(void);
void exynos4_restart(char mode, const char *cmd);
void exynos5_restart(char mode, const char *cmd);
void exynos_init_late(void);

#ifdef CONFIG_PM_GENERIC_DOMAINS
int exynos_pm_late_initcall(void);
#else
static int exynos_pm_late_initcall(void) { return 0; }
#endif

#ifdef CONFIG_ARCH_EXYNOS4
void exynos4_register_clocks(void);
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-armlex4210.c
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,7 @@ MACHINE_START(ARMLEX4210, "ARMLEX4210")
.map_io = armlex4210_map_io,
.handle_irq = gic_handle_irq,
.init_machine = armlex4210_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.restart = exynos4_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-exynos4-dt.c
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ DT_MACHINE_START(EXYNOS4210_DT, "Samsung Exynos4 (Flattened Device Tree)")
.map_io = exynos4210_dt_map_io,
.handle_irq = gic_handle_irq,
.init_machine = exynos4210_dt_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.dt_compat = exynos4210_dt_compat,
.restart = exynos4_restart,
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-exynos5-dt.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ DT_MACHINE_START(EXYNOS5_DT, "SAMSUNG EXYNOS5 (Flattened Device Tree)")
.map_io = exynos5250_dt_map_io,
.handle_irq = gic_handle_irq,
.init_machine = exynos5250_dt_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.dt_compat = exynos5250_dt_compat,
.restart = exynos5_restart,
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-nuri.c
Original file line number Diff line number Diff line change
Expand Up @@ -1350,6 +1350,7 @@ MACHINE_START(NURI, "NURI")
.map_io = nuri_map_io,
.handle_irq = gic_handle_irq,
.init_machine = nuri_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.reserve = &nuri_reserve,
.restart = exynos4_restart,
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-origen.c
Original file line number Diff line number Diff line change
Expand Up @@ -735,6 +735,7 @@ MACHINE_START(ORIGEN, "ORIGEN")
.map_io = origen_map_io,
.handle_irq = gic_handle_irq,
.init_machine = origen_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.reserve = &origen_reserve,
.restart = exynos4_restart,
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-smdk4x12.c
Original file line number Diff line number Diff line change
Expand Up @@ -303,6 +303,7 @@ MACHINE_START(SMDK4412, "SMDK4412")
.map_io = smdk4x12_map_io,
.handle_irq = gic_handle_irq,
.init_machine = smdk4x12_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.restart = exynos4_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-smdkv310.c
Original file line number Diff line number Diff line change
Expand Up @@ -393,6 +393,7 @@ MACHINE_START(SMDKC210, "SMDKC210")
.map_io = smdkv310_map_io,
.handle_irq = gic_handle_irq,
.init_machine = smdkv310_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.restart = exynos4_restart,
MACHINE_END
1 change: 1 addition & 0 deletions arch/arm/mach-exynos/mach-universal_c210.c
Original file line number Diff line number Diff line change
Expand Up @@ -1112,6 +1112,7 @@ MACHINE_START(UNIVERSAL_C210, "UNIVERSAL_C210")
.map_io = universal_map_io,
.handle_irq = gic_handle_irq,
.init_machine = universal_machine_init,
.init_late = exynos_init_late,
.timer = &exynos4_timer,
.reserve = &universal_reserve,
.restart = exynos4_restart,
Expand Down
3 changes: 1 addition & 2 deletions arch/arm/mach-exynos/pm_domains.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,8 @@ static __init int exynos4_pm_init_power_domain(void)
}
arch_initcall(exynos4_pm_init_power_domain);

static __init int exynos_pm_late_initcall(void)
int __init exynos_pm_late_initcall(void)
{
pm_genpd_poweroff_unused();
return 0;
}
late_initcall(exynos_pm_late_initcall);

0 comments on commit bb13fab

Please sign in to comment.