[PATCH 68/76] drm/amd/dal: debug options

Harry Wentland harry.wentland at amd.com
Mon Nov 21 23:01:28 UTC 2016


From: Tony Cheng <tony.cheng at amd.com>

- disable_clock_gate
- disable_power_gate

Signed-off-by: Tony Cheng <tony.cheng at amd.com>
Acked-by: Harry Wentland <harry.wentland at amd.com>
---
 drivers/gpu/drm/amd/dal/dc/dc.h                                | 8 +++++---
 drivers/gpu/drm/amd/dal/dc/gpu/dce110/dc_clock_gating_dce110.c | 5 +++++
 2 files changed, 10 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/dal/dc/dc.h b/drivers/gpu/drm/amd/dal/dc/dc.h
index 4c969eb26e85..6bb3aeb53261 100644
--- a/drivers/gpu/drm/amd/dal/dc/dc.h
+++ b/drivers/gpu/drm/amd/dal/dc/dc.h
@@ -137,13 +137,15 @@ struct dc_config {
 
 struct dc_debug {
 	bool surface_visual_confirm;
-	bool disable_stutter;
-	bool disable_dcc;
-	bool disable_dfs_bypass;
 	bool max_disp_clk;
 	bool target_trace;
 	bool surface_trace;
 	bool validation_trace;
+	bool disable_stutter;
+	bool disable_dcc;
+	bool disable_dfs_bypass;
+	bool disable_power_gate;
+	bool disable_clock_gate;
 };
 
 struct dc {
diff --git a/drivers/gpu/drm/amd/dal/dc/gpu/dce110/dc_clock_gating_dce110.c b/drivers/gpu/drm/amd/dal/dc/gpu/dce110/dc_clock_gating_dce110.c
index 7671e49ffa49..19543db48f99 100644
--- a/drivers/gpu/drm/amd/dal/dc/gpu/dce110/dc_clock_gating_dce110.c
+++ b/drivers/gpu/drm/amd/dal/dc/gpu/dce110/dc_clock_gating_dce110.c
@@ -102,4 +102,9 @@ void dal_dc_clock_gating_dce110_power_up(
 		force_hw_base_light_sleep(ctx);
 		underlay_clock_enable(ctx);
 	}
+
+#if 0
+    if (ctx->dc->debug.disable_clock_gate)
+    	return;   /* clock gating not implemented so nothing to disable */
+#endif
 }
-- 
2.10.1



More information about the amd-gfx mailing list