aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ll_temac_main.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/ll_temac_main.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/ll_temac_main.c')
-rw-r--r--drivers/net/ll_temac_main.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/ll_temac_main.c b/drivers/net/ll_temac_main.c
index ba617e3cf1bb..9c7395c10e44 100644
--- a/drivers/net/ll_temac_main.c
+++ b/drivers/net/ll_temac_main.c
@@ -858,14 +858,14 @@ temac_of_probe(struct of_device *op, const struct of_device_id *match)
858 mutex_init(&lp->indirect_mutex); 858 mutex_init(&lp->indirect_mutex);
859 859
860 /* map device registers */ 860 /* map device registers */
861 lp->regs = of_iomap(op->node, 0); 861 lp->regs = of_iomap(op->dev.of_node, 0);
862 if (!lp->regs) { 862 if (!lp->regs) {
863 dev_err(&op->dev, "could not map temac regs.\n"); 863 dev_err(&op->dev, "could not map temac regs.\n");
864 goto nodev; 864 goto nodev;
865 } 865 }
866 866
867 /* Find the DMA node, map the DMA registers, and decode the DMA IRQs */ 867 /* Find the DMA node, map the DMA registers, and decode the DMA IRQs */
868 np = of_parse_phandle(op->node, "llink-connected", 0); 868 np = of_parse_phandle(op->dev.of_node, "llink-connected", 0);
869 if (!np) { 869 if (!np) {
870 dev_err(&op->dev, "could not find DMA node\n"); 870 dev_err(&op->dev, "could not find DMA node\n");
871 goto nodev; 871 goto nodev;
@@ -890,7 +890,7 @@ temac_of_probe(struct of_device *op, const struct of_device_id *match)
890 of_node_put(np); /* Finished with the DMA node; drop the reference */ 890 of_node_put(np); /* Finished with the DMA node; drop the reference */
891 891
892 /* Retrieve the MAC address */ 892 /* Retrieve the MAC address */
893 addr = of_get_property(op->node, "local-mac-address", &size); 893 addr = of_get_property(op->dev.of_node, "local-mac-address", &size);
894 if ((!addr) || (size != 6)) { 894 if ((!addr) || (size != 6)) {
895 dev_err(&op->dev, "could not find MAC address\n"); 895 dev_err(&op->dev, "could not find MAC address\n");
896 rc = -ENODEV; 896 rc = -ENODEV;
@@ -898,11 +898,11 @@ temac_of_probe(struct of_device *op, const struct of_device_id *match)
898 } 898 }
899 temac_set_mac_address(ndev, (void *)addr); 899 temac_set_mac_address(ndev, (void *)addr);
900 900
901 rc = temac_mdio_setup(lp, op->node); 901 rc = temac_mdio_setup(lp, op->dev.of_node);
902 if (rc) 902 if (rc)
903 dev_warn(&op->dev, "error registering MDIO bus\n"); 903 dev_warn(&op->dev, "error registering MDIO bus\n");
904 904
905 lp->phy_node = of_parse_phandle(op->node, "phy-handle", 0); 905 lp->phy_node = of_parse_phandle(op->dev.of_node, "phy-handle", 0);
906 if (lp->phy_node) 906 if (lp->phy_node)
907 dev_dbg(lp->dev, "using PHY node %s (%p)\n", np->full_name, np); 907 dev_dbg(lp->dev, "using PHY node %s (%p)\n", np->full_name, np);
908 908