tty: serial: uartlite: Enable clocks at probe
At probe the uartlite is getting configured. Enable the clocks before assiging uart and disable after probe is done. Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
9d7c249a1e
commit
ea42d7a67a
@ -776,13 +776,17 @@ static int ulite_probe(struct platform_device *pdev)
|
||||
pdata->clk = NULL;
|
||||
}
|
||||
|
||||
ret = clk_prepare(pdata->clk);
|
||||
ret = clk_prepare_enable(pdata->clk);
|
||||
if (ret) {
|
||||
dev_err(&pdev->dev, "Failed to prepare clock\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
return ulite_assign(&pdev->dev, id, res->start, irq, pdata);
|
||||
ret = ulite_assign(&pdev->dev, id, res->start, irq, pdata);
|
||||
|
||||
clk_disable(pdata->clk);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
static int ulite_remove(struct platform_device *pdev)
|
||||
|
Loading…
Reference in New Issue
Block a user