@@ -670,7 +670,7 @@ static int cryp_disable_power(struct device *dev,
}
spin_unlock(&device_data->ctx_lock);
- clk_disable(device_data->clk);
+ clk_disable_unprepare(device_data->clk);
ret = regulator_disable(device_data->pwr_regulator);
if (ret)
dev_err(dev, "[%s]: "
@@ -703,9 +703,9 @@ static int cryp_enable_power(
goto out;
}
- ret = clk_enable(device_data->clk);
+ ret = clk_prepare_enable(device_data->clk);
if (ret) {
- dev_err(dev, "[%s]: clk_enable() failed!",
+ dev_err(dev, "[%s]: clk_prepare_enable() failed!",
__func__);
regulator_disable(device_data->pwr_regulator);
goto out;
If we fail to prepare the ux500-cryp clock before enabling it the platform will fail to boot. Here we insure this happens. Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: David S. Miller <davem@davemloft.net> Cc: Andreas Westin <andreas.westin@stericsson.com> Cc: linux-crypto@vger.kernel.org Signed-off-by: Lee Jones <lee.jones@linaro.org> --- drivers/crypto/ux500/cryp/cryp_core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)