ASoC: ops: improve snd_soc_get_volsw

* clamp the values if the register value read is
  out of range

Signed-off-by: Niranjan H Y <niranjan.hy@ti.com>
[This patch originally had two changes in it, I removed a second buggy
 one -- broonie]
--
v5:
 - remove clamp parameter
 - move the boundary check after sign-bit extension
Link: https://patch.msgid.link/20250912083624.804-1-niranjan.hy@ti.com
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
Niranjan H Y 2025-09-12 14:06:20 +05:30 • committed by Mark Brown
commit a0ce874cfa
No known key found for this signature in database
GPG key ID: 24D68B725D5487D0