net: at91_ether: use dev_get_platdata()
authorJingoo Han <[email protected]>
Fri, 30 Aug 2013 05:11:53 +0000 (14:11 +0900)
committerDavid S. Miller <[email protected]>
Fri, 30 Aug 2013 21:43:39 +0000 (17:43 -0400)
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 <[email protected]>
Acked-by: Nicolas Ferre <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
drivers/net/ethernet/cadence/at91_ether.c

index bb5d63fb2e6d7b9566dfcdd6bcc2de6bd831b8d9..ce75de9bae9e4f9eb219247bcf9cccffba9c0542 100644 (file)
@@ -304,7 +304,7 @@ MODULE_DEVICE_TABLE(of, at91ether_dt_ids);
 /* Detect MAC & PHY and perform ethernet interface initialization */
 static int __init at91ether_probe(struct platform_device *pdev)
 {
-       struct macb_platform_data *board_data = pdev->dev.platform_data;
+       struct macb_platform_data *board_data = dev_get_platdata(&pdev->dev);
        struct resource *regs;
        struct net_device *dev;
        struct phy_device *phydev;