sound: codecs: fix a missing check for regmap_update_bits
Subsystems (3)
PATCH 1/1 sound: codecs: fix a missing check for regmap_update_bits
regmap_update_bits could fail. The fix checks its status and if it fails, returns its error code upstream.
Signed-off-by Kangjie Lu <[email protected]>
--- sound/soc/codecs/cs35l34.c | 2 ++ 1 file changed, 2 insertions(+)
sound/soc/codecs/cs35l34.c +2 -0
@@ -262,6 +262,8 @@ static int cs35l34_sdin_event(struct snd_soc_dapm_widget *w, } ret =regmap_update_bits (priv->regmap,CS35L34_PWRCTL1 ,CS35L34_PDN_ALL ,CS35L34_PDN_ALL ); +if (ret <0 ) +return ret;break ;default :pr_err ("Invalid event = 0x%x\n" , event);
Signature · 1 line
2.17.1