diff options
author | Tony Lindgren <tony@atomide.com> | 2013-09-25 15:44:39 -0700 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2013-09-25 15:44:39 -0700 |
commit | 3e7a318530c3d536972e9a2bb44e0ce0c16eaa4e (patch) | |
tree | 9060eab9a327d78b1e9474e3839bab00fc0b3514 /arch/arm/mach-omap2/pdata-quirks.c | |
parent | 6a08e1e6f7fafa2fa5fb6a129c4c8d9c29f11b62 (diff) | |
download | blackbird-op-linux-3e7a318530c3d536972e9a2bb44e0ce0c16eaa4e.tar.gz blackbird-op-linux-3e7a318530c3d536972e9a2bb44e0ce0c16eaa4e.zip |
ARM: OMAP2+: Use pdata quirk support for board-generic.c
Let's use platform data quirk support for board-generic.c.
This removes all board specific hacks out of board-generic.c.
Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/mach-omap2/pdata-quirks.c')
-rw-r--r-- | arch/arm/mach-omap2/pdata-quirks.c | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/pdata-quirks.c b/arch/arm/mach-omap2/pdata-quirks.c index e6051998f929..648d9573aaea 100644 --- a/arch/arm/mach-omap2/pdata-quirks.c +++ b/arch/arm/mach-omap2/pdata-quirks.c @@ -20,7 +20,48 @@ struct pdata_init { void (*fn)(void); }; +/* + * Create alias for USB host PHY clock. + * Remove this when clock phandle can be provided via DT + */ +static void __init __used legacy_init_ehci_clk(char *clkname) +{ + int ret; + + ret = clk_add_alias("main_clk", NULL, clkname, NULL); + if (ret) + pr_err("%s:Failed to add main_clk alias to %s :%d\n", + __func__, clkname, ret); +} + +#ifdef CONFIG_ARCH_OMAP4 +static void __init omap4_sdp_legacy_init(void) +{ + omap_4430sdp_display_init_of(); +} + +static void __init omap4_panda_legacy_init(void) +{ + omap4_panda_display_init_of(); + legacy_init_ehci_clk("auxclk3_ck"); +} +#endif + +#ifdef CONFIG_SOC_OMAP5 +static void __init omap5_uevm_legacy_init(void) +{ + legacy_init_ehci_clk("auxclk1_ck"); +} +#endif + static struct pdata_init pdata_quirks[] __initdata = { +#ifdef CONFIG_ARCH_OMAP4 + { "ti,omap4-sdp", omap4_sdp_legacy_init, }, + { "ti,omap4-panda", omap4_panda_legacy_init, }, +#endif +#ifdef CONFIG_SOC_OMAP5 + { "ti,omap5-uevm", omap5_uevm_legacy_init, }, +#endif { /* sentinel */ }, }; |