diff options
author | Jingoo Han <jg1.han@samsung.com> | 2013-08-30 08:55:46 +0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-08-31 01:43:35 +0400 |
commit | 420fcd82206ff5e03690247b10a08e585446a517 (patch) | |
tree | f105563eb6df224ec51e1129d1014d36810344a9 | |
parent | cd4e2e4b368fd52e29817fe9447c2204b76467f9 (diff) | |
download | linux-420fcd82206ff5e03690247b10a08e585446a517.tar.xz |
net: ethoc: use dev_get_platdata()
Use the wrapper function for retrieving the platform data instead of
accessing dev->platform_data directly. This is a cosmetic change
to make the code simpler and enhance the readability.
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/ethernet/ethoc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/ethoc.c b/drivers/net/ethernet/ethoc.c index cf579fb39bc5..4de8cfd149cf 100644 --- a/drivers/net/ethernet/ethoc.c +++ b/drivers/net/ethernet/ethoc.c @@ -1030,8 +1030,8 @@ static int ethoc_probe(struct platform_device *pdev) } /* Allow the platform setup code to pass in a MAC address. */ - if (pdev->dev.platform_data) { - struct ethoc_platform_data *pdata = pdev->dev.platform_data; + if (dev_get_platdata(&pdev->dev)) { + struct ethoc_platform_data *pdata = dev_get_platdata(&pdev->dev); memcpy(netdev->dev_addr, pdata->hwaddr, IFHWADDRLEN); priv->phy_id = pdata->phy_id; } else { |