From d2e2c9be78d089a95464ee01d7210c636773cd81 Mon Sep 17 00:00:00 2001 From: Jack Xiao Date: Fri, 1 Mar 2024 16:52:05 +0800 Subject: [PATCH] drm/amdgpu/mes12: add uni_mes fw loading support Add the unified mes firmware loading support. Signed-off-by: Jack Xiao Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/mes_v12_0.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/mes_v12_0.c b/drivers/gpu/drm/amd/amdgpu/mes_v12_0.c index e92478b1f298f..e9c963ac452ac 100644 --- a/drivers/gpu/drm/amd/amdgpu/mes_v12_0.c +++ b/drivers/gpu/drm/amd/amdgpu/mes_v12_0.c @@ -34,8 +34,10 @@ MODULE_FIRMWARE("amdgpu/gc_12_0_0_mes.bin"); MODULE_FIRMWARE("amdgpu/gc_12_0_0_mes1.bin"); +MODULE_FIRMWARE("amdgpu/gc_12_0_0_uni_mes.bin"); MODULE_FIRMWARE("amdgpu/gc_12_0_1_mes.bin"); MODULE_FIRMWARE("amdgpu/gc_12_0_1_mes1.bin"); +MODULE_FIRMWARE("amdgpu/gc_12_0_1_uni_mes.bin"); static int mes_v12_0_hw_fini(void *handle); static int mes_v12_0_kiq_hw_init(struct amdgpu_device *adev); @@ -1331,6 +1333,14 @@ static int mes_v12_0_early_init(void *handle) struct amdgpu_device *adev = (struct amdgpu_device *)handle; int pipe, r; + if (adev->enable_uni_mes) { + r = amdgpu_mes_init_microcode(adev, AMDGPU_MES_SCHED_PIPE); + if (!r) + return 0; + + adev->enable_uni_mes = false; + } + for (pipe = 0; pipe < AMDGPU_MAX_MES_PIPES; pipe++) { if (!adev->enable_mes_kiq && pipe == AMDGPU_MES_KIQ_PIPE) continue; -- 2.49.0