summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-davinci/dm644x.c
diff options
context:
space:
mode:
authorManjunath Hadli <manjunath.hadli@ti.com>2011-12-21 19:13:39 +0530
committerSekhar Nori <nsekhar@ti.com>2012-02-25 02:40:25 +0530
commit12db9588ff811ae43a476b1234b27323055ab3ad (patch)
tree6c41d12ca748268d055eb7d4c9183b787db80bbb /arch/arm/mach-davinci/dm644x.c
parent314d7389608831202f5b445d9154e30161935630 (diff)
downloadtalos-op-linux-12db9588ff811ae43a476b1234b27323055ab3ad.tar.gz
talos-op-linux-12db9588ff811ae43a476b1234b27323055ab3ad.zip
ARM: davinci: dm644x: don't force vpfe registeration on all boards
Move all vpfe platform device registrations to the board specific file. This removes registration of vpfe platform devices on boards which do not use vpfe. Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com> Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'arch/arm/mach-davinci/dm644x.c')
-rw-r--r--arch/arm/mach-davinci/dm644x.c27
1 files changed, 15 insertions, 12 deletions
diff --git a/arch/arm/mach-davinci/dm644x.c b/arch/arm/mach-davinci/dm644x.c
index fc48faec57ec..23e81cafba8d 100644
--- a/arch/arm/mach-davinci/dm644x.c
+++ b/arch/arm/mach-davinci/dm644x.c
@@ -659,11 +659,6 @@ static struct platform_device dm644x_vpfe_dev = {
},
};
-void dm644x_set_vpfe_config(struct vpfe_config *cfg)
-{
- dm644x_vpfe_dev.dev.platform_data = cfg;
-}
-
/*----------------------------------------------------------------------*/
static struct map_desc dm644x_io_desc[] = {
@@ -791,14 +786,26 @@ void __init dm644x_init(void)
davinci_map_sysmod();
}
-static int __init dm644x_init_devices(void)
+int __init dm644x_init_video(struct vpfe_config *vpfe_cfg)
{
- if (!cpu_is_davinci_dm644x())
- return 0;
+ dm644x_vpfe_dev.dev.platform_data = vpfe_cfg;
/* Add ccdc clock aliases */
clk_add_alias("master", dm644x_ccdc_dev.name, "vpss_master", NULL);
clk_add_alias("slave", dm644x_ccdc_dev.name, "vpss_slave", NULL);
+
+ platform_device_register(&dm644x_vpss_device);
+ platform_device_register(&dm644x_ccdc_dev);
+ platform_device_register(&dm644x_vpfe_dev);
+
+ return 0;
+}
+
+static int __init dm644x_init_devices(void)
+{
+ if (!cpu_is_davinci_dm644x())
+ return 0;
+
platform_device_register(&dm644x_edma_device);
platform_device_register(&dm644x_mdio_device);
@@ -806,10 +813,6 @@ static int __init dm644x_init_devices(void)
clk_add_alias(NULL, dev_name(&dm644x_mdio_device.dev),
NULL, &dm644x_emac_device.dev);
- platform_device_register(&dm644x_vpss_device);
- platform_device_register(&dm644x_ccdc_dev);
- platform_device_register(&dm644x_vpfe_dev);
-
return 0;
}
postcore_initcall(dm644x_init_devices);
OpenPOWER on IntegriCloud