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

Commit 12ccea24 authored by Maciej Sosnowski's avatar Maciej Sosnowski Committed by David S. Miller
Browse files

[3/4] I/OAT: fix async_tx.callback checking



async_tx.callback should be checked for the first
not the last descriptor in the chain.

Cc: <stable@kernel.org>
Signed-off-by: default avatarMaciej Sosnowski <maciej.sosnowski@intel.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c2c0b4c5
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -525,7 +525,7 @@ static dma_cookie_t ioat1_tx_submit(struct dma_async_tx_descriptor *tx)
	}

	hw->ctl = IOAT_DMA_DESCRIPTOR_CTL_CP_STS;
	if (new->async_tx.callback) {
	if (first->async_tx.callback) {
		hw->ctl |= IOAT_DMA_DESCRIPTOR_CTL_INT_GN;
		if (first != new) {
			/* move callback into to last desc */
@@ -617,7 +617,7 @@ static dma_cookie_t ioat2_tx_submit(struct dma_async_tx_descriptor *tx)
	}

	hw->ctl |= IOAT_DMA_DESCRIPTOR_CTL_CP_STS;
	if (new->async_tx.callback) {
	if (first->async_tx.callback) {
		hw->ctl |= IOAT_DMA_DESCRIPTOR_CTL_INT_GN;
		if (first != new) {
			/* move callback into to last desc */