Commit 92c78222 authored by Dan Carpenter's avatar Dan Carpenter Committed by Mark Brown

ASoC: TAS2781: Fix tasdev_load_calibrated_data()

This function has a reversed if statement so it's either a no-op or it
leads to a NULL dereference.

Fixes: b195acf5 ("ASoC: tas2781: Fix wrong loading calibrated data sequence")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@linaro.org>
Link: https://patch.msgid.link/18a29b68-cc85-4139-b7c7-2514e8409a42@stanley.mountainSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 83340b85
......@@ -2162,7 +2162,7 @@ static void tasdev_load_calibrated_data(struct tasdevice_priv *priv, int i)
return;
cal = cal_fmw->calibrations;
if (cal)
if (!cal)
return;
load_calib_data(priv, &cal->dev_data);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment