Patch "dmaengine: idxd: fix device cleanup on disable" has been added to the 5.17-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    dmaengine: idxd: fix device cleanup on disable

to the 5.17-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     dmaengine-idxd-fix-device-cleanup-on-disable.patch
and it can be found in the queue-5.17 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit fccedbe7641a479690997d26a5dcddab7404e78a
Author: Dave Jiang <dave.jiang@xxxxxxxxx>
Date:   Tue Apr 5 14:53:39 2022 -0700

    dmaengine: idxd: fix device cleanup on disable
    
    [ Upstream commit 12e45e89556d7a532120f976081e9e7582addd2b ]
    
    There are certain parts of WQ that needs to be cleaned up even after WQ is
    disabled during the device disable. Those are the unchangeable parts for a
    WQ when the device is still enabled. Move the cleanup outside of WQ state
    check. Remove idxd_wq_disable_cleanup() inside idxd_wq_device_reset_cleanup()
    since only the unchangeable parts need to be cleared.
    
    Fixes: 0f225705cf65 ("dmaengine: idxd: fix wq settings post wq disable")
    Reported-by: Tony Zhu <tony.zhu@xxxxxxxxx>
    Tested-by: Tony Zhu <tony.zhu@xxxxxxxxx>
    Signed-off-by: Dave Jiang <dave.jiang@xxxxxxxxx>
    Link: https://lore.kernel.org/r/164919561905.1455025.13542366389944678346.stgit@xxxxxxxxxxxxxxxxxxxxxxxxxx
    Signed-off-by: Vinod Koul <vkoul@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/dma/idxd/device.c b/drivers/dma/idxd/device.c
index 3061fe857d69..5a0535a0f850 100644
--- a/drivers/dma/idxd/device.c
+++ b/drivers/dma/idxd/device.c
@@ -373,7 +373,6 @@ static void idxd_wq_device_reset_cleanup(struct idxd_wq *wq)
 {
 	lockdep_assert_held(&wq->wq_lock);
 
-	idxd_wq_disable_cleanup(wq);
 	wq->size = 0;
 	wq->group = NULL;
 }
@@ -701,9 +700,9 @@ static void idxd_device_wqs_clear_state(struct idxd_device *idxd)
 
 		if (wq->state == IDXD_WQ_ENABLED) {
 			idxd_wq_disable_cleanup(wq);
-			idxd_wq_device_reset_cleanup(wq);
 			wq->state = IDXD_WQ_DISABLED;
 		}
+		idxd_wq_device_reset_cleanup(wq);
 	}
 }
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux