Skip to content

Commit a80f2f8

Browse files
krzkbroonie
authored andcommitted
ASoC: arm: Use snd_soc_substream_to_rtd() for accessing private_data
Do not open-code snd_soc_substream_to_rtd(). Signed-off-by: Krzysztof Kozlowski <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
1 parent 72a666f commit a80f2f8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sound/arm/pxa2xx-pcm-lib.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ int pxa2xx_pcm_hw_params(struct snd_pcm_substream *substream,
3333
struct snd_pcm_hw_params *params)
3434
{
3535
struct dma_chan *chan = snd_dmaengine_pcm_get_chan(substream);
36-
struct snd_soc_pcm_runtime *rtd = substream->private_data;
36+
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
3737
struct snd_dmaengine_dai_dma_data *dma_params;
3838
struct dma_slave_config config;
3939
int ret;
@@ -79,7 +79,7 @@ EXPORT_SYMBOL(pxa2xx_pcm_prepare);
7979

8080
int pxa2xx_pcm_open(struct snd_pcm_substream *substream)
8181
{
82-
struct snd_soc_pcm_runtime *rtd = substream->private_data;
82+
struct snd_soc_pcm_runtime *rtd = snd_soc_substream_to_rtd(substream);
8383
struct snd_pcm_runtime *runtime = substream->runtime;
8484
struct snd_dmaengine_dai_dma_data *dma_params;
8585
int ret;

0 commit comments

Comments
 (0)