Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 30ce1987 authored by Boris Brezillon's avatar Boris Brezillon Committed by Felipe Balbi
Browse files

usb: gadget: at91_udc: add missing clk_put on fclk and iclk



This patch adds missing clk_put on fclk and iclk in case the probe function
fails after these clocks have been retrieved.

Signed-off-by: default avatarBoris BREZILLON <b.brezillon@overkiz.com>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 93487aa1
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1851,6 +1851,10 @@ static int at91udc_probe(struct platform_device *pdev)
fail2:
	free_irq(udc->udp_irq, udc);
fail1:
	if (!IS_ERR(udc->fclk))
		clk_put(udc->fclk);
	if (!IS_ERR(udc->iclk))
		clk_put(udc->iclk);
	iounmap(udc->udp_baseaddr);
fail0a:
	if (cpu_is_at91rm9200())