diff options
| author | Mark Brown <broonie@linaro.org> | 2013-09-27 09:56:20 -0400 |
|---|---|---|
| committer | Mark Brown <broonie@linaro.org> | 2013-09-27 09:56:20 -0400 |
| commit | 92396e78d339e1ba8c50e69fee96197a56d3911a (patch) | |
| tree | 7ccf274d046c0afe3bf24d6344e45adb51af1022 /sound/soc | |
| parent | 448c3f6884700fc467669d4453b7f5983a5ba1cb (diff) | |
| parent | d63733aed90b432e5cc489ddfa28e342f91b4652 (diff) | |
Merge remote-tracking branch 'asoc/fix/ab8500' into asoc-linus
Diffstat (limited to 'sound/soc')
| -rw-r--r-- | sound/soc/codecs/ab8500-codec.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sound/soc/codecs/ab8500-codec.c b/sound/soc/codecs/ab8500-codec.c index b8ba0adacfce..80555d7551e6 100644 --- a/sound/soc/codecs/ab8500-codec.c +++ b/sound/soc/codecs/ab8500-codec.c | |||
| @@ -1225,13 +1225,18 @@ static int anc_status_control_put(struct snd_kcontrol *kcontrol, | |||
| 1225 | struct ab8500_codec_drvdata *drvdata = dev_get_drvdata(codec->dev); | 1225 | struct ab8500_codec_drvdata *drvdata = dev_get_drvdata(codec->dev); |
| 1226 | struct device *dev = codec->dev; | 1226 | struct device *dev = codec->dev; |
| 1227 | bool apply_fir, apply_iir; | 1227 | bool apply_fir, apply_iir; |
| 1228 | int req, status; | 1228 | unsigned int req; |
| 1229 | int status; | ||
| 1229 | 1230 | ||
| 1230 | dev_dbg(dev, "%s: Enter.\n", __func__); | 1231 | dev_dbg(dev, "%s: Enter.\n", __func__); |
| 1231 | 1232 | ||
| 1232 | mutex_lock(&drvdata->anc_lock); | 1233 | mutex_lock(&drvdata->anc_lock); |
| 1233 | 1234 | ||
| 1234 | req = ucontrol->value.integer.value[0]; | 1235 | req = ucontrol->value.integer.value[0]; |
| 1236 | if (req >= ARRAY_SIZE(enum_anc_state)) { | ||
| 1237 | status = -EINVAL; | ||
| 1238 | goto cleanup; | ||
| 1239 | } | ||
| 1235 | if (req != ANC_APPLY_FIR_IIR && req != ANC_APPLY_FIR && | 1240 | if (req != ANC_APPLY_FIR_IIR && req != ANC_APPLY_FIR && |
| 1236 | req != ANC_APPLY_IIR) { | 1241 | req != ANC_APPLY_IIR) { |
| 1237 | dev_err(dev, "%s: ERROR: Unsupported status to set '%s'!\n", | 1242 | dev_err(dev, "%s: ERROR: Unsupported status to set '%s'!\n", |
