From: Mukul Joshi <mukul.joshi@xxxxxxx> The recent overhauling of SDMA queue management introduced a bug where XGMI SDMA user-mode queue allocation would mark bits in the SDMA queue bitmap as set, representing a queue from non-XGMI SDMA engines was allocated. This patch addresses this issue and fixes the xGMI SDMA queue allocation. Fixes: df7f2df1a466 ("drm/amdkfd: Update SDMA queue management for GFX9.4.3") Signed-off-by: Mukul Joshi <mukul.joshi@xxxxxxx> Reviewed-by: Amber Lin <Amber.Lin@xxxxxxx> Signed-off-by: Alex Deucher <alexander.deucher@xxxxxxx> --- drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c index 527a2e0eef81..ab91a0e211c8 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c @@ -1416,7 +1416,7 @@ static int allocate_sdma_queue(struct device_queue_manager *dqm, } else { bit = find_first_bit(dqm->xgmi_sdma_bitmap, get_num_xgmi_sdma_queues(dqm)); - clear_bit(bit, dqm->sdma_bitmap); + clear_bit(bit, dqm->xgmi_sdma_bitmap); q->sdma_id = bit; } /* sdma_engine_id is sdma id including -- 2.39.2