crypto: inside-secure - fix clock management
In this driver the clock is got but never put when the driver is removed
or if there is an error in the probe.
Using the managed version of clk_get() allows to let the kernel take care
of it.
Fixes: 1b44c5a60c
("crypto: inside-secure - add SafeXcel EIP197 crypto
engine driver")
cc: stable@vger.kernel.org
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
parent
efa94457e5
commit
f962eb46e7
|
@ -881,7 +881,7 @@ static int safexcel_probe(struct platform_device *pdev)
|
|||
return PTR_ERR(priv->base);
|
||||
}
|
||||
|
||||
priv->clk = of_clk_get(dev->of_node, 0);
|
||||
priv->clk = devm_clk_get(&pdev->dev, NULL);
|
||||
if (!IS_ERR(priv->clk)) {
|
||||
ret = clk_prepare_enable(priv->clk);
|
||||
if (ret) {
|
||||
|
|
Loading…
Reference in New Issue