]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
drm/amdgpu: use the ASP command for partition switch
authorShiwu Zhang <shiwu.zhang@amd.com>
Tue, 6 Jan 2026 08:50:01 +0000 (16:50 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 24 Apr 2026 14:58:33 +0000 (10:58 -0400)
Pass the compute partition mode to ASP.

v2: Squash fixes (Alex)

Reviewed-by: Likun Gao <Likun.Gao@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Shiwu Zhang <shiwu.zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/imu_v12_1.c

index 8e33ffcdfa4ccb6a9bb86ef9653493eadc4a0fa5..fe20cf2b9454522a94fc6e4cd8c5c243fa2ed29d 100644 (file)
@@ -140,16 +140,12 @@ static int imu_v12_1_switch_compute_partition(struct amdgpu_device *adev,
        int ret;
 
        if (adev->psp.funcs) {
-               /*TODO: revisit asp interface once it's avaialble */
-               ret = psp_spatial_partition(&adev->psp,
-                                           NUM_XCC(adev->gfx.xcc_mask) /
-                                                   num_xccs_per_xcp);
+               ret = psp_spatial_partition(&adev->psp, compute_partition_mode);
                if (ret)
                        return ret;
        }
 
        adev->gfx.num_xcc_per_xcp = num_xccs_per_xcp;
-
        return 0;
 }