summaryrefslogtreecommitdiff
path: root/tools
AgeCommit message (Collapse)AuthorFilesLines
2017-11-06tools/aubdump: Avoid ISO C90 warningThierry Reding1-1/+2
GCC will warn about ISO C90 forbidding to mix declarations and code. Declare the variable at the beginning of the function to suppress the warning. Signed-off-by: Thierry Reding <treding@nvidia.com>
2017-10-24meson: intel_dp_compliance depends on libudevJani Nikula1-4/+9
Only build intel_dp_compliance when libudev is available, also include libudev in the list of dependencies. Fixes error when libudev isn't there: ../tools/intel_dp_compliance_hotplug.c:33:21: fatal error: libudev.h: No such file or directory #include <libudev.h> Signed-off-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
2017-10-20tools/intel_vbt_decode: abstract child devices printing moreJani Nikula1-39/+31
Unify the common code for current and legacy blocks. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: dump more child device data for version < 152Jani Nikula1-3/+0
There's no evidence that this is the limit. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: unify legacy child device block dumpingJani Nikula2-43/+24
It's the same stuff as in the new child devices. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: unify child device printing across versionsJani Nikula1-57/+71
Make it easier to compare dumping against the struct definition. v2: Fix version comparison for flags, aux channel and dongle detect, and fix some typos while at it (Ville) Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: abstract DSI bridge type dumpJani Nikula1-15/+16
Cleaner than having it inline. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: use %.*s instead of duplicating a stringJani Nikula1-5/+1
child->device_id may not be terminated, but we can use %.*s format specifier to define the max length to print. No need to make a copy. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: update dvo port name dumpingJani Nikula2-34/+25
Add names for new ports, throw out unused macros. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-20tools/intel_vbt_decode: make a copy of child devices before dumpingJani Nikula1-2/+18
Take child device size into account, avoid reading past the actual child device. Acked-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-10-10intel_aubdump: Default to 48-bit AUBs when the gen is unknownJordan Justen1-10/+16
v2: * Use 48-bit rather than 64-bit (Ken) * Use 'addr_bits' rather than 'use_64bit' Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2017-10-04Fix compilation on some distrosAusmus, James1-0/+1
Some distros (such as Gentoo) are removing the include of sys/sysmacros.h from sys/types.h. Explicitly include sysmacros.h in files where we use the minor() and major() functions. Signed-off-by: James Ausmus <james.ausmus@intel.com> Reviewed-by: Petri Latvala <petri.latvala@intel.com>
2017-10-02meson: Distribute meson build system filesPetri Latvala2-0/+7
Signed-off-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-09-21intel_aubdump: Support I915_EXEC_BATCH_FIRST.Kenneth Graunke1-1/+7
The batch is now on the other end of the list. Fixes issues where modern Mesa and modern kernels together start putting the batch at the front of the list, and intel_aubdump looks for it at the end of the list, causing it to interpret some other buffer as the batch. Then AubLoad or aubinator see bogus data like 1.0 float as a GPU command and get grumpy.
2017-09-15meson: Process intel_aubdump.in into intel_aubdumpJordan Justen1-0/+7
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15intel_aubdump.in: Set executable permissions (for meson build)Jordan Justen1-0/+0
Meson detects if an input file is executable, and copies that to the output file. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Install intel_gpu_abrtVille Syrjälä1-0/+4
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Drop the 'lib' prefix from intel_aubdump.soVille Syrjälä1-1/+4
Autotools didn't add the 'lib' prefix to the intel_aubdump.so filename. Coerce meson to match that. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Build and install intel_dp_complianceVille Syrjälä1-0/+5
v2: Fix spaces vs. tabs (Jordan) Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Build and install intel_l3_parityVille Syrjälä1-0/+5
v2: Fix spaces vs. tabs (Jordan) Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Install intel_reg register definitionsVille Syrjälä1-0/+5
FIXME: install_subdir exclude_files knob seems to require meson 0.42+. Is that acceptable? v2: Fix spaces vs. tabs (Jordan) Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Build and install intel_regVille Syrjälä1-0/+10
v2: Fix spaces vs. tabs (Jordan) Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15tools/intel_reg: s/PKGDATADIR/IGT_DATADIR/Ville Syrjälä2-2/+2
We use IGT_DATADIR to refer to $pkgdatadir elsewhere, so let's have intel_reg follow suit. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-15meson: Install toolsVille Syrjälä1-1/+2
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-08meson: basic build system supportDaniel Vetter2-0/+74
Why? Because it's fast. Like really, really fast. Some data (from a snb laptop, so rather lower-powered): - Incremental build after $ touch lib/igt_core.c with meson: 0.6s It notices that the symbol list of the libigt.so hasn't changed and doesn't bother re-linking the almost 300 binaries we have. make -j 6 for the same scenario takes 44s. - Incremental build with nothing changed: make: 0.7s, meson: 0.2s This means stuff like --disable-git-hash is entirely pointless with meson, it's faster than a make ever can be (with 0.6s). - Reconfigure stage: ninja reconfigure 0.8s vs. ./configure 8.6s) - Running tests, after a full build: ninja test 6s vs. make check 24s - Full build (i.e. including ./autogen.sh respectively meson build), including tests, from a pristine git checkout. automake 2m49s vs. meson 44s. Cc: Ville Syrjälä <ville.syrjala@linux.intel.com> Cc: Eric Anholt <eric@anholt.net> Cc: Daniel Stone <daniel@fooishbar.org> Acked-by: Jani Nikula <jani.nikula@intel.com> Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Stone <daniels@collabora.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
2017-09-08build: remove _GNU_SOURCE from source filesDaniel Vetter9-12/+0
We are, the build system takes care of that. Reviewed-by: Eric Anholt <eric@anholt.net> Acked-by: Jani Nikula <jani.nikula@intel.com> Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Stone <daniels@collabora.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-09-08build: Nuke #ifdef HAVE_CONFIG_H cargo-cultDaniel Vetter4-8/+0
We have it. Daniel Stone said the #ifdef HAVE_CONFIG_H comes from the X11 transition to the modular build, where in the imake -> modular build transition config.h wasn't universally available. Now we just make this a requirement (so yeah Android better generate one too). v2: Improve commit message a bit. Reviewed-by: Eric Anholt <eric@anholt.net> Acked-by: Jani Nikula <jani.nikula@intel.com> Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Stone <daniels@collabora.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-09-08build: Define _GNU_SOURCE in Makefile.amDaniel Vetter1-1/+1
In meson I want to just set this everywhere (no reason not to), and doing so will allow us to clean up a few things. But that means autofoo needs to follow suit. v2: Rebase. Reviewed-by: Eric Anholt <eric@anholt.net> Acked-by: Jani Nikula <jani.nikula@intel.com> Acked-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Petri Latvala <petri.latvala@intel.com> Acked-by: Daniel Stone <daniels@collabora.com> Acked-by: Radoslaw Szwichtenberg <radoslaw.szwichtenberg@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
2017-09-08Fix compiler warnings about printf() argumentsVille Syrjälä1-1/+1
gem_spin_batch.c:51:13: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘long unsigned int’ [-Wformat=] intel_opregion_decode.c:313:9: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘uint64_t {aka const long long unsigned int}’ [-Wformat=] Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2017-09-05intel_display_poller: Fix truncation of a test name.Eric Anholt1-1/+1
Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-09-05intel_watermark: Fix a warning about "const char" return being silly.Eric Anholt1-1/+1
Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2017-08-30tools: Add intel_vbt_defs.h to Makefile.sourcesArkadiusz Hiler1-0/+1
So is will be picked up for the distributable tarball. Fixes: 09f35ea4dc06 ("tools/intel_vbt_decode: start migrating to kernel intel_vbt_defs.h") Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Acked-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate backlight dumping to kernel structJani Nikula2-28/+8
Drop obsolete field dumping. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate child device type bits decoding to kernel defsJani Nikula3-40/+41
This lets us use the verbatim copy of the kernel intel_vbt_defs.h file after kernel commit 058727ee8d9a ("drm/i915/bios: amend edp block based on intel_vbt_decode"). Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate edp dumping to kernel structJani Nikula3-36/+39
No functional changes. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate psr dumping to kernel structJani Nikula3-27/+32
No functional changes. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate child device dumping to kernel structJani Nikula3-81/+118
Retain the legacy definition for the obsolete child device block, at least for now. No functional changes. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: migrate timing dumping to kernel structJani Nikula3-31/+37
Adapt the dumping according to the changes, and do what the kernel does. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: start migrating to kernel intel_vbt_defs.hJani Nikula3-311/+715
Copy over most of intel_vbt_defs.h, and use everything that matches with minor changes from there. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: clean up struct lvds_dvo_timingJani Nikula2-22/+3
For reasons unknown, we have two copies of the struct. Deduplicate. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_vbt_decode: remove unused definitions from intel_bios.hJani Nikula1-268/+0
This is prep work for refactoring VBT definitions. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-29tools/intel_lid: use local register definitionJani Nikula1-2/+3
This makes the future intel_vbt_decode refactoring easier. Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2017-08-24aubdump: Log some information about the execbuf callsJason Ekstrand1-1/+10
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
2017-08-24aubdump: Use write_reloc for filling out the ringbufferJason Ekstrand1-34/+32
Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-24aubdump: Reject execbuffer2 calls with bad BOsJason Ekstrand1-0/+8
This is required for the supports_48b_addresses check in the Vulkan driver to work without messing up the resulting aub. Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-16tools/intel_vbt_decode: Fix decoding of child device structureVille Syrjälä1-1/+1
Fix decoding of the start of the child device structure. I had accidentally duplicated the "device class/type" member and forgot to include the add-in offset later. Fortunately both were two byte fields so they effectively cancelled each other out and thus the remainder of the child device structure was being decoded correctly. But of course anything sitting between these two fields was being decoded incorrectly. Fixes: 86a546f6f798 ("tools/intel_bios_reader: Dump out more information from the child device structure") Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2017-08-08intel_gpu_top: Use drm_open_driver, don't need drm masterPetri Latvala1-1/+1
Signed-off-by: Petri Latvala <petri.latvala@intel.com> Reviewed-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
2017-07-11igt: Add LOCAL defines for distro compatibilityArkadiusz Hiler1-1/+4
Each Linux distro takes a different spin on providing kernel's uapi headers (especialy the *drm*.h). You can get them with linux-headers, you can get them with libdrm. Sometime you can even get them twice, from both sources. Sometimes the headers match your kernel version, sometimes you end up stuck with headers matching the kernel that the given release of the distro came out with. This makes things harder for code that does not depend on libdrm, as we cannot have sane ./configure-time checks. So let's define LOCAL_ version for FENCE and EXECBUFFER2_WB defines until all the stable distros catch up (+/- some epsilon). Cc: Petri Latvala <petri.latvala@intel.com> Cc: Chris Wilson <chris@chris-wilson.co.uk> Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2017-07-06Make igtrc configuration common, with configurable suspend/resume delayPaul Kocialkowski1-2/+2
This adds support for configurable suspend/resume delay and takes the occasion to move igtrc configuation from igt_chamelium to igt_core. This way, suspend/resume delay configuration can be used for all tests. Signed-off-by: Paul Kocialkowski <paul.kocialkowski@linux.intel.com> Reviewed-by: Lyude Paul <lyude@redhat.com>
2017-06-09Fix a couple of typos CLFAGS -> CFLAGSPetri Latvala1-1/+1
Signed-off-by: Petri Latvala <petri.latvala@intel.com>