Skip to contentSkip to conversation

drm/amdgpu/powerplay/ci: return an error of copying to smc fails

PATCH In review Alex Deucher 2 participants 2 messages Nov 30, 2020 – Dec 1, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amdgpu/powerplay/ci: return an error of copying to smc fails

Rather than just silently dropping it. Also fixes a set but unused variable warning.

---
 drivers/gpu/drm/amd/pm/powerplay/smumgr/ci_smumgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/powerplay/smumgr/ci_smumgr.c +1 -1
index 329bf4d44bbc..93a1c7248e26 100644
@@ -2193,7 +2193,7 @@ static int ci_thermal_setup_fan_table(struct pp_hwmgr *hwmgr)
 
 	res = ci_copy_bytes_to_smc(hwmgr, ci_data->fan_table_start, (uint8_t *)&fan_table, (uint32_t)sizeof(fan_table), SMC_RAM_END);
 
-	return 0;
+	return res;
 }
 
 static int ci_program_mem_timing_parameters(struct pp_hwmgr *hwmgr)
Signature · 6 lines
2.25.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by on v1 1/1
#1 lore raw

[AMD Official Use Only - Internal Distribution Only]

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Alex Deucher
Sent: Tuesday, December 1, 2020 7:13 AM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>
Subject: [PATCH] drm/amdgpu/powerplay/ci: return an error of copying to smc fails

Rather than just silently dropping it. Also fixes a set but unused variable warning.

---
 drivers/gpu/drm/amd/pm/powerplay/smumgr/ci_smumgr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/pm/powerplay/smumgr/ci_smumgr.c +1 -1
index 329bf4d44bbc..93a1c7248e26 100644
@@ -2193,7 +2193,7 @@ static int ci_thermal_setup_fan_table(struct pp_hwmgr *hwmgr)
 
 res = ci_copy_bytes_to_smc(hwmgr, ci_data->fan_table_start, (uint8_t *)&fan_table, (uint32_t)sizeof(fan_table), SMC_RAM_END);
 
-return 0;
+return res;
 }
 
 static int ci_program_mem_timing_parameters(struct pp_hwmgr *hwmgr)

--
2.25.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfx&amp;data=04%7C01%7Cevan.quan%40amd.com%7Cdc04b379d57c4d96929b08d895858b0d%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637423748100898322%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=4%2FnT%2FoAlE5Yj5T2nyzQ1RgxAW21BZRbzdHnIml7gYaQ%3D&amp;reserved=0
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx