[PATCH net-next 3/3] ezchip: Further clean-up

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Now that is only call to platform_get_drvdata() is removed, calling
platform_set_drvdata() looks useless. Remove it.

While at it, remove a useless 'err' initialization and change its type to a
more common 'int'

Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
---
 drivers/net/ethernet/ezchip/nps_enet.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/ezchip/nps_enet.c b/drivers/net/ethernet/ezchip/nps_enet.c
index 21e230150104..139510d9669f 100644
--- a/drivers/net/ethernet/ezchip/nps_enet.c
+++ b/drivers/net/ethernet/ezchip/nps_enet.c
@@ -574,7 +574,7 @@ static s32 nps_enet_probe(struct platform_device *pdev)
 	struct device *dev = &pdev->dev;
 	struct net_device *ndev;
 	struct nps_enet_priv *priv;
-	s32 err = 0;
+	int err;
 
 	if (!dev->of_node)
 		return -ENODEV;
@@ -583,7 +583,6 @@ static s32 nps_enet_probe(struct platform_device *pdev)
 	if (!ndev)
 		return -ENOMEM;
 
-	platform_set_drvdata(pdev, ndev);
 	SET_NETDEV_DEV(ndev, dev);
 	priv = netdev_priv(ndev);
 
-- 
2.34.1




[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux