aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/gianfar.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2010-04-13 19:12:29 -0400
committerGrant Likely <grant.likely@secretlab.ca>2010-05-18 18:10:44 -0400
commit61c7a080a5a061c976988fd4b844dfb468dda255 (patch)
tree8cb492b73f2755c38a6164d770da34d5af6486a0 /drivers/net/gianfar.c
parentd12d42f744f805a9ccc33cd76f04b237cd83ce56 (diff)
of: Always use 'struct device.of_node' to get device node pointer.
The following structure elements duplicate the information in 'struct device.of_node' and so are being eliminated. This patch makes all readers of these elements use device.of_node instead. (struct of_device *)->node (struct dev_archdata *)->prom_node (sparc) (struct dev_archdata *)->of_node (powerpc & microblaze) Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/net/gianfar.c')
-rw-r--r--drivers/net/gianfar.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c
index 080d1cea5b26..b71bba91064c 100644
--- a/drivers/net/gianfar.c
+++ b/drivers/net/gianfar.c
@@ -603,7 +603,7 @@ static int gfar_of_init(struct of_device *ofdev, struct net_device **pdev)
603 int err = 0, i; 603 int err = 0, i;
604 struct net_device *dev = NULL; 604 struct net_device *dev = NULL;
605 struct gfar_private *priv = NULL; 605 struct gfar_private *priv = NULL;
606 struct device_node *np = ofdev->node; 606 struct device_node *np = ofdev->dev.of_node;
607 struct device_node *child = NULL; 607 struct device_node *child = NULL;
608 const u32 *stash; 608 const u32 *stash;
609 const u32 *stash_len; 609 const u32 *stash_len;
@@ -641,7 +641,7 @@ static int gfar_of_init(struct of_device *ofdev, struct net_device **pdev)
641 return -ENOMEM; 641 return -ENOMEM;
642 642
643 priv = netdev_priv(dev); 643 priv = netdev_priv(dev);
644 priv->node = ofdev->node; 644 priv->node = ofdev->dev.of_node;
645 priv->ndev = dev; 645 priv->ndev = dev;
646 646
647 dev->num_tx_queues = num_tx_qs; 647 dev->num_tx_queues = num_tx_qs;
@@ -888,7 +888,7 @@ static int gfar_probe(struct of_device *ofdev,
888 priv = netdev_priv(dev); 888 priv = netdev_priv(dev);
889 priv->ndev = dev; 889 priv->ndev = dev;
890 priv->ofdev = ofdev; 890 priv->ofdev = ofdev;
891 priv->node = ofdev->node; 891 priv->node = ofdev->dev.of_node;
892 SET_NETDEV_DEV(dev, &ofdev->dev); 892 SET_NETDEV_DEV(dev, &ofdev->dev);
893 893
894 spin_lock_init(&priv->bflock); 894 spin_lock_init(&priv->bflock);