From: Frank Li Replace direct calls to chan->device->device_prep_slave_sg() with the dmaengine_prep_slave_sg_context() helper in both sprd-pcm-dma.c and sprd-pcm-compress.c. No functional change. Prepare to make struct dma_device private to the DMA engine. Signed-off-by: Frank Li --- Last user use prep_sg with context argument. Suggest go through DMA Engine tree directly. --- sound/soc/sprd/sprd-pcm-compress.c | 6 +++--- sound/soc/sprd/sprd-pcm-dma.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/sound/soc/sprd/sprd-pcm-compress.c b/sound/soc/sprd/sprd-pcm-compress.c index a810c9c8a0b5b..228cb8741c438 100644 --- a/sound/soc/sprd/sprd-pcm-compress.c +++ b/sound/soc/sprd/sprd-pcm-compress.c @@ -236,9 +236,9 @@ static int sprd_platform_compr_dma_config(struct snd_soc_component *component, * We configure the DMA request mode, interrupt mode, channel * mode and channel trigger mode by the flags. */ - dma->desc = dma->chan->device->device_prep_slave_sg(dma->chan, sg, - sg_num, dir, - flags, &link); + dma->desc = dmaengine_prep_slave_sg_context(dma->chan, sg, + sg_num, dir, + flags, &link); if (!dma->desc) { dev_err(dev, "failed to prepare slave sg\n"); ret = -ENOMEM; diff --git a/sound/soc/sprd/sprd-pcm-dma.c b/sound/soc/sprd/sprd-pcm-dma.c index 968901ae4c335..bb72cb272d4b3 100644 --- a/sound/soc/sprd/sprd-pcm-dma.c +++ b/sound/soc/sprd/sprd-pcm-dma.c @@ -277,9 +277,9 @@ static int sprd_pcm_hw_params(struct snd_soc_component *component, */ flags = SPRD_DMA_FLAGS(SPRD_DMA_CHN_MODE_NONE, SPRD_DMA_NO_TRG, SPRD_DMA_FRAG_REQ, SPRD_DMA_TRANS_INT); - data->desc = chan->device->device_prep_slave_sg(chan, sg, - sg_num, dir, - flags, &link); + data->desc = dmaengine_prep_slave_sg_context(chan, sg, + sg_num, dir, + flags, &link); if (!data->desc) { dev_err(component->dev, "failed to prepare slave sg\n"); ret = -ENOMEM; -- 2.43.0