From: Sean MacLennan <smaclennan@pikatech.com>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: linux-kernel@vger.kernel.org, michal.simek@petalogix.com,
microblaze-uclinux@itee.uq.edu.au, sparclinux@vger.kernel.org,
linuxppc-dev@lists.ozlabs.org, davem@davemloft.net
Subject: Re: [V2 PATCH 06/10] of/drivers: Always use struct device.of_node to get node pointer
Date: Thu, 18 Mar 2010 12:59:39 -0400 [thread overview]
Message-ID: <20100318125939.2b39d7f2@lappy.seanm.ca> (raw)
In-Reply-To: <20100318152238.21082.10985.stgit@angua>
On Thu, 18 Mar 2010 09:22:39 -0600
Grant Likely <grant.likely@secretlab.ca> wrote:
> The following structure elements duplicate the information in
> 'struct device.of_node' and so are being eliminated. This patches
> makes all readers of the following elements use device.of_node
> instead.
The NDFC driver also needs a patch... or at least the version from your
last of_patch set does. I am included the patch I needed to get it to
compile.
Cheers,
Sean
diff --git a/drivers/mtd/nand/ndfc.c b/drivers/mtd/nand/ndfc.c
index 19d94a2..5a232ec 100644
--- a/drivers/mtd/nand/ndfc.c
+++ b/drivers/mtd/nand/ndfc.c
@@ -238,14 +238,14 @@ static int __devinit ndfc_probe(struct of_device *ofdev,
dev_set_drvdata(&ofdev->dev, ndfc);
/* Read the reg property to get the chip select */
- reg = of_get_property(ofdev->node, "reg", &len);
+ reg = of_get_property(ofdev->dev.of_node, "reg", &len);
if (reg == NULL || len != 12) {
dev_err(&ofdev->dev, "unable read reg property (%d)\n", len);
return -ENOENT;
}
ndfc->chip_select = reg[0];
- ndfc->ndfcbase = of_iomap(ofdev->node, 0);
+ ndfc->ndfcbase = of_iomap(ofdev->dev.of_node, 0);
if (!ndfc->ndfcbase) {
dev_err(&ofdev->dev, "failed to get memory\n");
return -EIO;
@@ -254,20 +254,20 @@ static int __devinit ndfc_probe(struct of_device *ofdev,
ccr = NDFC_CCR_BS(ndfc->chip_select);
/* It is ok if ccr does not exist - just default to 0 */
- reg = of_get_property(ofdev->node, "ccr", NULL);
+ reg = of_get_property(ofdev->dev.of_node, "ccr", NULL);
if (reg)
ccr |= *reg;
out_be32(ndfc->ndfcbase + NDFC_CCR, ccr);
/* Set the bank settings if given */
- reg = of_get_property(ofdev->node, "bank-settings", NULL);
+ reg = of_get_property(ofdev->dev.of_node, "bank-settings", NULL);
if (reg) {
int offset = NDFC_BCFG0 + (ndfc->chip_select << 2);
out_be32(ndfc->ndfcbase + offset, *reg);
}
- err = ndfc_chip_init(ndfc, ofdev->node);
+ err = ndfc_chip_init(ndfc, ofdev->dev.of_node);
if (err) {
iounmap(ndfc->ndfcbase);
return err;
next prev parent reply other threads:[~2010-03-18 17:06 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-18 15:22 [V2 PATCH 00/10] of: Consolidate scattered device node pointers in struct device Grant Likely
2010-03-18 15:22 ` [V2 PATCH 01/10] driver-core: Add device node pointer to " Grant Likely
2010-03-18 15:22 ` [V2 PATCH 02/10] i2c/of: Allow device node to be passed via i2c_board_info Grant Likely
2010-03-18 15:22 ` [V2 PATCH 03/10] arch/sparc: Always use 'struct device.of_node' to get device node pointer Grant Likely
2010-03-18 15:22 ` [V2 PATCH 04/10] arch/powerpc: " Grant Likely
2010-03-18 15:22 ` [V2 PATCH 05/10] arch/microblaze: " Grant Likely
2010-03-18 15:22 ` [V2 PATCH 06/10] of/drivers: Always use struct device.of_node to get " Grant Likely
2010-03-18 15:58 ` Jochen Friedrich
2010-03-18 16:24 ` Grant Likely
2010-03-18 16:59 ` Sean MacLennan [this message]
2010-03-18 17:07 ` Grant Likely
2010-03-18 17:10 ` Sean MacLennan
2010-03-18 17:12 ` Sean MacLennan
2010-03-18 15:22 ` [V2 PATCH 07/10] of: eliminate calls to dev_archdata_set_node() Grant Likely
2010-03-18 15:22 ` [V2 PATCH 08/10] arch/powerpc: Remove obsolete dev_archdata.of_node and of_devce.node Grant Likely
2010-03-18 15:47 ` Anton Vorontsov
2010-03-18 16:22 ` Grant Likely
2010-03-18 15:22 ` [V2 PATCH 09/10] arch/microblaze: " Grant Likely
2010-03-18 15:23 ` [V2 PATCH 10/10] arch/sparc: Remove obsolete dev_archdata.prom_node " Grant Likely
2010-03-18 15:35 ` [V2 PATCH 00/10] of: Consolidate scattered device node pointers in struct device Grant Likely
2010-03-23 6:57 ` Michael Ellerman
2010-03-23 7:06 ` Grant Likely
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100318125939.2b39d7f2@lappy.seanm.ca \
--to=smaclennan@pikatech.com \
--cc=davem@davemloft.net \
--cc=grant.likely@secretlab.ca \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=michal.simek@petalogix.com \
--cc=microblaze-uclinux@itee.uq.edu.au \
--cc=sparclinux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).