12 Commits

Author SHA1 Message Date
Thomas Wood
aa75f37397 tools: print a warning for tools replaced by intel_reg
Cc: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-06-11 14:48:58 +01:00
Jani Nikula
12d785bcd4 intel_reg_{read,write}: switch to INREG and OUTREG
Use INREG and OUTREG instead of using mmio directly.

Signed-off-by: Jani Nikula <jani.nikula@intel.com>
2015-05-05 13:10:12 +03:00
Daniel Vetter
c03c6ceb29 lib: rename intel_gpu_tools.h to intel_io.h
With the header cleanup we can now give this header a suitable name,
since it now really only contains register access and other I/O
functions and assorted definitions.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 21:34:29 +01:00
Daniel Vetter
6cfcd71589 lib: remove uncessary #includes from headers
Only include what the header itself needs. The big fish here is
intel-gpu-tools.h. More will follow.

One ugly thing removed here is the duplicated GEN6_TD_CTL #define, one
of which was broken.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2014-03-22 20:08:13 +01:00
Ben Widawsky
ea944a9faf intel_reg_read: use strtol instead of atoi
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-08-23 11:32:57 -07:00
Ben Widawsky
baf026d692 intel_reg_read: support -c option to read multiple dwords
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-08-23 11:29:43 -07:00
Eugeni Dodonov
be7ca950d7 intel_reg_read: add a flag to simplify bit decoding
This allows to specify '-d' parameter which will decode individual bits in
each register being read.

The register bits are printed horizontally for space reasons. This
requires more than 80x25 terminal to see them all. An alternative solution
would be to print them vertically, but this will become much more
difficult to read when printing multiple registers at the same time.

v2: fix spacing to get us a bit closer to the code nirvana.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-03-13 17:55:51 -03:00
Eugeni Dodonov
8d45456428 intel_reg_read: support reading multiple registers
The registers must be passed on the command line and will be read
sequentially, one at a time.

Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-03-13 17:55:51 -03:00
Eugeni Dodonov
b7464e4032 intel_reg_read: add support for getopt
This will allow us to pass more options to it in the future.

v2: fix whitespacing issues and improve scary warning text as suggested by
Paul Menzel.

Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
2012-03-13 17:55:51 -03:00
Ben Widawsky
6e3066c9c3 intel_reg_read: use register access init/fini
This will do the proper forcewake stuff.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
2012-01-25 21:05:15 -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
Zhenyu Wang
4cc8b0543a Add 'intel_reg_read' tool
This is a handy tool to just check state of one register, which might
not bother to be included in intel_reg_dumper tool. And also take in Ben's
original full range register dump with '-f' option.

Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2010-01-06 13:50:08 +08:00