@@ -77,6 +77,13 @@ static inline int omap4_pm_init_early(void)
}
#endif
+#if defined(CONFIG_PM) && (defined(CONFIG_SOC_AM33XX) || \
+ defined(CONFIG_SOC_AM43XX))
+void amx3_common_pm_init(void);
+#else
+static inline void amx3_common_pm_init(void) { }
+#endif
+
extern void omap2_init_common_infrastructure(void);
extern void omap_init_time(void);
@@ -652,6 +652,7 @@ void __init am33xx_init_early(void)
void __init am33xx_init_late(void)
{
omap_common_late_init();
+ amx3_common_pm_init();
}
#endif
@@ -676,6 +677,7 @@ void __init am43xx_init_late(void)
{
omap_common_late_init();
omap2_clk_enable_autoidle_all();
+ amx3_common_pm_init();
}
#endif
@@ -179,3 +179,15 @@ struct am33xx_pm_platform_data *am33xx_pm_get_pdata(void)
else
return NULL;
}
+
+void __init amx3_common_pm_init(void)
+{
+ struct platform_device_info devinfo = { };
+ struct am33xx_pm_platform_data *pdata;
+
+ pdata = am33xx_pm_get_pdata();
+ devinfo.name = "pm33xx";
+ devinfo.data = pdata;
+ devinfo.size_data = sizeof(*pdata);
+ platform_device_register_full(&devinfo);
+}
Add amx3_common_pm_init to create a dummy platform_device for pm33xx so that our pm33xx module can probe and am335x and am437x platforms to enable basic suspend to mem and standby support. Signed-off-by: Dave Gerlach <d-gerlach@ti.com> --- arch/arm/mach-omap2/common.h | 7 +++++++ arch/arm/mach-omap2/io.c | 2 ++ arch/arm/mach-omap2/pm33xx-core.c | 12 ++++++++++++ 3 files changed, 21 insertions(+)