aboutsummaryrefslogtreecommitdiffstats
path: root/common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch
diff options
context:
space:
mode:
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch')
-rw-r--r--common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch35
1 files changed, 35 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch b/common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch
new file mode 100644
index 00000000..92a3192a
--- /dev/null
+++ b/common/recipes-kernel/linux/linux-yocto-4.14.71/0891-drm-amd-amdgpu-Tidy-up-gfx_v9_0_enable_gfx_cg_power_.patch
@@ -0,0 +1,35 @@
+From 628fe8073e2ed269c10622de7ec68dbe1b2563cf Mon Sep 17 00:00:00 2001
+From: Tom St Denis <tom.stdenis@amd.com>
+Date: Thu, 31 Aug 2017 09:14:41 -0400
+Subject: [PATCH 0891/4131] drm/amd/amdgpu: Tidy up
+ gfx_v9_0_enable_gfx_cg_power_gating()
+
+Make it consistent in style with the other CG/PG enable functions...
+
+Signed-off-by: Tom St Denis <tom.stdenis@amd.com>
+Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
+---
+ drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
+index 8f9c3d8..e7b73e1 100644
+--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
++++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
+@@ -1883,10 +1883,9 @@ static void gfx_v9_0_enable_gfx_cg_power_gating(struct amdgpu_device *adev,
+ uint32_t data, default_data;
+
+ default_data = data = RREG32(SOC15_REG_OFFSET(GC, 0, mmRLC_PG_CNTL));
+- if (enable == true)
+- data |= RLC_PG_CNTL__GFX_POWER_GATING_ENABLE_MASK;
+- else
+- data &= ~RLC_PG_CNTL__GFX_POWER_GATING_ENABLE_MASK;
++ data = REG_SET_FIELD(data, RLC_PG_CNTL,
++ GFX_POWER_GATING_ENABLE,
++ enable ? 1 : 0);
+ if(default_data != data)
+ WREG32(SOC15_REG_OFFSET(GC, 0, mmRLC_PG_CNTL), data);
+ }
+--
+2.7.4
+