diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-08 04:17:38 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-08 04:17:38 +0000 |
commit | 9db339b27f903add3e85b6448c6ca4681450c187 (patch) | |
tree | 2e9f25d374e0b322841a7cabe8100b5b52c0e69d /drivers/i2c/busses/i2c-sprd.c | |
parent | Adding upstream version 4.19.282. (diff) | |
download | linux-9db339b27f903add3e85b6448c6ca4681450c187.tar.xz linux-9db339b27f903add3e85b6448c6ca4681450c187.zip |
Adding upstream version 4.19.289.upstream/4.19.289
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'drivers/i2c/busses/i2c-sprd.c')
-rw-r--r-- | drivers/i2c/busses/i2c-sprd.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-sprd.c b/drivers/i2c/busses/i2c-sprd.c index bb1478e78..6c95b809a 100644 --- a/drivers/i2c/busses/i2c-sprd.c +++ b/drivers/i2c/busses/i2c-sprd.c @@ -581,10 +581,12 @@ static int sprd_i2c_remove(struct platform_device *pdev) ret = pm_runtime_get_sync(i2c_dev->dev); if (ret < 0) - return ret; + dev_err(&pdev->dev, "Failed to resume device (%pe)\n", ERR_PTR(ret)); i2c_del_adapter(&i2c_dev->adap); - clk_disable_unprepare(i2c_dev->clk); + + if (ret >= 0) + clk_disable_unprepare(i2c_dev->clk); pm_runtime_put_noidle(i2c_dev->dev); pm_runtime_disable(i2c_dev->dev); |