Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e4c84b50 authored by Rex Zhu's avatar Rex Zhu Committed by Greg Kroah-Hartman
Browse files

drm/amd/pp: fix typecast error in powerplay.



commit 8d8258bd upstream.

resulted in unexpected data truncation

Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarRex Zhu <Rex.Zhu@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 78f4bb6e
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -850,9 +850,9 @@ static int init_over_drive_limits(
		const ATOM_Tonga_POWERPLAYTABLE *powerplay_table)
{
	hwmgr->platform_descriptor.overdriveLimit.engineClock =
		le16_to_cpu(powerplay_table->ulMaxODEngineClock);
		le32_to_cpu(powerplay_table->ulMaxODEngineClock);
	hwmgr->platform_descriptor.overdriveLimit.memoryClock =
		le16_to_cpu(powerplay_table->ulMaxODMemoryClock);
		le32_to_cpu(powerplay_table->ulMaxODMemoryClock);

	hwmgr->platform_descriptor.minOverdriveVDDC = 0;
	hwmgr->platform_descriptor.maxOverdriveVDDC = 0;