drm/amd/powerplay: correct LoadLineResistance value in pptable.
Subsystems (2)
PATCH 1/1 drm/amd/powerplay: correct LoadLineResistance value in pptable.
this value is used by avfs to adjust inversion voltage.
Change-Id Ic6520c184ae938384d9f5e1590ecaf864fa9f95a
Signed-off-by Rex Zhu <[email protected]>
--- drivers/gpu/drm/amd/powerplay/hwmgr/vega10_powertune.c | 4 ++-- drivers/gpu/drm/amd/powerplay/hwmgr/vega10_processpptables.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
drivers/gpu/drm/amd/powerplay/hwmgr/vega10_powertune.c +2 -2
@@ -48,8 +48,8 @@ void vega10_initialize_power_tune_defaults(struct pp_hwmgr *hwmgr) table->Tliquid1Limit =cpu_to_le16 (tdp_table->usTemperatureLimitLiquid1); table->Tliquid2Limit =cpu_to_le16 (tdp_table->usTemperatureLimitLiquid2); table->TplxLimit =cpu_to_le16 (tdp_table->usTemperatureLimitPlx); - table->LoadLineResistance =cpu_to_le16 ( - hwmgr->platform_descriptor.LoadLineSlope); + table->LoadLineResistance = + hwmgr->platform_descriptor.LoadLineSlope *256 ; table->FitLimit =0 ;/* Not used for Vega10 */ table->Liquid1_I2C_address = tdp_table->ucLiquid1_I2C_address;
drivers/gpu/drm/amd/powerplay/hwmgr/vega10_processpptables.c +2 -2
@@ -407,7 +407,7 @@ static int get_tdp_table( tdp_table->ucPlx_I2C_address = power_tune_table->ucPlx_I2C_address; tdp_table->ucPlx_I2C_Line = power_tune_table->ucPlx_I2C_LineSCL; tdp_table->ucPlx_I2C_LineSDA = power_tune_table->ucPlx_I2C_LineSDA; - hwmgr->platform_descriptor.LoadLineSlope = power_tune_table->usLoadLineResistance; + hwmgr->platform_descriptor.LoadLineSlope =le16_to_cpu (power_tune_table->usLoadLineResistance); }else { power_tune_table_v2 = (ATOM_Vega10_PowerTune_Table_V2 *)table; tdp_table->usMaximumPowerDeliveryLimit =le16_to_cpu (power_tune_table_v2->usSocketPowerLimit);
@@ -453,7 +453,7 @@ static int get_tdp_table( tdp_table->ucPlx_I2C_LineSDA = sda; hwmgr->platform_descriptor.LoadLineSlope = - power_tune_table_v2->usLoadLineResistance; +le16_to_cpu (power_tune_table_v2->usLoadLineResistance); } *info_tdp_table = tdp_table;
Signature · 6 lines
1.9.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 1493707768-29337-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org
Alex Deucher
Reviewed-byQuoted 4 lines · Rex Zhu
this value is used by avfs to adjust inversion voltage.
Change-Id Ic6520c184ae938384d9f5e1590ecaf864fa9f95aSigned-off-by Rex Zhu <[email protected]>
Reviewed-by Alex Deucher <[email protected]>
Quoted 45 lines
--- drivers/gpu/drm/amd/powerplay/hwmgr/vega10_powertune.c | 4 ++-- drivers/gpu/drm/amd/powerplay/hwmgr/vega10_processpptables.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)drivers/gpu/drm/amd/powerplay/hwmgr/vega10_powertune.c +2
-2@@ -48,8 +48,8 @@ void vega10_initialize_power_tune_defaults(struct pp_hwmgr *hwmgr) table->Tliquid1Limit =cpu_to_le16 (tdp_table->usTemperatureLimitLiquid1); table->Tliquid2Limit =cpu_to_le16 (tdp_table->usTemperatureLimitLiquid2); table->TplxLimit =cpu_to_le16 (tdp_table->usTemperatureLimitPlx); - table->LoadLineResistance =cpu_to_le16 ( - hwmgr->platform_descriptor.LoadLineSlope); + table->LoadLineResistance = + hwmgr->platform_descriptor.LoadLineSlope *256 ; table->FitLimit =0 ;/* Not used for Vega10 */ table->Liquid1_I2C_address = tdp_table->ucLiquid1_I2C_address;drivers/gpu/drm/amd/powerplay/hwmgr/vega10_processpptables.c +2
-3@@ -407,7 +407,7 @@ static int get_tdp_table( tdp_table->ucPlx_I2C_address = power_tune_table->ucPlx_I2C_address; tdp_table->ucPlx_I2C_Line = power_tune_table->ucPlx_I2C_LineSCL; tdp_table->ucPlx_I2C_LineSDA = power_tune_table->ucPlx_I2C_LineSDA; - hwmgr->platform_descriptor.LoadLineSlope = power_tune_table->usLoadLineResistance; + hwmgr->platform_descriptor.LoadLineSlope =le16_to_cpu (power_tune_table->usLoadLineResistance); }else { power_tune_table_v2 = (ATOM_Vega10_PowerTune_Table_V2 *)table; tdp_table->usMaximumPowerDeliveryLimit =le16_to_cpu (power_tune_table_v2->usSocketPowerLimit);@@ -453,7 +453,7 @@ static int get_tdp_table( tdp_table->ucPlx_I2C_LineSDA = sda; hwmgr->platform_descriptor.LoadLineSlope = - power_tune_table_v2->usLoadLineResistance; +le16_to_cpu (power_tune_table_v2->usLoadLineResistance); } *info_tdp_table = tdp_table; --1.9.1
Quoted 4 lines
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx