aboutsummaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorZhu Jun <zhujun2@cmss.chinamobile.com>2024-10-09 00:39:38 -0700
committerMark Brown <broonie@kernel.org>2024-10-10 12:15:01 +0100
commit251ce34a446ef0e1d6acd65cf5947abd5d10b8b6 (patch)
tree24da4a6ec886b111c6a5c3b346d8d57f4be42388 /sound
parentd0e806b0cc6260b59c65e606034a63145169c04c (diff)
ASoC: codecs: Fix error handling in aw_dev_get_dsp_status function
Added proper error handling for register value check that return -EPERM when register value does not meet expected condition Signed-off-by: Zhu Jun <zhujun2@cmss.chinamobile.com> Link: https://patch.msgid.link/20241009073938.7472-1-zhujun2@cmss.chinamobile.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/aw88399.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/codecs/aw88399.c b/sound/soc/codecs/aw88399.c
index 8dc2b8aa6832..bba59885242d 100644
--- a/sound/soc/codecs/aw88399.c
+++ b/sound/soc/codecs/aw88399.c
@@ -656,7 +656,7 @@ static int aw_dev_get_dsp_status(struct aw_device *aw_dev)
if (ret)
return ret;
if (!(reg_val & (~AW88399_WDT_CNT_MASK)))
- ret = -EPERM;
+ return -EPERM;
return 0;
}