]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drm/i915/selftests: Do not try to sanitize mock HW
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 27 Sep 2019 21:06:46 +0000 (22:06 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 27 Sep 2019 21:17:30 +0000 (22:17 +0100)
If we are mocking the device, skip trying to sanitize the pm HW state.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Andi Shyti <andi.shyti@intel.com>
Reviewed-by: Andi Shyti <andi.shyti@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20190927210646.29664-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/gt/intel_gt_pm.c

index 42f175d9b98c44f384511900e0102c412a5f4abe..29fa1dabbc2e073d45635aae916685d08456deea 100644 (file)
@@ -137,7 +137,8 @@ void intel_gt_sanitize(struct intel_gt *gt, bool force)
 
 void intel_gt_pm_disable(struct intel_gt *gt)
 {
-       intel_sanitize_gt_powersave(gt->i915);
+       if (!is_mock_gt(gt))
+               intel_sanitize_gt_powersave(gt->i915);
 }
 
 void intel_gt_pm_fini(struct intel_gt *gt)