Enable clock gating for Navi12
Subsystems (2)
cover Enable clock gating for Navi12
Alex has helped to reviewed these patches in AMD internally. Re-send them to public mail list.
Xiaojie Yuan (10):
drm/amdgpu: enable gfx clock gatings for navi12 drm/amdgpu: enable hdp clock gating for navi12 drm/amdgpu/sdma5: set sdma clock gating for navi12 drm/amdgpu: enable sdma clock gating for navi12 drm/amdgpu/mmhub2: set clock gating for navi12 drm/amdgpu: enable mmhub clock gating for navi12 drm/amdgpu: enable ih clock gating for navi12 drm/amdgpu/athub2: set clock gating for navi12 drm/amdgpu: enable athub clock gating for navi12 drm/amdgpu: enable vcn clock gating for navi12
drivers/gpu/drm/amd/amdgpu/athub_v2_0.c | 1 + drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c | 1 + drivers/gpu/drm/amd/amdgpu/nv.c | 16 +++++++++++++++- drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c | 1 + 4 files changed, 18 insertions(+), 1 deletion(-)
Signature · 6 lines
2.20.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): [email protected]
PATCH 1/10 drm/amdgpu: enable gfx clock gatings for navi12
enables following gfx clock gating features:
- medium grained clock gating
- medium grained light sleep
- coarse grained clock gating
- cp memory light sleep
- rlc memory light sleep
CGLS (Coarse Grained Light Sleep) will break s3, so don't enable it.
--- drivers/gpu/drm/amd/amdgpu/nv.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +5 -1
@@ -561,7 +561,11 @@ static int nv_common_early_init(void *handle) adev->external_rev_id = adev->rev_id +0x1 ;break ;case CHIP_NAVI12 : - adev->cg_flags =0 ; + adev->cg_flags =AMD_CG_SUPPORT_GFX_MGCG | +AMD_CG_SUPPORT_GFX_MGLS | +AMD_CG_SUPPORT_GFX_CGCG | +AMD_CG_SUPPORT_GFX_CP_LS | +AMD_CG_SUPPORT_GFX_RLC_LS ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 2/10 drm/amdgpu: enable hdp clock gating for navi12
In reply to a message not in the archiveenables hdp medium grained clock gating and memory light sleep
--- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +3 -1
@@ -565,7 +565,9 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_GFX_MGLS |AMD_CG_SUPPORT_GFX_CGCG |AMD_CG_SUPPORT_GFX_CP_LS | -AMD_CG_SUPPORT_GFX_RLC_LS ; +AMD_CG_SUPPORT_GFX_RLC_LS | +AMD_CG_SUPPORT_HDP_MGCG | +AMD_CG_SUPPORT_HDP_LS ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 3/10 drm/amdgpu/sdma5: set sdma clock gating for navi12
In reply to a message not in the archiveadd navi12 define
--- drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/sdma_v5_0.c +1 -0
@@ -1491,6 +1491,7 @@ static int sdma_v5_0_set_clockgating_state(void *handle,switch (adev->asic_type) {case CHIP_NAVI10 : +case CHIP_NAVI12 :sdma_v5_0_update_medium_grain_clock_gating (adev, state ==AMD_CG_STATE_GATE ? true : false); sdma_v5_0_update_medium_grain_light_sleep(adev,
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 4/10 drm/amdgpu: enable sdma clock gating for navi12
In reply to a message not in the archiveenables sdma medium grained clock gating and memory light sleep
--- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +3 -1
@@ -567,7 +567,9 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_GFX_CP_LS |AMD_CG_SUPPORT_GFX_RLC_LS |AMD_CG_SUPPORT_HDP_MGCG | -AMD_CG_SUPPORT_HDP_LS ; +AMD_CG_SUPPORT_HDP_LS | +AMD_CG_SUPPORT_SDMA_MGCG | +AMD_CG_SUPPORT_SDMA_LS ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 5/10 drm/amdgpu/mmhub2: set clock gating for navi12
In reply to a message not in the archiveadd navi12 define
--- drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c +1 -0
@@ -421,6 +421,7 @@ int mmhub_v2_0_set_clockgating(struct amdgpu_device *adev,switch (adev->asic_type) {case CHIP_NAVI10 : +case CHIP_NAVI12 :mmhub_v2_0_update_medium_grain_clock_gating (adev, state ==AMD_CG_STATE_GATE ? true : false); mmhub_v2_0_update_medium_grain_light_sleep(adev,
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 6/10 drm/amdgpu: enable mmhub clock gating for navi12
In reply to a message not in the archiveenables mmhub medium grained clock gating and memory light sleep
--- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +3 -1
@@ -569,7 +569,9 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_HDP_MGCG |AMD_CG_SUPPORT_HDP_LS |AMD_CG_SUPPORT_SDMA_MGCG | -AMD_CG_SUPPORT_SDMA_LS ; +AMD_CG_SUPPORT_SDMA_LS | +AMD_CG_SUPPORT_MC_MGCG | +AMD_CG_SUPPORT_MC_LS ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 7/10 drm/amdgpu: enable ih clock gating for navi12
In reply to a message not in the archiveenables ih clock gating
--- drivers/gpu/drm/amd/amdgpu/nv.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/nv.c +1 -0
@@ -566,6 +566,7 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_GFX_CGCG |AMD_CG_SUPPORT_GFX_CP_LS |AMD_CG_SUPPORT_GFX_RLC_LS | +AMD_CG_SUPPORT_IH_CG |AMD_CG_SUPPORT_HDP_MGCG |AMD_CG_SUPPORT_HDP_LS | AMD_CG_SUPPORT_SDMA_MGCG |
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 8/10 drm/amdgpu/athub2: set clock gating for navi12
In reply to a message not in the archiveadd navi12 define
--- drivers/gpu/drm/amd/amdgpu/athub_v2_0.c | 1 + 1 file changed, 1 insertion(+)
drivers/gpu/drm/amd/amdgpu/athub_v2_0.c +1 -0
@@ -74,6 +74,7 @@ int athub_v2_0_set_clockgating(struct amdgpu_device *adev,switch (adev->asic_type) {case CHIP_NAVI10 : +case CHIP_NAVI12 :athub_v2_0_update_medium_grain_clock_gating (adev, state ==AMD_CG_STATE_GATE ? true : false); athub_v2_0_update_medium_grain_light_sleep(adev,
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 9/10 drm/amdgpu: enable athub clock gating for navi12
In reply to a message not in the archiveenables athub medium grained clock gating and memory light sleep
--- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +3 -1
@@ -572,7 +572,9 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_SDMA_MGCG |AMD_CG_SUPPORT_SDMA_LS |AMD_CG_SUPPORT_MC_MGCG | -AMD_CG_SUPPORT_MC_LS ; +AMD_CG_SUPPORT_MC_LS | +AMD_CG_SUPPORT_ATHUB_MGCG | +AMD_CG_SUPPORT_ATHUB_LS ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 10/10 drm/amdgpu: enable vcn clock gating for navi12
In reply to a message not in the archiveenables vcn medium grained clock gating
--- drivers/gpu/drm/amd/amdgpu/nv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/nv.c +2 -1
@@ -574,7 +574,8 @@ static int nv_common_early_init(void *handle)AMD_CG_SUPPORT_MC_MGCG |AMD_CG_SUPPORT_MC_LS |AMD_CG_SUPPORT_ATHUB_MGCG | -AMD_CG_SUPPORT_ATHUB_LS ; +AMD_CG_SUPPORT_ATHUB_LS | +AMD_CG_SUPPORT_VCN_MGCG ; adev->pg_flags =AMD_PG_SUPPORT_VCN_DPG ; adev->external_rev_id = adev->rev_id +0xa ;break ;
Signature · 6 lines
2.20.1 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx