Commit 1266b7f7 authored by Rex Zhu's avatar Rex Zhu Committed by Alex Deucher

drm/amd/powerplay: fix coding style in hwmgr.c

Signed-off-by: default avatarRex Zhu <Rex.Zhu@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 5bbc5c64
...@@ -582,26 +582,26 @@ int phm_get_sclk_for_voltage_evv(struct pp_hwmgr *hwmgr, ...@@ -582,26 +582,26 @@ int phm_get_sclk_for_voltage_evv(struct pp_hwmgr *hwmgr,
phm_ppt_v1_voltage_lookup_table *lookup_table, phm_ppt_v1_voltage_lookup_table *lookup_table,
uint16_t virtual_voltage_id, int32_t *sclk) uint16_t virtual_voltage_id, int32_t *sclk)
{ {
uint8_t entryId; uint8_t entry_id;
uint8_t voltageId; uint8_t voltage_id;
struct phm_ppt_v1_information *table_info = struct phm_ppt_v1_information *table_info =
(struct phm_ppt_v1_information *)(hwmgr->pptable); (struct phm_ppt_v1_information *)(hwmgr->pptable);
PP_ASSERT_WITH_CODE(lookup_table->count != 0, "Lookup table is empty", return -EINVAL); PP_ASSERT_WITH_CODE(lookup_table->count != 0, "Lookup table is empty", return -EINVAL);
/* search for leakage voltage ID 0xff01 ~ 0xff08 and sckl */ /* search for leakage voltage ID 0xff01 ~ 0xff08 and sckl */
for (entryId = 0; entryId < table_info->vdd_dep_on_sclk->count; entryId++) { for (entry_id = 0; entry_id < table_info->vdd_dep_on_sclk->count; entry_id++) {
voltageId = table_info->vdd_dep_on_sclk->entries[entryId].vddInd; voltage_id = table_info->vdd_dep_on_sclk->entries[entry_id].vddInd;
if (lookup_table->entries[voltageId].us_vdd == virtual_voltage_id) if (lookup_table->entries[voltage_id].us_vdd == virtual_voltage_id)
break; break;
} }
if (entryId >= table_info->vdd_dep_on_sclk->count) { if (entry_id >= table_info->vdd_dep_on_sclk->count) {
pr_debug("Can't find requested voltage id in vdd_dep_on_sclk table\n"); pr_debug("Can't find requested voltage id in vdd_dep_on_sclk table\n");
return -EINVAL; return -EINVAL;
} }
*sclk = table_info->vdd_dep_on_sclk->entries[entryId].clk; *sclk = table_info->vdd_dep_on_sclk->entries[entry_id].clk;
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment