[2/2] drm/amdgpu/gfx9: bypass clockgating setting

Submitted by Yu, Xiangliang on April 18, 2017, 7:38 a.m.

Details

Message ID 1492501104-26995-1-git-send-email-Xiangliang.Yu@amd.com
State New
Headers show
Series "Series without cover letter" ( rev: 1 ) in AMD X.Org drivers

Not browsing as part of any series.

Commit Message

Yu, Xiangliang April 18, 2017, 7:38 a.m.
For SRIOV doesn't need clockgating, bypass it.

Signed-off-by: Xiangliang Yu <Xiangliang.Yu@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 3 +++
 1 file changed, 3 insertions(+)

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
index f6b2329..ca77e33 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
@@ -2740,6 +2740,9 @@  static int gfx_v9_0_set_clockgating_state(void *handle,
 {
 	struct amdgpu_device *adev = (struct amdgpu_device *)handle;
 
+	if (amdgpu_sriov_vf(adev))
+		return 0;
+
 	switch (adev->asic_type) {
 	case CHIP_VEGA10:
 		gfx_v9_0_update_gfx_clock_gating(adev,

Comments

> -----Original Message-----

> From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf

> Of Xiangliang Yu

> Sent: Tuesday, April 18, 2017 3:38 AM

> To: amd-gfx@lists.freedesktop.org

> Cc: Yu, Xiangliang

> Subject: [PATCH 2/2] drm/amdgpu/gfx9: bypass clockgating setting

> 

> For SRIOV doesn't need clockgating, bypass it.

> 

> Signed-off-by: Xiangliang Yu <Xiangliang.Yu@amd.com>


Reviewed-by: Alex Deucher <alexander.deucher@amd.com>


> ---

>  drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 3 +++

>  1 file changed, 3 insertions(+)

> 

> diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c

> b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c

> index f6b2329..ca77e33 100644

> --- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c

> +++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c

> @@ -2740,6 +2740,9 @@ static int gfx_v9_0_set_clockgating_state(void

> *handle,

>  {

>  	struct amdgpu_device *adev = (struct amdgpu_device *)handle;

> 

> +	if (amdgpu_sriov_vf(adev))

> +		return 0;

> +

>  	switch (adev->asic_type) {

>  	case CHIP_VEGA10:

>  		gfx_v9_0_update_gfx_clock_gating(adev,

> --

> 2.7.4

> 

> _______________________________________________

> amd-gfx mailing list

> amd-gfx@lists.freedesktop.org

> https://lists.freedesktop.org/mailman/listinfo/amd-gfx