mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-15 08:14:15 +08:00
ASoC: codecs: Modify the wrong judgment of re value
An error code should be return when the re is greater than the maximum value or less than the minimum value Signed-off-by: Weidong Wang <wangweidong.a@awinic.com> Link: https://lore.kernel.org/r/20231101090211.177125-3-wangweidong.a@awinic.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
c9e920ffa7
commit
baf46c3c76
@ -486,8 +486,8 @@ static int aw_dev_update_cali_re(struct aw_cali_desc *cali_desc)
|
||||
u32 cali_re;
|
||||
int ret;
|
||||
|
||||
if ((aw_dev->cali_desc.cali_re <= AW88399_CALI_RE_MAX) ||
|
||||
(aw_dev->cali_desc.cali_re >= AW88399_CALI_RE_MIN))
|
||||
if ((aw_dev->cali_desc.cali_re >= AW88399_CALI_RE_MAX) ||
|
||||
(aw_dev->cali_desc.cali_re <= AW88399_CALI_RE_MIN))
|
||||
return -EINVAL;
|
||||
|
||||
cali_re = AW88399_SHOW_RE_TO_DSP_RE((aw_dev->cali_desc.cali_re +
|
||||
|
Loading…
Reference in New Issue
Block a user