diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2010-04-13 19:12:29 -0400 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2010-05-18 18:10:44 -0400 |
commit | 61c7a080a5a061c976988fd4b844dfb468dda255 (patch) | |
tree | 8cb492b73f2755c38a6164d770da34d5af6486a0 /drivers/net/fs_enet/fs_enet-main.c | |
parent | d12d42f744f805a9ccc33cd76f04b237cd83ce56 (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/fs_enet/fs_enet-main.c')
-rw-r--r-- | drivers/net/fs_enet/fs_enet-main.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/fs_enet/fs_enet-main.c b/drivers/net/fs_enet/fs_enet-main.c index 0770e2f6da6b..caeb88b67bc6 100644 --- a/drivers/net/fs_enet/fs_enet-main.c +++ b/drivers/net/fs_enet/fs_enet-main.c | |||
@@ -1015,7 +1015,7 @@ static int __devinit fs_enet_probe(struct of_device *ofdev, | |||
1015 | return -ENOMEM; | 1015 | return -ENOMEM; |
1016 | 1016 | ||
1017 | if (!IS_FEC(match)) { | 1017 | if (!IS_FEC(match)) { |
1018 | data = of_get_property(ofdev->node, "fsl,cpm-command", &len); | 1018 | data = of_get_property(ofdev->dev.of_node, "fsl,cpm-command", &len); |
1019 | if (!data || len != 4) | 1019 | if (!data || len != 4) |
1020 | goto out_free_fpi; | 1020 | goto out_free_fpi; |
1021 | 1021 | ||
@@ -1027,8 +1027,8 @@ static int __devinit fs_enet_probe(struct of_device *ofdev, | |||
1027 | fpi->rx_copybreak = 240; | 1027 | fpi->rx_copybreak = 240; |
1028 | fpi->use_napi = 1; | 1028 | fpi->use_napi = 1; |
1029 | fpi->napi_weight = 17; | 1029 | fpi->napi_weight = 17; |
1030 | fpi->phy_node = of_parse_phandle(ofdev->node, "phy-handle", 0); | 1030 | fpi->phy_node = of_parse_phandle(ofdev->dev.of_node, "phy-handle", 0); |
1031 | if ((!fpi->phy_node) && (!of_get_property(ofdev->node, "fixed-link", | 1031 | if ((!fpi->phy_node) && (!of_get_property(ofdev->dev.of_node, "fixed-link", |
1032 | NULL))) | 1032 | NULL))) |
1033 | goto out_free_fpi; | 1033 | goto out_free_fpi; |
1034 | 1034 | ||
@@ -1061,7 +1061,7 @@ static int __devinit fs_enet_probe(struct of_device *ofdev, | |||
1061 | spin_lock_init(&fep->lock); | 1061 | spin_lock_init(&fep->lock); |
1062 | spin_lock_init(&fep->tx_lock); | 1062 | spin_lock_init(&fep->tx_lock); |
1063 | 1063 | ||
1064 | mac_addr = of_get_mac_address(ofdev->node); | 1064 | mac_addr = of_get_mac_address(ofdev->dev.of_node); |
1065 | if (mac_addr) | 1065 | if (mac_addr) |
1066 | memcpy(ndev->dev_addr, mac_addr, 6); | 1066 | memcpy(ndev->dev_addr, mac_addr, 6); |
1067 | 1067 | ||