Commit 18d33cdb authored by Takashi Iwai's avatar Takashi Iwai

ASoC: amd: Avoid passing NULL to memory allocators

We should pass a proper non-NULL device object to memory allocators
although it was accepted in the past.  The card->dev points to the
most appropriate device object in such a case, so let's put it.
Acked-by: default avatarChristoph Hellwig <hch@lst.de>
Acked-by: default avatarMark Brown <broonie@kernel.org>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent bc70a9d7
...@@ -369,7 +369,8 @@ static int acp3x_dma_new(struct snd_soc_pcm_runtime *rtd) ...@@ -369,7 +369,8 @@ static int acp3x_dma_new(struct snd_soc_pcm_runtime *rtd)
{ {
return snd_pcm_lib_preallocate_pages_for_all(rtd->pcm, return snd_pcm_lib_preallocate_pages_for_all(rtd->pcm,
SNDRV_DMA_TYPE_DEV, SNDRV_DMA_TYPE_DEV,
NULL, MIN_BUFFER, rtd->pcm->card->dev,
MIN_BUFFER,
MAX_BUFFER); MAX_BUFFER);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment