Netdev List
 help / color / mirror / Atom feed
* [PATCH 22/37] drivers/leds: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:05 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/leds/leds-gpio.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c
index e5225d2..7ff758a 100644
--- a/drivers/leds/leds-gpio.c
+++ b/drivers/leds/leds-gpio.c
@@ -210,7 +210,7 @@ struct gpio_led_of_platform_data {
 static int __devinit of_gpio_leds_probe(struct of_device *ofdev,
 					const struct of_device_id *match)
 {
-	struct device_node *np = ofdev->node, *child;
+	struct device_node *np = ofdev->dev.of_node, *child;
 	struct gpio_led led;
 	struct gpio_led_of_platform_data *pdata;
 	int count = 0, ret;


^ permalink raw reply related

* [PATCH 23/37] drivers/i2c: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:05 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/i2c/busses/i2c-mpc.c |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 78a15af..0123a6e 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -559,14 +559,14 @@ static int __devinit fsl_i2c_probe(struct of_device *op,
 
 	init_waitqueue_head(&i2c->queue);
 
-	i2c->base = of_iomap(op->node, 0);
+	i2c->base = of_iomap(op->dev.of_node, 0);
 	if (!i2c->base) {
 		dev_err(i2c->dev, "failed to map controller\n");
 		result = -ENOMEM;
 		goto fail_map;
 	}
 
-	i2c->irq = irq_of_parse_and_map(op->node, 0);
+	i2c->irq = irq_of_parse_and_map(op->dev.of_node, 0);
 	if (i2c->irq != NO_IRQ) { /* i2c->irq = NO_IRQ implies polling */
 		result = request_irq(i2c->irq, mpc_i2c_isr,
 				     IRQF_SHARED, "i2c-mpc", i2c);
@@ -576,21 +576,22 @@ static int __devinit fsl_i2c_probe(struct of_device *op,
 		}
 	}
 
-	if (of_get_property(op->node, "fsl,preserve-clocking", NULL)) {
+	if (of_get_property(op->dev.of_node, "fsl,preserve-clocking", NULL)) {
 		clock = MPC_I2C_CLOCK_PRESERVE;
 	} else {
-		prop = of_get_property(op->node, "clock-frequency", &plen);
+		prop = of_get_property(op->dev.of_node, "clock-frequency",
+					&plen);
 		if (prop && plen == sizeof(u32))
 			clock = *prop;
 	}
 
 	if (match->data) {
 		struct mpc_i2c_data *data = match->data;
-		data->setup(op->node, i2c, clock, data->prescaler);
+		data->setup(op->dev.of_node, i2c, clock, data->prescaler);
 	} else {
 		/* Backwards compatibility */
-		if (of_get_property(op->node, "dfsrr", NULL))
-			mpc_i2c_setup_8xxx(op->node, i2c, clock, 0);
+		if (of_get_property(op->dev.of_node, "dfsrr", NULL))
+			mpc_i2c_setup_8xxx(op->dev.of_node, i2c, clock, 0);
 	}
 
 	dev_set_drvdata(&op->dev, i2c);
@@ -604,7 +605,7 @@ static int __devinit fsl_i2c_probe(struct of_device *op,
 		dev_err(i2c->dev, "failed to add adapter\n");
 		goto fail_add;
 	}
-	of_register_i2c_devices(&i2c->adap, op->node);
+	of_register_i2c_devices(&i2c->adap, op->dev.of_node);
 
 	return result;
 


^ permalink raw reply related

* [PATCH 24/37] drivers/char: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/char/hw_random/n2-drv.c     |    2 +-
 drivers/char/hw_random/pasemi-rng.c |    2 +-
 drivers/char/ipmi/ipmi_si_intf.c    |    4 ++--
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/char/hw_random/n2-drv.c b/drivers/char/hw_random/n2-drv.c
index 9b3e09c..4d05003 100644
--- a/drivers/char/hw_random/n2-drv.c
+++ b/drivers/char/hw_random/n2-drv.c
@@ -660,7 +660,7 @@ static int __devinit n2rng_probe(struct of_device *op,
 				np->hvapi_major);
 			goto out_hvapi_unregister;
 		}
-		np->num_units = of_getintprop_default(op->node,
+		np->num_units = of_getintprop_default(op->dev.of_node,
 						      "rng-#units", 0);
 		if (!np->num_units) {
 			dev_err(&op->dev, "VF RNG lacks rng-#units property\n");
diff --git a/drivers/char/hw_random/pasemi-rng.c b/drivers/char/hw_random/pasemi-rng.c
index 7fa61dd..b213855 100644
--- a/drivers/char/hw_random/pasemi-rng.c
+++ b/drivers/char/hw_random/pasemi-rng.c
@@ -98,7 +98,7 @@ static int __devinit rng_probe(struct of_device *ofdev,
 			       const struct of_device_id *match)
 {
 	void __iomem *rng_regs;
-	struct device_node *rng_np = ofdev->node;
+	struct device_node *rng_np = ofdev->dev.of_node;
 	struct resource res;
 	int err = 0;
 
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 176f175..45305f2 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -2406,7 +2406,7 @@ static int __devinit ipmi_of_probe(struct of_device *dev,
 	struct smi_info *info;
 	struct resource resource;
 	const int *regsize, *regspacing, *regshift;
-	struct device_node *np = dev->node;
+	struct device_node *np = dev->dev.of_node;
 	int ret;
 	int proplen;
 
@@ -2462,7 +2462,7 @@ static int __devinit ipmi_of_probe(struct of_device *dev,
 	info->io.regspacing	= regspacing ? *regspacing : DEFAULT_REGSPACING;
 	info->io.regshift	= regshift ? *regshift : 0;
 
-	info->irq		= irq_of_parse_and_map(dev->node, 0);
+	info->irq		= irq_of_parse_and_map(dev->dev.of_node, 0);
 	info->dev		= &dev->dev;
 
 	dev_dbg(&dev->dev, "addr 0x%lx regsize %d spacing %d irq %x\n",


^ permalink raw reply related

* [PATCH 25/37] drivers/infiniband: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/infiniband/hw/ehca/ehca_main.c |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/drivers/infiniband/hw/ehca/ehca_main.c b/drivers/infiniband/hw/ehca/ehca_main.c
index 129a6be..2639185 100644
--- a/drivers/infiniband/hw/ehca/ehca_main.c
+++ b/drivers/infiniband/hw/ehca/ehca_main.c
@@ -291,8 +291,9 @@ static int ehca_sense_attributes(struct ehca_shca *shca)
 	};
 
 	ehca_gen_dbg("Probing adapter %s...",
-		     shca->ofdev->node->full_name);
-	loc_code = of_get_property(shca->ofdev->node, "ibm,loc-code", NULL);
+		     shca->ofdev->dev.of_node->full_name);
+	loc_code = of_get_property(shca->ofdev->dev.of_node, "ibm,loc-code",
+				   NULL);
 	if (loc_code)
 		ehca_gen_dbg(" ... location lode=%s", loc_code);
 
@@ -720,16 +721,16 @@ static int __devinit ehca_probe(struct of_device *dev,
 	int ret, i, eq_size;
 	unsigned long flags;
 
-	handle = of_get_property(dev->node, "ibm,hca-handle", NULL);
+	handle = of_get_property(dev->dev.of_node, "ibm,hca-handle", NULL);
 	if (!handle) {
 		ehca_gen_err("Cannot get eHCA handle for adapter: %s.",
-			     dev->node->full_name);
+			     dev->dev.of_node->full_name);
 		return -ENODEV;
 	}
 
 	if (!(*handle)) {
 		ehca_gen_err("Wrong eHCA handle for adapter: %s.",
-			     dev->node->full_name);
+			     dev->dev.of_node->full_name);
 		return -ENODEV;
 	}
 


^ permalink raw reply related

* [PATCH 26/37] drivers/mtd: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/mtd/maps/physmap_of.c    |    6 +++---
 drivers/mtd/maps/sun_uflash.c    |    2 +-
 drivers/mtd/nand/fsl_elbc_nand.c |    6 +++---
 drivers/mtd/nand/pasemi_nand.c   |    2 +-
 4 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/drivers/mtd/maps/physmap_of.c b/drivers/mtd/maps/physmap_of.c
index 61e4eb4..494af8e 100644
--- a/drivers/mtd/maps/physmap_of.c
+++ b/drivers/mtd/maps/physmap_of.c
@@ -142,7 +142,7 @@ static int of_flash_remove(struct of_device *dev)
 static struct mtd_info * __devinit obsolete_probe(struct of_device *dev,
 						  struct map_info *map)
 {
-	struct device_node *dp = dev->node;
+	struct device_node *dp = dev->dev.of_node;
 	const char *of_probe;
 	struct mtd_info *mtd;
 	static const char *rom_probe_types[]
@@ -179,7 +179,7 @@ static int __devinit of_flash_probe(struct of_device *dev,
 	static const char *part_probe_types[]
 		= { "cmdlinepart", "RedBoot", NULL };
 #endif
-	struct device_node *dp = dev->node;
+	struct device_node *dp = dev->dev.of_node;
 	struct resource res;
 	struct of_flash *info;
 	const char *probe_type = match->data;
@@ -203,7 +203,7 @@ static int __devinit of_flash_probe(struct of_device *dev,
 	p = of_get_property(dp, "reg", &count);
 	if (count % reg_tuple_size != 0) {
 		dev_err(&dev->dev, "Malformed reg property on %s\n",
-				dev->node->full_name);
+				dev->dev.of_node->full_name);
 		err = -EINVAL;
 		goto err_flash_remove;
 	}
diff --git a/drivers/mtd/maps/sun_uflash.c b/drivers/mtd/maps/sun_uflash.c
index fd7a101..365811d 100644
--- a/drivers/mtd/maps/sun_uflash.c
+++ b/drivers/mtd/maps/sun_uflash.c
@@ -109,7 +109,7 @@ int uflash_devinit(struct of_device *op, struct device_node *dp)
 
 static int __devinit uflash_probe(struct of_device *op, const struct of_device_id *match)
 {
-	struct device_node *dp = op->node;
+	struct device_node *dp = op->dev.of_node;
 
 	/* Flashprom must have the "user" property in order to
 	 * be used by this driver.
diff --git a/drivers/mtd/nand/fsl_elbc_nand.c b/drivers/mtd/nand/fsl_elbc_nand.c
index ae30fb6..4a60795 100644
--- a/drivers/mtd/nand/fsl_elbc_nand.c
+++ b/drivers/mtd/nand/fsl_elbc_nand.c
@@ -1030,14 +1030,14 @@ static int __devinit fsl_elbc_ctrl_probe(struct of_device *ofdev,
 	init_waitqueue_head(&ctrl->controller.wq);
 	init_waitqueue_head(&ctrl->irq_wait);
 
-	ctrl->regs = of_iomap(ofdev->node, 0);
+	ctrl->regs = of_iomap(ofdev->dev.of_node, 0);
 	if (!ctrl->regs) {
 		dev_err(&ofdev->dev, "failed to get memory region\n");
 		ret = -ENODEV;
 		goto err;
 	}
 
-	ctrl->irq = of_irq_to_resource(ofdev->node, 0, NULL);
+	ctrl->irq = of_irq_to_resource(ofdev->dev.of_node, 0, NULL);
 	if (ctrl->irq == NO_IRQ) {
 		dev_err(&ofdev->dev, "failed to get irq resource\n");
 		ret = -ENODEV;
@@ -1058,7 +1058,7 @@ static int __devinit fsl_elbc_ctrl_probe(struct of_device *ofdev,
 		goto err;
 	}
 
-	for_each_child_of_node(ofdev->node, child)
+	for_each_child_of_node(ofdev->dev.of_node, child)
 		if (of_device_is_compatible(child, "fsl,elbc-fcm-nand"))
 			fsl_elbc_chip_probe(ctrl, child);
 
diff --git a/drivers/mtd/nand/pasemi_nand.c b/drivers/mtd/nand/pasemi_nand.c
index a8b9376..edfc27b 100644
--- a/drivers/mtd/nand/pasemi_nand.c
+++ b/drivers/mtd/nand/pasemi_nand.c
@@ -93,7 +93,7 @@ static int __devinit pasemi_nand_probe(struct of_device *ofdev,
 				      const struct of_device_id *match)
 {
 	struct pci_dev *pdev;
-	struct device_node *np = ofdev->node;
+	struct device_node *np = ofdev->dev.of_node;
 	struct resource res;
 	struct nand_chip *chip;
 	int err = 0;


^ permalink raw reply related

* [PATCH 27/37] drivers/of: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/of/device.c |   20 ++++++++++----------
 1 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/drivers/of/device.c b/drivers/of/device.c
index 224ae6b..24068bb 100644
--- a/drivers/of/device.c
+++ b/drivers/of/device.c
@@ -21,9 +21,9 @@
 const struct of_device_id *of_match_device(const struct of_device_id *matches,
 					const struct of_device *dev)
 {
-	if (!dev->node)
+	if (!dev->dev.of_node)
 		return NULL;
-	return of_match_node(matches, dev->node);
+	return of_match_node(matches, dev->dev.of_node);
 }
 EXPORT_SYMBOL(of_match_device);
 
@@ -54,7 +54,7 @@ static ssize_t devspec_show(struct device *dev,
 	struct of_device *ofdev;
 
 	ofdev = to_of_device(dev);
-	return sprintf(buf, "%s\n", ofdev->node->full_name);
+	return sprintf(buf, "%s\n", ofdev->dev.of_node->full_name);
 }
 
 static ssize_t name_show(struct device *dev,
@@ -63,7 +63,7 @@ static ssize_t name_show(struct device *dev,
 	struct of_device *ofdev;
 
 	ofdev = to_of_device(dev);
-	return sprintf(buf, "%s\n", ofdev->node->name);
+	return sprintf(buf, "%s\n", ofdev->dev.of_node->name);
 }
 
 static ssize_t modalias_show(struct device *dev,
@@ -97,14 +97,14 @@ void of_release_dev(struct device *dev)
 	struct of_device *ofdev;
 
 	ofdev = to_of_device(dev);
-	of_node_put(ofdev->node);
+	of_node_put(ofdev->dev.of_node);
 	kfree(ofdev);
 }
 EXPORT_SYMBOL(of_release_dev);
 
 int of_device_register(struct of_device *ofdev)
 {
-	BUG_ON(ofdev->node == NULL);
+	BUG_ON(ofdev->dev.of_node == NULL);
 
 	device_initialize(&ofdev->dev);
 
@@ -112,7 +112,7 @@ int of_device_register(struct of_device *ofdev)
 	 * the parent. If there is no parent defined, set the node
 	 * explicitly */
 	if (!ofdev->dev.parent)
-		set_dev_node(&ofdev->dev, of_node_to_nid(ofdev->node));
+		set_dev_node(&ofdev->dev, of_node_to_nid(ofdev->dev.of_node));
 
 	return device_add(&ofdev->dev);
 }
@@ -132,11 +132,11 @@ ssize_t of_device_get_modalias(struct of_device *ofdev,
 	ssize_t tsize, csize, repend;
 
 	/* Name & Type */
-	csize = snprintf(str, len, "of:N%sT%s",
-				ofdev->node->name, ofdev->node->type);
+	csize = snprintf(str, len, "of:N%sT%s", ofdev->dev.of_node->name,
+			 ofdev->dev.of_node->type);
 
 	/* Get compatible property if any */
-	compat = of_get_property(ofdev->node, "compatible", &cplen);
+	compat = of_get_property(ofdev->dev.of_node, "compatible", &cplen);
 	if (!compat)
 		return csize;
 


^ permalink raw reply related

* [PATCH 28/37] drivers/scsi: use .of_node instead of .archdata.of_node in struct device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.node is being removed from Microblaze, SPARC and PowerPC.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/scsi/ibmvscsi/ibmvfc.c   |    2 +-
 drivers/scsi/ibmvscsi/ibmvscsi.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c
index 732f6d3..e230cd4 100644
--- a/drivers/scsi/ibmvscsi/ibmvfc.c
+++ b/drivers/scsi/ibmvscsi/ibmvfc.c
@@ -1155,7 +1155,7 @@ static void ibmvfc_gather_partition_info(struct ibmvfc_host *vhost)
 static void ibmvfc_set_login_info(struct ibmvfc_host *vhost)
 {
 	struct ibmvfc_npiv_login *login_info = &vhost->login_info;
-	struct device_node *of_node = vhost->dev->archdata.of_node;
+	struct device_node *of_node = vhost->dev->of_node;
 	const char *location;
 
 	memset(login_info, 0, sizeof(*login_info));
diff --git a/drivers/scsi/ibmvscsi/ibmvscsi.c b/drivers/scsi/ibmvscsi/ibmvscsi.c
index e3a18e0..c4b5af3 100644
--- a/drivers/scsi/ibmvscsi/ibmvscsi.c
+++ b/drivers/scsi/ibmvscsi/ibmvscsi.c
@@ -955,7 +955,7 @@ static void send_mad_capabilities(struct ibmvscsi_host_data *hostdata)
 	struct viosrp_capabilities *req;
 	struct srp_event_struct *evt_struct;
 	unsigned long flags;
-	struct device_node *of_node = hostdata->dev->archdata.of_node;
+	struct device_node *of_node = hostdata->dev->of_node;
 	const char *location;
 
 	evt_struct = get_event_struct(&hostdata->pool);


^ permalink raw reply related

* [PATCH 29/37] drivers/char: use .of_node instead of .archdata.of_node in struct device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.node is being removed from Microblaze, SPARC and PowerPC.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/char/viotape.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/char/viotape.c b/drivers/char/viotape.c
index 042c814..f37935c 100644
--- a/drivers/char/viotape.c
+++ b/drivers/char/viotape.c
@@ -865,7 +865,7 @@ static int viotape_probe(struct vio_dev *vdev, const struct vio_device_id *id)
 {
 	int i = vdev->unit_address;
 	int j;
-	struct device_node *node = vdev->dev.archdata.of_node;
+	struct device_node *node = vdev->dev.of_node;
 
 	if (i >= VIOTAPE_MAX_TAPE)
 		return -ENODEV;


^ permalink raw reply related

* [PATCH 30/37] drivers/cdrom: use .of_node instead of .archdata.of_node in struct device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.node is being removed from Microblaze, SPARC and PowerPC.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/cdrom/viocd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/cdrom/viocd.c b/drivers/cdrom/viocd.c
index cc435be..451cd70 100644
--- a/drivers/cdrom/viocd.c
+++ b/drivers/cdrom/viocd.c
@@ -567,7 +567,7 @@ static int viocd_probe(struct vio_dev *vdev, const struct vio_device_id *id)
 	struct disk_info *d;
 	struct cdrom_device_info *c;
 	struct request_queue *q;
-	struct device_node *node = vdev->dev.archdata.of_node;
+	struct device_node *node = vdev->dev.of_node;
 
 	deviceno = vdev->unit_address;
 	if (deviceno >= VIOCD_MAX_CD)


^ permalink raw reply related

* [PATCH 31/37] drivers/of: use .of_node instead of .archdata.of_node in struct device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.node is being removed from Microblaze, SPARC and PowerPC.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/of/of_i2c.c  |    1 -
 drivers/of/of_mdio.c |    1 -
 drivers/of/of_spi.c  |    1 -
 3 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/drivers/of/of_i2c.c b/drivers/of/of_i2c.c
index 43f803e..ab6522c 100644
--- a/drivers/of/of_i2c.c
+++ b/drivers/of/of_i2c.c
@@ -42,7 +42,6 @@ void of_register_i2c_devices(struct i2c_adapter *adap,
 
 		info.addr = be32_to_cpup(addr);
 
-		dev_archdata_set_node(&dev_ad, node); /* temporary */
 		info.of_node = node;
 		info.archdata = &dev_ad;
 
diff --git a/drivers/of/of_mdio.c b/drivers/of/of_mdio.c
index 64e08d7..794fbc2 100644
--- a/drivers/of/of_mdio.c
+++ b/drivers/of/of_mdio.c
@@ -79,7 +79,6 @@ int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)
 		/* Associate the OF node with the device structure so it
 		 * can be looked up later */
 		of_node_get(child);
-		dev_archdata_set_node(&phy->dev.archdata, child); /* temp */
 		phy->dev.of_node = child;
 
 		/* All data is now stored in the phy struct; register it */
diff --git a/drivers/of/of_spi.c b/drivers/of/of_spi.c
index 433d76d..5fed7e3 100644
--- a/drivers/of/of_spi.c
+++ b/drivers/of/of_spi.c
@@ -80,7 +80,6 @@ void of_register_spi_devices(struct spi_master *master, struct device_node *np)
 		/* Store a pointer to the node in the device structure */
 		of_node_get(nc);
 		spi->dev.of_node = nc;
-		spi->dev.archdata.of_node = nc; /* temporary */
 
 		/* Register the new device */
 		request_module(spi->modalias);


^ permalink raw reply related

* [PATCH 32/37] sound/aoa: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 sound/aoa/fabrics/layout.c          |    2 +-
 sound/aoa/soundbus/core.c           |    8 ++++----
 sound/aoa/soundbus/i2sbus/control.c |    2 +-
 sound/aoa/soundbus/i2sbus/core.c    |    4 ++--
 sound/aoa/soundbus/sysfs.c          |    4 ++--
 5 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/sound/aoa/fabrics/layout.c b/sound/aoa/fabrics/layout.c
index 7a437da..da38f2b 100644
--- a/sound/aoa/fabrics/layout.c
+++ b/sound/aoa/fabrics/layout.c
@@ -991,7 +991,7 @@ static int aoa_fabric_layout_probe(struct soundbus_dev *sdev)
 		return -ENODEV;
 
 	/* by breaking out we keep a reference */
-	while ((sound = of_get_next_child(sdev->ofdev.node, sound))) {
+	while ((sound = of_get_next_child(sdev->ofdev.dev.of_node, sound))) {
 		if (sound->type && strcasecmp(sound->type, "soundchip") == 0)
 			break;
 	}
diff --git a/sound/aoa/soundbus/core.c b/sound/aoa/soundbus/core.c
index fa8ab28..99ca712 100644
--- a/sound/aoa/soundbus/core.c
+++ b/sound/aoa/soundbus/core.c
@@ -74,11 +74,11 @@ static int soundbus_uevent(struct device *dev, struct kobj_uevent_env *env)
 	of = &soundbus_dev->ofdev;
 
 	/* stuff we want to pass to /sbin/hotplug */
-	retval = add_uevent_var(env, "OF_NAME=%s", of->node->name);
+	retval = add_uevent_var(env, "OF_NAME=%s", of->dev.of_node->name);
 	if (retval)
 		return retval;
 
-	retval = add_uevent_var(env, "OF_TYPE=%s", of->node->type);
+	retval = add_uevent_var(env, "OF_TYPE=%s", of->dev.of_node->type);
 	if (retval)
 		return retval;
 
@@ -86,7 +86,7 @@ static int soundbus_uevent(struct device *dev, struct kobj_uevent_env *env)
 	 * it's not really legal to split it out with commas. We split it
 	 * up using a number of environment variables instead. */
 
-	compat = of_get_property(of->node, "compatible", &cplen);
+	compat = of_get_property(of->dev.of_node, "compatible", &cplen);
 	while (compat && cplen > 0) {
 		int tmp = env->buflen;
 		retval = add_uevent_var(env, "OF_COMPATIBLE_%d=%s", seen, compat);
@@ -169,7 +169,7 @@ int soundbus_add_one(struct soundbus_dev *dev)
 
 	/* sanity checks */
 	if (!dev->attach_codec ||
-	    !dev->ofdev.node ||
+	    !dev->ofdev.dev.of_node ||
 	    dev->pcmname ||
 	    dev->pcmid != -1) {
 		printk(KERN_ERR "soundbus: adding device failed sanity check!\n");
diff --git a/sound/aoa/soundbus/i2sbus/control.c b/sound/aoa/soundbus/i2sbus/control.c
index 87beb4a..799804d 100644
--- a/sound/aoa/soundbus/i2sbus/control.c
+++ b/sound/aoa/soundbus/i2sbus/control.c
@@ -41,7 +41,7 @@ int i2sbus_control_add_dev(struct i2sbus_control *c,
 {
 	struct device_node *np;
 
-	np = i2sdev->sound.ofdev.node;
+	np = i2sdev->sound.ofdev.dev.of_node;
 	i2sdev->enable = pmf_find_function(np, "enable");
 	i2sdev->cell_enable = pmf_find_function(np, "cell-enable");
 	i2sdev->clock_enable = pmf_find_function(np, "clock-enable");
diff --git a/sound/aoa/soundbus/i2sbus/core.c b/sound/aoa/soundbus/i2sbus/core.c
index 4e3b819..ddb1577 100644
--- a/sound/aoa/soundbus/i2sbus/core.c
+++ b/sound/aoa/soundbus/i2sbus/core.c
@@ -220,8 +220,8 @@ static int i2sbus_add_dev(struct macio_dev *macio,
 
 	mutex_init(&dev->lock);
 	spin_lock_init(&dev->low_lock);
-	dev->sound.ofdev.node = np;
 	dev->sound.ofdev.dma_mask = macio->ofdev.dma_mask;
+	dev->sound.ofdev.dev.of_node = np;
 	dev->sound.ofdev.dev.dma_mask = &dev->sound.ofdev.dma_mask;
 	dev->sound.ofdev.dev.parent = &macio->ofdev.dev;
 	dev->sound.ofdev.dev.release = i2sbus_release_dev;
@@ -345,7 +345,7 @@ static int i2sbus_probe(struct macio_dev* dev, const struct of_device_id *match)
 		return -ENODEV;
 	}
 
-	while ((np = of_get_next_child(dev->ofdev.node, np))) {
+	while ((np = of_get_next_child(dev->ofdev.dev.of_node, np))) {
 		if (of_device_is_compatible(np, "i2sbus") ||
 		    of_device_is_compatible(np, "i2s-modem")) {
 			got += i2sbus_add_dev(dev, control, np);
diff --git a/sound/aoa/soundbus/sysfs.c b/sound/aoa/soundbus/sysfs.c
index f580942..6496e75 100644
--- a/sound/aoa/soundbus/sysfs.c
+++ b/sound/aoa/soundbus/sysfs.c
@@ -9,7 +9,7 @@ field##_show (struct device *dev, struct device_attribute *attr,	\
               char *buf)						\
 {									\
 	struct soundbus_dev *mdev = to_soundbus_device (dev);		\
-	return sprintf (buf, format_string, mdev->ofdev.node->field);	\
+	return sprintf (buf, format_string, mdev->ofdev.dev.of_node->field); \
 }
 
 static ssize_t modalias_show(struct device *dev, struct device_attribute *attr,
@@ -25,7 +25,7 @@ static ssize_t modalias_show(struct device *dev, struct device_attribute *attr,
 		length = strlen(buf);
 	} else {
 		length = sprintf(buf, "of:N%sT%s\n",
-				 of->node->name, of->node->type);
+				 of->dev.of_node->name, of->dev.of_node->type);
 	}
 
 	return length;


^ permalink raw reply related

* [PATCH 33/37] sound/soc: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 sound/soc/fsl/mpc8610_hpcd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/sound/soc/fsl/mpc8610_hpcd.c b/sound/soc/fsl/mpc8610_hpcd.c
index ef67d1c..d7e1b9a 100644
--- a/sound/soc/fsl/mpc8610_hpcd.c
+++ b/sound/soc/fsl/mpc8610_hpcd.c
@@ -202,7 +202,7 @@ static struct snd_soc_ops mpc8610_hpcd_ops = {
 static int mpc8610_hpcd_probe(struct of_device *ofdev,
 	const struct of_device_id *match)
 {
-	struct device_node *np = ofdev->node;
+	struct device_node *np = ofdev->dev.of_node;
 	struct device_node *codec_np = NULL;
 	struct device_node *guts_np = NULL;
 	struct device_node *dma_np = NULL;


^ permalink raw reply related

* [PATCH 34/37] sound/sparc: use .dev.of_node instead of .node in struct of_device
From: Grant Likely @ 2010-03-11 18:06 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.node is being removed

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 sound/sparc/cs4231.c |    6 +++---
 sound/sparc/dbri.c   |    2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/sound/sparc/cs4231.c b/sound/sparc/cs4231.c
index 8d13d93..14cb87c 100644
--- a/sound/sparc/cs4231.c
+++ b/sound/sparc/cs4231.c
@@ -2076,12 +2076,12 @@ static int __devinit cs4231_ebus_probe(struct of_device *op, const struct of_dev
 static int __devinit cs4231_probe(struct of_device *op, const struct of_device_id *match)
 {
 #ifdef EBUS_SUPPORT
-	if (!strcmp(op->node->parent->name, "ebus"))
+	if (!strcmp(op->dev.of_node->parent->name, "ebus"))
 		return cs4231_ebus_probe(op, match);
 #endif
 #ifdef SBUS_SUPPORT
-	if (!strcmp(op->node->parent->name, "sbus") ||
-	    !strcmp(op->node->parent->name, "sbi"))
+	if (!strcmp(op->dev.of_node->parent->name, "sbus") ||
+	    !strcmp(op->dev.of_node->parent->name, "sbi"))
 		return cs4231_sbus_probe(op, match);
 #endif
 	return -ENODEV;
diff --git a/sound/sparc/dbri.c b/sound/sparc/dbri.c
index 1d2e51b..2734c36 100644
--- a/sound/sparc/dbri.c
+++ b/sound/sparc/dbri.c
@@ -2650,7 +2650,7 @@ static int __devinit dbri_probe(struct of_device *op, const struct of_device_id
 
 	printk(KERN_INFO "audio%d at %p (irq %d) is DBRI(%c)+CS4215(%d)\n",
 	       dev, dbri->regs,
-	       dbri->irq, op->node->name[9], dbri->mm.version);
+	       dbri->irq, op->dev.of_node->name[9], dbri->mm.version);
 	dev++;
 
 	return 0;


^ permalink raw reply related

* [PATCH 35/37] arch/powerpc: Remove .archdata.of_node and use .of_node in struct device
From: Grant Likely @ 2010-03-11 18:07 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.of_node is being removed from Microblaze, SPARC and PowerPC
because it duplicates the struct device .of_node pointer.  This patch
also removes .node from struct of_device for the same reason.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 arch/powerpc/include/asm/device.h       |   16 ++++++++--------
 arch/powerpc/include/asm/of_device.h    |    1 -
 arch/powerpc/kernel/of_device.c         |    4 +---
 arch/powerpc/kernel/pci-common.c        |    1 -
 arch/powerpc/kernel/vio.c               |   17 ++++++++---------
 arch/powerpc/platforms/cell/iommu.c     |    5 ++---
 arch/powerpc/platforms/pasemi/setup.c   |    4 ++--
 arch/powerpc/platforms/ps3/system-bus.c |    1 -
 arch/powerpc/platforms/pseries/iommu.c  |    2 +-
 9 files changed, 22 insertions(+), 29 deletions(-)

diff --git a/arch/powerpc/include/asm/device.h b/arch/powerpc/include/asm/device.h
index 0aa81d3..3d6ff0a 100644
--- a/arch/powerpc/include/asm/device.h
+++ b/arch/powerpc/include/asm/device.h
@@ -10,8 +10,14 @@ struct dma_map_ops;
 struct device_node;
 
 struct dev_archdata {
-	/* Optional pointer to an OF device node */
-	struct device_node	*of_node;
+	/*
+	 * struct device_node *of_node;
+	 * This has been removed and moved into struct device proper.  If
+	 * this broke your code, then replace
+	 * (struct device *)->archdata.of_node
+	 *    with
+	 * (struct device *)->of_node
+	 */
 
 	/* DMA operations on that device */
 	struct dma_map_ops	*dma_ops;
@@ -30,12 +36,6 @@ struct dev_archdata {
 #endif
 };
 
-static inline void dev_archdata_set_node(struct dev_archdata *ad,
-					 struct device_node *np)
-{
-	ad->of_node = np;
-}
-
 struct pdev_archdata {
 };
 
diff --git a/arch/powerpc/include/asm/of_device.h b/arch/powerpc/include/asm/of_device.h
index a64debf..8b26f96 100644
--- a/arch/powerpc/include/asm/of_device.h
+++ b/arch/powerpc/include/asm/of_device.h
@@ -12,7 +12,6 @@
  */
 struct of_device
 {
-	struct device_node	*node;		/* to be obsoleted */
 	u64			dma_mask;	/* DMA mask */
 	struct device		dev;		/* Generic device interface */
 };
diff --git a/arch/powerpc/kernel/of_device.c b/arch/powerpc/kernel/of_device.c
index 55dafc7..20b3474 100644
--- a/arch/powerpc/kernel/of_device.c
+++ b/arch/powerpc/kernel/of_device.c
@@ -69,12 +69,10 @@ struct of_device *of_device_alloc(struct device_node *np,
 	if (!dev)
 		return NULL;
 
-	dev->node = of_node_get(np);
+	dev->dev.of_node = of_node_get(np);
 	dev->dev.dma_mask = &dev->dma_mask;
 	dev->dev.parent = parent;
 	dev->dev.release = of_release_dev;
-	dev->dev.archdata.of_node = np; /* temporary; remove after merging */
-	dev->dev.of_node = np;
 
 	if (bus_id)
 		dev_set_name(&dev->dev, "%s", bus_id);
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c
index 90501f2..ba3bb42 100644
--- a/arch/powerpc/kernel/pci-common.c
+++ b/arch/powerpc/kernel/pci-common.c
@@ -1112,7 +1112,6 @@ void __devinit pcibios_setup_bus_devices(struct pci_bus *bus)
 			continue;
 
 		/* Setup OF node pointer in the device */
-		sd->of_node = pci_device_to_OF_node(dev); /* temporary */
 		dev->dev.of_node = pci_device_to_OF_node(dev);
 
 		/* Fixup NUMA node as it may not be setup yet by the generic
diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c
index 70b52c7..d4981c6 100644
--- a/arch/powerpc/kernel/vio.c
+++ b/arch/powerpc/kernel/vio.c
@@ -704,7 +704,7 @@ static int vio_cmo_bus_probe(struct vio_dev *viodev)
 	 * Check to see that device has a DMA window and configure
 	 * entitlement for the device.
 	 */
-	if (of_get_property(viodev->dev.archdata.of_node,
+	if (of_get_property(viodev->dev.of_node,
 	                    "ibm,my-dma-window", NULL)) {
 		/* Check that the driver is CMO enabled and get desired DMA */
 		if (!viodrv->get_desired_dma) {
@@ -1048,7 +1048,7 @@ static struct iommu_table *vio_build_iommu_table(struct vio_dev *dev)
 	if (firmware_has_feature(FW_FEATURE_ISERIES))
 		return vio_build_iommu_table_iseries(dev);
 
-	dma_window = of_get_property(dev->dev.archdata.of_node,
+	dma_window = of_get_property(dev->dev.of_node,
 				  "ibm,my-dma-window", NULL);
 	if (!dma_window)
 		return NULL;
@@ -1057,7 +1057,7 @@ static struct iommu_table *vio_build_iommu_table(struct vio_dev *dev)
 	if (tbl == NULL)
 		return NULL;
 
-	of_parse_dma_window(dev->dev.archdata.of_node, dma_window,
+	of_parse_dma_window(dev->dev.of_node, dma_window,
 			    &tbl->it_index, &offset, &size);
 
 	/* TCE table size - measured in tce entries */
@@ -1085,7 +1085,7 @@ static const struct vio_device_id *vio_match_device(
 {
 	while (ids->type[0] != '\0') {
 		if ((strncmp(dev->type, ids->type, strlen(ids->type)) == 0) &&
-		    of_device_is_compatible(dev->dev.archdata.of_node,
+		    of_device_is_compatible(dev->dev.of_node,
 					 ids->compat))
 			return ids;
 		ids++;
@@ -1178,7 +1178,7 @@ EXPORT_SYMBOL(vio_unregister_driver);
 static void __devinit vio_dev_release(struct device *dev)
 {
 	/* XXX should free TCE table */
-	of_node_put(dev->archdata.of_node);
+	of_node_put(dev->of_node);
 	kfree(to_vio_dev(dev));
 }
 
@@ -1230,7 +1230,6 @@ struct vio_dev *vio_register_device_node(struct device_node *of_node)
 			viodev->unit_address = *unit_address;
 	}
 	viodev->dev.of_node = of_node_get(of_node);
-	viodev->dev.archdata.of_node = viodev->dev.of_node; /* temporary */
 
 	if (firmware_has_feature(FW_FEATURE_CMO))
 		vio_cmo_set_dma_ops(viodev);
@@ -1315,7 +1314,7 @@ static ssize_t name_show(struct device *dev,
 static ssize_t devspec_show(struct device *dev,
 		struct device_attribute *attr, char *buf)
 {
-	struct device_node *of_node = dev->archdata.of_node;
+	struct device_node *of_node = dev->of_node;
 
 	return sprintf(buf, "%s\n", of_node ? of_node->full_name : "none");
 }
@@ -1347,7 +1346,7 @@ static int vio_hotplug(struct device *dev, struct kobj_uevent_env *env)
 	struct device_node *dn;
 	const char *cp;
 
-	dn = dev->archdata.of_node;
+	dn = dev->of_node;
 	if (!dn)
 		return -ENODEV;
 	cp = of_get_property(dn, "compatible", NULL);
@@ -1378,7 +1377,7 @@ static struct bus_type vio_bus_type = {
 */
 const void *vio_get_attribute(struct vio_dev *vdev, char *which, int *length)
 {
-	return of_get_property(vdev->dev.archdata.of_node, which, length);
+	return of_get_property(vdev->dev.of_node, which, length);
 }
 EXPORT_SYMBOL(vio_get_attribute);
 
diff --git a/arch/powerpc/platforms/cell/iommu.c b/arch/powerpc/platforms/cell/iommu.c
index ca5bfdf..b610122 100644
--- a/arch/powerpc/platforms/cell/iommu.c
+++ b/arch/powerpc/platforms/cell/iommu.c
@@ -544,7 +544,6 @@ static struct iommu_table *cell_get_iommu_table(struct device *dev)
 {
 	struct iommu_window *window;
 	struct cbe_iommu *iommu;
-	struct dev_archdata *archdata = &dev->archdata;
 
 	/* Current implementation uses the first window available in that
 	 * node's iommu. We -might- do something smarter later though it may
@@ -553,7 +552,7 @@ static struct iommu_table *cell_get_iommu_table(struct device *dev)
 	iommu = cell_iommu_for_node(dev_to_node(dev));
 	if (iommu == NULL || list_empty(&iommu->windows)) {
 		printk(KERN_ERR "iommu: missing iommu for %s (node %d)\n",
-		       archdata->of_node ? archdata->of_node->full_name : "?",
+		       dev->of_node ? dev->of_node->full_name : "?",
 		       dev_to_node(dev));
 		return NULL;
 	}
@@ -896,7 +895,7 @@ static u64 cell_iommu_get_fixed_address(struct device *dev)
 	const u32 *ranges = NULL;
 	int i, len, best, naddr, nsize, pna, range_size;
 
-	np = of_node_get(dev->archdata.of_node);
+	np = of_node_get(dev->of_node);
 	while (1) {
 		naddr = of_n_addr_cells(np);
 		nsize = of_n_size_cells(np);
diff --git a/arch/powerpc/platforms/pasemi/setup.c b/arch/powerpc/platforms/pasemi/setup.c
index 242f809..0ba5f86 100644
--- a/arch/powerpc/platforms/pasemi/setup.c
+++ b/arch/powerpc/platforms/pasemi/setup.c
@@ -359,10 +359,10 @@ static int pcmcia_notify(struct notifier_block *nb, unsigned long action,
 	/* We know electra_cf devices will always have of_node set, since
 	 * electra_cf is an of_platform driver.
 	 */
-	if (!parent->archdata.of_node)
+	if (!parent->of_node)
 		return 0;
 
-	if (!of_device_is_compatible(parent->archdata.of_node, "electra-cf"))
+	if (!of_device_is_compatible(parent->of_node, "electra-cf"))
 		return 0;
 
 	/* We use the direct ops for localbus */
diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/platforms/ps3/system-bus.c
index 5f162c0..1a96243 100644
--- a/arch/powerpc/platforms/ps3/system-bus.c
+++ b/arch/powerpc/platforms/ps3/system-bus.c
@@ -766,7 +766,6 @@ int ps3_system_bus_device_register(struct ps3_system_bus_device *dev)
 	};
 
 	dev->core.of_node = NULL;
-	dev->core.archdata.of_node = NULL; /* temporary */
 	set_dev_node(&dev->core, 0);
 
 	pr_debug("%s:%d add %s\n", __func__, __LINE__, dev_name(&dev->core));
diff --git a/arch/powerpc/platforms/pseries/iommu.c b/arch/powerpc/platforms/pseries/iommu.c
index 1a0000a..d26182d 100644
--- a/arch/powerpc/platforms/pseries/iommu.c
+++ b/arch/powerpc/platforms/pseries/iommu.c
@@ -468,7 +468,7 @@ static void pci_dma_dev_setup_pSeries(struct pci_dev *dev)
 
 	pr_debug("pci_dma_dev_setup_pSeries: %s\n", pci_name(dev));
 
-	dn = dev->dev.archdata.of_node;
+	dn = dev->dev.of_node;
 
 	/* If we're the direct child of a root bus, then we need to allocate
 	 * an iommu table ourselves. The bus setup code should have setup


^ permalink raw reply related

* [PATCH 36/37] arch/microblaze: Remove .archdata.of_node and use .of_node in struct device
From: Grant Likely @ 2010-03-11 18:07 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.of_node is being removed from Microblaze, SPARC and PowerPC
because it duplicates the struct device .of_node pointer.  This patch
also removes .node from struct of_device for the same reason.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 arch/microblaze/include/asm/device.h    |    8 --------
 arch/microblaze/include/asm/of_device.h |    1 -
 arch/microblaze/kernel/of_device.c      |    4 +---
 3 files changed, 1 insertions(+), 12 deletions(-)

diff --git a/arch/microblaze/include/asm/device.h b/arch/microblaze/include/asm/device.h
index 2370888..8d46822 100644
--- a/arch/microblaze/include/asm/device.h
+++ b/arch/microblaze/include/asm/device.h
@@ -12,19 +12,11 @@
 struct device_node;
 
 struct dev_archdata {
-	/* Optional pointer to an OF device node */
-	struct device_node	*of_node;
 };
 
 struct pdev_archdata {
 };
 
-static inline void dev_archdata_set_node(struct dev_archdata *ad,
-					 struct device_node *np)
-{
-	ad->of_node = np;
-}
-
 #endif /* _ASM_MICROBLAZE_DEVICE_H */
 
 
diff --git a/arch/microblaze/include/asm/of_device.h b/arch/microblaze/include/asm/of_device.h
index ba917cf..ab25a40 100644
--- a/arch/microblaze/include/asm/of_device.h
+++ b/arch/microblaze/include/asm/of_device.h
@@ -21,7 +21,6 @@
  * probed using OF properties.
  */
 struct of_device {
-	struct device_node	*node; /* to be obsoleted */
 	u64			dma_mask; /* DMA mask */
 	struct device		dev; /* Generic device interface */
 };
diff --git a/arch/microblaze/kernel/of_device.c b/arch/microblaze/kernel/of_device.c
index ae165fc..ac7e6e1 100644
--- a/arch/microblaze/kernel/of_device.c
+++ b/arch/microblaze/kernel/of_device.c
@@ -49,12 +49,10 @@ struct of_device *of_device_alloc(struct device_node *np,
 	if (!dev)
 		return NULL;
 
-	dev->node = of_node_get(np);
+	dev->dev.of_node = of_node_get(np);
 	dev->dev.dma_mask = &dev->dma_mask;
 	dev->dev.parent = parent;
 	dev->dev.release = of_release_dev;
-	dev->dev.archdata.of_node = np; /* temporary; remove after merging */
-	dev->dev.of_node = np;
 
 	if (bus_id)
 		dev_set_name(&dev->dev, bus_id);


^ permalink raw reply related

* [PATCH 37/37] arch/sparc: Remove .archdata.of_node and use .of_node in struct device
From: Grant Likely @ 2010-03-11 18:07 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

.archdata.of_node is being removed from Microblaze, SPARC and PowerPC
because it duplicates the struct device .of_node pointer.  This patch
also removes .node from struct of_device for the same reason.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 arch/sparc/include/asm/device.h    |    9 ---------
 arch/sparc/include/asm/of_device.h |    1 -
 arch/sparc/kernel/of_device_32.c   |    3 ---
 arch/sparc/kernel/of_device_64.c   |    2 --
 arch/sparc/kernel/pci.c            |    1 -
 5 files changed, 0 insertions(+), 16 deletions(-)

diff --git a/arch/sparc/include/asm/device.h b/arch/sparc/include/asm/device.h
index 55dadca..d4c4521 100644
--- a/arch/sparc/include/asm/device.h
+++ b/arch/sparc/include/asm/device.h
@@ -13,19 +13,10 @@ struct dev_archdata {
 	void			*iommu;
 	void			*stc;
 	void			*host_controller;
-
-	struct device_node	*prom_node;
 	struct of_device	*op;
-
 	int			numa_node;
 };
 
-static inline void dev_archdata_set_node(struct dev_archdata *ad,
-					 struct device_node *np)
-{
-	ad->prom_node = np;
-}
-
 struct pdev_archdata {
 };
 
diff --git a/arch/sparc/include/asm/of_device.h b/arch/sparc/include/asm/of_device.h
index a5d9811..f320246 100644
--- a/arch/sparc/include/asm/of_device.h
+++ b/arch/sparc/include/asm/of_device.h
@@ -14,7 +14,6 @@
  */
 struct of_device
 {
-	struct device_node		*node;
 	struct device			dev;
 	struct resource			resource[PROMREG_MAX];
 	unsigned int			irqs[PROMINTR_MAX];
diff --git a/arch/sparc/kernel/of_device_32.c b/arch/sparc/kernel/of_device_32.c
index 909bee0..37ab163 100644
--- a/arch/sparc/kernel/of_device_32.c
+++ b/arch/sparc/kernel/of_device_32.c
@@ -345,12 +345,9 @@ static struct of_device * __init scan_one_device(struct device_node *dp,
 		return NULL;
 
 	sd = &op->dev.archdata;
-	sd->prom_node = dp; /* temporary */
 	sd->op = op;
 	op->dev.of_node = dp;
 
-	op->node = dp;
-
 	op->clock_freq = of_getintprop_default(dp, "clock-frequency",
 					       (25*1000*1000));
 	op->portid = of_getintprop_default(dp, "upa-portid", -1);
diff --git a/arch/sparc/kernel/of_device_64.c b/arch/sparc/kernel/of_device_64.c
index e436381..1dae807 100644
--- a/arch/sparc/kernel/of_device_64.c
+++ b/arch/sparc/kernel/of_device_64.c
@@ -640,11 +640,9 @@ static struct of_device * __init scan_one_device(struct device_node *dp,
 		return NULL;
 
 	sd = &op->dev.archdata;
-	sd->prom_node = dp; /* temporary */
 	sd->op = op;
 
 	op->dev.of_node = dp;
-	op->node = dp;
 
 	op->clock_freq = of_getintprop_default(dp, "clock-frequency",
 					       (25*1000*1000));
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
index 89c17d0..8a8363a 100644
--- a/arch/sparc/kernel/pci.c
+++ b/arch/sparc/kernel/pci.c
@@ -261,7 +261,6 @@ static struct pci_dev *of_create_pci_dev(struct pci_pbm_info *pbm,
 	sd->iommu = pbm->iommu;
 	sd->stc = &pbm->stc;
 	sd->host_controller = pbm;
-	sd->prom_node = node; /* temporary */
 	sd->op = op = of_find_device_by_node(node);
 	sd->numa_node = pbm->numa_node;
 


^ permalink raw reply related

* Re: [PATCH 0/7] tcp: bugs and cleanup for 2.6.34-rc1
From: Joe Perches @ 2010-03-11 18:14 UTC (permalink / raw)
  To: William Allen Simpson
  Cc: Eric Dumazet, Linus Torvalds, Andrew Morton,
	Linux Kernel Developers, Linux Kernel Network Developers,
	David Miller, Penttilä Mika
In-Reply-To: <4B992A89.6040700@gmail.com>

On Thu, 2010-03-11 at 12:38 -0500, William Allen Simpson wrote:
> > http://git2.kernel.org/?p=linux/kernel/git/davem/net-2.6.git;a=commit;h=28b2774a0d5852236dab77a4147b8b88548110f1

In that patch, it might be  better to use
	u16 s_data_desired = 0;
not
	int s_data_desired = 0;



^ permalink raw reply

* Re: [net-next-2.6 PATCH] ixgbe: convert to use netdev_for_each_mc_addr
From: Jeff Kirsher @ 2010-03-11 18:18 UTC (permalink / raw)
  To: Jiri Pirko; +Cc: netdev@vger.kernel.org, davem@davemloft.net
In-Reply-To: <20100311100809.GB3054@psychotron.lab.eng.brq.redhat.com>

On Thu, 2010-03-11 at 03:08 -0700, Jiri Pirko wrote:
> Wed, Feb 24, 2010 at 10:30:54AM CET, jeffrey.t.kirsher@intel.com wrote:
> >On Tue, Feb 23, 2010 at 11:05, Jiri Pirko <jpirko@redhat.com> wrote:
> >>
> >> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
> >> ---
> >>  drivers/net/ixgbe/ixgbe_common.c |   16 +++++++---------
> >>  drivers/net/ixgbe/ixgbe_common.h |    5 ++---
> >>  drivers/net/ixgbe/ixgbe_main.c   |   24 ++----------------------
> >>  drivers/net/ixgbe/ixgbe_type.h   |    3 +--
> >>  4 files changed, 12 insertions(+), 36 deletions(-)
> >>
> >
> >Thanks Jiri, I have added the patch to my queue of ixgbe patches.
> 
> Hi Jeff,
> 
> when do you think this and ixgbevf bits will be merged into net-next-2.6?
> 
> Thanks a lot.
> 
> Jirka

I am waiting for when Dave opens up net-next-2.6 to push this and a
couple other patches.  Usually net-next-2.6 opens up around -rc2 time
frame.

-- 
Cheers,
Jeff


^ permalink raw reply

* Re: [PATCH 00/37] OF: move device node pointer into struct device.
From: David Miller @ 2010-03-11 18:20 UTC (permalink / raw)
  To: grant.likely
  Cc: sfr, monstr, broonie, linux-scsi, linux-ide, benh,
	devicetree-discuss, gregkh, netdev, linux-kernel, jeremy.kerr,
	linuxppc-dev, James.Bottomley, linux-i2c, ben-linux,
	microblaze-uclinux, sparclinux, akpm, alsa-devel, jgarzik, dwmw2
In-Reply-To: <20100311174830.4824.19820.stgit@angua>

From: Grant Likely <grant.likely@secretlab.ca>
Date: Thu, 11 Mar 2010 11:03:47 -0700

> Currently on OF enabled platforms, the device node pointer is stored in
> both device.archdata.of_node (.prom_node on sparc), and in of_device.node
> OF device tree support is being generalized to work on any platform, so
> instead of adding the of_node pointer to each platform's archdata
> individually, this patch series moves the of_node pointer into struct
> device proper and fixes up all users to reference the new location.
> 
> The last 3 patches in this series remove the old .archdata.of_node,
> .archdata.prom_node and of_device.node instances.
> 
> This series has been compile tested on powerpc, sparc and microblaze,
> (allmodconfig used on sparc and powerpc) and boot tested on an mpc5200
> powerpc.  All known (or at least all I could find) in-tree users of the
> old names have been removed.

Three or four of the patches don't apply because only your tree
has those "/* temporary */" comments, f.e. in arch/sparc/kernel/pci.c

I took care of this when applying to my tree.

> This series should also be fully bisectable.  After I collect acks, I
> would like to get this whole series into linux-next to see if I've
> missed any references, but I can probably hold off merging the last
> three patches when the 2.6.35 merge window opens to give out of tree
> users a bit more time to adapt.  In fact, I'd probably wait a few
> extra days after pushing out the bulk of this series before I push the
> last 3 patches into my linux-next branch to isolate the drivers that I
> missed while fixing.

I'd rather you just apply the sparc one immediately in 2.6.35 and
not wait at all.

^ permalink raw reply

* [PATCH 00/27] Clean up of_platform drivers
From: Grant Likely @ 2010-03-11 18:21 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2

struct of_platform_driver unnecessarily duplicates the .owner and
.name fields from the encapsulated struct device_driver.  This patch
series goes through all of_platform drivers and makes it use the
device_driver instance so that the duplicate field can be removed.

Since every of_platform_driver is getting touched anyway, this series
takes the opportunity to also move the of_device_id match table out
of struct of_platform_driver and into struct device_driver proper.
This makes it possible for all bus types to make use of OF-style
binding when CONFIG_OF is set.

I've compile tested this on sparc, powerpc and microblaze.  It should
all be fully bisectable, and only the last patch removes the old
fields (ie. nothing should break without the last patch).

g.

---

Grant Likely (27):
      of: remove obsolete members from of_platform_driver
      arch/sparc/of: don't use deprecated field in of_platform_driver
      arch/powerpc/of: don't use deprecated field in of_platform_driver
      sound/of: don't use deprecated fields in of_platform_driver
      drivers/infiniband/of: don't use deprecated fields in of_platform_driver
      drivers/i2c/of: don't use deprecated field in of_platform_driver
      drivers/hwmon/of: don't use deprecated field in of_platform_driver
      drivers/mmc/of: don't use deprecated field in of_platform_driver
      drivers/pcmcia/of: don't use deprecated field in of_platform_driver
      drivers/parport/of: don't use deprecated field in of_platform_driver
      drivers/sbus/of: don't use deprecated field in of_platform_driver
      drivers/scsi/of: don't use deprecated field in of_platform_driver
      drivers/spi/of: don't use deprecated field in of_platform_driver
      drivers/serial/of: don't use deprecated field in of_platform_driver
      drivers/net/of: don't use deprecated field in of_platform_driver
      drivers/mtd/of: don't use deprecated field in of_platform_driver
      drivers/macintosh/of: don't use deprecated field in of_platform_driver
      drivers/input/of: don't use deprecated field in of_platform_driver
      drivers/atm/of: don't use deprecated field in of_platform_driver
      drivers/crypto/of: don't use deprecated field in of_platform_driver
      drivers/char/of: don't use deprecated field in of_platform_driver
      drivers/block/of: don't use deprecated field in of_platform_driver
      drivers/usb/of: don't use deprecated field in of_platform_driver
      drivers/video/of: don't use deprecated field in of_platform_driver
      drivers/watchdog/of: don't use deprecated .name and .owner in of_platform_driver
      drivers/gpio/of: don't use deprecated fields in of_platform_driver
      drivercore: Add of_match_table to the common device drivers


 arch/powerpc/kernel/ibmebus.c                 |    2 +-
 arch/powerpc/kernel/of_platform.c             |    3 ++-
 arch/powerpc/platforms/52xx/mpc52xx_gpio.c    |   14 ++++++++----
 arch/powerpc/platforms/52xx/mpc52xx_gpt.c     |    7 ++++--
 arch/powerpc/platforms/52xx/mpc52xx_lpbfifo.c |    8 ++++---
 arch/powerpc/platforms/82xx/ep8248e.c         |    3 ++-
 arch/powerpc/platforms/83xx/suspend.c         |    7 ++++--
 arch/powerpc/platforms/cell/axon_msi.c        |    7 +++---
 arch/powerpc/platforms/pasemi/gpio_mdio.c     |    7 +++---
 arch/powerpc/sysdev/axonram.c                 |    8 +++----
 arch/powerpc/sysdev/bestcomm/bestcomm.c       |   10 +++-----
 arch/powerpc/sysdev/fsl_msi.c                 |    7 ++++--
 arch/powerpc/sysdev/fsl_pmc.c                 |    7 ++++--
 arch/powerpc/sysdev/fsl_rio.c                 |    7 ++++--
 arch/powerpc/sysdev/pmi.c                     |    7 +++---
 arch/powerpc/sysdev/qe_lib/qe.c               |    7 ++++--
 arch/sparc/include/asm/parport.h              |    7 ++++--
 arch/sparc/kernel/apc.c                       |    7 ++++--
 arch/sparc/kernel/auxio_64.c                  |    7 +++---
 arch/sparc/kernel/central.c                   |   14 +++++++-----
 arch/sparc/kernel/chmc.c                      |    7 ++++--
 arch/sparc/kernel/pci_fire.c                  |    7 ++++--
 arch/sparc/kernel/pci_psycho.c                |    7 ++++--
 arch/sparc/kernel/pci_sabre.c                 |    7 ++++--
 arch/sparc/kernel/pci_schizo.c                |    7 ++++--
 arch/sparc/kernel/pci_sun4v.c                 |    7 ++++--
 arch/sparc/kernel/pmc.c                       |    7 ++++--
 arch/sparc/kernel/power.c                     |    7 +++---
 arch/sparc/kernel/time_32.c                   |    7 +++---
 arch/sparc/kernel/time_64.c                   |   21 ++++++++++--------
 drivers/ata/pata_of_platform.c                |    7 ++++--
 drivers/ata/sata_fsl.c                        |    7 ++++--
 drivers/atm/fore200e.c                        |    7 ++++--
 drivers/block/xsysace.c                       |    5 ++--
 drivers/char/hw_random/n2-drv.c               |    7 ++++--
 drivers/char/hw_random/pasemi-rng.c           |    7 ++++--
 drivers/char/ipmi/ipmi_si_intf.c              |    7 ++++--
 drivers/char/xilinx_hwicap/xilinx_hwicap.c    |    5 ++--
 drivers/crypto/amcc/crypto4xx_core.c          |    7 ++++--
 drivers/crypto/talitos.c                      |    7 ++++--
 drivers/dma/fsldma.c                          |   13 +++++++----
 drivers/dma/ppc4xx/adma.c                     |    2 +-
 drivers/edac/mpc85xx_edac.c                   |   30 ++++++++++---------------
 drivers/edac/ppc4xx_edac.c                    |   10 ++++----
 drivers/hwmon/ultra45_env.c                   |    7 ++++--
 drivers/i2c/busses/i2c-cpm.c                  |   10 ++++----
 drivers/i2c/busses/i2c-ibm_iic.c              |    7 ++++--
 drivers/i2c/busses/i2c-mpc.c                  |    8 +++----
 drivers/infiniband/hw/ehca/ehca_main.c        |    7 +++---
 drivers/input/misc/sparcspkr.c                |   14 ++++++++----
 drivers/input/serio/i8042-sparcio.h           |    7 ++++--
 drivers/input/serio/xilinx_ps2.c              |    7 ++++--
 drivers/leds/leds-gpio.c                      |    2 +-
 drivers/macintosh/macio_asic.c                |    5 ++--
 drivers/macintosh/smu.c                       |    7 ++++--
 drivers/macintosh/therm_pm72.c                |    7 ++++--
 drivers/macintosh/therm_windtunnel.c          |    7 ++++--
 drivers/mmc/host/sdhci-of-core.c              |    7 ++++--
 drivers/mtd/maps/physmap_of.c                 |    7 ++++--
 drivers/mtd/maps/sun_uflash.c                 |    7 ++++--
 drivers/mtd/nand/fsl_elbc_nand.c              |    5 +++-
 drivers/mtd/nand/fsl_upm.c                    |    7 ++++--
 drivers/mtd/nand/ndfc.c                       |    5 +++-
 drivers/mtd/nand/pasemi_nand.c                |    7 ++++--
 drivers/mtd/nand/socrates_nand.c              |    7 ++++--
 drivers/net/can/mscan/mpc5xxx_can.c           |    8 ++++---
 drivers/net/can/sja1000/sja1000_of_platform.c |    8 ++++---
 drivers/net/ehea/ehea_main.c                  |    7 ++++--
 drivers/net/fs_enet/fs_enet-main.c            |    7 ++++--
 drivers/net/fs_enet/mii-bitbang.c             |    7 ++++--
 drivers/net/fs_enet/mii-fec.c                 |    7 ++++--
 drivers/net/fsl_pq_mdio.c                     |    7 ++++--
 drivers/net/gianfar.c                         |   10 +++++---
 drivers/net/ibm_newemac/core.c                |    8 ++++---
 drivers/net/ibm_newemac/mal.c                 |    8 ++++---
 drivers/net/ibm_newemac/rgmii.c               |    8 ++++---
 drivers/net/ibm_newemac/tah.c                 |    8 ++++---
 drivers/net/ibm_newemac/zmii.c                |    8 ++++---
 drivers/net/ll_temac_main.c                   |    2 +-
 drivers/net/myri_sbus.c                       |    7 ++++--
 drivers/net/niu.c                             |    7 ++++--
 drivers/net/phy/mdio-gpio.c                   |    7 ++++--
 drivers/net/sunbmac.c                         |    7 ++++--
 drivers/net/sunhme.c                          |    7 ++++--
 drivers/net/sunlance.c                        |    7 ++++--
 drivers/net/sunqe.c                           |    7 ++++--
 drivers/net/ucc_geth.c                        |    7 ++++--
 drivers/net/xilinx_emaclite.c                 |    7 ++++--
 drivers/of/platform.c                         |   10 ++------
 drivers/parport/parport_sunbpp.c              |    7 ++++--
 drivers/pcmcia/electra_cf.c                   |    7 ++++--
 drivers/pcmcia/m8xx_pcmcia.c                  |    7 ++++--
 drivers/sbus/char/bbc_i2c.c                   |    7 ++++--
 drivers/sbus/char/display7seg.c               |    7 ++++--
 drivers/sbus/char/envctrl.c                   |    7 ++++--
 drivers/sbus/char/flash.c                     |    7 ++++--
 drivers/sbus/char/uctrl.c                     |    7 ++++--
 drivers/scsi/qlogicpti.c                      |    7 ++++--
 drivers/scsi/sun_esp.c                        |    7 ++++--
 drivers/serial/apbuart.c                      |    8 +++----
 drivers/serial/cpm_uart/cpm_uart_core.c       |    7 ++++--
 drivers/serial/mpc52xx_uart.c                 |    7 +++---
 drivers/serial/of_serial.c                    |    8 ++++---
 drivers/serial/sunhv.c                        |    7 ++++--
 drivers/serial/sunsab.c                       |    7 ++++--
 drivers/serial/sunsu.c                        |    7 ++++--
 drivers/serial/sunzilog.c                     |    7 ++++--
 drivers/serial/uartlite.c                     |    5 ++--
 drivers/serial/ucc_uart.c                     |    8 ++++---
 drivers/spi/mpc52xx_psc_spi.c                 |    4 +--
 drivers/spi/mpc52xx_spi.c                     |    8 ++++---
 drivers/spi/spi_mpc8xxx.c                     |    7 ++++--
 drivers/spi/spi_ppc4xx.c                      |    2 +-
 drivers/spi/xilinx_spi_of.c                   |    2 +-
 drivers/usb/gadget/fsl_qe_udc.c               |    7 ++++--
 drivers/usb/host/ehci-ppc-of.c                |    9 +++-----
 drivers/usb/host/ehci-xilinx-of.c             |    9 +++-----
 drivers/usb/host/fhci-hcd.c                   |    7 ++++--
 drivers/usb/host/isp1760-if.c                 |    7 ++++--
 drivers/usb/host/ohci-ppc-of.c                |   13 +++--------
 drivers/video/bw2.c                           |    7 ++++--
 drivers/video/cg14.c                          |    7 ++++--
 drivers/video/cg3.c                           |    7 ++++--
 drivers/video/cg6.c                           |    7 ++++--
 drivers/video/ffb.c                           |    7 ++++--
 drivers/video/fsl-diu-fb.c                    |    8 ++++---
 drivers/video/leo.c                           |    7 ++++--
 drivers/video/mb862xx/mb862xxfb.c             |    8 ++++---
 drivers/video/p9100.c                         |    7 ++++--
 drivers/video/platinumfb.c                    |    7 ++++--
 drivers/video/tcx.c                           |    7 ++++--
 drivers/video/xilinxfb.c                      |    5 ++--
 drivers/watchdog/cpwd.c                       |    7 ++++--
 drivers/watchdog/gef_wdt.c                    |    8 ++++---
 drivers/watchdog/mpc8xxx_wdt.c                |    8 +++----
 drivers/watchdog/riowd.c                      |    7 ++++--
 include/linux/device.h                        |    4 +++
 include/linux/of_platform.h                   |    4 ---
 sound/soc/fsl/mpc5200_psc_ac97.c              |    2 +-
 sound/soc/fsl/mpc5200_psc_i2s.c               |    2 +-
 sound/soc/fsl/mpc8610_hpcd.c                  |    8 ++++---
 sound/sparc/amd7930.c                         |    7 ++++--
 sound/sparc/cs4231.c                          |    7 ++++--
 sound/sparc/dbri.c                            |    7 ++++--
 144 files changed, 665 insertions(+), 380 deletions(-)

-- 
Signature

^ permalink raw reply

* [PATCH 04/27] drivers/video/of: don't use deprecated field in of_platform_driver
From: Grant Likely @ 2010-03-11 18:22 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311181604.13103.30088.stgit@angua>

.name, .match_table and .owner are duplicated in both of_platform_driver
and device_driver, so the of_platform_driver copies will be removed soon.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/video/bw2.c               |    7 +++++--
 drivers/video/cg14.c              |    7 +++++--
 drivers/video/cg3.c               |    7 +++++--
 drivers/video/cg6.c               |    7 +++++--
 drivers/video/ffb.c               |    7 +++++--
 drivers/video/fsl-diu-fb.c        |    8 +++++---
 drivers/video/leo.c               |    7 +++++--
 drivers/video/mb862xx/mb862xxfb.c |    8 +++++---
 drivers/video/p9100.c             |    7 +++++--
 drivers/video/platinumfb.c        |    7 +++++--
 drivers/video/tcx.c               |    7 +++++--
 drivers/video/xilinxfb.c          |    5 ++---
 12 files changed, 57 insertions(+), 27 deletions(-)

diff --git a/drivers/video/bw2.c b/drivers/video/bw2.c
index b0b147c..05d6663 100644
--- a/drivers/video/bw2.c
+++ b/drivers/video/bw2.c
@@ -377,8 +377,11 @@ static const struct of_device_id bw2_match[] = {
 MODULE_DEVICE_TABLE(of, bw2_match);
 
 static struct of_platform_driver bw2_driver = {
-	.name		= "bw2",
-	.match_table	= bw2_match,
+	.driver = {
+		.name = "bw2",
+		.owner = THIS_MODULE,
+		.of_match_table = bw2_match,
+	},
 	.probe		= bw2_probe,
 	.remove		= __devexit_p(bw2_remove),
 };
diff --git a/drivers/video/cg14.c b/drivers/video/cg14.c
index fe45a3b..5634131 100644
--- a/drivers/video/cg14.c
+++ b/drivers/video/cg14.c
@@ -597,8 +597,11 @@ static const struct of_device_id cg14_match[] = {
 MODULE_DEVICE_TABLE(of, cg14_match);
 
 static struct of_platform_driver cg14_driver = {
-	.name		= "cg14",
-	.match_table	= cg14_match,
+	.driver = {
+		.name = "cg14",
+		.owner = THIS_MODULE,
+		.of_match_table = cg14_match,
+	},
 	.probe		= cg14_probe,
 	.remove		= __devexit_p(cg14_remove),
 };
diff --git a/drivers/video/cg3.c b/drivers/video/cg3.c
index b2319fa..a807823 100644
--- a/drivers/video/cg3.c
+++ b/drivers/video/cg3.c
@@ -464,8 +464,11 @@ static const struct of_device_id cg3_match[] = {
 MODULE_DEVICE_TABLE(of, cg3_match);
 
 static struct of_platform_driver cg3_driver = {
-	.name		= "cg3",
-	.match_table	= cg3_match,
+	.driver = {
+		.name = "cg3",
+		.owner = THIS_MODULE,
+		.of_match_table = cg3_match,
+	},
 	.probe		= cg3_probe,
 	.remove		= __devexit_p(cg3_remove),
 };
diff --git a/drivers/video/cg6.c b/drivers/video/cg6.c
index 978c15f..ecfcf69 100644
--- a/drivers/video/cg6.c
+++ b/drivers/video/cg6.c
@@ -857,8 +857,11 @@ static const struct of_device_id cg6_match[] = {
 MODULE_DEVICE_TABLE(of, cg6_match);
 
 static struct of_platform_driver cg6_driver = {
-	.name		= "cg6",
-	.match_table	= cg6_match,
+	.driver = {
+		.name = "cg6",
+		.owner = THIS_MODULE,
+		.of_match_table = cg6_match,
+	},
 	.probe		= cg6_probe,
 	.remove		= __devexit_p(cg6_remove),
 };
diff --git a/drivers/video/ffb.c b/drivers/video/ffb.c
index be0c982..d1a9515 100644
--- a/drivers/video/ffb.c
+++ b/drivers/video/ffb.c
@@ -1054,8 +1054,11 @@ static const struct of_device_id ffb_match[] = {
 MODULE_DEVICE_TABLE(of, ffb_match);
 
 static struct of_platform_driver ffb_driver = {
-	.name		= "ffb",
-	.match_table	= ffb_match,
+	.driver = {
+		.name = "ffb",
+		.owner = THIS_MODULE,
+		.of_match_table = ffb_match,
+	},
 	.probe		= ffb_probe,
 	.remove		= __devexit_p(ffb_remove),
 };
diff --git a/drivers/video/fsl-diu-fb.c b/drivers/video/fsl-diu-fb.c
index 4637bcb..94ac2c0 100644
--- a/drivers/video/fsl-diu-fb.c
+++ b/drivers/video/fsl-diu-fb.c
@@ -1646,9 +1646,11 @@ static struct of_device_id fsl_diu_match[] = {
 MODULE_DEVICE_TABLE(of, fsl_diu_match);
 
 static struct of_platform_driver fsl_diu_driver = {
-	.owner  	= THIS_MODULE,
-	.name   	= "fsl_diu",
-	.match_table    = fsl_diu_match,
+	.driver = {
+		.name = "fsl_diu",
+		.owner = THIS_MODULE,
+		.of_match_table = fsl_diu_match,
+	},
 	.probe  	= fsl_diu_probe,
 	.remove 	= fsl_diu_remove,
 	.suspend	= fsl_diu_suspend,
diff --git a/drivers/video/leo.c b/drivers/video/leo.c
index e145e2d..cf79cb7 100644
--- a/drivers/video/leo.c
+++ b/drivers/video/leo.c
@@ -664,8 +664,11 @@ static const struct of_device_id leo_match[] = {
 MODULE_DEVICE_TABLE(of, leo_match);
 
 static struct of_platform_driver leo_driver = {
-	.name		= "leo",
-	.match_table	= leo_match,
+	.driver = {
+		.name = "leo",
+		.owner = THIS_MODULE,
+		.of_match_table = leo_match,
+	},
 	.probe		= leo_probe,
 	.remove		= __devexit_p(leo_remove),
 };
diff --git a/drivers/video/mb862xx/mb862xxfb.c b/drivers/video/mb862xx/mb862xxfb.c
index fabb0c5..664665c 100644
--- a/drivers/video/mb862xx/mb862xxfb.c
+++ b/drivers/video/mb862xx/mb862xxfb.c
@@ -731,9 +731,11 @@ static struct of_device_id __devinitdata of_platform_mb862xx_tbl[] = {
 };
 
 static struct of_platform_driver of_platform_mb862xxfb_driver = {
-	.owner		= THIS_MODULE,
-	.name		= DRV_NAME,
-	.match_table	= of_platform_mb862xx_tbl,
+	.driver = {
+		.name = DRV_NAME,
+		.owner = THIS_MODULE,
+		.of_match_table = of_platform_mb862xx_tbl,
+	},
 	.probe		= of_platform_mb862xx_probe,
 	.remove		= __devexit_p(of_platform_mb862xx_remove),
 };
diff --git a/drivers/video/p9100.c b/drivers/video/p9100.c
index 7fa4ab0..cf67b99 100644
--- a/drivers/video/p9100.c
+++ b/drivers/video/p9100.c
@@ -354,8 +354,11 @@ static const struct of_device_id p9100_match[] = {
 MODULE_DEVICE_TABLE(of, p9100_match);
 
 static struct of_platform_driver p9100_driver = {
-	.name		= "p9100",
-	.match_table	= p9100_match,
+	.driver = {
+		.name = "p9100",
+		.owner = THIS_MODULE,
+		.of_match_table = p9100_match,
+	},
 	.probe		= p9100_probe,
 	.remove		= __devexit_p(p9100_remove),
 };
diff --git a/drivers/video/platinumfb.c b/drivers/video/platinumfb.c
index 0a366d8..af04cca 100644
--- a/drivers/video/platinumfb.c
+++ b/drivers/video/platinumfb.c
@@ -680,8 +680,11 @@ static struct of_device_id platinumfb_match[] =
 
 static struct of_platform_driver platinum_driver = 
 {
-	.name 		= "platinumfb",
-	.match_table	= platinumfb_match,
+	.driver = {
+		.name = "platinumfb",
+		.owner = THIS_MODULE,
+		.of_match_table = platinumfb_match,
+	},
 	.probe		= platinumfb_probe,
 	.remove		= platinumfb_remove,
 };
diff --git a/drivers/video/tcx.c b/drivers/video/tcx.c
index 45b8835..1140dd0 100644
--- a/drivers/video/tcx.c
+++ b/drivers/video/tcx.c
@@ -513,8 +513,11 @@ static const struct of_device_id tcx_match[] = {
 MODULE_DEVICE_TABLE(of, tcx_match);
 
 static struct of_platform_driver tcx_driver = {
-	.name		= "tcx",
-	.match_table	= tcx_match,
+	.driver = {
+		.name = "tcx",
+		.owner = THIS_MODULE,
+		.of_match_table = tcx_match,
+	},
 	.probe		= tcx_probe,
 	.remove		= __devexit_p(tcx_remove),
 };
diff --git a/drivers/video/xilinxfb.c b/drivers/video/xilinxfb.c
index ed7c8d0..d7654ab 100644
--- a/drivers/video/xilinxfb.c
+++ b/drivers/video/xilinxfb.c
@@ -491,13 +491,12 @@ static struct of_device_id xilinxfb_of_match[] __devinitdata = {
 MODULE_DEVICE_TABLE(of, xilinxfb_of_match);
 
 static struct of_platform_driver xilinxfb_of_driver = {
-	.owner = THIS_MODULE,
-	.name = DRIVER_NAME,
-	.match_table = xilinxfb_of_match,
 	.probe = xilinxfb_of_probe,
 	.remove = __devexit_p(xilinxfb_of_remove),
 	.driver = {
 		.name = DRIVER_NAME,
+		.owner = THIS_MODULE,
+		.of_match_table = xilinxfb_of_match,
 	},
 };
 


^ permalink raw reply related

* [PATCH 07/27] drivers/char/of: don't use deprecated field in of_platform_driver
From: Grant Likely @ 2010-03-11 18:22 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311181604.13103.30088.stgit@angua>

.name, .match_table and .owner are duplicated in both of_platform_driver
and device_driver, so the of_platform_driver copies will be removed soon.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/char/hw_random/n2-drv.c            |    7 +++++--
 drivers/char/hw_random/pasemi-rng.c        |    7 +++++--
 drivers/char/ipmi/ipmi_si_intf.c           |    7 +++++--
 drivers/char/xilinx_hwicap/xilinx_hwicap.c |    5 ++---
 4 files changed, 17 insertions(+), 9 deletions(-)

diff --git a/drivers/char/hw_random/n2-drv.c b/drivers/char/hw_random/n2-drv.c
index 4d05003..c82a571 100644
--- a/drivers/char/hw_random/n2-drv.c
+++ b/drivers/char/hw_random/n2-drv.c
@@ -751,8 +751,11 @@ static const struct of_device_id n2rng_match[] = {
 MODULE_DEVICE_TABLE(of, n2rng_match);
 
 static struct of_platform_driver n2rng_driver = {
-	.name		= "n2rng",
-	.match_table	= n2rng_match,
+	.driver = {
+		.name = "n2rng",
+		.owner = THIS_MODULE,
+		.of_match_table = n2rng_match,
+	},
 	.probe		= n2rng_probe,
 	.remove		= __devexit_p(n2rng_remove),
 };
diff --git a/drivers/char/hw_random/pasemi-rng.c b/drivers/char/hw_random/pasemi-rng.c
index b213855..261ba8f 100644
--- a/drivers/char/hw_random/pasemi-rng.c
+++ b/drivers/char/hw_random/pasemi-rng.c
@@ -140,8 +140,11 @@ static struct of_device_id rng_match[] = {
 };
 
 static struct of_platform_driver rng_driver = {
-	.name		= "pasemi-rng",
-	.match_table	= rng_match,
+	.driver = {
+		.name = "pasemi-rng",
+		.owner = THIS_MODULE,
+		.of_match_table = rng_match,
+	},
 	.probe		= rng_probe,
 	.remove		= rng_remove,
 };
diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c
index 45305f2..012e63b 100644
--- a/drivers/char/ipmi/ipmi_si_intf.c
+++ b/drivers/char/ipmi/ipmi_si_intf.c
@@ -2492,8 +2492,11 @@ static struct of_device_id ipmi_match[] =
 };
 
 static struct of_platform_driver ipmi_of_platform_driver = {
-	.name		= "ipmi",
-	.match_table	= ipmi_match,
+	.driver = {
+		.name = "ipmi",
+		.owner = THIS_MODULE,
+		.of_match_table = ipmi_match,
+	},
 	.probe		= ipmi_of_probe,
 	.remove		= __devexit_p(ipmi_of_remove),
 };
diff --git a/drivers/char/xilinx_hwicap/xilinx_hwicap.c b/drivers/char/xilinx_hwicap/xilinx_hwicap.c
index 4846d50..1fb8665 100644
--- a/drivers/char/xilinx_hwicap/xilinx_hwicap.c
+++ b/drivers/char/xilinx_hwicap/xilinx_hwicap.c
@@ -811,13 +811,12 @@ static const struct of_device_id __devinitconst hwicap_of_match[] = {
 MODULE_DEVICE_TABLE(of, hwicap_of_match);
 
 static struct of_platform_driver hwicap_of_driver = {
-	.owner = THIS_MODULE,
-	.name = DRIVER_NAME,
-	.match_table = hwicap_of_match,
 	.probe = hwicap_of_probe,
 	.remove = __devexit_p(hwicap_of_remove),
 	.driver = {
 		.name = DRIVER_NAME,
+		.owner = THIS_MODULE,
+		.of_match_table = hwicap_of_match,
 	},
 };
 


^ permalink raw reply related

* [PATCH 06/27] drivers/block/of: don't use deprecated field in of_platform_driver
From: Grant Likely @ 2010-03-11 18:22 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311181604.13103.30088.stgit@angua>

.name, .match_table and .owner are duplicated in both of_platform_driver
and device_driver, so the of_platform_driver copies will be removed soon.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/ata/pata_of_platform.c |    7 +++++--
 drivers/ata/sata_fsl.c         |    7 +++++--
 drivers/block/xsysace.c        |    5 ++---
 3 files changed, 12 insertions(+), 7 deletions(-)

diff --git a/drivers/ata/pata_of_platform.c b/drivers/ata/pata_of_platform.c
index 19da29f..5a1b82c 100644
--- a/drivers/ata/pata_of_platform.c
+++ b/drivers/ata/pata_of_platform.c
@@ -91,8 +91,11 @@ static struct of_device_id pata_of_platform_match[] = {
 MODULE_DEVICE_TABLE(of, pata_of_platform_match);
 
 static struct of_platform_driver pata_of_platform_driver = {
-	.name		= "pata_of_platform",
-	.match_table	= pata_of_platform_match,
+	.driver = {
+		.name = "pata_of_platform",
+		.owner = THIS_MODULE,
+		.of_match_table = pata_of_platform_match,
+	},
 	.probe		= pata_of_platform_probe,
 	.remove		= __devexit_p(pata_of_platform_remove),
 };
diff --git a/drivers/ata/sata_fsl.c b/drivers/ata/sata_fsl.c
index ce4136e..463fb9c 100644
--- a/drivers/ata/sata_fsl.c
+++ b/drivers/ata/sata_fsl.c
@@ -1426,8 +1426,11 @@ static struct of_device_id fsl_sata_match[] = {
 MODULE_DEVICE_TABLE(of, fsl_sata_match);
 
 static struct of_platform_driver fsl_sata_driver = {
-	.name		= "fsl-sata",
-	.match_table	= fsl_sata_match,
+	.driver = {
+		.name = "fsl-sata",
+		.owner = THIS_MODULE,
+		.of_match_table = fsl_sata_match,
+	},
 	.probe		= sata_fsl_probe,
 	.remove		= sata_fsl_remove,
 #ifdef CONFIG_PM
diff --git a/drivers/block/xsysace.c b/drivers/block/xsysace.c
index e1c95e2..cffcd71 100644
--- a/drivers/block/xsysace.c
+++ b/drivers/block/xsysace.c
@@ -1237,13 +1237,12 @@ static const struct of_device_id ace_of_match[] __devinitconst = {
 MODULE_DEVICE_TABLE(of, ace_of_match);
 
 static struct of_platform_driver ace_of_driver = {
-	.owner = THIS_MODULE,
-	.name = "xsysace",
-	.match_table = ace_of_match,
 	.probe = ace_of_probe,
 	.remove = __devexit_p(ace_of_remove),
 	.driver = {
 		.name = "xsysace",
+		.owner = THIS_MODULE,
+		.of_match_table = ace_of_match,
 	},
 };
 


^ permalink raw reply related

* [PATCH 08/27] drivers/crypto/of: don't use deprecated field in of_platform_driver
From: Grant Likely @ 2010-03-11 18:22 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311181604.13103.30088.stgit@angua>

.name, .match_table and .owner are duplicated in both of_platform_driver
and device_driver, so the of_platform_driver copies will be removed soon.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/crypto/amcc/crypto4xx_core.c |    7 +++++--
 drivers/crypto/talitos.c             |    7 +++++--
 2 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/drivers/crypto/amcc/crypto4xx_core.c b/drivers/crypto/amcc/crypto4xx_core.c
index 1c3849f..36b5fb1 100644
--- a/drivers/crypto/amcc/crypto4xx_core.c
+++ b/drivers/crypto/amcc/crypto4xx_core.c
@@ -1280,8 +1280,11 @@ static const struct of_device_id crypto4xx_match[] = {
 };
 
 static struct of_platform_driver crypto4xx_driver = {
-	.name		= "crypto4xx",
-	.match_table	= crypto4xx_match,
+	.driver = {
+		.name = "crypto4xx",
+		.owner = THIS_MODULE,
+		.of_match_table = crypto4xx_match,
+	},
 	.probe		= crypto4xx_probe,
 	.remove		= crypto4xx_remove,
 };
diff --git a/drivers/crypto/talitos.c b/drivers/crypto/talitos.c
index fd529d6..917faf7 100644
--- a/drivers/crypto/talitos.c
+++ b/drivers/crypto/talitos.c
@@ -1967,8 +1967,11 @@ static const struct of_device_id talitos_match[] = {
 MODULE_DEVICE_TABLE(of, talitos_match);
 
 static struct of_platform_driver talitos_driver = {
-	.name = "talitos",
-	.match_table = talitos_match,
+	.driver = {
+		.name = "talitos",
+		.owner = THIS_MODULE,
+		.of_match_table = talitos_match,
+	},
 	.probe = talitos_probe,
 	.remove = talitos_remove,
 };


^ permalink raw reply related

* [PATCH 10/27] drivers/input/of: don't use deprecated field in of_platform_driver
From: Grant Likely @ 2010-03-11 18:22 UTC (permalink / raw)
  To: monstr, gregkh, benh, akpm, davem, sfr, jgarzik, ben-linux, dwmw2
In-Reply-To: <20100311181604.13103.30088.stgit@angua>

.name, .match_table and .owner are duplicated in both of_platform_driver
and device_driver, so the of_platform_driver copies will be removed soon.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---

 drivers/input/misc/sparcspkr.c      |   14 ++++++++++----
 drivers/input/serio/i8042-sparcio.h |    7 +++++--
 drivers/input/serio/xilinx_ps2.c    |    7 +++++--
 3 files changed, 20 insertions(+), 8 deletions(-)

diff --git a/drivers/input/misc/sparcspkr.c b/drivers/input/misc/sparcspkr.c
index b064419..11ad153 100644
--- a/drivers/input/misc/sparcspkr.c
+++ b/drivers/input/misc/sparcspkr.c
@@ -258,8 +258,11 @@ static const struct of_device_id bbc_beep_match[] = {
 };
 
 static struct of_platform_driver bbc_beep_driver = {
-	.name		= "bbcbeep",
-	.match_table	= bbc_beep_match,
+	.driver = {
+		.name = "bbcbeep",
+		.owner = THIS_MODULE,
+		.of_match_table = bbc_beep_match,
+	},
 	.probe		= bbc_beep_probe,
 	.remove		= __devexit_p(bbc_remove),
 	.shutdown	= sparcspkr_shutdown,
@@ -337,8 +340,11 @@ static const struct of_device_id grover_beep_match[] = {
 };
 
 static struct of_platform_driver grover_beep_driver = {
-	.name		= "groverbeep",
-	.match_table	= grover_beep_match,
+	.driver = {
+		.name = "groverbeep",
+		.owner = THIS_MODULE,
+		.of_match_table = grover_beep_match,
+	},
 	.probe		= grover_beep_probe,
 	.remove		= __devexit_p(grover_remove),
 	.shutdown	= sparcspkr_shutdown,
diff --git a/drivers/input/serio/i8042-sparcio.h b/drivers/input/serio/i8042-sparcio.h
index 29e1769..04e32f2 100644
--- a/drivers/input/serio/i8042-sparcio.h
+++ b/drivers/input/serio/i8042-sparcio.h
@@ -96,8 +96,11 @@ static const struct of_device_id sparc_i8042_match[] = {
 MODULE_DEVICE_TABLE(of, sparc_i8042_match);
 
 static struct of_platform_driver sparc_i8042_driver = {
-	.name		= "i8042",
-	.match_table	= sparc_i8042_match,
+	.driver = {
+		.name = "i8042",
+		.owner = THIS_MODULE,
+		.of_match_table = sparc_i8042_match,
+	},
 	.probe		= sparc_i8042_probe,
 	.remove		= __devexit_p(sparc_i8042_remove),
 };
diff --git a/drivers/input/serio/xilinx_ps2.c b/drivers/input/serio/xilinx_ps2.c
index f154153..e787053 100644
--- a/drivers/input/serio/xilinx_ps2.c
+++ b/drivers/input/serio/xilinx_ps2.c
@@ -361,8 +361,11 @@ static const struct of_device_id xps2_of_match[] __devinitconst = {
 MODULE_DEVICE_TABLE(of, xps2_of_match);
 
 static struct of_platform_driver xps2_of_driver = {
-	.name		= DRIVER_NAME,
-	.match_table	= xps2_of_match,
+	.driver = {
+		.name = DRIVER_NAME,
+		.owner = THIS_MODULE,
+		.of_match_table = xps2_of_match,
+	},
 	.probe		= xps2_of_probe,
 	.remove		= __devexit_p(xps2_of_remove),
 };


^ permalink raw reply related


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox