summaryrefslogtreecommitdiff
path: root/drivers/dma/ipu
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2010-03-27 02:52:10 +0300
committerDan Williams <dan.j.williams@intel.com>2010-03-27 02:52:10 +0300
commitbca3469205402d9fb14060d255d8786ae2256640 (patch)
tree3b0c7f246fb9a6eafd3a82dd621dd9753589b3f4 /drivers/dma/ipu
parent0793448187643b50af89d36b08470baf45a3cab4 (diff)
downloadlinux-bca3469205402d9fb14060d255d8786ae2256640.tar.xz
dmaengine: provide helper for setting txstate
Simple conditional struct filler to cut out some duplicated code. Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/dma/ipu')
-rw-r--r--drivers/dma/ipu/ipu_idmac.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/dma/ipu/ipu_idmac.c b/drivers/dma/ipu/ipu_idmac.c
index b9cef8b1701c..246a6143e4a7 100644
--- a/drivers/dma/ipu/ipu_idmac.c
+++ b/drivers/dma/ipu/ipu_idmac.c
@@ -1651,11 +1651,7 @@ static enum dma_status idmac_tx_status(struct dma_chan *chan,
{
struct idmac_channel *ichan = to_idmac_chan(chan);
- if (txstate) {
- txstate->last = ichan->completed;
- txstate->used = chan->cookie;
- txstate->residue = 0;
- }
+ dma_set_tx_state(txstate, ichan->completed, chan->cookie, 0);
if (cookie != chan->cookie)
return DMA_ERROR;
return DMA_SUCCESS;