aboutsummaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
authorMarek Vasut2018-06-18 09:35:45 +0200
committerMarek Vasut2018-06-19 06:15:55 +0200
commitc4a8d9ca046a6881babe1ca6e08223bd1a2f7d59 (patch)
tree26c185737df66bba3c1d56770651880e4cda315c /drivers/net
parent24417edfff837e21c8f4b659e08c4da5f59181b8 (diff)
net: ravb: Do not shut down clock in start callback
Do not stop the clock in the start callback in case of failure, keep them running to also keep the PHY running. The failure could be ie. PHY failing to negotiate link and if the clock get shut down, another attempt at bringing the link up would fail. The clock right now are started in probe function and stopped in remove function, which is the correct behavior. Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com> Cc: Nobuhiro Iwamatsu <iwamatsu@nigauri.org> Cc: Joe Hershberger <joe.hershberger@ni.com>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/ravb.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/net/ravb.c b/drivers/net/ravb.c
index 999894f0f6d..c1c946856bc 100644
--- a/drivers/net/ravb.c
+++ b/drivers/net/ravb.c
@@ -437,7 +437,7 @@ static int ravb_start(struct udevice *dev)
ret = ravb_reset(dev);
if (ret)
- goto err;
+ return ret;
ravb_base_desc_init(eth);
ravb_tx_desc_init(eth);
@@ -445,16 +445,12 @@ static int ravb_start(struct udevice *dev)
ret = ravb_config(dev);
if (ret)
- goto err;
+ return ret;
/* Setting the control will start the AVB-DMAC process. */
writel(CCC_OPC_OPERATION, eth->iobase + RAVB_REG_CCC);
return 0;
-
-err:
- clk_disable(&eth->clk);
- return ret;
}
static void ravb_stop(struct udevice *dev)