diff options
| author | Mark Brown <broonie@kernel.org> | 2026-04-20 18:40:07 +0100 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2026-04-20 18:40:07 +0100 |
| commit | cec9d64c09c505c818e9a8093a012234051c2d14 (patch) | |
| tree | 53d4f17997dc234ad88776517ba9b6faec7e36d8 /sound | |
| parent | c15bc1681045f158811643d6c990f87c590dd693 (diff) | |
| parent | 956c032be7ca3f440d4786ea37e941bf862bb170 (diff) | |
| download | linux-next-cec9d64c09c505c818e9a8093a012234051c2d14.tar.gz linux-next-cec9d64c09c505c818e9a8093a012234051c2d14.zip | |
ASoC: Correct bug parsing DisCo booleans
Charles Keepax <ckeepax@opensource.cirrus.com> says:
MIPI DisCo uses the unfortunate convention of allowing boolean
properties to be present but having a zero value. Opposed to the
normal convention of simply not specifying the property. Fix an
issue in the SDCA code where mipi-sdca-control-deferrable is not
parsed correctly.
However, we also have some shipping ACPIs where these properties
are not specified correctly. Update the MBQ regmap to attempt defers
albeit with a warning in the case where a control attempts to defer
but is not marked at such. There is little down side to this as if
defer is genuinely not supported then the control will just return
the same error again.
Diffstat (limited to 'sound')
| -rw-r--r-- | sound/soc/sdca/sdca_functions.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sound/soc/sdca/sdca_functions.c b/sound/soc/sdca/sdca_functions.c index fd6a254c9530..196bade11ab5 100644 --- a/sound/soc/sdca/sdca_functions.c +++ b/sound/soc/sdca/sdca_functions.c @@ -1006,8 +1006,11 @@ static int find_sdca_entity_control(struct device *dev, struct sdca_entity *enti control->has_fixed = true; fallthrough; case SDCA_ACCESS_MODE_RO: - control->deferrable = fwnode_property_read_bool(control_node, - "mipi-sdca-control-deferrable"); + ret = fwnode_property_read_u32(control_node, + "mipi-sdca-control-deferrable", + &tmp); + if (ret == 0) + control->deferrable = !!tmp; break; default: break; |
