|
@@ -1147,18 +1147,21 @@ static int acp_dma_new(struct snd_soc_pcm_runtime *rtd)
|
|
|
struct snd_soc_component *component = snd_soc_rtdcom_lookup(rtd,
|
|
struct snd_soc_component *component = snd_soc_rtdcom_lookup(rtd,
|
|
|
DRV_NAME);
|
|
DRV_NAME);
|
|
|
struct audio_drv_data *adata = dev_get_drvdata(component->dev);
|
|
struct audio_drv_data *adata = dev_get_drvdata(component->dev);
|
|
|
|
|
+ struct device *parent = component->dev->parent;
|
|
|
|
|
|
|
|
switch (adata->asic_type) {
|
|
switch (adata->asic_type) {
|
|
|
case CHIP_STONEY:
|
|
case CHIP_STONEY:
|
|
|
ret = snd_pcm_lib_preallocate_pages_for_all(rtd->pcm,
|
|
ret = snd_pcm_lib_preallocate_pages_for_all(rtd->pcm,
|
|
|
SNDRV_DMA_TYPE_DEV,
|
|
SNDRV_DMA_TYPE_DEV,
|
|
|
- NULL, ST_MIN_BUFFER,
|
|
|
|
|
|
|
+ parent,
|
|
|
|
|
+ ST_MIN_BUFFER,
|
|
|
ST_MAX_BUFFER);
|
|
ST_MAX_BUFFER);
|
|
|
break;
|
|
break;
|
|
|
default:
|
|
default:
|
|
|
ret = snd_pcm_lib_preallocate_pages_for_all(rtd->pcm,
|
|
ret = snd_pcm_lib_preallocate_pages_for_all(rtd->pcm,
|
|
|
SNDRV_DMA_TYPE_DEV,
|
|
SNDRV_DMA_TYPE_DEV,
|
|
|
- NULL, MIN_BUFFER,
|
|
|
|
|
|
|
+ parent,
|
|
|
|
|
+ MIN_BUFFER,
|
|
|
MAX_BUFFER);
|
|
MAX_BUFFER);
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|