ASoC: Remove impossible case from wm8994_hw_params
authorAxel Lin <axel.lin@gmail.com>
Tue, 11 Oct 2011 23:03:09 +0000 (07:03 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 12 Oct 2011 10:25:58 +0000 (11:25 +0100)
We set hw_params callback for wm8994_aif3_dai_ops to wm8994_aif3_hw_params.
Thus no need to check wm8994-aif3 in wm8994_hw_params.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/codecs/wm8994.c

index 16542de21db8dd26737ce48eae7ad5195525b5cf..68e769ead7d0509cef854669f5b9e31f12445e68 100644 (file)
@@ -2235,7 +2235,6 @@ static int wm8994_hw_params(struct snd_pcm_substream *substream,
                            struct snd_soc_dai *dai)
 {
        struct snd_soc_codec *codec = dai->codec;
-       struct wm8994 *control = codec->control_data;
        struct wm8994_priv *wm8994 = snd_soc_codec_get_drvdata(codec);
        int aif1_reg;
        int aif2_reg;
@@ -2278,15 +2277,6 @@ static int wm8994_hw_params(struct snd_pcm_substream *substream,
                        dev_dbg(codec->dev, "AIF2 using split LRCLK\n");
                }
                break;
-       case 3:
-               switch (control->type) {
-               case WM1811:
-               case WM8958:
-                       aif1_reg = WM8958_AIF3_CONTROL_1;
-                       break;
-               default:
-                       return 0;
-               }
        default:
                return -EINVAL;
        }