Browse Source

dpaa_eth: fix error in dpaa_remove()

The recent changes that make the driver probing compatible with DSA
were not propagated in the dpa_remove() function, breaking the
module unload function. Using the proper device to address the issue.

Signed-off-by: Madalin Bucur <madalin.bucur@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Madalin Bucur 7 năm trước cách đây
mục cha
commit
88075256ee
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      drivers/net/ethernet/freescale/dpaa/dpaa_eth.c

+ 1 - 1
drivers/net/ethernet/freescale/dpaa/dpaa_eth.c

@@ -2860,7 +2860,7 @@ static int dpaa_remove(struct platform_device *pdev)
 	struct device *dev;
 	int err;
 
-	dev = &pdev->dev;
+	dev = pdev->dev.parent;
 	net_dev = dev_get_drvdata(dev);
 
 	priv = netdev_priv(net_dev);