]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ASoC: cq93vc: Use table based control registration
authorMark Brown <broonie@linaro.org>
Sat, 31 Aug 2013 12:46:05 +0000 (13:46 +0100)
committerMark Brown <broonie@linaro.org>
Tue, 24 Sep 2013 18:40:09 +0000 (19:40 +0100)
Saves a little code.

Signed-off-by: Mark Brown <broonie@linaro.org>
sound/soc/codecs/cq93vc.c

index e2c4c0a896e2f9e22f9492cc9a720ee322427089..e538f4eca980702e3d718594254cfa47d3c1c664 100644 (file)
@@ -156,10 +156,6 @@ static int cq93vc_probe(struct snd_soc_codec *codec)
        davinci_vc->cq93vc.codec = codec;
        codec->control_data = davinci_vc;
 
-       /* Set controls */
-       snd_soc_add_codec_controls(codec, cq93vc_snd_controls,
-                            ARRAY_SIZE(cq93vc_snd_controls));
-
        /* Off, with power on */
        cq93vc_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
 
@@ -180,6 +176,8 @@ static struct snd_soc_codec_driver soc_codec_dev_cq93vc = {
        .probe = cq93vc_probe,
        .remove = cq93vc_remove,
        .resume = cq93vc_resume,
+       .controls = cq93vc_snd_controls,
+       .num_controls = ARRAY_SIZE(cq93vc_snd_controls),
 };
 
 static int cq93vc_platform_probe(struct platform_device *pdev)