mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-21 00:42:16 +00:00
ARM: prima2: use machine specific hook for late init
Signed-off-by: Shawn Guo <shawn.guo@linaro.org> Reviewed-by: Barry Song <baohua.song@csr.com>
This commit is contained in:
parent
cafa61907c
commit
a4b4674e26
@ -24,4 +24,10 @@ static inline void sirfsoc_map_lluart(void) {}
|
||||
extern void __init sirfsoc_map_lluart(void);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_SUSPEND
|
||||
extern int sirfsoc_pm_init(void);
|
||||
#else
|
||||
static inline int sirfsoc_pm_init(void) { return 0; }
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
@ -85,12 +85,11 @@ static const struct platform_suspend_ops sirfsoc_pm_ops = {
|
||||
.valid = suspend_valid_only_mem,
|
||||
};
|
||||
|
||||
static int __init sirfsoc_pm_init(void)
|
||||
int __init sirfsoc_pm_init(void)
|
||||
{
|
||||
suspend_set_ops(&sirfsoc_pm_ops);
|
||||
return 0;
|
||||
}
|
||||
late_initcall(sirfsoc_pm_init);
|
||||
|
||||
static const struct of_device_id pwrc_ids[] = {
|
||||
{ .compatible = "sirf,prima2-pwrc" },
|
||||
|
@ -25,6 +25,11 @@ void __init sirfsoc_mach_init(void)
|
||||
of_platform_bus_probe(NULL, sirfsoc_of_bus_ids, NULL);
|
||||
}
|
||||
|
||||
void __init sirfsoc_init_late(void)
|
||||
{
|
||||
sirfsoc_pm_init();
|
||||
}
|
||||
|
||||
static const char *prima2cb_dt_match[] __initdata = {
|
||||
"sirf,prima2-cb",
|
||||
NULL
|
||||
@ -39,6 +44,7 @@ MACHINE_START(PRIMA2_EVB, "prima2cb")
|
||||
.timer = &sirfsoc_timer,
|
||||
.dma_zone_size = SZ_256M,
|
||||
.init_machine = sirfsoc_mach_init,
|
||||
.init_late = sirfsoc_init_late,
|
||||
.dt_compat = prima2cb_dt_match,
|
||||
.restart = sirfsoc_restart,
|
||||
MACHINE_END
|
||||
|
Loading…
Reference in New Issue
Block a user