ASoC: fsl_ssi: Use snd_soc_init_dma_data instead
authorNicolin Chen <nicoleotsuka@gmail.com>
Mon, 12 Feb 2018 22:03:19 +0000 (14:03 -0800)
committerMark Brown <broonie@kernel.org>
Wed, 21 Feb 2018 12:30:55 +0000 (12:30 +0000)
Since there is a helper function, use it to help readability.

Signed-off-by: Nicolin Chen <nicoleotsuka@gmail.com>
Tested-by: Caleb Crome <caleb@crome.org>
Tested-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
Reviewed-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/fsl/fsl_ssi.c

index 00dfdc7..7e15b30 100644 (file)
@@ -1110,10 +1110,9 @@ static int fsl_ssi_dai_probe(struct snd_soc_dai *dai)
 {
        struct fsl_ssi *ssi = snd_soc_dai_get_drvdata(dai);
 
-       if (ssi->soc->imx && ssi->use_dma) {
-               dai->playback_dma_data = &ssi->dma_params_tx;
-               dai->capture_dma_data = &ssi->dma_params_rx;
-       }
+       if (ssi->soc->imx && ssi->use_dma)
+               snd_soc_dai_init_dma_data(dai, &ssi->dma_params_tx,
+                                         &ssi->dma_params_rx);
 
        return 0;
 }