summaryrefslogtreecommitdiff
path: root/tests/i915/i915_pm_rpm.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2020-01-31 10:57:06 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2020-01-31 16:00:34 +0000
commitd524f385a17a73e3cfeeb2ed5a0610f0f0e3a61b (patch)
treef0b97d32ee4f9579561dff501826711370b2dd89 /tests/i915/i915_pm_rpm.c
parent93aefe6baa3fabf8c0cabe83e185f7b8f8d8753d (diff)
lib: Find the associated runtime-pm sysfs for the device
Remove the hardcoded path to the igfx (00:00:02.00) and instead pass in the fd of the DRM device we wish to control, and look up the associated device/power/ under sysfs. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Imre Deak <imre.deak@intel.com> Reviewed-by: Imre Deak <imre.deak@intel.com>
Diffstat (limited to 'tests/i915/i915_pm_rpm.c')
-rw-r--r--tests/i915/i915_pm_rpm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/i915/i915_pm_rpm.c b/tests/i915/i915_pm_rpm.c
index f5f813c3..3d734324 100644
--- a/tests/i915/i915_pm_rpm.c
+++ b/tests/i915/i915_pm_rpm.c
@@ -768,7 +768,7 @@ static bool setup_environment(void)
igt_pm_enable_sata_link_power_management();
- has_runtime_pm = igt_setup_runtime_pm();
+ has_runtime_pm = igt_setup_runtime_pm(drm_fd);
setup_pc8();
igt_info("Runtime PM support: %d\n", has_runtime_pm);