projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
474fc2e
)
spi: Fix missing unlock on error in sp7021_spi_master_transfer_one()
author
Yang Yingliang
<yangyingliang@huawei.com>
Thu, 27 Jan 2022 11:58:15 +0000
(19:58 +0800)
committer
Mark Brown
<broonie@kernel.org>
Fri, 28 Jan 2022 13:06:52 +0000
(13:06 +0000)
Add the missing unlock before return from sp7021_spi_master_transfer_one()
in the error handling case.
Fixes:
f62ca4e2a863
("spi: Add spi driver for Sunplus SP7021")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link:
https://lore.kernel.org/r/20220127115815.3148950-1-yangyingliang@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-sunplus-sp7021.c
patch
|
blob
|
history
diff --git
a/drivers/spi/spi-sunplus-sp7021.c
b/drivers/spi/spi-sunplus-sp7021.c
index
627b9c3
..
cbbb166
100644
(file)
--- a/
drivers/spi/spi-sunplus-sp7021.c
+++ b/
drivers/spi/spi-sunplus-sp7021.c
@@
-351,6
+351,7
@@
static int sp7021_spi_master_transfer_one(struct spi_controller *ctlr, struct sp
if (!wait_for_completion_interruptible_timeout(&pspim->isr_done, timeout)) {
dev_err(&spi->dev, "wait_for_completion err\n");
+ mutex_unlock(&pspim->buf_lock);
return -ETIMEDOUT;
}