summaryrefslogtreecommitdiff
path: root/tools
AgeCommit message (Collapse)Author
2016-12-01Silence a bunch of "const discard" warningsChris Wilson
A few warnings of the form: gem_mmap_gtt.c: In function ‘copy_wc_page’: gem_mmap_gtt.c:480:16: warning: initialization discards ‘const’ qualifier from pointer target type [enabled by default] __m128i *S = (const __m128i *)src; are no more. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-11-28aubdump: Add a PCI-ID= entry to the AUB file commentJason Ekstrand
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2016-11-28aubdump: Set the application nameJason Ekstrand
This will help with identifying aub files Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2016-11-28Revert "aubdump: Bump the GTT size to 256MB"Jason Ekstrand
This reverts commit c6191a41f6c858cbdd4280e9ffcc91170e87ebeb. It turns out that having a GTT that large causes the simulator massive headaches. Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
2016-11-24aubdump: Fix intel_aubdump -o <filename>Kenneth Graunke
This looks like a mistake in 1f43677f895a88ae880b35f9b18cc7e6869d0ca6. Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2016-11-22aubdump: Bump the GTT size to 256MBJason Ekstrand
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2016-11-22aubdump: Fix GTT setup for Gen8+Francisco Jerez
Gen8+ have 64 bit GTT entries, so we need to allocate twice as much space for the GTT table in order to cover the same number of GTT pages. Fixes sporadic page-fault crashes on the simulator. Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-11-22aubdump: Handle 48-bit relocations properlyJason Ekstrand
aubdump was only writing 32-bits regardless of platform. This is fine if the client being dumped leaves the top 32 bits zero since the aubdump GTT is fairly small. However, if the client does store something in the upper 32 bits, this results in an invalid relocation. Cc: Kristian Høgsberg <krh@bitplanet.net> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2016-11-09aubdump: add --command option to stream aubdump to another programLionel Landwerlin
This comes handy if you want to look at your application output without having to save it into a file. For example, use this with aubinator from Mesa : $ intel_aubdump -c '/path/to/aubinator --gen=hsw' my_gl_app v2: Fix handling empty command line option v3: Fix command line concatenation (again...) v4: Use execvp (Petri) Indentation (Petri) Allow recording to a file and stream to an external application (Lionel) Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Sirisha Gandikota <Sirisha.Gandikota@intel.com>
2016-11-09tools: intel_aubdump: pass configuration through file descriptorLionel Landwerlin
This makes parsing options less complicated and easier to extend. v2: Fix device id parsing (atoi -> sscanf) (Sirisha) Combine with previous commit moving init function (Sirisha) v3: Fix behavior change between bash 4.3 & 4.4 in <<< with \n characters (Lionel) Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Sirisha Gandikota <Sirisha.Gandikota@intel.com>
2016-11-09lib: use the local intel_aub.h fileEmil Velikov
File is provided by the libdrm_intel package which is optional. Since we already have a local copy of the file, we might as well use it ;-) v2: Move the file alongside intel_bufmgr.h and use it in the disable-intel case. Cc: Brian Starkey <brian.starkey@arm.com> Reported-by: Brian Starkey <brian.starkey@arm.com> Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Tested-by: Brian Starkey <brian.starkey@arm.com>
2016-11-03tools: Add intel_guc_logger to .gitignorePetri Latvala
Also re-sort the file. Signed-off-by: Petri Latvala <petri.latvala@intel.com>
2016-10-25This patch provides a test utility which helps capture GuC firmware logs andAkash Goel
then dump them to file. The logs are pulled from a debugfs file '/sys/kernel/debug/dri/guc_log' and by default stored into a file 'guc_log_dump.dat'. The name, including the location, of the output file can be changed through a command line argument. The utility goes into an infinite loop where it waits for the arrival of new logs and as soon as new set of logs are produced it captures them in its local buffer which is then flushed out to the file on disk. Any time when logging needs to be ended, User can stop this utility (CTRL+C). Before entering into a loop, it first discards whatever logs are present in the debugfs file. This way User can first launch this utility and then start a workload/activity for which GuC firmware logs are to be actually captured and keep running the utility for as long as its needed, like once the workload is over this utility can be forcefully stopped. If the logging wasn't enabled on GuC side by the Driver at boot time, utility will first enable the logging and later on when it is stopped (CTRL+C) it will also pause the logging on GuC side. v2: - Use combination of alarm system call & SIGALRM signal to run the utility for required duration. (Tvrtko) - Fix inconsistencies, do minor cleanup and refactoring. (Tvrtko) v3: - Fix discrepancy for the output file command line option and update the Usage/help string. v4: - Update the exit condition for flusher thread, now will exit only after the capture loop is over and not when the flag to stop logging is set. This handles a corner case, due to which the dump of last captured buffer was getting missed. - Add a newline character at the end of assert messages. - Avoid the assert for the case, which occurs very rarely, when there are no bytes read from the relay file. Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com> Signed-off-by: Akash Goel <akash.goel@intel.com> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> (v3)
2016-10-15tools/l3_parity: Skip on ivb with only a single sliceChris Wilson
The l3_parity tool requires multiple banks and fails on ivb which has no l3_parity_slice_1. References: https://bugs.freedesktop.org/show_bug.cgi?id=97565 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-10-07tools/intel_reg: Return SUCCESS after a succesful dumpVille Syrjälä
No reason why 'intel_reg dump' can't declare success after a succesful dumping. Spotted after fixing tools_test to use the right tool :) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-09-26tools/intel_bios_reader: Dump PSR block from VBTVille Syrjälä
Decode the PSR block (9) from VBT. Looks like the same block ID may have been used for something else in the past, so a version check is also needed. The wakeup times part is still up in the air due to the spec not knowing what it's saying, but let's do something that makes at least some sense given the VBTs currently out there in the wild. v2: Actually dump out tp2/3 wakeup time Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-09-16tools/intel_reg: add kabylake register spec fileJani Nikula
Just do whatever skylake does. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-08-10intel_error_decode: Skip inflation for uncompressed ascii85 streamsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-10intel_error_decode: Fix buildChris Wilson
Fixes f984bc7de204 ("tools/Makefile: Don't build tools that depend on libdrm_intel") Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-08-05tools/intel_reg: Dump DP_BUFTRANS registers on ILK-IVBVille Syrjälä
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-08-05tools/intel_reg: Dump fence registers on ILKVille Syrjälä
Currently ILK doesn't get its fences dumped. Let's fix that. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-08-05tools/intel_reg: Don't reuse stale decoded results for later registersVille Syrjälä
In case the ->debug_output() function skips decoding the register it just returns, which means the caller will reuse whatever it already has in the tmp buffer as the decoded result for this result. What it usually has in there is the decoded result of some previous register. Showing incorrect decoded results is no good, so let's allow ->debug_output() to actually return how many bytes it wrote, and the caller can then skip showing the decoded results if zero bytes were produced. We'll make a variant of snprintf() that's safe to call without having to check the return value for the case when it didn't have enough space to do its work, that is, make it return 0 in case no bytes were written. v2: Document the _DEBUGSTRING() funcion (Jani) Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Jani Nikula <jani.nikula@intel.com>
2016-08-04tools/Makefile: Replace automake specific name of listings in Makfile.sourcesRobert Foss
Replace the automake specific names of listings in Makefile.sources with something not automake specific. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2016-08-04tools/Makefile: Format whitespaceRobert Foss
Harmonize tabs/spaces etc. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2016-08-04tools/Makefile: Don't build tools that depend on libdrm_intelRobert Foss
Use the HAS_INTEL automake flag to avoid building tools that won't compile unless libdrm_intel is available in the build system. Signed-off-by: Robert Foss <robert.foss@collabora.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2016-07-27lib: Update igt_chipset docsDaniel Vetter
gtkdoc can't handle aliasing, so let's rename the intel_device_info function. Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2016-07-25intel_chipset: Fixup HAS_PCH_SPLIT() to exclude AtomsChris Wilson
The Atoms do not have the PCH split, exclude them from HAS_PCH_SPLIT(). At the time, I was planning to add the feature flag and make intel_pch_type() useful, but for now take the simple option of expanding th predicate. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-07-14tools/intel_bios_reader: Dump out more of the eDP blockVille Syrjälä
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-07-14tools/intel_bios_reader: Dump out more information from the child device ↵Ville Syrjälä
structure Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-07-14tools/intel_bios_reader: Dump more bits for general bit definitions block (1)Ville Syrjälä
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2016-07-08aubdump: Only close aub file if we opened itKristian Høgsberg Kristensen
2016-07-08aubdump: Support softpin bosKristian Høgsberg Kristensen
2016-06-30intel_chipset: Replace lookup of GT size with computationChris Wilson
Instead of a large if-chain for matching devid to GT, we can just compute it directly from the encoded devid. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-06-30intel_chipset: Convert IS_PINEVIEW to device infoChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-06-30lib: Start weaning off defunct intel_chipset.hChris Wilson
Several years ago we made the plan of only having one canonical source for i915_pciids.h, the kernel and everyone importing their definitions from that. For consistency, we style the intel_device_info after the kernel, most notably using a generation mask and a per-codename bitfield. This first step converts looking up the generation for a devid tree from a massive if(devid)-chain to a (cached) table lookup. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-05-13tools/intel_bios_reader: print errors to stderr, return EXIT_FAILUREJani Nikula
Be consistent with exit status and printing errors to stderr. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-13tools/intel_bios_reader: clean up VBT/BDB header dumpingJani Nikula
Make the output nicer. Do not print the header if a specific block is requested. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-13tools/intel_bios_reader: abstract header information dumpingJani Nikula
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: add helpMarius Vlad
Signed-off-by: Marius Vlad <marius.c.vlad@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: free the block returned by find_sectionJani Nikula
Since we no longer store pointers to previous blocks, we can free them. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: add --all-panels option to dump all panelsJani Nikula
Only dump the one matching panel_type by default. Cleans up the output, and allows the users to get more verbose output if he so chooses. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: add support for dumping only specific sectionJani Nikula
Now that the parsers for blocks don't depend on the dump ordering, we can also choose to dump specific sections only. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: add --hexdump option to dump hex, disable by defaultJani Nikula
The hex dump is useful, just not by default. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: dump the blocks in numerical orderJani Nikula
All parsers fetch the information they need without ordering constraints, so dump all in numerical order. This also makes it unnecessary to track already dumped blocks. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: let the user specify panel type on the command lineJani Nikula
On some systems the VBT panel type may be overridden in the opregion, and we can't necessarily get at that. Let the user specify it on the command line. As a byproduct, the section parsing order no longer matters. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: drop dependencies on lvds block parsingJani Nikula
Don't mandate a specific ordering on the parsing of the blocks. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: move devid to context tooJani Nikula
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: move more globals to struct contextJani Nikula
It's just good hygiene. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: pass around a context pointer instead of bdb_headerJani Nikula
Allow putting stuff in there instead of a global. A bit like passing dev_priv in the kernel. Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2016-05-12tools/intel_bios_reader: drop silly tv_present variable and printoutJani Nikula
There's no point in dumping a fixed value. Signed-off-by: Jani Nikula <jani.nikula@intel.com>