]> err.no Git - linux-2.6/commitdiff
async_tx: kill ->device_dependency_added
authorDan Williams <dan.j.williams@intel.com>
Fri, 18 Apr 2008 03:17:26 +0000 (20:17 -0700)
committerDan Williams <dan.j.williams@intel.com>
Thu, 17 Apr 2008 20:25:54 +0000 (13:25 -0700)
DMA drivers no longer need to be notified of dependency submission
events as async_tx_run_dependencies and async_tx_channel_switch will
handle the scheduling and execution of dependent operations.

[sfr@canb.auug.org.au: extend this for fsldma]
Acked-by: Shannon Nelson <shannon.nelson@intel.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/dma/dmaengine.c
drivers/dma/fsldma.c
drivers/dma/ioat_dma.c
drivers/dma/iop-adma.c
include/linux/dmaengine.h

index 9cb898a76bb311736d16e77566c68cd7c0906752..af6911a75dae48a96333a8638f477d2233eba661 100644 (file)
@@ -362,7 +362,6 @@ int dma_async_device_register(struct dma_device *device)
 
        BUG_ON(!device->device_alloc_chan_resources);
        BUG_ON(!device->device_free_chan_resources);
-       BUG_ON(!device->device_dependency_added);
        BUG_ON(!device->device_is_tx_complete);
        BUG_ON(!device->device_issue_pending);
        BUG_ON(!device->dev);
index d8ae18dbf1a795c9c053625ee5b6af408440c43b..95b36b7934a5ae71e74ba2a6ecd9b23d8a0b32fb 100644 (file)
@@ -658,13 +658,6 @@ static void fsl_dma_memcpy_issue_pending(struct dma_chan *chan)
        fsl_chan_xfer_ld_queue(fsl_chan);
 }
 
-static void fsl_dma_dependency_added(struct dma_chan *chan)
-{
-       struct fsl_dma_chan *fsl_chan = to_fsl_chan(chan);
-
-       fsl_chan_ld_cleanup(fsl_chan);
-}
-
 /**
  * fsl_dma_is_complete - Determine the DMA status
  * @fsl_chan : Freescale DMA channel
@@ -1089,7 +1082,6 @@ static int __devinit of_fsl_dma_probe(struct of_device *dev,
        fdev->common.device_prep_dma_memcpy = fsl_dma_prep_memcpy;
        fdev->common.device_is_tx_complete = fsl_dma_is_complete;
        fdev->common.device_issue_pending = fsl_dma_memcpy_issue_pending;
-       fdev->common.device_dependency_added = fsl_dma_dependency_added;
        fdev->common.dev = &dev->dev;
 
        irq = irq_of_parse_and_map(dev->node, 0);
index 4017d9e7acd2a2b68020e2584c71dc654dd20cae..1517fe4e2d142c91ccbf863727c4218490c166c1 100644 (file)
@@ -924,17 +924,6 @@ static void ioat_dma_memcpy_cleanup(struct ioat_dma_chan *ioat_chan)
        spin_unlock_bh(&ioat_chan->cleanup_lock);
 }
 
-static void ioat_dma_dependency_added(struct dma_chan *chan)
-{
-       struct ioat_dma_chan *ioat_chan = to_ioat_chan(chan);
-       spin_lock_bh(&ioat_chan->desc_lock);
-       if (ioat_chan->pending == 0) {
-               spin_unlock_bh(&ioat_chan->desc_lock);
-               ioat_dma_memcpy_cleanup(ioat_chan);
-       } else
-               spin_unlock_bh(&ioat_chan->desc_lock);
-}
-
 /**
  * ioat_dma_is_complete - poll the status of a IOAT DMA transaction
  * @chan: IOAT DMA channel handle
@@ -1316,7 +1305,6 @@ struct ioatdma_device *ioat_dma_probe(struct pci_dev *pdev,
 
        dma_cap_set(DMA_MEMCPY, device->common.cap_mask);
        device->common.device_is_tx_complete = ioat_dma_is_complete;
-       device->common.device_dependency_added = ioat_dma_dependency_added;
        switch (device->version) {
        case IOAT_VER_1_2:
                device->common.device_prep_dma_memcpy = ioat1_dma_prep_memcpy;
index 21854cd7190f115e79dc9d1a85b76da5d33e3bf9..2aa3df50c842bc5d45a42dc16ca9dc5d9a109f06 100644 (file)
@@ -672,12 +672,6 @@ iop_adma_prep_dma_zero_sum(struct dma_chan *chan, dma_addr_t *dma_src,
        return sw_desc ? &sw_desc->async_tx : NULL;
 }
 
-static void iop_adma_dependency_added(struct dma_chan *chan)
-{
-       struct iop_adma_chan *iop_chan = to_iop_adma_chan(chan);
-       tasklet_schedule(&iop_chan->irq_tasklet);
-}
-
 static void iop_adma_free_chan_resources(struct dma_chan *chan)
 {
        struct iop_adma_chan *iop_chan = to_iop_adma_chan(chan);
@@ -1178,7 +1172,6 @@ static int __devinit iop_adma_probe(struct platform_device *pdev)
        dma_dev->device_free_chan_resources = iop_adma_free_chan_resources;
        dma_dev->device_is_tx_complete = iop_adma_is_complete;
        dma_dev->device_issue_pending = iop_adma_issue_pending;
-       dma_dev->device_dependency_added = iop_adma_dependency_added;
        dma_dev->dev = &pdev->dev;
 
        /* set prep routines based on capability */
index 91252a7e4d037577faea898c50d33a99e9580319..cd34df78c6aa71706c880c18d85900fd022171bf 100644 (file)
@@ -258,7 +258,6 @@ struct dma_async_tx_descriptor {
  * @device_prep_dma_zero_sum: prepares a zero_sum operation
  * @device_prep_dma_memset: prepares a memset operation
  * @device_prep_dma_interrupt: prepares an end of chain interrupt operation
- * @device_dependency_added: async_tx notifies the channel about new deps
  * @device_issue_pending: push pending transactions to hardware
  */
 struct dma_device {
@@ -293,7 +292,6 @@ struct dma_device {
        struct dma_async_tx_descriptor *(*device_prep_dma_interrupt)(
                struct dma_chan *chan);
 
-       void (*device_dependency_added)(struct dma_chan *chan);
        enum dma_status (*device_is_tx_complete)(struct dma_chan *chan,
                        dma_cookie_t cookie, dma_cookie_t *last,
                        dma_cookie_t *used);