Skip to contentSkip to conversation

drm/amdgpu: fix gpu idle power consumtion issue for gfx v12

PATCH In review Yang Wang 1 participant 2 messages Mar 5

Subsystems (2)
lore
Share & tools
lore

Yang Wang

author
#0 lore raw

PATCH 1/1 drm/amdgpu: fix gpu idle power consumtion issue for gfx v12

Older versions of the MES firmware may cause abnormal GPU power consumption. When performing inference tasks on the GPU (e.g., with Ollama using ROCm),
the GPU may show abnormal power consumption in idle state and incorrect GPU load information. This issue has been fixed in firmware version 0x8b and newer.

---
 drivers/gpu/drm/amd/amdgpu/mes_v12_0.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/mes_v12_0.c +2 -1
index 5bfa5d1d0b36..6584ade3b3f6 100644
@@ -731,6 +731,7 @@ static int mes_v12_0_set_hw_resources(struct amdgpu_mes *mes, int pipe)
 	int i;
 	struct amdgpu_device *adev = mes->adev;
 	union MESAPI_SET_HW_RESOURCES mes_set_hw_res_pkt;
+	uint32_t mes_rev = mes->sched_version & AMDGPU_MES_VERSION_MASK;
 
 	memset(&mes_set_hw_res_pkt, 0, sizeof(mes_set_hw_res_pkt));
 
@@ -785,7 +786,7 @@ static int mes_v12_0_set_hw_resources(struct amdgpu_mes *mes, int pipe)
 	 * handling support, other queue will not use the oversubscribe timer.
 	 * handling  mode - 0: disabled; 1: basic version; 2: basic+ version
 	 */
-	mes_set_hw_res_pkt.oversubscription_timer = 50;
+	mes_set_hw_res_pkt.oversubscription_timer = mes_rev <= 0x8b ? 0 : 50;
 	mes_set_hw_res_pkt.unmapped_doorbell_handling = 1;
 
 	if (amdgpu_mes_log_enable) {
Signature · 1 line
2.47.3
#1 lore raw

[AMD Official Use Only - AMD Internal Distribution Only]

Please ignore this change.

Best Regards,
Kevin

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Yang Wang
Sent: Thursday, March 5, 2026 9:14 AM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Zhang, Hawking <[email protected]>; Xiao, Jack <[email protected]>
Subject: [PATCH] drm/amdgpu: fix gpu idle power consumtion issue for gfx v12

Older versions of the MES firmware may cause abnormal GPU power consumption.
When performing inference tasks on the GPU (e.g., with Ollama using ROCm), the GPU may show abnormal power consumption in idle state and incorrect GPU load information. This issue has been fixed in firmware version 0x8b and newer.

---
 drivers/gpu/drm/amd/amdgpu/mes_v12_0.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/mes_v12_0.c +2 -1
index 5bfa5d1d0b36..6584ade3b3f6 100644
@@ -731,6 +731,7 @@ static int mes_v12_0_set_hw_resources(struct amdgpu_mes *mes, int pipe)
        int i;
        struct amdgpu_device *adev = mes->adev;
        union MESAPI_SET_HW_RESOURCES mes_set_hw_res_pkt;
+       uint32_t mes_rev = mes->sched_version & AMDGPU_MES_VERSION_MASK;
 
        memset(&mes_set_hw_res_pkt, 0, sizeof(mes_set_hw_res_pkt));
 
@@ -785,7 +786,7 @@ static int mes_v12_0_set_hw_resources(struct amdgpu_mes *mes, int pipe)
         * handling support, other queue will not use the oversubscribe timer.
         * handling  mode - 0: disabled; 1: basic version; 2: basic+ version
         */
-       mes_set_hw_res_pkt.oversubscription_timer = 50;
+       mes_set_hw_res_pkt.oversubscription_timer = mes_rev <= 0x8b ? 0 : 50;
        mes_set_hw_res_pkt.unmapped_doorbell_handling = 1;
 
        if (amdgpu_mes_log_enable) {

--
2.47.3