From a0d48518cdc855ed188be385abb4df1752a4003c Mon Sep 17 00:00:00 2001 From: Zhang Changzhong Date: Wed, 9 Sep 2020 22:06:37 +0800 Subject: net: pxa168_eth: remove redundant null check before clk_disable_unprepare() Because clk_prepare_enable() and clk_disable_unprepare() already checked NULL clock parameter, so the additional checks are unnecessary, just remove them. Reported-by: Hulk Robot Signed-off-by: Zhang Changzhong Signed-off-by: David S. Miller --- drivers/net/ethernet/marvell/pxa168_eth.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'drivers/net/ethernet/marvell/pxa168_eth.c') diff --git a/drivers/net/ethernet/marvell/pxa168_eth.c b/drivers/net/ethernet/marvell/pxa168_eth.c index eb8cf60ecf12..faac94b2d5ff 100644 --- a/drivers/net/ethernet/marvell/pxa168_eth.c +++ b/drivers/net/ethernet/marvell/pxa168_eth.c @@ -1541,10 +1541,8 @@ static int pxa168_eth_remove(struct platform_device *pdev) } if (dev->phydev) phy_disconnect(dev->phydev); - if (pep->clk) { - clk_disable_unprepare(pep->clk); - } + clk_disable_unprepare(pep->clk); mdiobus_unregister(pep->smi_bus); mdiobus_free(pep->smi_bus); unregister_netdev(dev); -- cgit v1.2.3