linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] powerpc/85xx: Additional consolidate of_platform_bus_probe calls
@ 2011-11-24  7:08 Kumar Gala
  2011-11-24  7:08 ` [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c to common.c Kumar Gala
  0 siblings, 1 reply; 3+ messages in thread
From: Kumar Gala @ 2011-11-24  7:08 UTC (permalink / raw)
  To: linuxppc-dev

P1010RDB & P1023RDS can use the new mpc85xx_common_publish_devices().
Also move 'fsl,srio' into the list of standard buses.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
 arch/powerpc/platforms/85xx/mpc85xx_common.c |    1 +
 arch/powerpc/platforms/85xx/mpc85xx_mds.c    |    1 -
 arch/powerpc/platforms/85xx/p1010rdb.c       |   15 +++------------
 arch/powerpc/platforms/85xx/p1023_rds.c      |   19 +++----------------
 4 files changed, 7 insertions(+), 29 deletions(-)

diff --git a/arch/powerpc/platforms/85xx/mpc85xx_common.c b/arch/powerpc/platforms/85xx/mpc85xx_common.c
index fe40668..9fef530 100644
--- a/arch/powerpc/platforms/85xx/mpc85xx_common.c
+++ b/arch/powerpc/platforms/85xx/mpc85xx_common.c
@@ -20,6 +20,7 @@ static struct of_device_id __initdata mpc85xx_common_ids[] = {
 	{ .compatible = "gianfar", },
 	{ .compatible = "fsl,qe", },
 	{ .compatible = "fsl,cpm2", },
+	{ .compatible = "fsl,srio", },
 	{},
 };
 
diff --git a/arch/powerpc/platforms/85xx/mpc85xx_mds.c b/arch/powerpc/platforms/85xx/mpc85xx_mds.c
index 38cb473..495cfd9 100644
--- a/arch/powerpc/platforms/85xx/mpc85xx_mds.c
+++ b/arch/powerpc/platforms/85xx/mpc85xx_mds.c
@@ -411,7 +411,6 @@ machine_arch_initcall(mpc8568_mds, board_fixups);
 machine_arch_initcall(mpc8569_mds, board_fixups);
 
 static struct of_device_id mpc85xx_ids[] = {
-	{ .compatible = "fsl,srio", },
 	{ .compatible = "fsl,mpc8548-guts", },
 	{ .compatible = "gpio-leds", },
 	{},
diff --git a/arch/powerpc/platforms/85xx/p1010rdb.c b/arch/powerpc/platforms/85xx/p1010rdb.c
index d7387fa..2f479f8 100644
--- a/arch/powerpc/platforms/85xx/p1010rdb.c
+++ b/arch/powerpc/platforms/85xx/p1010rdb.c
@@ -28,6 +28,8 @@
 #include <sysdev/fsl_soc.h>
 #include <sysdev/fsl_pci.h>
 
+#include "mpc85xx.h"
+
 void __init p1010_rdb_pic_init(void)
 {
 	struct mpic *mpic;
@@ -81,18 +83,7 @@ static void __init p1010_rdb_setup_arch(void)
 	printk(KERN_INFO "P1010 RDB board from Freescale Semiconductor\n");
 }
 
-static struct of_device_id __initdata p1010rdb_ids[] = {
-	{ .type = "soc", },
-	{ .compatible = "soc", },
-	{ .compatible = "simple-bus", },
-	{},
-};
-
-static int __init p1010rdb_publish_devices(void)
-{
-	return of_platform_bus_probe(NULL, p1010rdb_ids, NULL);
-}
-machine_device_initcall(p1010_rdb, p1010rdb_publish_devices);
+machine_device_initcall(p1010_rdb, mpc85xx_common_publish_devices);
 machine_arch_initcall(p1010_rdb, swiotlb_setup_bus_notifier);
 
 /*
diff --git a/arch/powerpc/platforms/85xx/p1023_rds.c b/arch/powerpc/platforms/85xx/p1023_rds.c
index 835e0b3..e76c4dc 100644
--- a/arch/powerpc/platforms/85xx/p1023_rds.c
+++ b/arch/powerpc/platforms/85xx/p1023_rds.c
@@ -34,6 +34,8 @@
 #include <sysdev/fsl_soc.h>
 #include <sysdev/fsl_pci.h>
 
+#include "mpc85xx.h"
+
 /* ************************************************************************
  *
  * Setup the architecture
@@ -92,22 +94,7 @@ static void __init mpc85xx_rds_setup_arch(void)
 #endif
 }
 
-static struct of_device_id p1023_ids[] = {
-	{ .type = "soc", },
-	{ .compatible = "soc", },
-	{ .compatible = "simple-bus", },
-	{},
-};
-
-
-static int __init p1023_publish_devices(void)
-{
-	of_platform_bus_probe(NULL, p1023_ids, NULL);
-
-	return 0;
-}
-
-machine_device_initcall(p1023_rds, p1023_publish_devices);
+machine_device_initcall(p1023_rds, mpc85xx_common_publish_devices);
 
 static void __init mpc85xx_rds_pic_init(void)
 {
-- 
1.7.3.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c to common.c
  2011-11-24  7:08 [PATCH 1/2] powerpc/85xx: Additional consolidate of_platform_bus_probe calls Kumar Gala
@ 2011-11-24  7:08 ` Kumar Gala
  2011-11-24 10:22   ` David Laight
  0 siblings, 1 reply; 3+ messages in thread
From: Kumar Gala @ 2011-11-24  7:08 UTC (permalink / raw)
  To: linuxppc-dev

The file name is already scoped by the directory its in.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
---
 arch/powerpc/platforms/85xx/Makefile               |    2 +-
 .../platforms/85xx/{mpc85xx_common.c => common.c}  |    0
 2 files changed, 1 insertions(+), 1 deletions(-)
 rename arch/powerpc/platforms/85xx/{mpc85xx_common.c => common.c} (100%)

diff --git a/arch/powerpc/platforms/85xx/Makefile b/arch/powerpc/platforms/85xx/Makefile
index b6beec8..9cb2d43 100644
--- a/arch/powerpc/platforms/85xx/Makefile
+++ b/arch/powerpc/platforms/85xx/Makefile
@@ -3,7 +3,7 @@
 #
 obj-$(CONFIG_SMP) += smp.o
 
-obj-y += mpc85xx_common.o
+obj-y += common.o
 
 obj-$(CONFIG_MPC8540_ADS) += mpc85xx_ads.o
 obj-$(CONFIG_MPC8560_ADS) += mpc85xx_ads.o
diff --git a/arch/powerpc/platforms/85xx/mpc85xx_common.c b/arch/powerpc/platforms/85xx/common.c
similarity index 100%
rename from arch/powerpc/platforms/85xx/mpc85xx_common.c
rename to arch/powerpc/platforms/85xx/common.c
-- 
1.7.3.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c to common.c
  2011-11-24  7:08 ` [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c to common.c Kumar Gala
@ 2011-11-24 10:22   ` David Laight
  0 siblings, 0 replies; 3+ messages in thread
From: David Laight @ 2011-11-24 10:22 UTC (permalink / raw)
  To: Kumar Gala, linuxppc-dev

=20
> Subject: [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c=20
> to common.c
>=20
> The file name is already scoped by the directory its in.
...
> rename from arch/powerpc/platforms/85xx/mpc85xx_common.c
> rename to arch/powerpc/platforms/85xx/common.c

All very well until you only have a reference to the
filename part somewhere and want to 'find' the file
in a large directory tree.

	David

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-11-24 10:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-24  7:08 [PATCH 1/2] powerpc/85xx: Additional consolidate of_platform_bus_probe calls Kumar Gala
2011-11-24  7:08 ` [PATCH 2/2] powerpc/85xx: Renamed mpc85xx_common.c to common.c Kumar Gala
2011-11-24 10:22   ` David Laight

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).