Message ID | 20240125103117.2622095-3-ckeepax@opensource.cirrus.com (mailing list archive) |
---|---|
State | Accepted |
Commit | a2e7cf55db781654fdb2d3b2529e28c4d93e24fc |
Headers | show |
Series | [v2,1/7] ASoC: cs42l43: Tidy up header includes | expand |
diff --git a/sound/soc/codecs/cs42l43-jack.c b/sound/soc/codecs/cs42l43-jack.c index 4f7a405b7e06a..67ccdc8bab6f6 100644 --- a/sound/soc/codecs/cs42l43-jack.c +++ b/sound/soc/codecs/cs42l43-jack.c @@ -106,8 +106,13 @@ int cs42l43_set_jack(struct snd_soc_component *component, goto error; } - device_property_read_u32_array(cs42l43->dev, "cirrus,buttons-ohms", - priv->buttons, ret); + ret = device_property_read_u32_array(cs42l43->dev, "cirrus,buttons-ohms", + priv->buttons, ret); + if (ret < 0) { + dev_err(priv->dev, "Property cirrus,button-ohms malformed: %d\n", + ret); + goto error; + } } else { priv->buttons[0] = 70; priv->buttons[1] = 185;