mirror of
https://github.com/torvalds/linux.git
synced 2026-05-24 15:12:13 +02:00
ASoC: SDCA: Fix return value in sdca_regmap_mbq_size()
The MBQ size function returns an integer representing the size of a
Control. Currently if the Control is not found the function will return
false which makes little sense. Correct this typo to return -EINVAL.
Fixes: e3f7caf74b ("ASoC: SDCA: Add generic regmap SDCA helpers")
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Message-ID: <20250820163717.1095846-2-ckeepax@opensource.cirrus.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
1b237f190e
commit
f81e630476
|
|
@ -196,7 +196,7 @@ int sdca_regmap_mbq_size(struct sdca_function_data *function, unsigned int reg)
|
|||
|
||||
control = function_find_control(function, reg);
|
||||
if (!control)
|
||||
return false;
|
||||
return -EINVAL;
|
||||
|
||||
return clamp_val(control->nbits / BITS_PER_BYTE, sizeof(u8), sizeof(u32));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user