Skip to contentSkip to conversation

drm/amd/dc: Trigger set power state task when display configuration changes

PATCH In review Rex Zhu 3 participants 5 messages Sep 14, 2018 – Sep 18, 2018 4 messages not in the archive

Subsystems (3)
lore
Share & tools
lore

Rex Zhu

author
#0 lore raw

PATCH 1/1 drm/amd/dc: Trigger set power state task when display configuration changes

Revert "drm/amd/display: Remove call to amdgpu_pm_compute_clocks"

This reverts commit dcd473770e86517543691bdb227103d6c781cd0a.

when display configuration changes, dc need to update the changes to powerplay, also need to trigger a power state task. amdgpu_pm_compute_clocks is the interface to set power state task either dpm enabled or powerplay enabled

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c +2 -0
index 6d16b4a..0fab64a 100644
@@ -105,6 +105,8 @@ bool dm_pp_apply_display_requirements(
 			adev->powerplay.pp_funcs->display_configuration_change(
 				adev->powerplay.pp_handle,
 				&adev->pm.pm_display_cfg);
+
+		amdgpu_pm_compute_clocks(adev);
 	}
 
 	return true;
Signature · 6 lines
1.9.1

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
#2 lore raw
In reply to a message not in the archive

________________________________
From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org> on behalf of Rex Zhu <[email protected]>
Sent: Friday, September 14, 2018 1:57:07 AM
To: [email protected]
Cc: Zhu, Rex
Subject: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

Revert "drm/amd/display: Remove call to amdgpu_pm_compute_clocks"

This reverts commit dcd473770e86517543691bdb227103d6c781cd0a.

when display configuration changes, dc need to update the changes to powerplay, also need to trigger a power state task. amdgpu_pm_compute_clocks is the interface to set power state task either dpm enabled or powerplay enabled

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c +2 -0
index 6d16b4a..0fab64a 100644
@@ -105,6 +105,8 @@ bool dm_pp_apply_display_requirements(
                         adev->powerplay.pp_funcs->display_configuration_change(
                                 adev->powerplay.pp_handle,
                                 &adev->pm.pm_display_cfg);
+
+               amdgpu_pm_compute_clocks(adev);
         }
 
         return true;

--
1.9.1

_______________________________________________
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

author Acked-by Alex Deucher
#4 lore raw
In reply to a message not in the archive

+Harry and David.

Best Regards
Rex

From: Deucher, Alexander
Sent: Friday, September 14, 2018 9:40 PM
To: Zhu, Rex <[email protected]>; [email protected]
Subject: Re: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

________________________________
From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org<mailto:[email protected]>> on behalf of Rex Zhu <[email protected]<mailto:[email protected]>>
Sent: Friday, September 14, 2018 1:57:07 AM
To: [email protected]<mailto:[email protected]>
Cc: Zhu, Rex
Subject: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

Revert "drm/amd/display: Remove call to amdgpu_pm_compute_clocks"

This reverts commit dcd473770e86517543691bdb227103d6c781cd0a.

when display configuration changes, dc need to update the changes to powerplay, also need to trigger a power state task. amdgpu_pm_compute_clocks is the interface to set power state task either dpm enabled or powerplay enabled

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c +2 -0
index 6d16b4a..0fab64a 100644
@@ -105,6 +105,8 @@ bool dm_pp_apply_display_requirements(
                         adev->powerplay.pp_funcs->display_configuration_change(
                                 adev->powerplay.pp_handle,
                                 &adev->pm.pm_display_cfg);
+
+               amdgpu_pm_compute_clocks(adev);
         }
 
         return true;

--
1.9.1

_______________________________________________
amd-gfx mailing list [email protected]<mailto:[email protected]>
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Acked-by Alex Deucher
#6 lore raw
In reply to a message not in the archive

On Linux, the clocks are already set by the time that function call is reached. amdgpu_pm_compute clocks resets the clocks to their default value.

________________________________
From: Zhu, Rex
Sent: September 17, 2018 4:12:33 AM
To: Deucher, Alexander; Wentland, Harry; Francis, David
Cc: [email protected]
Subject: RE: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

+Harry and David.

Best Regards

Rex

From: Deucher, Alexander
Sent: Friday, September 14, 2018 9:40 PM
To: Zhu, Rex <[email protected]>; [email protected]
Subject: Re: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

________________________________

From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org<mailto:[email protected]>> on behalf of Rex Zhu <[email protected]<mailto:[email protected]>>
Sent: Friday, September 14, 2018 1:57:07 AM
To: [email protected]<mailto:[email protected]>
Cc: Zhu, Rex
Subject: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

Revert "drm/amd/display: Remove call to amdgpu_pm_compute_clocks"

This reverts commit dcd473770e86517543691bdb227103d6c781cd0a.

when display configuration changes, dc need to update the changes to powerplay, also need to trigger a power state task. amdgpu_pm_compute_clocks is the interface to set power state task either dpm enabled or powerplay enabled

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c +2 -0
index 6d16b4a..0fab64a 100644
@@ -105,6 +105,8 @@ bool dm_pp_apply_display_requirements(
                         adev->powerplay.pp_funcs->display_configuration_change(
                                 adev->powerplay.pp_handle,
                                 &adev->pm.pm_display_cfg);
+
+               amdgpu_pm_compute_clocks(adev);
         }
 
         return true;

--
1.9.1

_______________________________________________
amd-gfx mailing list [email protected]<mailto:[email protected]>
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

author Acked-by Alex Deucher
#8 lore raw
In reply to a message not in the archive

Hi David,

Yes, There is an issue you pointed out on Raven. Because the force_dpm_level was added for UMD-P state and the min clocks were hardcode. The display's clock requests were ignored. I will fix this issue.
Thanks.

Best Regards
Rex

From: Francis, David
Sent: Monday, September 17, 2018 9:31 PM
To: Zhu, Rex <[email protected]>; Deucher, Alexander <[email protected]>; Wentland, Harry <[email protected]>
Cc: [email protected]
Subject: Re: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

On Linux, the clocks are already set by the time that function call is reached. amdgpu_pm_compute clocks resets the clocks to their default value.

________________________________
From: Zhu, Rex
Sent: September 17, 2018 4:12:33 AM
To: Deucher, Alexander; Wentland, Harry; Francis, David
Cc: [email protected]<mailto:[email protected]>
Subject: RE: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

+Harry and David.

Best Regards

Rex

From: Deucher, Alexander
Sent: Friday, September 14, 2018 9:40 PM
To: Zhu, Rex <[email protected]<mailto:[email protected]>>; [email protected]<mailto:[email protected]>
Subject: Re: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

________________________________

From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org<mailto:[email protected]>> on behalf of Rex Zhu <[email protected]<mailto:[email protected]>>
Sent: Friday, September 14, 2018 1:57:07 AM
To: [email protected]<mailto:[email protected]>
Cc: Zhu, Rex
Subject: [PATCH] drm/amd/dc: Trigger set power state task when display configuration changes

Revert "drm/amd/display: Remove call to amdgpu_pm_compute_clocks"

This reverts commit dcd473770e86517543691bdb227103d6c781cd0a.

when display configuration changes, dc need to update the changes to powerplay, also need to trigger a power state task. amdgpu_pm_compute_clocks is the interface to set power state task either dpm enabled or powerplay enabled

---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c +2 -0
index 6d16b4a..0fab64a 100644
@@ -105,6 +105,8 @@ bool dm_pp_apply_display_requirements(
                         adev->powerplay.pp_funcs->display_configuration_change(
                                 adev->powerplay.pp_handle,
                                 &adev->pm.pm_display_cfg);
+
+               amdgpu_pm_compute_clocks(adev);
         }
 
         return true;

--
1.9.1

_______________________________________________
amd-gfx mailing list [email protected]<mailto:[email protected]>
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx