summaryrefslogtreecommitdiff
path: root/tests/kms_frontbuffer_tracking.c
diff options
context:
space:
mode:
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2018-03-12 17:49:40 +0100
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2018-08-30 11:09:31 +0200
commit8f89a00c8b61613be3da5cd7e756a5276fc4a5a8 (patch)
tree3e00aaccd62b731756ed28d45fcbb561754167f4 /tests/kms_frontbuffer_tracking.c
parent903366f8699d730345e560dcaf854da69150a8d9 (diff)
lib/psr: Add support for toggling edp psr through debugfs, v5.
It's harmful to write to enable_psr at runtime, and the patch that allows us to change i915_edp_psr_debug with the panel running will require us to abandon the module parameter. Hence the userspace change needs to be put in IGT first before we can change it at kernel time. Toggling it to debugfs will mean we can skip a modeset when changing our feature set. Changes since v1: - Rebase with the previous patches dropped. Changes since v2: - Rebase on top of new api in i915_edp_psr_debug. Changes since v3: - Enable IRQ debugging for extra logging. - Force PSR1 mode. (dhnkrn) - Move PSR enable/disable functions to lib/igt_psr. (dhnkrn) Changes since v4: - Redisable irqs right away when debugfs api doesn't work. (dhnkrn) - Use hex everywhere. (dhnkrn) Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> [mlankhorst: Fix -ENODEV explanation in has_psr_debugfs (dhnkrn)] Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
Diffstat (limited to 'tests/kms_frontbuffer_tracking.c')
-rw-r--r--tests/kms_frontbuffer_tracking.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c
index 1dfd7c1c..7ea2f697 100644
--- a/tests/kms_frontbuffer_tracking.c
+++ b/tests/kms_frontbuffer_tracking.c
@@ -941,8 +941,6 @@ static bool drrs_wait_until_rr_switch_to_low(void)
#define fbc_enable() igt_set_module_param_int("enable_fbc", 1)
#define fbc_disable() igt_set_module_param_int("enable_fbc", 0)
-#define psr_enable() igt_set_module_param_int("enable_psr", 1)
-#define psr_disable() igt_set_module_param_int("enable_psr", 0)
#define drrs_enable() drrs_set(1)
#define drrs_disable() drrs_set(0)
@@ -1137,7 +1135,7 @@ static void disable_features(const struct test_mode *t)
return;
fbc_disable();
- psr_disable();
+ psr_disable(drm.debugfs);
drrs_disable();
}
@@ -1719,7 +1717,7 @@ static void enable_features_for_test(const struct test_mode *t)
if (t->feature & FEATURE_FBC)
fbc_enable();
if (t->feature & FEATURE_PSR)
- psr_enable();
+ psr_enable(drm.debugfs);
if (t->feature & FEATURE_DRRS)
drrs_enable();
}