From 644f364da22f486ef0ab5f50e71d0b6802302a44 Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso Date: Thu, 18 Feb 2016 14:23:25 +0100 Subject: lib: Assert we are on i915 from intel_get_drm_devid I915_PARAM_CHIPSET_ID is a i915-only thing, so if a subtest ends up calling it when testing another driver, the subtest (or the library) needs to be fixed. Signed-off-by: Tomeu Vizoso Reviewed-by: Daniel Stone Acked-by: Daniel Vetter --- lib/intel_chipset.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib') diff --git a/lib/intel_chipset.c b/lib/intel_chipset.c index 0e5b016c..56746b00 100644 --- a/lib/intel_chipset.c +++ b/lib/intel_chipset.c @@ -38,6 +38,7 @@ #include #include "i915_drm.h" +#include "drmtest.h" #include "intel_chipset.h" #include "igt_core.h" @@ -129,6 +130,7 @@ intel_get_drm_devid(int fd) { const char *override; + igt_assert(is_i915_device(fd)); igt_assert(__drm_device_id); override = getenv("INTEL_DEVID_OVERRIDE"); -- cgit v1.2.3