Merge branch 'topic/dma_control_cleanup_acks' into for-linus

This commit is contained in:
Vinod Koul 2014-10-15 21:38:49 +05:30
commit 2856fcdc1f
8 changed files with 11 additions and 17 deletions

View File

@ -420,7 +420,7 @@ dma_xfer(struct arasan_cf_dev *acdev, dma_addr_t src, dma_addr_t dest, u32 len)
/* Wait for DMA to complete */ /* Wait for DMA to complete */
if (!wait_for_completion_timeout(&acdev->dma_completion, TIMEOUT)) { if (!wait_for_completion_timeout(&acdev->dma_completion, TIMEOUT)) {
chan->device->device_control(chan, DMA_TERMINATE_ALL, 0); dmaengine_terminate_all(chan);
dev_err(acdev->host->dev, "wait_for_completion_timeout\n"); dev_err(acdev->host->dev, "wait_for_completion_timeout\n");
return -ETIMEDOUT; return -ETIMEDOUT;
} }
@ -928,8 +928,7 @@ static int arasan_cf_suspend(struct device *dev)
struct arasan_cf_dev *acdev = host->ports[0]->private_data; struct arasan_cf_dev *acdev = host->ports[0]->private_data;
if (acdev->dma_chan) if (acdev->dma_chan)
acdev->dma_chan->device->device_control(acdev->dma_chan, dmaengine_terminate_all(acdev->dma_chan);
DMA_TERMINATE_ALL, 0);
cf_exit(acdev); cf_exit(acdev);
return ata_host_suspend(host, PMSG_SUSPEND); return ata_host_suspend(host, PMSG_SUSPEND);

View File

@ -2156,7 +2156,7 @@ coh901318_free_chan_resources(struct dma_chan *chan)
spin_unlock_irqrestore(&cohc->lock, flags); spin_unlock_irqrestore(&cohc->lock, flags);
chan->device->device_control(chan, DMA_TERMINATE_ALL, 0); dmaengine_terminate_all(chan);
} }

View File

@ -415,10 +415,8 @@ static void mx3_stop_streaming(struct vb2_queue *q)
struct mx3_camera_buffer *buf, *tmp; struct mx3_camera_buffer *buf, *tmp;
unsigned long flags; unsigned long flags;
if (ichan) { if (ichan)
struct dma_chan *chan = &ichan->dma_chan; dmaengine_pause(&ichan->dma_chan);
chan->device->device_control(chan, DMA_PAUSE, 0);
}
spin_lock_irqsave(&mx3_cam->lock, flags); spin_lock_irqsave(&mx3_cam->lock, flags);

View File

@ -605,7 +605,7 @@ static int dma_xfer(struct fsmc_nand_data *host, void *buffer, int len,
wait_for_completion_timeout(&host->dma_access_complete, wait_for_completion_timeout(&host->dma_access_complete,
msecs_to_jiffies(3000)); msecs_to_jiffies(3000));
if (ret <= 0) { if (ret <= 0) {
chan->device->device_control(chan, DMA_TERMINATE_ALL, 0); dmaengine_terminate_all(chan);
dev_err(host->dev, "wait_for_completion_timeout\n"); dev_err(host->dev, "wait_for_completion_timeout\n");
if (!ret) if (!ret)
ret = -ETIMEDOUT; ret = -ETIMEDOUT;

View File

@ -395,7 +395,7 @@ static int flctl_dma_fifo0_transfer(struct sh_flctl *flctl, unsigned long *buf,
msecs_to_jiffies(3000)); msecs_to_jiffies(3000));
if (ret <= 0) { if (ret <= 0) {
chan->device->device_control(chan, DMA_TERMINATE_ALL, 0); dmaengine_terminate_all(chan);
dev_err(&flctl->pdev->dev, "wait_for_completion_timeout\n"); dev_err(&flctl->pdev->dev, "wait_for_completion_timeout\n");
} }

View File

@ -875,13 +875,11 @@ static void ks8842_stop_dma(struct ks8842_adapter *adapter)
tx_ctl->adesc = NULL; tx_ctl->adesc = NULL;
if (tx_ctl->chan) if (tx_ctl->chan)
tx_ctl->chan->device->device_control(tx_ctl->chan, dmaengine_terminate_all(tx_ctl->chan);
DMA_TERMINATE_ALL, 0);
rx_ctl->adesc = NULL; rx_ctl->adesc = NULL;
if (rx_ctl->chan) if (rx_ctl->chan)
rx_ctl->chan->device->device_control(rx_ctl->chan, dmaengine_terminate_all(rx_ctl->chan);
DMA_TERMINATE_ALL, 0);
if (sg_dma_address(&rx_ctl->sg)) if (sg_dma_address(&rx_ctl->sg))
dma_unmap_single(adapter->dev, sg_dma_address(&rx_ctl->sg), dma_unmap_single(adapter->dev, sg_dma_address(&rx_ctl->sg),

View File

@ -1403,7 +1403,7 @@ static void work_fn_rx(struct work_struct *work)
unsigned long flags; unsigned long flags;
int count; int count;
chan->device->device_control(chan, DMA_TERMINATE_ALL, 0); dmaengine_terminate_all(chan);
dev_dbg(port->dev, "Read %zu bytes with cookie %d\n", dev_dbg(port->dev, "Read %zu bytes with cookie %d\n",
sh_desc->partial, sh_desc->cookie); sh_desc->partial, sh_desc->cookie);

View File

@ -461,8 +461,7 @@ static void sdc_disable_channel(struct mx3fb_info *mx3_fbi)
spin_unlock_irqrestore(&mx3fb->lock, flags); spin_unlock_irqrestore(&mx3fb->lock, flags);
mx3_fbi->txd->chan->device->device_control(mx3_fbi->txd->chan, dmaengine_terminate_all(mx3_fbi->txd->chan);
DMA_TERMINATE_ALL, 0);
mx3_fbi->txd = NULL; mx3_fbi->txd = NULL;
mx3_fbi->cookie = -EINVAL; mx3_fbi->cookie = -EINVAL;
} }