diff options
author | Peng Wu <[email protected]> | 2022-06-11 02:11:17 +0000 |
---|---|---|
committer | Mark Brown <[email protected]> | 2022-06-13 15:55:42 +0100 |
commit | 116679aef2f92d535ea8049ef2a610bc73f94660 (patch) | |
tree | ec50bcfc212123303536a7aab8f4f440a0a19dbe | |
parent | c349fad389c5916facead610d454250f67cfb20b (diff) |
spi: micro: fix unreasonable clk_prepare_enable() on error in mchp_corespi_probe()
Fix the unreasonable clk_prepare_enable() with clk_disable_unprepare()
before return from mchp_corespi_probe() in the error handling case.
Signed-off-by: Peng Wu <[email protected]>
Reviewed-by: Conor Dooley <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
-rw-r--r-- | drivers/spi/spi-microchip-core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/spi/spi-microchip-core.c b/drivers/spi/spi-microchip-core.c index 3bd285dd4964..5b22a1395554 100644 --- a/drivers/spi/spi-microchip-core.c +++ b/drivers/spi/spi-microchip-core.c @@ -580,7 +580,7 @@ static int mchp_corespi_probe(struct platform_device *pdev) error_release_hardware: mchp_corespi_disable(spi); - clk_prepare_enable(spi->clk); + clk_disable_unprepare(spi->clk); error_release_master: spi_master_put(master); |