Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 11bfedff authored by Vinod Koul's avatar Vinod Koul
Browse files

Merge branch 'topic/err_reporting' into for-linus



Signed-off-by: default avatarVinod Koul <vinod.koul@intel.com>

Conflicts:
	drivers/dma/cppi41.c
parents 0a98f4b8 793ae66c
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -282,6 +282,17 @@ supported.
			that is supposed to push the current
			transaction descriptor to a pending queue, waiting
			for issue_pending to be called.
     - In this structure the function pointer callback_result can be
       initialized in order for the submitter to be notified that a
       transaction has completed. In the earlier code the function pointer
       callback has been used. However it does not provide any status to the
       transaction and will be deprecated. The result structure defined as
       dmaengine_result that is passed in to callback_result has two fields:
       + result: This provides the transfer result defined by
		 dmaengine_tx_result. Either success or some error
		 condition.
       + residue: Provides the residue bytes of the transfer for those that
		  support residue.

   * device_issue_pending
     - Takes the first transaction descriptor in the pending queue,
+2 −9
Original line number Diff line number Diff line
@@ -473,15 +473,11 @@ atc_chain_complete(struct at_dma_chan *atchan, struct at_desc *desc)
	/* for cyclic transfers,
	 * no need to replay callback function while stopping */
	if (!atc_chan_is_cyclic(atchan)) {
		dma_async_tx_callback	callback = txd->callback;
		void			*param = txd->callback_param;

		/*
		 * The API requires that no submissions are done from a
		 * callback, so we don't need to drop the lock here
		 */
		if (callback)
			callback(param);
		dmaengine_desc_get_callback_invoke(txd, NULL);
	}

	dma_run_dependencies(txd);
@@ -598,15 +594,12 @@ static void atc_handle_cyclic(struct at_dma_chan *atchan)
{
	struct at_desc			*first = atc_first_active(atchan);
	struct dma_async_tx_descriptor	*txd = &first->txd;
	dma_async_tx_callback		callback = txd->callback;
	void				*param = txd->callback_param;

	dev_vdbg(chan2dev(&atchan->chan_common),
			"new cyclic period llp 0x%08x\n",
			channel_readl(atchan, DSCR));

	if (callback)
		callback(param);
	dmaengine_desc_get_callback_invoke(txd, NULL);
}

/*--  IRQ & Tasklet  ---------------------------------------------------*/
+4 −4
Original line number Diff line number Diff line
@@ -1572,8 +1572,8 @@ static void at_xdmac_handle_cyclic(struct at_xdmac_chan *atchan)
	desc = list_first_entry(&atchan->xfers_list, struct at_xdmac_desc, xfer_node);
	txd = &desc->tx_dma_desc;

	if (txd->callback && (txd->flags & DMA_PREP_INTERRUPT))
		txd->callback(txd->callback_param);
	if (txd->flags & DMA_PREP_INTERRUPT)
		dmaengine_desc_get_callback_invoke(txd, NULL);
}

static void at_xdmac_tasklet(unsigned long data)
@@ -1616,8 +1616,8 @@ static void at_xdmac_tasklet(unsigned long data)

		if (!at_xdmac_chan_is_cyclic(atchan)) {
			dma_cookie_complete(txd);
			if (txd->callback && (txd->flags & DMA_PREP_INTERRUPT))
				txd->callback(txd->callback_param);
			if (txd->flags & DMA_PREP_INTERRUPT)
				dmaengine_desc_get_callback_invoke(txd, NULL);
		}

		dma_run_dependencies(txd);
+3 −6
Original line number Diff line number Diff line
@@ -1875,8 +1875,7 @@ static void dma_tasklet(unsigned long data)
	struct coh901318_chan *cohc = (struct coh901318_chan *) data;
	struct coh901318_desc *cohd_fin;
	unsigned long flags;
	dma_async_tx_callback callback;
	void *callback_param;
	struct dmaengine_desc_callback cb;

	dev_vdbg(COHC_2_DEV(cohc), "[%s] chan_id %d"
		 " nbr_active_done %ld\n", __func__,
@@ -1891,8 +1890,7 @@ static void dma_tasklet(unsigned long data)
		goto err;

	/* locate callback to client */
	callback = cohd_fin->desc.callback;
	callback_param = cohd_fin->desc.callback_param;
	dmaengine_desc_get_callback(&cohd_fin->desc, &cb);

	/* sign this job as completed on the channel */
	dma_cookie_complete(&cohd_fin->desc);
@@ -1907,8 +1905,7 @@ static void dma_tasklet(unsigned long data)
	spin_unlock_irqrestore(&cohc->lock, flags);

	/* Call the callback when we're done */
	if (callback)
		callback(callback_param);
	dmaengine_desc_callback_invoke(&cb, NULL);

	spin_lock_irqsave(&cohc->lock, flags);

+1 −1
Original line number Diff line number Diff line
@@ -336,7 +336,7 @@ static irqreturn_t cppi41_irq(int irq, void *data)

			c->residue = pd_trans_len(c->desc->pd6) - len;
			dma_cookie_complete(&c->txd);
			c->txd.callback(c->txd.callback_param);
			dmaengine_desc_get_callback_invoke(&c->txd, NULL);

			/* Paired with cppi41_dma_issue_pending */
			pm_runtime_mark_last_busy(cdd->ddev.dev);
Loading