54 Commits

Author SHA1 Message Date
Damien Lespiau
cc6c254ae9 reg_dumper: Shut a warning down
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
2013-05-08 13:34:39 +01:00
Paulo Zanoni
b0c63a781d intel_reg_dumper: improve the dumping of backlight registers
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-04-09 13:52:54 -03:00
Paulo Zanoni
7253eb4e4f intel_reg_dumper: debug SDEISR on Haswell
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-03-22 14:45:06 -03:00
Paulo Zanoni
051e327247 intel_reg_dumper: dump HSW watermark registers
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-03-22 14:45:06 -03:00
Paulo Zanoni
eb88ce64b7 intel_reg_dumper: decode some useful Haswell registers
I've checked the value of these registers many many many times during
development.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-03-22 14:45:06 -03:00
Paulo Zanoni
5c0ce0f2a9 intel_reg_dumper: make Haswell dump useful
It was previously printing ironlake_debug_regs and haswell_debug_regs.
Since ironlake_debug_regs contains a lot of registers that don't exist
on Haswell, running intel_reg_dumper on Haswell caused "unclaimed
register" messages. Now I've copied the existing registers from
ironlake_debug_regs to haswell_debug_regs, so we won't print the
registers that don't exist anymore.

Also removed DP_TP_STATUS_A since it doesn't exist.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-03-22 14:45:06 -03:00
Paulo Zanoni
2fadf695ff intel_reg_dumper: recognize LPT
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
2013-03-22 14:45:06 -03:00
Daniel Vetter
da6473184c tools/intel_reg_dumper: add some cpt/ppt debug regs
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-12-01 00:57:36 +01:00
Damien Lespiau
c8b93b8b77 intel_reg_dumper: Add more information when dumping single registers
Now that we can dump registers giving a partial name, adding more
information about the dumped registers seems useful.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-09-04 13:55:10 +02:00
Damien Lespiau
62a026eac5 intel_reg_dumper: Allow partial register names on the command line
Let people give just a part of the register name. Handy when not
remembering the exact name or if the register is defined with a
different name than the one in the spec being looked at.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-09-04 13:55:10 +02:00
Damien Lespiau
763d22cbf8 intel_reg_dumper: Also decode registers given by address
One can now give an address instead of a register name to decode a
single register.

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-09-04 13:55:10 +02:00
Damien Lespiau
2fd80079c0 intel_reg_dumper: Add a single register decode mode
From time to time, one would like to decode a register value that have
been captured at a certain point in time (and say printed out with a
printk). intel_reg_dumper has all the knowledge to do that and this
patch adds a way to ask it to decode a value.

Example usage:

$ ./tools/intel_reg_dumper PCH_PP_CONTROL 0xabcd0002
       PCH_PP_CONTROL: 0xabcd0002 (blacklight disabled, power...

v2: friendlier invocation (Chris Wilson)
v3: remove unecessary casts and use strcasecmp (Jani Nikula)

Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-09-04 13:55:10 +02:00
Ben Widawsky
bc62567b77 clang: Fix static analysis warnings from clang
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-08-30 14:20:52 -07:00
Daniel Vetter
3d148e164d s/NO_PID/NOP_ID
Alan typo'ed it, I've failed to notice :(
2012-08-25 00:01:27 +02:00
Alan Coopersmith
6b3e6f28d2 Rename NOPID to NO_PID to avoid conflict with Solaris NOPID
Solaris <sys/types.h> already has #define NOPID (pid_t)(-1)

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-08-24 23:20:22 +02:00
Daniel Vetter
0efa6c7b27 tools/reg_dumper: really dump pipe C regs
Not just a copy of pipe B. Meh.

Also kill a few redudant #define for pipe B - they match pipe A.
2012-08-08 22:05:14 +02:00
Daniel Vetter
f56a289aa8 tools/reg_dumper: dump pipe C regs
Also reorder the pipe B regs a bit to be consisten with pipe A.
2012-08-07 14:50:54 +02:00
Eugeni Dodonov
c6fe31bc47 intel_reg_dumper: use intel_register_access_init/fini
We need to hold forcewake lock in order to be able to read GT registers.
Otherwise, when the GPU is in RC6 mode, we'll read all zeros.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-06-21 14:31:34 -03:00
Eugeni Dodonov
b28a399dcd intel_reg_dumper: dump more PM registers
Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-06-13 15:50:44 -03:00
Daniel Vetter
9739401fb5 intel_reg_dumper: dump pre-pch-split blc regs 2012-06-07 16:37:02 +02:00
Eugeni Dodonov
3986d9faf3 tools: add Haswell registers into intel_reg_dumper
For now, only print their content for diffing, but also add the necessary
bits that can be used for more verbose output in the fugure.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-05-08 21:14:20 +02:00
Eric Anholt
732547793f intel_reg_dumper: Add dumping of GPU turbo regs.
I was interested in finding why my IVB system is not getting GPU turbo
after suspend/resume.  The piece that looks weird to me is that
INTERRUPT_THRESHOLD is sitting at 0, whereas pre-suspend it's
0x12000000.
2012-02-22 10:45:01 +01:00
Eric Anholt
6624325f13 reg_dumper: Refactor duplicated reg-dumping code. 2012-02-22 10:44:42 +01:00
Daniel Vetter
8bedcae848 tests/intel_reg_dumper: s/pipe/disp_pipe/ to shut off the compiler
Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-02-16 12:26:23 +01:00
Paulo Zanoni
ecad594e02 reg_dumper: change and fix behavior when using dump files
Before this patch, handling dump files was wrong:
- when HAS_PCH_SPLIT was specified, intel_reg_dumper segfaulted inside
  intel_check_pch()
- the "devid" variable was used but not set
- there was no way to specify the device id of the machine used to
  generate the dump file

This patch fixes this behavior with the following changes:
- the HAS_PCH_SPLIT variable is gone
- there is now a '-d' argument that can be used to specify the device id
  used to interpret the results
- when a dump file is used but the '-d' argument is not provided, an
  Ironlake machine is assumed

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-02-16 00:01:30 +01:00
Paulo Zanoni
ad87b06fd6 reg_dumper: add interlaced information to TRANSCONF
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-02-16 00:01:28 +01:00
Paulo Zanoni
3310db08d8 reg_dumper: add interlaced and rotation information to PIPECONF
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-02-16 00:01:25 +01:00
Daniel Vetter
611e0cb333 intel_reg_dumper: add TRANS_VSYNCSHIFT
Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-01-27 18:50:21 +01:00
Daniel Vetter
5774fadf7d tools/intel_reg_dumper: fixup new warnings
Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-01-09 23:38:29 +01:00
Eugeni Dodonov
47a5bc505c tools/intel_reg_dumper: retrieve rc6 residency values
This allows to check if rc6 works, and how long have we been in each
state.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-01-03 15:18:06 -02:00
Eugeni Dodonov
1649ab350f tools/intel_reg_dumper: Add support for debug register
Right now, we only check for hardware DRRS support. But much more can be
done with it. Some day.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-01-03 15:18:06 -02:00
Jesse Barnes
2b484c16dd intel_reg_dumper: handle 3 pipe configs when dumping HDMI config
Could be on pipe A, B, or C.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2011-10-28 08:54:50 -07:00
Jesse Barnes
1708580217 intel_reg_dumper: use none instead of NULL if no port is assigned to TRANS_DP
Makes the output a little more readable.
2011-10-11 11:37:25 -07:00
Chris Wilson
4c0176e497 intel_reg_dumper: Slightly tidy the reporting of pipe configs
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-07-08 14:55:36 +01:00
Chris Wilson
41570d9bf5 Remove confusing use of IS_9XX
... and test for what we mean instead.

Reported-by: Diego Celix <dcelix@gmail.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-02-14 15:57:40 +00:00
Chris Wilson
2c9b293927 tests/intel_reg_dumper: Replace asprintf with snprintf
Stops the compiler warning about not checking the potential error return
from asprintf, which was a false positive anyway.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-02-10 10:50:48 +00:00
Jesse Barnes
7ab19ae6fe intel_reg_dumper: eDP port is on the CPU, not PCH
Made me think there was another register until I checked the offset.
2010-09-20 14:37:07 -07:00
Chris Wilson
c09fa38c01 reg dumper: Dump ILK panel fitting control debug registers
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-05 12:05:52 +01:00
Chris Wilson
a462fa6e29 reg dumper: Fix ilk panel fitter filter shift
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-05 10:53:12 +01:00
Chris Wilson
db91f220da reg dumper: Add panel backlight detailed information
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-08-25 12:00:05 +01:00
Jesse Barnes
b1e839d026 intel_reg_dumper: add some 945 MI reg dumping 2010-06-30 02:02:49 -07:00
Adam Jackson
be6e1a53fc Use longer string padding in intel_reg_dumper on ironlake
DIGITAL_PORT_HOTPLUG_CNTRL is 26 chars.  Bump out to 30.

Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-06-30 11:18:00 -04:00
Adam Jackson
439adf7a0a fix reg_dumper on systems without intel gpus 2010-06-30 10:58:32 -04:00
Chris Wilson
040fbc6ea3 intel_reg_dump: Off-by-one in calculation of i965 fence pitch
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-06-15 13:05:48 +01:00
Zhenyu Wang
50b8272d0b update PCH HDMI debug info
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2010-04-15 15:25:19 +08:00
Zhenyu Wang
eae80edbb3 reg dump update for SNB/CPT
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2010-04-15 15:25:07 +08:00
Chris Wilson
95374225e8 Enable compilation on non-Intel, non-DRM systems.
A few of the tools can be performed post-mortem from a different system,
so it is useful to be able to compile those tools on those foreign
systems. Obviously, any program to interact with the PCI device or talk
to GEM will fail on a non-Intel system.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-04-08 12:17:31 +01:00
Adam Jackson
cd64e19329 intel_reg_dumper: Add support for reading register dumps from files
Also add intel_reg_snapshot for creating such snapshots, and relevant
documentation.

Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-04-05 11:41:24 -04:00
Eric Anholt
b0ddd0688c Add Ironlake INSTDONE bits. 2010-03-24 12:01:38 -07:00
Eric Anholt
7c9d69de57 intel_reg_dumper: Fix the i915 fence reg decode to not be pure lies. 2010-03-24 12:01:38 -07:00