[PATCH] drm/amd/pp: Fix logic error in smu7_check_dpm_table_updated

Rex Zhu Rex.Zhu at amd.com
Wed Apr 11 12:00:06 UTC 2018


Signed-off-by: Rex Zhu <Rex.Zhu at amd.com>
---
 drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
index 68b9e0b..31d271f 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
@@ -4684,7 +4684,7 @@ static void smu7_check_dpm_table_updated(struct pp_hwmgr *hwmgr)
 	for (i=0; i < dep_table->count; i++) {
 		if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
 			data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC;
-			break;
+			return;
 		}
 	}
 	if (i == dep_table->count)
@@ -4695,7 +4695,7 @@ static void smu7_check_dpm_table_updated(struct pp_hwmgr *hwmgr)
 	for (i=0; i < dep_table->count; i++) {
 		if (dep_table->entries[i].vddc != odn_dep_table->entries[i].vddc) {
 			data->need_update_smu7_dpm_table |= DPMTABLE_OD_UPDATE_VDDC;
-			break;
+			return;
 		}
 	}
 	if (i == dep_table->count)
-- 
1.9.1



More information about the amd-gfx mailing list