diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2019-03-27 20:52:52 +0200 |
---|---|---|
committer | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2019-03-29 22:23:27 +0200 |
commit | e408d569973b610ba4aafdba016c48b25e563468 (patch) | |
tree | e3e1050d63918d053369c7669b62097d501a0451 /tools/intel_gpu_time.c | |
parent | 1ac3264e0370134d06e2cff211c0da4aa5c7d83b (diff) |
Revert "lib/igt_device: Move intel_get_pci_device under igt_device"
One significant usecase for intel_reg/etc. is to be able to examine
the hardware state *before* loading the driver. If the tool forces
the driver to load we've totally lost that capability.
This reverts commit 8ae86621d6fff60b6e20c6b0f9b336785c935b0f.
Cc: Michał Winiarski <michal.winiarski@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Acked-by: Jani Nikula <jani.nikula@intel.com>
Acked-by: Michał Winiarski <michal.winiarski@intel.com>
Diffstat (limited to 'tools/intel_gpu_time.c')
-rw-r--r-- | tools/intel_gpu_time.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/tools/intel_gpu_time.c b/tools/intel_gpu_time.c index 0fc73f92..56d65fe0 100644 --- a/tools/intel_gpu_time.c +++ b/tools/intel_gpu_time.c @@ -34,9 +34,8 @@ #include <sys/resource.h> #include <sys/wait.h> -#include "drmtest.h" -#include "igt_device.h" #include "intel_io.h" +#include "intel_chipset.h" #include "intel_reg.h" #define SAMPLES_PER_SEC 10000 @@ -67,11 +66,8 @@ int main(int argc, char **argv) struct timeval start, end; static struct rusage rusage; int status; - int fd; - fd = drm_open_driver(DRIVER_INTEL); - intel_mmio_use_pci_bar(igt_device_get_pci_device(fd)); - close(fd); + intel_mmio_use_pci_bar(intel_get_pci_device()); if (argc == 1) { fprintf(stderr, "usage: %s cmd [args...]\n", argv[0]); |