mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 02:30:52 +07:00
w1 i.MX: prepare/unprepare clock
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
c943740ccd
commit
60178b6329
@ -138,7 +138,7 @@ static int __devinit mxc_w1_probe(struct platform_device *pdev)
|
|||||||
goto failed_ioremap;
|
goto failed_ioremap;
|
||||||
}
|
}
|
||||||
|
|
||||||
clk_enable(mdev->clk);
|
clk_prepare_enable(mdev->clk);
|
||||||
__raw_writeb(mdev->clkdiv, mdev->regs + MXC_W1_TIME_DIVIDER);
|
__raw_writeb(mdev->clkdiv, mdev->regs + MXC_W1_TIME_DIVIDER);
|
||||||
|
|
||||||
mdev->bus_master.data = mdev;
|
mdev->bus_master.data = mdev;
|
||||||
@ -178,7 +178,7 @@ static int __devexit mxc_w1_remove(struct platform_device *pdev)
|
|||||||
|
|
||||||
iounmap(mdev->regs);
|
iounmap(mdev->regs);
|
||||||
release_mem_region(res->start, resource_size(res));
|
release_mem_region(res->start, resource_size(res));
|
||||||
clk_disable(mdev->clk);
|
clk_disable_unprepare(mdev->clk);
|
||||||
clk_put(mdev->clk);
|
clk_put(mdev->clk);
|
||||||
|
|
||||||
platform_set_drvdata(pdev, NULL);
|
platform_set_drvdata(pdev, NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user