[Intel-gfx] [PATCH i-g-t 4/4] tools/intel_display_poller: Allow the tool to be used without i915 loaded
ville.syrjala at linux.intel.com
ville.syrjala at linux.intel.com
Thu Dec 15 15:25:00 UTC 2016
From: Ville Syrjälä <ville.syrjala at linux.intel.com>
We don't need the drm fd to find out the PCI device ID. So let's drop
the drm stuff, which allows the tool to work without i915 loaded.
Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
tools/intel_display_poller.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/tools/intel_display_poller.c b/tools/intel_display_poller.c
index eab17c52428e..2129c613652d 100644
--- a/tools/intel_display_poller.c
+++ b/tools/intel_display_poller.c
@@ -961,7 +961,7 @@ static void __attribute__((noreturn)) usage(const char *name)
int main(int argc, char *argv[])
{
- int fd, i;
+ int i;
int pipe = 0, bit = 0, target_scanline = 0, target_fuzz = 1;
bool test_pixelcount = false;
uint32_t devid;
@@ -1045,9 +1045,7 @@ int main(int argc, char *argv[])
}
}
- fd = drm_open_driver(DRIVER_INTEL);
- devid = intel_get_drm_devid(fd);
- close(fd);
+ devid = intel_get_pci_device()->device_id;
/*
* check if the requires registers are
--
2.10.2
More information about the Intel-gfx
mailing list