UPSTREAM: ARM: Exynos: Remove a new bus_type instance for Exynos5
authorThomas Abraham <thomas.abraham@linaro.org>
Mon, 30 Apr 2012 17:10:12 +0000 (10:10 -0700)
committerSubash <subash.rp@samsung.com>
Thu, 14 Jun 2012 18:06:24 +0000 (11:06 -0700)
A seperate bus_type instance is not required for Exynos5. The existing bus_type
instance used with Exynos4 is sufficient for both Exynos4 and Exynos5. This
also solves issue of uninitialized usage of exynos4_subsys in Exynos4 power
management code that is reused for Exynos5 also. In addition to that, the
existing exynos4_subsys bus_type is renamed to exynos_subsys to indicate that
it is reused on both Exynos4 and Exynos5 platforms.

Signed-off-by: Thomas Abraham <thomas.abraham@linaro.org>
arch/arm/mach-exynos/common.c
arch/arm/mach-exynos/pm.c
arch/arm/plat-samsung/include/plat/cpu.h

index eff4446..3302a8d 100644 (file)
@@ -565,30 +565,18 @@ void __init exynos5_init_irq(void)
        s5p_init_irq(NULL, 0);
 }
 
-struct bus_type exynos4_subsys = {
-       .name           = "exynos4-core",
-       .dev_name       = "exynos4-core",
-};
-
-struct bus_type exynos5_subsys = {
-       .name           = "exynos5-core",
-       .dev_name       = "exynos5-core",
+struct bus_type exynos_subsys = {
+       .name           = "exynos-core",
+       .dev_name       = "exynos-core",
 };
 
 static struct device exynos4_dev = {
-       .bus    = &exynos4_subsys,
-};
-
-static struct device exynos5_dev = {
-       .bus    = &exynos5_subsys,
+       .bus    = &exynos_subsys,
 };
 
 static int __init exynos_core_init(void)
 {
-       if (soc_is_exynos5250())
-               return subsys_system_register(&exynos5_subsys, NULL);
-       else
-               return subsys_system_register(&exynos4_subsys, NULL);
+       return subsys_system_register(&exynos_subsys, NULL);
 }
 core_initcall(exynos_core_init);
 
@@ -675,10 +663,7 @@ static int __init exynos_init(void)
 {
        printk(KERN_INFO "EXYNOS: Initializing architecture\n");
 
-       if (soc_is_exynos5250())
-               return device_register(&exynos5_dev);
-       else
-               return device_register(&exynos4_dev);
+       return device_register(&exynos4_dev);
 }
 
 /* uart registration process */
index 428cfeb..7164aa9 100644 (file)
@@ -275,7 +275,7 @@ static void exynos4_restore_pll(void)
 
 static struct subsys_interface exynos4_pm_interface = {
        .name           = "exynos4_pm",
-       .subsys         = &exynos4_subsys,
+       .subsys         = &exynos_subsys,
        .add_dev        = exynos4_pm_add,
 };
 
index 787ceac..0721293 100644 (file)
@@ -202,7 +202,7 @@ extern struct bus_type s3c2443_subsys;
 extern struct bus_type s3c6410_subsys;
 extern struct bus_type s5p64x0_subsys;
 extern struct bus_type s5pv210_subsys;
-extern struct bus_type exynos4_subsys;
+extern struct bus_type exynos_subsys;
 
 extern void (*s5pc1xx_idle)(void);