diff options
author | Max Krummenacher <max.krummenacher@toradex.com> | 2024-02-19 18:44:12 +0100 |
---|---|---|
committer | Max Krummenacher <max.krummenacher@toradex.com> | 2024-02-19 18:44:12 +0100 |
commit | 80c8662762f98e2f55374dff45698e002b90372f (patch) | |
tree | 4d5970c39f1200df19254e82e3791e47c6712431 | |
parent | 3a47e76770c777f1d6d3601d11f595a55fb51d0b (diff) |
Revert "ASoC: ops: Fix bounds check for _sx controls"
This reverts commit 416f4b76240400260aaf0c4200565d63f49290d7.
-rw-r--r-- | sound/soc/soc-ops.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/soc-ops.c b/sound/soc/soc-ops.c index dfd7455c9f7a..d867f449d82d 100644 --- a/sound/soc/soc-ops.c +++ b/sound/soc/soc-ops.c @@ -435,7 +435,7 @@ int snd_soc_put_volsw_sx(struct snd_kcontrol *kcontrol, val = ucontrol->value.integer.value[0]; if (mc->platform_max && val > mc->platform_max) return -EINVAL; - if (val > max) + if (val > max - min) return -EINVAL; val_mask = mask << shift; val = (val + min) & mask; |