6 Commits

Author SHA1 Message Date
070fec2248 Fix typo in XLAT_TYPE_PAIR
* xlat.h (XLAT_TYPE_PAIR): Take "type" parameter.

Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
2016-04-29 20:04:38 +00:00
Jeff Mahoney
9019cf4cf5 Change type of struct xlat.val to uint64_t
Some ioctls have flags fields that are 64-bit.  A 32-bit val means
these flags will never be matched or printed.

* xlat.h: Include <stdint.h>.
(struct xlat): Change type of val to uint64_t.
2016-04-29 01:12:14 +00:00
0f4982691e Introduce XLAT_TYPE and XLAT_TYPE_PAIR macros
* xlat.h (XLAT_TYPE): New macro, similar to XLAT but casts
to the specified type instead of unsigned int.
(XLAT_TYPE_PAIR): New macro, similar to XLAT_PAIR but casts
to the specified type instead of unsigned int.
2016-04-29 00:15:01 +00:00
3f25b65d63 xlat: generate xlat pairs using new XLAT_PAIR macro
Before this change there were two forms of xlat entries: those that use XLAT
or XLAT_END macros, and others verbatim entries.  This change converts
the latter to use new XLAT_PAIR macro.

This is necessary for the upcoming change of xlat.val type.

* xlat.h (XLAT_PAIR): New macro.
* xlat/gen.sh (cond_xlat, gen_header): Use it.
2016-04-29 00:15:01 +00:00
a9f956d279 Explicitly cast argument of XLAT macro to unsigned int
This is necessary for the upcoming change of xlat.val type.

* xlat.h (XLAT): Cast the argument to unsigned int.
2016-04-29 00:15:01 +00:00
0e09704e09 Move definition of struct xlat to a separate header file
Define struct xlat in a separate file so that it could be used later by
tests without inclusion of defs.h header file.

* defs.h (struct xlat, XLAT, XLAT_END): Move ...
* xlat.h: ... here.
* Makefile.am (strace_SOURCES): Add xlat.h.
2016-04-26 00:08:16 +00:00