mirror of https://gitee.com/openkylin/linux.git
ARM: highbank: call highbank_pm_init from .init_machine
Being a module_init call, highbank_pm_init will cause problem with multi-platform build running on other platforms. Call it from .init_machine instead. Reported-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Rob Herring <rob.herring@calxeda.com> Signed-off-by: Olof Johansson <olof@lixom.net>
This commit is contained in:
parent
85594df2ba
commit
a283580c52
|
@ -8,4 +8,10 @@ extern void highbank_lluart_map_io(void);
|
||||||
static inline void highbank_lluart_map_io(void) {}
|
static inline void highbank_lluart_map_io(void) {}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM_SLEEP
|
||||||
|
extern void highbank_pm_init(void);
|
||||||
|
#else
|
||||||
|
static inline void highbank_pm_init(void) {}
|
||||||
|
#endif
|
||||||
|
|
||||||
extern void highbank_smc1(int fn, int arg);
|
extern void highbank_smc1(int fn, int arg);
|
||||||
|
|
|
@ -152,6 +152,7 @@ static void highbank_power_off(void)
|
||||||
static void __init highbank_init(void)
|
static void __init highbank_init(void)
|
||||||
{
|
{
|
||||||
pm_power_off = highbank_power_off;
|
pm_power_off = highbank_power_off;
|
||||||
|
highbank_pm_init();
|
||||||
|
|
||||||
of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
|
of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,9 +47,7 @@ static const struct platform_suspend_ops highbank_pm_ops = {
|
||||||
.valid = suspend_valid_only_mem,
|
.valid = suspend_valid_only_mem,
|
||||||
};
|
};
|
||||||
|
|
||||||
static int __init highbank_pm_init(void)
|
void __init highbank_pm_init(void)
|
||||||
{
|
{
|
||||||
suspend_set_ops(&highbank_pm_ops);
|
suspend_set_ops(&highbank_pm_ops);
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
module_init(highbank_pm_init);
|
|
||||||
|
|
Loading…
Reference in New Issue