summaryrefslogtreecommitdiff
path: root/drivers/soundwire/stream.c
diff options
context:
space:
mode:
authorWang Wensheng <wangwensheng4@huawei.com>2022-03-07 10:40:39 +0300
committerVinod Koul <vkoul@kernel.org>2022-04-05 07:19:25 +0300
commita7ad7ce41815145ccdb69554b2618fc084fc38a1 (patch)
tree280a7995da87939e002c6e991fa20633ddd032cc /drivers/soundwire/stream.c
parentd146de3430d2b21054f6dc8a890f84062515f4d2 (diff)
downloadlinux-a7ad7ce41815145ccdb69554b2618fc084fc38a1.tar.xz
soundwire: stream: Fix error return code in do_bank_switch()
Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wang Wensheng <wangwensheng4@huawei.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20220307074039.117488-1-wangwensheng4@huawei.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/soundwire/stream.c')
-rw-r--r--drivers/soundwire/stream.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/soundwire/stream.c b/drivers/soundwire/stream.c
index f273459b2023..d34150559142 100644
--- a/drivers/soundwire/stream.c
+++ b/drivers/soundwire/stream.c
@@ -822,6 +822,7 @@ static int do_bank_switch(struct sdw_stream_runtime *stream)
} else if (multi_link) {
dev_err(bus->dev,
"Post bank switch ops not implemented\n");
+ ret = -EINVAL;
goto error;
}