mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-01-22 11:04:50 -05:00
wifi: wilc1000: always release SDIO host in wilc_sdio_cmd53()
Ensure 'sdio_release_host()' is always issued on return from 'wilc_sdio_cmd53()'. Compile tested only. Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-by: Ajay Singh <ajay.kathat@microchip.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20231026141016.71407-2-dmantipov@yandex.ru
This commit is contained in:
committed by
Kalle Valo
parent
a0ddf39ac6
commit
ebab2723d0
@@ -106,9 +106,10 @@ static int wilc_sdio_cmd53(struct wilc *wilc, struct sdio_cmd53 *cmd)
|
||||
size = cmd->count;
|
||||
|
||||
if (cmd->use_global_buf) {
|
||||
if (size > sizeof(u32))
|
||||
return -EINVAL;
|
||||
|
||||
if (size > sizeof(u32)) {
|
||||
ret = -EINVAL;
|
||||
goto out;
|
||||
}
|
||||
buf = sdio_priv->cmd53_buf;
|
||||
}
|
||||
|
||||
@@ -123,7 +124,7 @@ static int wilc_sdio_cmd53(struct wilc *wilc, struct sdio_cmd53 *cmd)
|
||||
if (cmd->use_global_buf)
|
||||
memcpy(cmd->buffer, buf, size);
|
||||
}
|
||||
|
||||
out:
|
||||
sdio_release_host(func);
|
||||
|
||||
if (ret)
|
||||
|
||||
Reference in New Issue
Block a user