linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] 85xx: publish of device for cds platforms
@ 2008-06-16 21:32 Dave Jiang
  2008-06-16 21:36 ` Scott Wood
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Jiang @ 2008-06-16 21:32 UTC (permalink / raw)
  To: galak; +Cc: linuxppc-dev


Publish the devices listed in dts under SOC as of_device for 85xx_cds
platform. The devices are needed by the 85xx EDAC driver.

Signed-off-by: Dave Jiang <djiang@mvista.com>

---
 arch/powerpc/platforms/85xx/mpc85xx_cds.c |   14 ++++++++++++++
 1 file changed, 14 insertions(+)

Index: 2.6.26-rc5-mm3/arch/powerpc/platforms/85xx/mpc85xx_cds.c
===================================================================
--- 2.6.26-rc5-mm3.orig/arch/powerpc/platforms/85xx/mpc85xx_cds.c
+++ 2.6.26-rc5-mm3/arch/powerpc/platforms/85xx/mpc85xx_cds.c
@@ -26,6 +26,7 @@
 #include <linux/module.h>
 #include <linux/interrupt.h>
 #include <linux/fsl_devices.h>
+#include <linux/of_platform.h>
 
 #include <asm/system.h>
 #include <asm/pgtable.h>
@@ -335,6 +336,19 @@ static int __init mpc85xx_cds_probe(void
         return of_flat_dt_is_compatible(root, "MPC85xxCDS");
 }
 
+static struct of_device_id __initdata of_bus_ids[] = {
+	{ .type = "soc", },
+	{ .compatible = "soc", },
+	{},
+};
+
+static int __init declare_of_platform_devices(void)
+{
+	return of_platform_bus_probe(NULL, of_bus_ids, NULL);
+}
+machine_device_initcall(mpc85xx_cds, declare_of_platform_devices);
+
+
 define_machine(mpc85xx_cds) {
 	.name		= "MPC85xx CDS",
 	.probe		= mpc85xx_cds_probe,

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

* Re: [PATCH] 85xx: publish of device for cds platforms
  2008-06-16 21:32 [PATCH] 85xx: publish of device for cds platforms Dave Jiang
@ 2008-06-16 21:36 ` Scott Wood
  2008-06-16 22:36   ` [PATCH v2] " Dave Jiang
  0 siblings, 1 reply; 4+ messages in thread
From: Scott Wood @ 2008-06-16 21:36 UTC (permalink / raw)
  To: Dave Jiang; +Cc: linuxppc-dev

Dave Jiang wrote:
> +static struct of_device_id __initdata of_bus_ids[] = {
> +	{ .type = "soc", },
> +	{ .compatible = "soc", },
> +	{},
> +};

Also add .compatible = "simple-bus".

-Scott

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

* [PATCH v2] 85xx: publish of device for cds platforms
  2008-06-16 21:36 ` Scott Wood
@ 2008-06-16 22:36   ` Dave Jiang
  2008-07-02 17:41     ` Kumar Gala
  0 siblings, 1 reply; 4+ messages in thread
From: Dave Jiang @ 2008-06-16 22:36 UTC (permalink / raw)
  To: Scott Wood; +Cc: linuxppc-dev

Publish the devices listed in dts under SOC as of_device for 85xx_cds
platform. The devices are needed by the 85xx EDAC driver.

Signed-off-by: Dave Jiang <djiang@mvista.com>

---

Added "simple bus" per Scott Wood

 mrch/powerpc/platforms/85xx/pc85xx_cds.c |   15 +++++++++++++++
 1 file changed, 15 insertions(+)


Index: 2.6.26-rc5-mm3/arch/powerpc/platforms/85xx/mpc85xx_cds.c
===================================================================
--- 2.6.26-rc5-mm3.orig/arch/powerpc/platforms/85xx/mpc85xx_cds.c
+++ 2.6.26-rc5-mm3/arch/powerpc/platforms/85xx/mpc85xx_cds.c
@@ -26,6 +26,7 @@
 #include <linux/module.h>
 #include <linux/interrupt.h>
 #include <linux/fsl_devices.h>
+#include <linux/of_platform.h>
 
 #include <asm/system.h>
 #include <asm/pgtable.h>
@@ -335,6 +336,20 @@ static int __init mpc85xx_cds_probe(void
         return of_flat_dt_is_compatible(root, "MPC85xxCDS");
 }
 
+static struct of_device_id __initdata of_bus_ids[] = {
+	{ .type = "soc", },
+	{ .compatible = "soc", },
+	{ .compatible = "simple-bus", },
+	{},
+};
+
+static int __init declare_of_platform_devices(void)
+{
+	return of_platform_bus_probe(NULL, of_bus_ids, NULL);
+}
+machine_device_initcall(mpc85xx_cds, declare_of_platform_devices);
+
+
 define_machine(mpc85xx_cds) {
 	.name		= "MPC85xx CDS",
 	.probe		= mpc85xx_cds_probe,

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

* Re: [PATCH v2] 85xx: publish of device for cds platforms
  2008-06-16 22:36   ` [PATCH v2] " Dave Jiang
@ 2008-07-02 17:41     ` Kumar Gala
  0 siblings, 0 replies; 4+ messages in thread
From: Kumar Gala @ 2008-07-02 17:41 UTC (permalink / raw)
  To: Dave Jiang; +Cc: Scott Wood, linuxppc-dev


On Jun 16, 2008, at 5:36 PM, Dave Jiang wrote:

> Publish the devices listed in dts under SOC as of_device for 85xx_cds
> platform. The devices are needed by the 85xx EDAC driver.
>
> Signed-off-by: Dave Jiang <djiang@mvista.com>
>
> ---
>
> Added "simple bus" per Scott Wood
>
> mrch/powerpc/platforms/85xx/pc85xx_cds.c |   15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>

applied.

- k

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

end of thread, other threads:[~2008-07-02 17:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-16 21:32 [PATCH] 85xx: publish of device for cds platforms Dave Jiang
2008-06-16 21:36 ` Scott Wood
2008-06-16 22:36   ` [PATCH v2] " Dave Jiang
2008-07-02 17:41     ` Kumar Gala

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).