]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/amdgpu: remove the duplicated mes queue active state setting
authorPrike Liang <Prike.Liang@amd.com>
Fri, 28 Mar 2025 10:33:09 +0000 (18:33 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 11 Apr 2025 20:54:39 +0000 (16:54 -0400)
The MES queue deactivation and active status are already set in
mes_userq_unmap|map(), so the caller needn't set the queue_active
bit again.

Signed-off-by: Prike Liang <Prike.Liang@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/mes_userqueue.c

index b469b800119ff95043a4ba1f0b9e8d68f3918ddf..b9705cbec74d22ad8d4b046a19c9f3fc663f04ac 100644 (file)
@@ -358,10 +358,8 @@ mes_userq_mqd_destroy(struct amdgpu_userq_mgr *uq_mgr,
 static int mes_userq_suspend(struct amdgpu_userq_mgr *uq_mgr,
                                   struct amdgpu_usermode_queue *queue)
 {
-       if (queue->queue_active) {
+       if (queue->queue_active)
                mes_userq_unmap(uq_mgr, queue);
-               queue->queue_active = false;
-       }
 
        return 0;
 }
@@ -379,8 +377,6 @@ static int mes_userq_resume(struct amdgpu_userq_mgr *uq_mgr,
                DRM_ERROR("Failed to resume queue\n");
                return ret;
        }
-
-       queue->queue_active = true;
        return 0;
 }