dma: convert tasklets to use new tasklet_setup()
Subsystems (21)
cover dma: convert tasklets to use new tasklet_setup()
Commit 12cc923f1ccc ("tasklet: Introduce new initialization API")' introduced a new tasklet initialization API. This series converts all the dma drivers to use the new tasklet_setup() API
Allen Pais (35):
dma: altera-msgdma: convert tasklets to use new tasklet_setup() API
dma: at_hdmac: convert tasklets to use new tasklet_setup() API
dma: at_xdmac: convert tasklets to use new tasklet_setup() API
dma: coh901318: convert tasklets to use new tasklet_setup() API
dma: dw: convert tasklets to use new tasklet_setup() API
dma: ep93xx: convert tasklets to use new tasklet_setup() API
dma: fsl: convert tasklets to use new tasklet_setup() API
dma: imx-dma: convert tasklets to use new tasklet_setup() API
dma: ioat: convert tasklets to use new tasklet_setup() API
dma: iop_adma: convert tasklets to use new tasklet_setup() API
dma: ipu: convert tasklets to use new tasklet_setup() API
dma: k3dma: convert tasklets to use new tasklet_setup() API
dma: mediatek: convert tasklets to use new tasklet_setup() API
dma: mmp: convert tasklets to use new tasklet_setup() API
dma: mpc512x: convert tasklets to use new tasklet_setup() API
dma: mv_xor: convert tasklets to use new tasklet_setup() API
dma: mxs-dma: convert tasklets to use new tasklet_setup() API
dma: nbpfaxi: convert tasklets to use new tasklet_setup() API
dma: pch_dma: convert tasklets to use new tasklet_setup() API
dma: pl330: convert tasklets to use new tasklet_setup() API
dma: ppc4xx: convert tasklets to use new tasklet_setup() API
dma: qcom: convert tasklets to use new tasklet_setup() API
dma: sa11x0: convert tasklets to use new tasklet_setup() API
dma: sirf-dma: convert tasklets to use new tasklet_setup() API
dma: ste_dma40: convert tasklets to use new tasklet_setup() API
dma: sun6i: convert tasklets to use new tasklet_setup() API
dma: tegra20: convert tasklets to use new tasklet_setup() API
dma: timb_dma: convert tasklets to use new tasklet_setup() API
dma: txx9dmac: convert tasklets to use new tasklet_setup() API
dma: virt-dma: convert tasklets to use new tasklet_setup() API
dma: xgene: convert tasklets to use new tasklet_setup() API
dma: xilinx: convert tasklets to use new tasklet_setup() API
dma: plx_dma: convert tasklets to use new tasklet_setup() API
dma: sf-pdma: convert tasklets to use new tasklet_setup() API
dma: k3-udma: convert tasklets to use new tasklet_setup() API
drivers/dma/altera-msgdma.c | 6 +++--- drivers/dma/at_hdmac.c | 7 +++---- drivers/dma/at_xdmac.c | 5 ++--- drivers/dma/coh901318.c | 7 +++---- drivers/dma/dw/core.c | 6 +++--- drivers/dma/ep93xx_dma.c | 7 +++---- drivers/dma/fsl_raid.c | 6 +++--- drivers/dma/fsldma.c | 6 +++--- drivers/dma/imx-dma.c | 7 +++---- drivers/dma/ioat/dma.c | 6 +++--- drivers/dma/ioat/dma.h | 2 +- drivers/dma/ioat/init.c | 4 +--- drivers/dma/iop-adma.c | 8 ++++---- drivers/dma/ipu/ipu_idmac.c | 6 +++--- drivers/dma/k3dma.c | 6 +++--- drivers/dma/mediatek/mtk-cqdma.c | 7 +++---- drivers/dma/mmp_pdma.c | 6 +++--- drivers/dma/mmp_tdma.c | 6 +++--- drivers/dma/mpc512x_dma.c | 6 +++--- drivers/dma/mv_xor.c | 7 +++---- drivers/dma/mv_xor_v2.c | 8 ++++---- drivers/dma/mxs-dma.c | 7 +++---- drivers/dma/nbpfaxi.c | 6 +++--- drivers/dma/pch_dma.c | 7 +++---- drivers/dma/pl330.c | 12 ++++++------ drivers/dma/plx_dma.c | 7 +++---- drivers/dma/ppc4xx/adma.c | 7 +++---- drivers/dma/qcom/bam_dma.c | 6 +++--- drivers/dma/qcom/hidma.c | 6 +++--- drivers/dma/qcom/hidma_ll.c | 6 +++--- drivers/dma/sa11x0-dma.c | 6 +++--- drivers/dma/sf-pdma/sf-pdma.c | 14 ++++++-------- drivers/dma/sirf-dma.c | 6 +++--- drivers/dma/ste_dma40.c | 7 +++---- drivers/dma/sun6i-dma.c | 6 +++--- drivers/dma/tegra20-apb-dma.c | 7 +++---- drivers/dma/ti/k3-udma.c | 7 +++---- drivers/dma/timb_dma.c | 6 +++--- drivers/dma/txx9dmac.c | 14 ++++++-------- drivers/dma/virt-dma.c | 6 +++--- drivers/dma/xgene-dma.c | 7 +++---- drivers/dma/xilinx/xilinx_dma.c | 7 +++---- drivers/dma/xilinx/zynqmp_dma.c | 6 +++--- 43 files changed, 135 insertions(+), 157 deletions(-)
Signature · 1 line
2.17.1
PATCH 1/35 dma: altera-msgdma: convert tasklets to use new tasklet_setup() API
In preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/altera-msgdma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/altera-msgdma.c +3 -3
@@ -680,9 +680,9 @@ static int msgdma_alloc_chan_resources(struct dma_chan *dchan)* msgdma_tasklet - Schedule completion tasklet * @data: Pointer to the Altera sSGDMA channel structure */ -static void msgdma_tasklet (unsigned long data) +static void msgdma_tasklet (struct tasklet_struct *t) { -struct msgdma_device *mdev = (struct msgdma_device *)data; +struct msgdma_device *mdev =from_tasklet (mdev, t, irq_tasklet);u32 count;u32 __maybe_unused size;u32 __maybe_unused status;
@@ -830,7 +830,7 @@ static int msgdma_probe(struct platform_device *pdev)if (ret)return ret; -tasklet_init (&mdev->irq_tasklet, msgdma_tasklet, (unsigned long )mdev); +tasklet_setup (&mdev->irq_tasklet, msgdma_tasklet);dma_cookie_init (&mdev->dmachan);
Signature · 1 line
2.17.1
PATCH 2/35 dma: at_hdmac: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/at_hdmac.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/at_hdmac.c +3 -4
@@ -598,9 +598,9 @@ static void atc_handle_cyclic(struct at_dma_chan *atchan)/*-- IRQ & Tasklet ---------------------------------------------------*/ -static void atc_tasklet (unsigned long data) +static void atc_tasklet (struct tasklet_struct *t) { -struct at_dma_chan *atchan = (struct at_dma_chan *)data; +struct at_dma_chan *atchan =from_tasklet (atchan, t, tasklet);if (test_and_clear_bit (ATC_IS_ERROR , &atchan->status))return atc_handle_error (atchan);
@@ -1885,8 +1885,7 @@ static int __init at_dma_probe(struct platform_device *pdev)INIT_LIST_HEAD (&atchan->queue);INIT_LIST_HEAD (&atchan->free_list); -tasklet_init (&atchan->tasklet, atc_tasklet, - (unsigned long )atchan); +tasklet_setup (&atchan->tasklet, atc_tasklet);atc_enable_chan_irq (atdma, i); }
Signature · 1 line
2.17.1
PATCH 3/35 dma: at_xdmac: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/at_xdmac.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/dma/at_xdmac.c +2 -3
@@ -1615,7 +1615,7 @@ static void at_xdmac_handle_error(struct at_xdmac_chan *atchan)static void at_xdmac_tasklet (unsigned long data) { -struct at_xdmac_chan *atchan = (struct at_xdmac_chan *)data; +struct at_xdmac_chan *atchan =from_tasklet (atchan, t, tasklet);struct at_xdmac_desc *desc;u32 error_mask;
@@ -2063,8 +2063,7 @@ static int at_xdmac_probe(struct platform_device *pdev)spin_lock_init (&atchan->lock);INIT_LIST_HEAD (&atchan->xfers_list);INIT_LIST_HEAD (&atchan->free_descs_list); -tasklet_init (&atchan->tasklet, at_xdmac_tasklet, - (unsigned long )atchan); +tasklet_setup (&atchan->tasklet, at_xdmac_tasklet);/* Clear pending interrupts. */ while (at_xdmac_chan_read (atchan,AT_XDMAC_CIS ))
Signature · 1 line
2.17.1
kernel test robot
build botRe: [PATCH 03/35] dma: at_xdmac: convert tasklets to use new tasklet_setup() API
Thank you for the patch! Yet something to improve:
Hi Allen,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on vkoul-dmaengine/next]
[also build test ERROR on shawnguo/for-next v5.9-rc1 next-20200817] [cannot apply to xlnx/master]
[If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Allen-Pais/dma-convert-tasklets-to-use-new-tasklet_setup/20200817-162529 base: https://git.kernel.org/pub/scm/linux/kernel/git/vkoul/dmaengine.git next config: arm-defconfig (attached as .config) compiler: arm-linux-gnueabi-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
All errors (new ones prefixed by >>):
drivers/dma/at_xdmac.c: In function 'at_xdmac_tasklet':
>> drivers/dma/at_xdmac.c:1618:33: error: implicit declaration of function 'from_tasklet' [-Werror=implicit-function-declaration]
1618 | struct at_xdmac_chan *atchan = from_tasklet(atchan, t, tasklet);
| ^~~~~~~~~~~~
>> drivers/dma/at_xdmac.c:1618:54: error: 't' undeclared (first use in this function); did you mean 'tm'?
1618 | struct at_xdmac_chan *atchan = from_tasklet(atchan, t, tasklet);
| ^
| tm
drivers/dma/at_xdmac.c:1618:54: note: each undeclared identifier is reported only once for each function it appears in
>> drivers/dma/at_xdmac.c:1618:57: error: 'tasklet' undeclared (first use in this function)
1618 | struct at_xdmac_chan *atchan = from_tasklet(atchan, t, tasklet);
| ^~~~~~~
drivers/dma/at_xdmac.c: In function 'at_xdmac_probe':
>> drivers/dma/at_xdmac.c:2066:3: error: implicit declaration of function 'tasklet_setup' [-Werror=implicit-function-declaration]
2066 | tasklet_setup(&atchan->tasklet, at_xdmac_tasklet);
| ^~~~~~~~~~~~~cc1: some warnings being treated as errors
# https://github.com/0day-ci/linux/commit/fecf141cda7ac9d85728b94ac123ecb2a4ff1d7c
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Allen-Pais/dma-convert-tasklets-to-use-new-tasklet_setup/20200817-162529 git checkout fecf141cda7ac9d85728b94ac123ecb2a4ff1d7c
vim +/from_tasklet +1618 drivers/dma/at_xdmac.c
1615
1616 static void at_xdmac_tasklet(unsigned long data)
1617 {
> 1618 struct at_xdmac_chan *atchan = from_tasklet(atchan, t, tasklet);
1619 struct at_xdmac_desc *desc;
1620 u32 error_mask;
1621
1622 dev_dbg(chan2dev(&atchan->chan), "%s: status=0x%08x\n",
1623 __func__, atchan->irq_status);
1624
1625 error_mask = AT_XDMAC_CIS_RBEIS
1626 | AT_XDMAC_CIS_WBEIS
1627 | AT_XDMAC_CIS_ROIS;
1628
1629 if (at_xdmac_chan_is_cyclic(atchan)) {
1630 at_xdmac_handle_cyclic(atchan);
1631 } else if ((atchan->irq_status & AT_XDMAC_CIS_LIS)
1632 || (atchan->irq_status & error_mask)) {
1633 struct dma_async_tx_descriptor *txd;
1634
1635 if (atchan->irq_status & error_mask)
1636 at_xdmac_handle_error(atchan);
1637
1638 spin_lock_irq(&atchan->lock);
1639 desc = list_first_entry(&atchan->xfers_list,
1640 struct at_xdmac_desc,
1641 xfer_node);
1642 dev_vdbg(chan2dev(&atchan->chan), "%s: desc 0x%p\n", __func__, desc);
1643 if (!desc->active_xfer) {
1644 dev_err(chan2dev(&atchan->chan), "Xfer not active: exiting");
1645 spin_unlock_irq(&atchan->lock);
1646 return;
1647 }
1648
1649 txd = &desc->tx_dma_desc;
1650
1651 at_xdmac_remove_xfer(atchan, desc);
1652 spin_unlock_irq(&atchan->lock);
1653
1654 dma_cookie_complete(txd);
1655 if (txd->flags & DMA_PREP_INTERRUPT)
1656 dmaengine_desc_get_callback_invoke(txd, NULL);
1657
1658 dma_run_dependencies(txd);
1659
1660 spin_lock_irq(&atchan->lock);
1661 at_xdmac_advance_work(atchan);
1662 spin_unlock_irq(&atchan->lock);
1663 }
1664 }
1665
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
PATCH 4/35 dma: coh901318: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/coh901318.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/coh901318.c +3 -4
@@ -1868,9 +1868,9 @@ static struct coh901318_desc *coh901318_queue_start(struct coh901318_chan *cohc)* This tasklet is called from the interrupt handler to * handle each descriptor (DMA job) that is sent to a channel. */ -static void dma_tasklet (unsigned long data) +static void dma_tasklet (struct tasklet_struct *t) { -struct coh901318_chan *cohc = (struct coh901318_chan *) data; +struct coh901318_chan *cohc =from_tasklet (cohc, t, tasklet);struct coh901318_desc *cohd_fin;unsigned long flags;struct dmaengine_desc_callback cb;
@@ -2615,8 +2615,7 @@ static void coh901318_base_init(struct dma_device *dma, const int *pick_chans,INIT_LIST_HEAD (&cohc->active);INIT_LIST_HEAD (&cohc->queue); -tasklet_init (&cohc->tasklet, dma_tasklet, - (unsigned long ) cohc); +tasklet_setup (&cohc->tasklet, dma_tasklet);list_add_tail (&cohc->chan.device_node, &dma->channels);
Signature · 1 line
2.17.1
PATCH 5/35 dma: dw: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/dw/core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/dw/core.c +3 -3
@@ -463,9 +463,9 @@ static void dwc_handle_error(struct dw_dma *dw, struct dw_dma_chan *dwc)dwc_descriptor_complete (dwc, bad_desc, true); } -static void dw_dma_tasklet (unsigned long data) +static void dw_dma_tasklet (struct tasklet_struct *t) { -struct dw_dma *dw = (struct dw_dma *)data; +struct dw_dma *dw =from_tasklet (dw, t, tasklet);struct dw_dma_chan *dwc;u32 status_xfer;u32 status_err;
@@ -1138,7 +1138,7 @@ int do_dma_probe(struct dw_dma_chip *chip) goto err_pdata; } -tasklet_init (&dw->tasklet, dw_dma_tasklet, (unsigned long )dw); +tasklet_setup (&dw->tasklet, dw_dma_tasklet); err =request_irq (chip->irq, dw_dma_interrupt,IRQF_SHARED , dw->name, dw);
Signature · 1 line
2.17.1
PATCH 6/35 dma: ep93xx: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ep93xx_dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/ep93xx_dma.c +3 -4
@@ -745,9 +745,9 @@ static void ep93xx_dma_advance_work(struct ep93xx_dma_chan *edmac)spin_unlock_irqrestore (&edmac->lock, flags); } -static void ep93xx_dma_tasklet (unsigned long data) +static void ep93xx_dma_tasklet (struct tasklet_struct *t) { -struct ep93xx_dma_chan *edmac = (struct ep93xx_dma_chan *)data; +struct ep93xx_dma_chan *edmac =from_tasklet (edmac, t, tasklet);struct ep93xx_dma_desc *desc, *d;struct dmaengine_desc_callback cb;LIST_HEAD (list);
@@ -1353,8 +1353,7 @@ static int __init ep93xx_dma_probe(struct platform_device *pdev)INIT_LIST_HEAD (&edmac->active);INIT_LIST_HEAD (&edmac->queue);INIT_LIST_HEAD (&edmac->free_list); -tasklet_init (&edmac->tasklet, ep93xx_dma_tasklet, - (unsigned long )edmac); +tasklet_setup (&edmac->tasklet, ep93xx_dma_tasklet);list_add_tail (&edmac->chan.device_node, &dma_dev->channels);
Signature · 1 line
2.17.1
PATCH 7/35 dma: fsl: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/fsl_raid.c | 6 +++--- drivers/dma/fsldma.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-)
drivers/dma/fsl_raid.c +3 -3
@@ -154,9 +154,9 @@ static void fsl_re_cleanup_descs(struct fsl_re_chan *re_chan)fsl_re_issue_pending (&re_chan->chan); } -static void fsl_re_dequeue (unsigned long data) +static void fsl_re_dequeue (struct tasklet_struct *t) { -struct fsl_re_chan *re_chan; + struct fsl_re_chan *re_chan from_tasklet(re_chan, t, irqtask);struct fsl_re_desc *desc, *_desc;struct fsl_re_hw_desc *hwdesc;unsigned long flags;
@@ -671,7 +671,7 @@ static int fsl_re_chan_probe(struct platform_device *ofdev,snprintf (chan->name,sizeof (chan->name),"re_jr%02d" , q); chandev = &chan_ofdev->dev; -tasklet_init (&chan->irqtask, fsl_re_dequeue, (unsigned long )chandev); +tasklet_setup (&chan->irqtask, fsl_re_dequeue); ret =request_irq (chan->irq, fsl_re_isr,0 , chan->name, chandev);if (ret) {
drivers/dma/fsldma.c +3 -3
@@ -976,9 +976,9 @@ static irqreturn_t fsldma_chan_irq(int irq, void *data)return IRQ_HANDLED ; } -static void dma_do_tasklet (unsigned long data) +static void dma_do_tasklet (struct tasklet_struct *t) { -struct fsldma_chan *chan = (struct fsldma_chan *)data; +struct fsldma_chan *chan =from_tasklet (chan, t, tasklet);chan_dbg (chan,"tasklet entry\n" );
@@ -1151,7 +1151,7 @@ static int fsl_dma_chan_probe(struct fsldma_device *fdev, } fdev->chan[chan->id] = chan; -tasklet_init (&chan->tasklet, dma_do_tasklet, (unsigned long )chan); +tasklet_setup (&chan->tasklet, dma_do_tasklet);snprintf (chan->name,sizeof (chan->name),"chan%d" , chan->id);/* Initialize the channel */
Signature · 1 line
2.17.1
PATCH 8/35 dma: imx-dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/imx-dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/imx-dma.c +3 -4
@@ -613,9 +613,9 @@ static int imxdma_xfer_desc(struct imxdma_desc *d)return 0 ; } -static void imxdma_tasklet (unsigned long data) +static void imxdma_tasklet (struct tasklet_struct *t) { -struct imxdma_channel *imxdmac = (void *)data; +struct imxdma_channel *imxdmac =from_tasklet (imxdmac, t, dma_tasklet);struct imxdma_engine *imxdma = imxdmac->imxdma;struct imxdma_desc *desc, *next_desc;unsigned long flags;
@@ -1169,8 +1169,7 @@ static int __init imxdma_probe(struct platform_device *pdev)INIT_LIST_HEAD (&imxdmac->ld_free);INIT_LIST_HEAD (&imxdmac->ld_active); -tasklet_init (&imxdmac->dma_tasklet, imxdma_tasklet, - (unsigned long )imxdmac); +tasklet_setup (&imxdmac->dma_tasklet, imxdma_tasklet); imxdmac->chan.device = &imxdma->dma_device;dma_cookie_init (&imxdmac->chan); imxdmac->channel = i;
Signature · 1 line
2.17.1
PATCH 9/35 dma: ioat: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ioat/dma.c | 6 +++--- drivers/dma/ioat/dma.h | 2 +- drivers/dma/ioat/init.c | 4 +--- 3 files changed, 5 insertions(+), 7 deletions(-)
drivers/dma/ioat/dma.c +3 -3
@@ -165,7 +165,7 @@ void ioat_stop(struct ioatdma_chan *ioat_chan)tasklet_kill (&ioat_chan->cleanup_task);/* final cleanup now that everything is quiesced and can't re-arm */ -ioat_cleanup_event ((unsigned long )&ioat_chan->dma_chan); +ioat_cleanup_event (&ioat_chan->cleanup_task); }static void __ioat_issue_pending (struct ioatdma_chan *ioat_chan)
@@ -690,9 +690,9 @@ static void ioat_cleanup(struct ioatdma_chan *ioat_chan)spin_unlock_bh (&ioat_chan->cleanup_lock); } -void ioat_cleanup_event (unsigned long data) +void ioat_cleanup_event (struct tasklet_struct *t) { -struct ioatdma_chan *ioat_chan =to_ioat_chan ((void *)data); +struct ioatdma_chan *ioat_chan =from_tasklet (ioat_chan, t, cleanup_task);ioat_cleanup (ioat_chan);if (!test_bit (IOAT_RUN , &ioat_chan->state))
drivers/dma/ioat/dma.h +1 -1
@@ -393,7 +393,7 @@ int ioat_reset_hw(struct ioatdma_chan *ioat_chan);enum dma_status ioat_tx_status (struct dma_chan *c,dma_cookie_t cookie,struct dma_tx_state *txstate); -void ioat_cleanup_event (unsigned long data); +void ioat_cleanup_event (struct tasklet_struct *t);void ioat_timer_event (struct timer_list *t);int ioat_check_space_lock (struct ioatdma_chan *ioat_chan,int num_descs);void ioat_issue_pending (struct dma_chan *chan);
drivers/dma/ioat/init.c +1 -3
@@ -767,8 +767,6 @@ ioat_init_channel(struct ioatdma_device *ioat_dma, struct ioatdma_chan *ioat_chan, int idx) {struct dma_device *dma = &ioat_dma->dma_dev; -struct dma_chan *c = &ioat_chan->dma_chan; -unsigned long data = (unsigned long ) c; ioat_chan->ioat_dma = ioat_dma; ioat_chan->reg_base = ioat_dma->reg_base + (0x80 * (idx +1 ));
@@ -778,7 +776,7 @@ ioat_init_channel(struct ioatdma_device *ioat_dma,list_add_tail (&ioat_chan->dma_chan.device_node, &dma->channels); ioat_dma->idx[idx] = ioat_chan;timer_setup (&ioat_chan->timer, ioat_timer_event,0 ); -tasklet_init (&ioat_chan->cleanup_task, ioat_cleanup_event, data); +tasklet_setup (&ioat_chan->cleanup_task, ioat_cleanup_event); }#define IOAT_NUM_SRC_TEST 6/* must be <= 8 */
Signature · 1 line
2.17.1
PATCH 10/35 dma: iop_adma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/iop-adma.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/dma/iop-adma.c +4 -4
@@ -238,9 +238,10 @@ iop_adma_slot_cleanup(struct iop_adma_chan *iop_chan)spin_unlock_bh (&iop_chan->lock); } -static void iop_adma_tasklet (unsigned long data) +static void iop_adma_tasklet (struct tasklet_struct *t) { -struct iop_adma_chan *iop_chan = (struct iop_adma_chan *) data; +struct iop_adma_chan *iop_chan =from_tasklet (iop_chan, t, + irq_tasklet);/* lockdep will flag depedency submissions as potentially * recursive locking, this is not the case as a dependency
@@ -1351,8 +1352,7 @@ static int iop_adma_probe(struct platform_device *pdev) ret = -ENOMEM ; goto err_free_iop_chan; } -tasklet_init (&iop_chan->irq_tasklet, iop_adma_tasklet, (unsigned long ) - iop_chan); +tasklet_setup (&iop_chan->irq_tasklet, iop_adma_tasklet);/* clear errors before enabling interrupts */ iop_adma_device_clear_err_status (iop_chan);
Signature · 1 line
2.17.1
PATCH 11/35 dma: ipu: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ipu/ipu_idmac.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/ipu/ipu_idmac.c +3 -3
@@ -1299,9 +1299,9 @@ static irqreturn_t idmac_interrupt(int irq, void *dev_id)return IRQ_HANDLED ; } -static void ipu_gc_tasklet (unsigned long arg) +static void ipu_gc_tasklet (struct tasklet_struct *t) { -struct ipu *ipu = (struct ipu *)arg; +struct ipu *ipu =from_tasklet (ipu, t, tasklet);int i;for (i =0 ; i <IPU_CHANNELS_NUM ; i++) {
@@ -1740,7 +1740,7 @@ static int __init ipu_probe(struct platform_device *pdev)if (ret <0 ) goto err_idmac_init; -tasklet_init (&ipu_data.tasklet, ipu_gc_tasklet, (unsigned long )&ipu_data); +tasklet_setup (&ipu_data.tasklet, ipu_gc_tasklet); ipu_data.dev = &pdev->dev;
Signature · 1 line
2.17.1
PATCH 12/35 dma: k3dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/k3dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/k3dma.c +3 -3
@@ -297,9 +297,9 @@ static int k3_dma_start_txd(struct k3_dma_chan *c)return -EAGAIN ; } -static void k3_dma_tasklet (unsigned long arg) +static void k3_dma_tasklet (struct tasklet_struct *t) { -struct k3_dma_dev *d = (struct k3_dma_dev *)arg; +struct k3_dma_dev *d =from_tasklet (d, t, task);struct k3_dma_phy *p;struct k3_dma_chan *c, *cn;unsigned pch, pch_alloc =0 ;
@@ -962,7 +962,7 @@ static int k3_dma_probe(struct platform_device *op)spin_lock_init (&d->lock);INIT_LIST_HEAD (&d->chan_pending); -tasklet_init (&d->task, k3_dma_tasklet, (unsigned long )d); +tasklet_setup (&d->task, k3_dma_tasklet);platform_set_drvdata (op, d);dev_info (&op->dev,"initialized\n" );
Signature · 1 line
2.17.1
PATCH 13/35 dma: mediatek: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/mediatek/mtk-cqdma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/mediatek/mtk-cqdma.c +3 -4
@@ -356,9 +356,9 @@ static struct mtk_cqdma_vdescreturn ret; } -static void mtk_cqdma_tasklet_cb (unsigned long data) +static void mtk_cqdma_tasklet_cb (struct tasklet_struct *t) { -struct mtk_cqdma_pchan *pc = (struct mtk_cqdma_pchan *)data; +struct mtk_cqdma_pchan *pc =from_tasklet (pc, t, tasklet);struct mtk_cqdma_vdesc *cvd =NULL ;unsigned long flags;
@@ -878,8 +878,7 @@ static int mtk_cqdma_probe(struct platform_device *pdev)/* initialize tasklet for each PC */ for (i =0 ; i < cqdma->dma_channels; ++i) -tasklet_init (&cqdma->pc[i]->tasklet, mtk_cqdma_tasklet_cb, - (unsigned long )cqdma->pc[i]); +tasklet_setup (&cqdma->pc[i]->tasklet, mtk_cqdma_tasklet_cb);dev_info (&pdev->dev,"MediaTek CQDMA driver registered\n" );
Signature · 1 line
2.17.1
PATCH 14/35 dma: mmp: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/mmp_pdma.c | 6 +++--- drivers/dma/mmp_tdma.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-)
drivers/dma/mmp_pdma.c +3 -3
@@ -873,9 +873,9 @@ static void mmp_pdma_issue_pending(struct dma_chan *dchan)* Do call back * Start pending list */ -static void dma_do_tasklet (unsigned long data) +static void dma_do_tasklet (struct tasklet_struct *t) { -struct mmp_pdma_chan *chan = (struct mmp_pdma_chan *)data; +struct mmp_pdma_chan *chan =from_tasklet (chan, t, tasklet);struct mmp_pdma_desc_sw *desc, *_desc;LIST_HEAD (chain_cleanup);unsigned long flags;
@@ -993,7 +993,7 @@ static int mmp_pdma_chan_init(struct mmp_pdma_device *pdev, int idx, int irq)spin_lock_init (&chan->desc_lock); chan->dev = pdev->dev; chan->chan.device = &pdev->device; -tasklet_init (&chan->tasklet, dma_do_tasklet, (unsigned long )chan); +tasklet_setup (&chan->tasklet, dma_do_tasklet);INIT_LIST_HEAD (&chan->chain_pending);INIT_LIST_HEAD (&chan->chain_running);
drivers/dma/mmp_tdma.c +3 -3
@@ -346,9 +346,9 @@ static irqreturn_t mmp_tdma_int_handler(int irq, void *dev_id)return IRQ_NONE ; } -static void dma_do_tasklet (unsigned long data) +static void dma_do_tasklet (struct tasklet_struct *t) { -struct mmp_tdma_chan *tdmac = (struct mmp_tdma_chan *)data; +struct mmp_tdma_chan *tdmac =from_tasklet (tdmac, t, tasklet);dmaengine_desc_get_callback_invoke (&tdmac->desc,NULL ); }
@@ -586,7 +586,7 @@ static int mmp_tdma_chan_init(struct mmp_tdma_device *tdev, tdmac->pool = pool; tdmac->status =DMA_COMPLETE ; tdev->tdmac[tdmac->idx] = tdmac; -tasklet_init (&tdmac->tasklet, dma_do_tasklet, (unsigned long )tdmac); +tasklet_setup (&tdmac->tasklet, dma_do_tasklet);/* add the channel to tdma_chan list */ list_add_tail(&tdmac->chan.device_node,
Signature · 1 line
2.17.1
PATCH 15/35 dma: mpc512x: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/mpc512x_dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/mpc512x_dma.c +3 -3
@@ -414,9 +414,9 @@ static void mpc_dma_process_completed(struct mpc_dma *mdma) }/* DMA Tasklet */ -static void mpc_dma_tasklet (unsigned long data) +static void mpc_dma_tasklet (struct tasklet_struct *t) { -struct mpc_dma *mdma = (void *)data; +struct mpc_dma *mdma =from_tasklet (mdma, t, tasklet);unsigned long flags;uint es;
@@ -1009,7 +1009,7 @@ static int mpc_dma_probe(struct platform_device *op)list_add_tail (&mchan->chan.device_node, &dma->channels); } -tasklet_init (&mdma->tasklet, mpc_dma_tasklet, (unsigned long )mdma); +tasklet_setup (&mdma->tasklet, mpc_dma_tasklet);/* * Configure DMA Engine:
Signature · 1 line
2.17.1
PATCH 16/35 dma: mv_xor: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/mv_xor.c | 7 +++---- drivers/dma/mv_xor_v2.c | 8 ++++---- 2 files changed, 7 insertions(+), 8 deletions(-)
drivers/dma/mv_xor.c +3 -4
@@ -336,9 +336,9 @@ static void mv_chan_slot_cleanup(struct mv_xor_chan *mv_chan) mv_chan->dmachan.completed_cookie = cookie; } -static void mv_xor_tasklet (unsigned long data) +static void mv_xor_tasklet (struct tasklet_struct *t) { -struct mv_xor_chan *chan = (struct mv_xor_chan *) data; +struct mv_xor_chan *chan =from_tasklet (chan, t, irq_tasklet);spin_lock (&chan->lock);mv_chan_slot_cleanup (chan);
@@ -1097,8 +1097,7 @@ mv_xor_channel_add(struct mv_xor_device *xordev, mv_chan->mmr_base = xordev->xor_base; mv_chan->mmr_high_base = xordev->xor_high_base; -tasklet_init (&mv_chan->irq_tasklet, mv_xor_tasklet, (unsigned long ) - mv_chan); +tasklet_setup (&mv_chan->irq_tasklet, mv_xor_tasklet);/* clear errors before enabling interrupts */ mv_chan_clear_err_status (mv_chan);
drivers/dma/mv_xor_v2.c +4 -4
@@ -553,9 +553,10 @@ int mv_xor_v2_get_pending_params(struct mv_xor_v2_device *xor_dev,/* * handle the descriptors after HW process */ -static void mv_xor_v2_tasklet (unsigned long data) +static void mv_xor_v2_tasklet (struct tasklet_struct *t) { -struct mv_xor_v2_device *xor_dev = (struct mv_xor_v2_device *) data; +struct mv_xor_v2_device *xor_dev =from_tasklet (xor_dev, t, + irq_tasklet);int pending_ptr, num_of_pending, i;struct mv_xor_v2_sw_desc *next_pending_sw_desc =NULL ;
@@ -780,8 +781,7 @@ static int mv_xor_v2_probe(struct platform_device *pdev)if (ret) goto free_msi_irqs; -tasklet_init (&xor_dev->irq_tasklet, mv_xor_v2_tasklet, - (unsigned long ) xor_dev); +tasklet_setup (&xor_dev->irq_tasklet, mv_xor_v2_tasklet); xor_dev->desc_size =mv_xor_v2_set_desc_size (xor_dev);
Signature · 1 line
2.17.1
PATCH 17/35 dma: mxs-dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/mxs-dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/mxs-dma.c +3 -4
@@ -320,9 +320,9 @@ static dma_cookie_t mxs_dma_tx_submit(struct dma_async_tx_descriptor *tx)return dma_cookie_assign (tx); } -static void mxs_dma_tasklet (unsigned long data) +static void mxs_dma_tasklet (struct tasklet_struct *t) { -struct mxs_dma_chan *mxs_chan = (struct mxs_dma_chan *) data; +struct mxs_dma_chan *mxs_chan =from_tasklet (mxs_chan, t, tasklet);dmaengine_desc_get_callback_invoke (&mxs_chan->desc,NULL ); }
@@ -812,8 +812,7 @@ static int __init mxs_dma_probe(struct platform_device *pdev) mxs_chan->chan.device = &mxs_dma->dma_device;dma_cookie_init (&mxs_chan->chan); -tasklet_init (&mxs_chan->tasklet, mxs_dma_tasklet, - (unsigned long ) mxs_chan); +tasklet_setup (&mxs_chan->tasklet, mxs_dma_tasklet);/* Add the channel to mxs_chan list */
Signature · 1 line
2.17.1
PATCH 18/35 dma: nbpfaxi: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/nbpfaxi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/nbpfaxi.c +3 -3
@@ -1113,9 +1113,9 @@ static struct dma_chan *nbpf_of_xlate(struct of_phandle_args *dma_spec,return dchan; } -static void nbpf_chan_tasklet (unsigned long data) +static void nbpf_chan_tasklet (struct tasklet_struct *t) { -struct nbpf_channel *chan = (struct nbpf_channel *)data; +struct nbpf_channel *chan =from_tasklet (chan, t, tasklet);struct nbpf_desc *desc, *tmp;struct dmaengine_desc_callback cb;
@@ -1260,7 +1260,7 @@ static int nbpf_chan_probe(struct nbpf_device *nbpf, int n)snprintf (chan->name,sizeof (chan->name),"nbpf %d" , n); -tasklet_init (&chan->tasklet, nbpf_chan_tasklet, (unsigned long )chan); +tasklet_setup (&chan->tasklet, nbpf_chan_tasklet); ret =devm_request_irq (dma_dev->dev, chan->irq, nbpf_chan_irq,IRQF_SHARED , chan->name, chan);
Signature · 1 line
2.17.1
PATCH 19/35 dma: pch_dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/pch_dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/pch_dma.c +3 -4
@@ -670,9 +670,9 @@ static int pd_device_terminate_all(struct dma_chan *chan)return 0 ; } -static void pdc_tasklet (unsigned long data) +static void pdc_tasklet (struct tasklet_struct *t) { -struct pch_dma_chan *pd_chan = (struct pch_dma_chan *)data; +struct pch_dma_chan *pd_chan =from_tasklet (pd_chan, t, tasklet);unsigned long flags;if (!pdc_is_idle (pd_chan)) {
@@ -898,8 +898,7 @@ static int pch_dma_probe(struct pci_dev *pdev,INIT_LIST_HEAD (&pd_chan->queue);INIT_LIST_HEAD (&pd_chan->free_list); -tasklet_init (&pd_chan->tasklet, pdc_tasklet, - (unsigned long )pd_chan); +tasklet_setup (&pd_chan->tasklet, pdc_tasklet);list_add_tail (&pd_chan->chan.device_node, &pd->dma.channels); }
Signature · 1 line
2.17.1
PATCH 20/35 dma: pl330: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/pl330.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/dma/pl330.c +6 -6
@@ -1580,9 +1580,9 @@ static void dma_pl330_rqcb(struct dma_pl330_desc *desc, enum pl330_op_err err)tasklet_schedule (&pch->task); } -static void pl330_dotask (unsigned long data) +static void pl330_dotask (struct tasklet_struct *t) { -struct pl330_dmac *pl330 = (struct pl330_dmac *) data; +struct pl330_dmac *pl330 =from_tasklet (pl330, t, tasks);unsigned long flags;int i;
@@ -1986,7 +1986,7 @@ static int pl330_add(struct pl330_dmac *pl330)return ret; } -tasklet_init (&pl330->tasks, pl330_dotask, (unsigned long ) pl330); +tasklet_setup (&pl330->tasks, pl330_dotask); pl330->state =INIT ;
@@ -2069,9 +2069,9 @@ static inline void fill_queue(struct dma_pl330_chan *pch) } } -static void pl330_tasklet (unsigned long data) +static void pl330_tasklet (struct tasklet_struct *t) { -struct dma_pl330_chan *pch = (struct dma_pl330_chan *)data; +struct dma_pl330_chan *pch =from_tasklet (pch, t, task);struct dma_pl330_desc *desc, *_dt;unsigned long flags;bool power_down = false;
@@ -2179,7 +2179,7 @@ static int pl330_alloc_chan_resources(struct dma_chan *chan)return -ENOMEM ; } -tasklet_init (&pch->task, pl330_tasklet, (unsigned long ) pch); +tasklet_setup (&pch->task, pl330_tasklet);spin_unlock_irqrestore (&pl330->lock, flags);
Signature · 1 line
2.17.1
PATCH 21/35 dma: ppc4xx: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ppc4xx/adma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/ppc4xx/adma.c +3 -4
@@ -1660,9 +1660,9 @@ static void __ppc440spe_adma_slot_cleanup(struct ppc440spe_adma_chan *chan)/** * ppc440spe_adma_tasklet - clean up watch-dog initiator */ -static void ppc440spe_adma_tasklet (unsigned long data) +static void ppc440spe_adma_tasklet (struct tasklet_struct *t) { -struct ppc440spe_adma_chan *chan = (struct ppc440spe_adma_chan *) data; +struct ppc440spe_adma_chan *chan =from_tasklet (chan, t, irq_tasklet);spin_lock_nested (&chan->lock,SINGLE_DEPTH_NESTING );__ppc440spe_adma_slot_cleanup (chan);
@@ -4141,8 +4141,7 @@ static int ppc440spe_adma_probe(struct platform_device *ofdev) chan->common.device = &adev->common;dma_cookie_init (&chan->common);list_add_tail (&chan->common.device_node, &adev->common.channels); -tasklet_init (&chan->irq_tasklet, ppc440spe_adma_tasklet, - (unsigned long )chan); +tasklet_setup (&chan->irq_tasklet, ppc440spe_adma_tasklet);/* allocate and map helper pages for async validation or * async_mult/async_sum_product operations on DMA0/1.
Signature · 1 line
2.17.1
PATCH 22/35 dma: qcom: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/qcom/bam_dma.c | 6 +++--- drivers/dma/qcom/hidma.c | 6 +++--- drivers/dma/qcom/hidma_ll.c | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-)
drivers/dma/qcom/bam_dma.c +3 -3
@@ -1075,9 +1075,9 @@ static void bam_start_dma(struct bam_chan *bchan)* * Sets up next DMA operation and then processes all completed transactions */ -static void dma_tasklet (unsigned long data) +static void dma_tasklet (struct tasklet_struct *t) { -struct bam_device *bdev = (struct bam_device *)data; +struct bam_device *bdev =from_tasklet (bdev, t, task);struct bam_chan *bchan;unsigned long flags;unsigned int i;
@@ -1293,7 +1293,7 @@ static int bam_dma_probe(struct platform_device *pdev)if (ret) goto err_disable_clk; -tasklet_init (&bdev->task, dma_tasklet, (unsigned long )bdev); +tasklet_setup (&bdev->task, dma_tasklet); bdev->channels =devm_kcalloc (bdev->dev, bdev->num_channels,sizeof (*bdev->channels),GFP_KERNEL );
drivers/dma/qcom/hidma.c +3 -3
@@ -224,9 +224,9 @@ static int hidma_chan_init(struct hidma_dev *dmadev, u32 dma_sig)return 0 ; } -static void hidma_issue_task (unsigned long arg) +static void hidma_issue_task (struct tasklet_struct *t) { -struct hidma_dev *dmadev = (struct hidma_dev *)arg; +struct hidma_dev *dmadev =from_tasklet (dmadev, t, task);pm_runtime_get_sync (dmadev->ddev.dev);hidma_ll_start (dmadev->lldev);
@@ -885,7 +885,7 @@ static int hidma_probe(struct platform_device *pdev) goto uninit; dmadev->irq = chirq; -tasklet_init (&dmadev->task, hidma_issue_task, (unsigned long )dmadev); +tasklet_setup (&dmadev->task, hidma_issue_task);hidma_debug_init (dmadev);hidma_sysfs_init (dmadev);dev_info (&pdev->dev,"HI-DMA engine driver registration complete\n" );
drivers/dma/qcom/hidma_ll.c +3 -3
@@ -173,9 +173,9 @@ int hidma_ll_request(struct hidma_lldev *lldev, u32 sig, const char *dev_name,/* * Multiple TREs may be queued and waiting in the pending queue. */ -static void hidma_ll_tre_complete (unsigned long arg) +static void hidma_ll_tre_complete (struct tasklet_struct *t) { -struct hidma_lldev *lldev = (struct hidma_lldev *)arg; +struct hidma_lldev *lldev =from_tasklet (lldev, t, task);struct hidma_tre *tre;while (kfifo_out (&lldev->handoff_fifo, &tre,1 )) {
@@ -792,7 +792,7 @@ struct hidma_lldev *hidma_ll_init(struct device *dev, u32 nr_tres,return NULL ;spin_lock_init (&lldev->lock); -tasklet_init (&lldev->task, hidma_ll_tre_complete, (unsigned long )lldev); +tasklet_setup (&lldev->task, hidma_ll_tre_complete); lldev->initialized =1 ;writel (ENABLE_IRQS , lldev->evca +HIDMA_EVCA_IRQ_EN_REG );return lldev;
Signature · 1 line
2.17.1
PATCH 23/35 dma: sa11x0: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/sa11x0-dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/sa11x0-dma.c +3 -3
@@ -323,9 +323,9 @@ static void sa11x0_dma_start_txd(struct sa11x0_dma_chan *c) } } -static void sa11x0_dma_tasklet (unsigned long arg) +static void sa11x0_dma_tasklet (struct tasklet_struct *t) { -struct sa11x0_dma_dev *d = (struct sa11x0_dma_dev *)arg; +struct sa11x0_dma_dev *d =from_tasklet (d, t, task);struct sa11x0_dma_phy *p;struct sa11x0_dma_chan *c;unsigned pch, pch_alloc =0 ;
@@ -928,7 +928,7 @@ static int sa11x0_dma_probe(struct platform_device *pdev) goto err_ioremap; } -tasklet_init (&d->task, sa11x0_dma_tasklet, (unsigned long )d); +tasklet_setup (&d->task, sa11x0_dma_tasklet);for (i =0 ; i <NR_PHY_CHAN ; i++) {struct sa11x0_dma_phy *p = &d->phy[i];
Signature · 1 line
2.17.1
PATCH 24/35 dma: sirf-dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/sirf-dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/sirf-dma.c +3 -3
@@ -393,9 +393,9 @@ static void sirfsoc_dma_process_completed(struct sirfsoc_dma *sdma) }/* DMA Tasklet */ -static void sirfsoc_dma_tasklet (unsigned long data) +static void sirfsoc_dma_tasklet (struct tasklet_struct *t) { -struct sirfsoc_dma *sdma = (void *)data; +struct sirfsoc_dma *sdma =from_tasklet (sdma, t, tasklet);sirfsoc_dma_process_completed (sdma); }
@@ -938,7 +938,7 @@ static int sirfsoc_dma_probe(struct platform_device *op)list_add_tail (&schan->chan.device_node, &dma->channels); } -tasklet_init (&sdma->tasklet, sirfsoc_dma_tasklet, (unsigned long )sdma); +tasklet_setup (&sdma->tasklet, sirfsoc_dma_tasklet);/* Register DMA engine */ dev_set_drvdata (dev, sdma);
Signature · 1 line
2.17.1
PATCH 25/35 dma: ste_dma40: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ste_dma40.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/ste_dma40.c +3 -4
@@ -1573,9 +1573,9 @@ static void dma_tc_handle(struct d40_chan *d40c) } -static void dma_tasklet (unsigned long data) +static void dma_tasklet (struct tasklet_struct *t) { -struct d40_chan *d40c = (struct d40_chan *) data; +struct d40_chan *d40c =from_tasklet (d40c, t, tasklet);struct d40_desc *d40d;unsigned long flags;bool callback_active;
@@ -2806,8 +2806,7 @@ static void __init d40_chan_init(struct d40_base *base, struct dma_device *dma,INIT_LIST_HEAD (&d40c->client);INIT_LIST_HEAD (&d40c->prepare_queue); -tasklet_init (&d40c->tasklet, dma_tasklet, - (unsigned long ) d40c); +tasklet_setup (&d40c->tasklet, dma_tasklet);list_add_tail (&d40c->chan.device_node, &dma->channels);
Signature · 1 line
2.17.1
PATCH 26/35 dma: sun6i: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/sun6i-dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/sun6i-dma.c +3 -3
@@ -467,9 +467,9 @@ static int sun6i_dma_start_desc(struct sun6i_vchan *vchan)return 0 ; } -static void sun6i_dma_tasklet (unsigned long data) +static void sun6i_dma_tasklet (struct tasklet_struct *t) { -struct sun6i_dma_dev *sdev = (struct sun6i_dma_dev *)data; +struct sun6i_dma_dev *sdev =from_tasklet (sdev, t, task);struct sun6i_vchan *vchan;struct sun6i_pchan *pchan;unsigned int pchan_alloc =0 ;
@@ -1343,7 +1343,7 @@ static int sun6i_dma_probe(struct platform_device *pdev)if (!sdc->vchans)return -ENOMEM ; -tasklet_init (&sdc->task, sun6i_dma_tasklet, (unsigned long )sdc); +tasklet_setup (&sdc->task, sun6i_dma_tasklet);for (i =0 ; i < sdc->num_pchans; i++) {struct sun6i_pchan *pchan = &sdc->pchans[i];
Signature · 1 line
2.17.1
PATCH 27/35 dma: tegra20: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/tegra20-apb-dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/tegra20-apb-dma.c +3 -4
@@ -644,9 +644,9 @@ static void handle_cont_sngl_cycle_dma_done(struct tegra_dma_channel *tdc, } } -static void tegra_dma_tasklet (unsigned long data) +static void tegra_dma_tasklet (struct tasklet_struct *t) { -struct tegra_dma_channel *tdc = (struct tegra_dma_channel *)data; +struct tegra_dma_channel *tdc =from_tasklet (tdc, t, tasklet);struct dmaengine_desc_callback cb;struct tegra_dma_desc *dma_desc;unsigned int cb_count;
@@ -1523,8 +1523,7 @@ static int tegra_dma_probe(struct platform_device *pdev) tdc->id = i; tdc->slave_id =TEGRA_APBDMA_SLAVE_ID_INVALID ; -tasklet_init (&tdc->tasklet, tegra_dma_tasklet, - (unsigned long )tdc); +tasklet_setup (&tdc->tasklet, tegra_dma_tasklet);spin_lock_init (&tdc->lock);init_waitqueue_head (&tdc->wq);
Signature · 1 line
2.17.1
PATCH 28/35 dma: timb_dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/timb_dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/timb_dma.c +3 -3
@@ -563,9 +563,9 @@ static int td_terminate_all(struct dma_chan *chan)return 0 ; } -static void td_tasklet (unsigned long data) +static void td_tasklet (struct tasklet_struct *t) { -struct timb_dma *td = (struct timb_dma *)data; +struct timb_dma *td =from_tasklet (td, t, tasklet);u32 isr;u32 ipr;u32 ier;
@@ -658,7 +658,7 @@ static int td_probe(struct platform_device *pdev)iowrite32 (0x0 , td->membase +TIMBDMA_IER );iowrite32 (0xFFFFFFFF , td->membase +TIMBDMA_ISR ); -tasklet_init (&td->tasklet, td_tasklet, (unsigned long )td); +tasklet_setup (&td->tasklet, td_tasklet); err =request_irq (irq, td_irq,IRQF_SHARED ,DRIVER_NAME , td);if (err) {
Signature · 1 line
2.17.1
PATCH 29/35 dma: txx9dmac: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/txx9dmac.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-)
drivers/dma/txx9dmac.c +6 -8
@@ -601,13 +601,13 @@ static void txx9dmac_scan_descriptors(struct txx9dmac_chan *dc) } } -static void txx9dmac_chan_tasklet (unsigned long data) +static void txx9dmac_chan_tasklet (struct tasklet_struct *t) {int irq;u32 csr;struct txx9dmac_chan *dc; - dc = (struct txx9dmac_chan *)data; + dc =from_tasklet (dc, t, tasklet); csr =channel_readl (dc,CSR );dev_vdbg (chan2dev (&dc->chan),"tasklet: status=%x\n" , csr);
@@ -638,13 +638,13 @@ static irqreturn_t txx9dmac_chan_interrupt(int irq, void *dev_id)return IRQ_HANDLED ; } -static void txx9dmac_tasklet (unsigned long data) +static void txx9dmac_tasklet (struct tasklet_struct *t) {int irq;u32 csr;struct txx9dmac_chan *dc; -struct txx9dmac_dev *ddev = (struct txx9dmac_dev *)data; +struct txx9dmac_dev *ddev =from_tasklet (ddev, t, tasklet);u32 mcr;int i;
@@ -1113,8 +1113,7 @@ static int __init txx9dmac_chan_probe(struct platform_device *pdev) irq =platform_get_irq (pdev,0 );if (irq <0 )return irq; -tasklet_init (&dc->tasklet, txx9dmac_chan_tasklet, - (unsigned long )dc); +tasklet_setup (&dc->tasklet, txx9dmac_chan_tasklet); dc->irq = irq; err =devm_request_irq (&pdev->dev, dc->irq, txx9dmac_chan_interrupt,0 ,dev_name (&pdev->dev), dc);
@@ -1200,8 +1199,7 @@ static int __init txx9dmac_probe(struct platform_device *pdev) ddev->irq =platform_get_irq (pdev,0 );if (ddev->irq >=0 ) { -tasklet_init (&ddev->tasklet, txx9dmac_tasklet, - (unsigned long )ddev); +tasklet_setup (&ddev->tasklet, txx9dmac_tasklet); err =devm_request_irq (&pdev->dev, ddev->irq, txx9dmac_interrupt,0 ,dev_name (&pdev->dev), ddev);if (err)
Signature · 1 line
2.17.1
PATCH 30/35 dma: virt-dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/virt-dma.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/dma/virt-dma.c +3 -3
@@ -80,9 +80,9 @@ EXPORT_SYMBOL_GPL(vchan_find_desc);* This tasklet handles the completion of a DMA descriptor by * calling its callback and freeing it. */ -static void vchan_complete (unsigned long arg) +static void vchan_complete (struct tasklet_struct *t) { -struct virt_dma_chan *vc = (struct virt_dma_chan *)arg; +struct virt_dma_chan *vc =from_tasklet (vc, t, task);struct virt_dma_desc *vd, *_vd;struct dmaengine_desc_callback cb;LIST_HEAD (head);
@@ -131,7 +131,7 @@ void vchan_init(struct virt_dma_chan *vc, struct dma_device *dmadev)INIT_LIST_HEAD (&vc->desc_completed);INIT_LIST_HEAD (&vc->desc_terminated); -tasklet_init (&vc->task, vchan_complete, (unsigned long )vc); +tasklet_setup (&vc->task, vchan_complete); vc->chan.device = dmadev;list_add_tail (&vc->chan.device_node, &dmadev->channels);
Signature · 1 line
2.17.1
PATCH 31/35 dma: xgene: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/xgene-dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/xgene-dma.c +3 -4
@@ -975,9 +975,9 @@ static enum dma_status xgene_dma_tx_status(struct dma_chan *dchan,return dma_cookie_status (dchan, cookie, txstate); } -static void xgene_dma_tasklet_cb (unsigned long data) +static void xgene_dma_tasklet_cb (struct tasklet_struct *t) { -struct xgene_dma_chan *chan = (struct xgene_dma_chan *)data; +struct xgene_dma_chan *chan =from_tasklet (chan, t, tasklet);/* Run all cleanup for descriptors which have been completed */ xgene_dma_cleanup_descriptors (chan);
@@ -1539,8 +1539,7 @@ static int xgene_dma_async_register(struct xgene_dma *pdma, int id)INIT_LIST_HEAD (&chan->ld_pending);INIT_LIST_HEAD (&chan->ld_running);INIT_LIST_HEAD (&chan->ld_completed); -tasklet_init (&chan->tasklet, xgene_dma_tasklet_cb, - (unsigned long )chan); +tasklet_setup (&chan->tasklet, xgene_dma_tasklet_cb); chan->pending =0 ; chan->desc_pool =NULL ;
Signature · 1 line
2.17.1
PATCH 32/35 dma: xilinx: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/xilinx/xilinx_dma.c | 7 +++---- drivers/dma/xilinx/zynqmp_dma.c | 6 +++--- 2 files changed, 6 insertions(+), 7 deletions(-)
drivers/dma/xilinx/xilinx_dma.c +3 -4
@@ -1046,9 +1046,9 @@ static void xilinx_dma_chan_desc_cleanup(struct xilinx_dma_chan *chan)* xilinx_dma_do_tasklet - Schedule completion tasklet * @data: Pointer to the Xilinx DMA channel structure */ -static void xilinx_dma_do_tasklet (unsigned long data) +static void xilinx_dma_do_tasklet (struct tasklet_struct *t) { -struct xilinx_dma_chan *chan = (struct xilinx_dma_chan *)data; +struct xilinx_dma_chan *chan =from_tasklet (chan, t, tasklet);xilinx_dma_chan_desc_cleanup (chan); }
@@ -2866,8 +2866,7 @@ static int xilinx_dma_chan_probe(struct xilinx_dma_device *xdev, }/* Initialize the tasklet */ -tasklet_init (&chan->tasklet, xilinx_dma_do_tasklet, - (unsigned long )chan); +tasklet_setup (&chan->tasklet, xilinx_dma_do_tasklet);/* * Initialize the DMA channel and add it to the DMA engine channels
drivers/dma/xilinx/zynqmp_dma.c +3 -3
@@ -744,9 +744,9 @@ static irqreturn_t zynqmp_dma_irq_handler(int irq, void *data)* zynqmp_dma_do_tasklet - Schedule completion tasklet * @data: Pointer to the ZynqMP DMA channel structure */ -static void zynqmp_dma_do_tasklet (unsigned long data) +static void zynqmp_dma_do_tasklet (struct tasklet_struct *t) { -struct zynqmp_dma_chan *chan = (struct zynqmp_dma_chan *)data; +struct zynqmp_dma_chan *chan =from_tasklet (chan, t, tasklet);u32 count;unsigned long irqflags;
@@ -908,7 +908,7 @@ static int zynqmp_dma_chan_probe(struct zynqmp_dma_device *zdev, chan->is_dmacoherent =of_property_read_bool (node,"dma-coherent" ); zdev->chan = chan; -tasklet_init (&chan->tasklet, zynqmp_dma_do_tasklet, (ulong )chan); +tasklet_setup (&chan->tasklet, zynqmp_dma_do_tasklet);spin_lock_init (&chan->lock);INIT_LIST_HEAD (&chan->active_list);INIT_LIST_HEAD (&chan->pending_list);
Signature · 1 line
2.17.1
PATCH 33/35 dma: plx_dma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/plx_dma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/plx_dma.c +3 -4
@@ -241,9 +241,9 @@ static void plx_dma_stop(struct plx_dma_dev *plxdev)rcu_read_unlock (); } -static void plx_dma_desc_task (unsigned long data) +static void plx_dma_desc_task (struct tasklet_struct *t) { -struct plx_dma_dev *plxdev = (void *)data; +struct plx_dma_dev *plxdev =from_tasklet (plxdev, t, desc_task);plx_dma_process_desc (plxdev); }
@@ -513,8 +513,7 @@ static int plx_dma_create(struct pci_dev *pdev) }spin_lock_init (&plxdev->ring_lock); -tasklet_init (&plxdev->desc_task, plx_dma_desc_task, - (unsigned long )plxdev); +tasklet_setup (&plxdev->desc_task, plx_dma_desc_task);RCU_INIT_POINTER (plxdev->pdev, pdev); plxdev->bar =pcim_iomap_table (pdev)[0 ];
Signature · 1 line
2.17.1
PATCH 34/35 dma: sf-pdma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/sf-pdma/sf-pdma.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-)
drivers/dma/sf-pdma/sf-pdma.c +6 -8
@@ -281,9 +281,9 @@ static void sf_pdma_free_desc(struct virt_dma_desc *vdesc) desc->in_use = false; } -static void sf_pdma_donebh_tasklet (unsigned long arg) +static void sf_pdma_donebh_tasklet (struct tasklet_struct *t) { -struct sf_pdma_chan *chan = (struct sf_pdma_chan *)arg; +struct sf_pdma_chan *chan =from_tasklet (chan, t, done_tasklet);struct sf_pdma_desc *desc = chan->desc;unsigned long flags;
@@ -298,9 +298,9 @@ static void sf_pdma_donebh_tasklet(unsigned long arg)dmaengine_desc_get_callback_invoke (desc->async_tx,NULL ); } -static void sf_pdma_errbh_tasklet (unsigned long arg) +static void sf_pdma_errbh_tasklet (struct tasklet_struct *t) { -struct sf_pdma_chan *chan = (struct sf_pdma_chan *)arg; +struct sf_pdma_chan *chan =from_tasklet (chan, t, err_tasklet);struct sf_pdma_desc *desc = chan->desc;unsigned long flags;
@@ -476,10 +476,8 @@ static void sf_pdma_setup_chans(struct sf_pdma *pdma)writel (PDMA_CLEAR_CTRL , chan->regs.ctrl); -tasklet_init (&chan->done_tasklet, - sf_pdma_donebh_tasklet, (unsigned long )chan); -tasklet_init (&chan->err_tasklet, - sf_pdma_errbh_tasklet, (unsigned long )chan); +tasklet_setup (&chan->done_tasklet, sf_pdma_donebh_tasklet); +tasklet_setup (&chan->err_tasklet, sf_pdma_errbh_tasklet); } }
Signature · 1 line
2.17.1
PATCH 35/35 dma: k3-udma: convert tasklets to use new tasklet_setup() API
In reply to Allen PaisIn preparation for unconditionally passing the struct tasklet_struct pointer to all tasklet callbacks, switch to using the new tasklet_setup() and from_tasklet() to pass the tasklet pointer explicitly.
--- drivers/dma/ti/k3-udma.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/dma/ti/k3-udma.c +3 -4
@@ -2914,9 +2914,9 @@ static void udma_desc_pre_callback(struct virt_dma_chan *vc,* This tasklet handles the completion of a DMA descriptor by * calling its callback and freeing it. */ -static void udma_vchan_complete (unsigned long arg) +static void udma_vchan_complete (struct tasklet_struct *t) { -struct virt_dma_chan *vc = (struct virt_dma_chan *)arg; +struct virt_dma_chan *vc =from_tasklet (vc, t, task);struct virt_dma_desc *vd, *_vd;struct dmaengine_desc_callback cb;LIST_HEAD (head);
@@ -3649,8 +3649,7 @@ static int udma_probe(struct platform_device *pdev)vchan_init (&uc->vc, &ud->ddev);/* Use custom vchan completion handling */ -tasklet_init (&uc->vc.task, udma_vchan_complete, - (unsigned long )&uc->vc); +tasklet_setup (&uc->vc.task, udma_vchan_complete);init_completion (&uc->teardown_completed);INIT_DELAYED_WORK (&uc->tx_drain.work, udma_check_tx_completion); }
Signature · 1 line
2.17.1