diff options
author | Manjunath Hadli <manjunath.hadli@ti.com> | 2011-12-21 08:43:39 -0500 |
---|---|---|
committer | Sekhar Nori <nsekhar@ti.com> | 2012-02-24 16:10:25 -0500 |
commit | 12db9588ff811ae43a476b1234b27323055ab3ad (patch) | |
tree | 6c41d12ca748268d055eb7d4c9183b787db80bbb /arch/arm/mach-davinci/dm644x.c | |
parent | 314d7389608831202f5b445d9154e30161935630 (diff) |
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.c | 27 |
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 = { | |||
659 | }, | 659 | }, |
660 | }; | 660 | }; |
661 | 661 | ||
662 | void dm644x_set_vpfe_config(struct vpfe_config *cfg) | ||
663 | { | ||
664 | dm644x_vpfe_dev.dev.platform_data = cfg; | ||
665 | } | ||
666 | |||
667 | /*----------------------------------------------------------------------*/ | 662 | /*----------------------------------------------------------------------*/ |
668 | 663 | ||
669 | static struct map_desc dm644x_io_desc[] = { | 664 | static struct map_desc dm644x_io_desc[] = { |
@@ -791,14 +786,26 @@ void __init dm644x_init(void) | |||
791 | davinci_map_sysmod(); | 786 | davinci_map_sysmod(); |
792 | } | 787 | } |
793 | 788 | ||
794 | static int __init dm644x_init_devices(void) | 789 | int __init dm644x_init_video(struct vpfe_config *vpfe_cfg) |
795 | { | 790 | { |
796 | if (!cpu_is_davinci_dm644x()) | 791 | dm644x_vpfe_dev.dev.platform_data = vpfe_cfg; |
797 | return 0; | ||
798 | 792 | ||
799 | /* Add ccdc clock aliases */ | 793 | /* Add ccdc clock aliases */ |
800 | clk_add_alias("master", dm644x_ccdc_dev.name, "vpss_master", NULL); | 794 | clk_add_alias("master", dm644x_ccdc_dev.name, "vpss_master", NULL); |
801 | clk_add_alias("slave", dm644x_ccdc_dev.name, "vpss_slave", NULL); | 795 | clk_add_alias("slave", dm644x_ccdc_dev.name, "vpss_slave", NULL); |
796 | |||
797 | platform_device_register(&dm644x_vpss_device); | ||
798 | platform_device_register(&dm644x_ccdc_dev); | ||
799 | platform_device_register(&dm644x_vpfe_dev); | ||
800 | |||
801 | return 0; | ||
802 | } | ||
803 | |||
804 | static int __init dm644x_init_devices(void) | ||
805 | { | ||
806 | if (!cpu_is_davinci_dm644x()) | ||
807 | return 0; | ||
808 | |||
802 | platform_device_register(&dm644x_edma_device); | 809 | platform_device_register(&dm644x_edma_device); |
803 | 810 | ||
804 | platform_device_register(&dm644x_mdio_device); | 811 | platform_device_register(&dm644x_mdio_device); |
@@ -806,10 +813,6 @@ static int __init dm644x_init_devices(void) | |||
806 | clk_add_alias(NULL, dev_name(&dm644x_mdio_device.dev), | 813 | clk_add_alias(NULL, dev_name(&dm644x_mdio_device.dev), |
807 | NULL, &dm644x_emac_device.dev); | 814 | NULL, &dm644x_emac_device.dev); |
808 | 815 | ||
809 | platform_device_register(&dm644x_vpss_device); | ||
810 | platform_device_register(&dm644x_ccdc_dev); | ||
811 | platform_device_register(&dm644x_vpfe_dev); | ||
812 | |||
813 | return 0; | 816 | return 0; |
814 | } | 817 | } |
815 | postcore_initcall(dm644x_init_devices); | 818 | postcore_initcall(dm644x_init_devices); |