snd_soc_pcm_set_drvdata() will set driver data to rtd->dev,
but driver data of rtd->dev is already used as "rtd" on
soc_post_component_init().

        static int soc_post_component_init(xxx)
        {
                ...
                dev_set_drvdata(rtd->dev, rtd);
                ...
        }

To remove confusion, snd_soc_pcm_set/get_drvdata() should be
removed soon. This patch is for it.

intel/haswell/sst-haswell-pcm.c is using snd_soc_pcm_set(),
but no one use it on this driver. Let's remove it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto...@renesas.com>
---

** Note **

I did compile test only.
Please check it

 sound/soc/intel/haswell/sst-haswell-pcm.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/sound/soc/intel/haswell/sst-haswell-pcm.c 
b/sound/soc/intel/haswell/sst-haswell-pcm.c
index 994256b..3154525 100644
--- a/sound/soc/intel/haswell/sst-haswell-pcm.c
+++ b/sound/soc/intel/haswell/sst-haswell-pcm.c
@@ -819,7 +819,6 @@ static int hsw_pcm_open(struct snd_pcm_substream *substream)
        mutex_lock(&pcm_data->mutex);
        pm_runtime_get_sync(pdata->dev);
 
-       snd_soc_pcm_set_drvdata(rtd, pcm_data);
        pcm_data->substream = substream;
 
        snd_soc_set_runtime_hwparams(substream, &hsw_pcm_hardware);
-- 
1.9.1

Reply via email to