Skip to content

Commit

Permalink
net: gianfar: remove the unneeded check of disabled device
Browse files Browse the repository at this point in the history
Since commit cd1e650 ("of/device: Don't register disabled
devices"), the disabled device will not be registered at all. So we
don't need to do the check again in the platform device driver.

Signed-off-by: Kevin Hao <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
haokexin authored and davem330 committed Jan 29, 2015
1 parent 7866a62 commit 4b222ca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ethernet/freescale/gianfar.c
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,7 @@ static int gfar_of_init(struct platform_device *ofdev, struct net_device **pdev)
u32 *tx_queues, *rx_queues;
unsigned short mode, poll_mode;

if (!np || !of_device_is_available(np))
if (!np)
return -ENODEV;

if (of_device_is_compatible(np, "fsl,etsec2")) {
Expand Down

0 comments on commit 4b222ca

Please sign in to comment.