From: Vinod Koul Date: Wed, 21 Jul 2021 04:23:59 +0000 (+0530) Subject: Merge branch 'fixes' into next X-Git-Tag: v5.15~318^2~76 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=88c5d0a2b9b043d0e000a4f64a28313e57d96a9c;p=platform%2Fkernel%2Flinux-starfive.git Merge branch 'fixes' into next Signed-off-by: Vinod Koul --- 88c5d0a2b9b043d0e000a4f64a28313e57d96a9c diff --cc drivers/dma/idxd/submit.c index 425eeea9577b,36c9c1a89b7e..6ef704dd4d0b --- a/drivers/dma/idxd/submit.c +++ b/drivers/dma/idxd/submit.c @@@ -99,6 -162,16 +154,16 @@@ int idxd_submit_desc(struct idxd_wq *wq * even on UP because the recipient is a device. */ wmb(); + + /* + * Pending the descriptor to the lockless list for the irq_entry + * that we designated the descriptor to. + */ + if (desc->hw->flags & IDXD_OP_FLAG_RCI) { - ie = &idxd->irq_entries[desc->vector]; ++ ie = &idxd->irq_entries[wq->id + 1]; + llist_add(&desc->llnode, &ie->pending_llist); + } + if (wq_dedicated(wq)) { iosubmit_cmds512(portal, desc->hw, 1); } else { @@@ -110,7 -183,8 +175,9 @@@ */ rc = enqcmds(portal, desc->hw); if (rc < 0) { + percpu_ref_put(&wq->wq_active); + if (ie) + llist_abort_desc(wq, ie, desc); return rc; } }