freebsd-skq/sys/compat/freebsd32
John Baldwin ffb6607984 Decode kevent structures logged via ktrace(2) in kdump.
- Add a new KTR_STRUCT_ARRAY ktrace record type which dumps an array of
  structures.

  The structure name in the record payload is preceded by a size_t
  containing the size of the individual structures.  Use this to
  replace the previous code that dumped the kevent arrays dumped for
  kevent().  kdump is now able to decode the kevent structures rather
  than dumping their contents via a hexdump.

  One change from before is that the 'changes' and 'events' arrays are
  not marked with separate 'read' and 'write' annotations in kdump
  output.  Instead, the first array is the 'changes' array, and the
  second array (only present if kevent doesn't fail with an error) is
  the 'events' array.  For kevent(), empty arrays are denoted by an
  entry with an array containing zero entries rather than no record.

- Move kevent decoding tables from truss to libsysdecode.

  This adds three new functions to decode members of struct kevent:
  sysdecode_kevent_filter, sysdecode_kevent_flags, and
  sysdecode_kevent_fflags.

  kdump uses these helper functions to pretty-print kevent fields.

- Move structure definitions for freebsd11 and freebsd32 kevent
  structures to <sys/event.h> so that they can be shared with userland.
  The 32-bit structures are only exposed if _WANT_KEVENT32 is defined.
  The freebsd11 structures are only exposed if _WANT_FREEBSD11_KEVENT is
  defined.  The 32-bit freebsd11 structure requires both.

- Decode freebsd11 kevent structures in truss for the compat11.kevent()
  system call.

- Log 32-bit kevent structures via ktrace for 32-bit compat kevent()
  system calls.

- While here, constify the 'void *data' argument to ktrstruct().

Reviewed by:	kib (earlier version)
MFC after:	1 month
Differential Revision:	https://reviews.freebsd.org/D12470
2017-11-25 04:49:12 +00:00
..
capabilities.conf allow posix_fallocate in 32-bit compat capability mode 2017-10-12 18:30:54 +00:00
freebsd32_capability.c Add compat32 support for capsicum. 2016-09-18 22:03:07 +00:00
freebsd32_ioctl.c sys: further adoption of SPDX licensing ID tags. 2017-11-20 19:43:44 +00:00
freebsd32_ioctl.h sys: further adoption of SPDX licensing ID tags. 2017-11-20 19:43:44 +00:00
freebsd32_ipc.h Add shmatt_t. 2016-07-26 17:23:49 +00:00
freebsd32_misc.c Decode kevent structures logged via ktrace(2) in kdump. 2017-11-25 04:49:12 +00:00
freebsd32_misc.h
freebsd32_proto.h Regen. 2017-06-17 00:58:19 +00:00
freebsd32_signal.h Store a 32-bit PT_LWPINFO struct for 32-bit process core dumps. 2017-06-29 21:31:13 +00:00
freebsd32_syscall.h Regen. 2017-06-17 00:58:19 +00:00
freebsd32_syscalls.c Regen. 2017-06-17 00:58:19 +00:00
freebsd32_sysent.c regen freebsd32_sysent.c after r324564 (freebsd32_posix_fallocate) 2017-10-12 18:31:28 +00:00
freebsd32_systrace_args.c Regen. 2017-06-17 00:58:19 +00:00
freebsd32_util.h Correct sysent flags for dynamically loaded syscalls. 2017-07-14 09:34:44 +00:00
freebsd32.h Decode kevent structures logged via ktrace(2) in kdump. 2017-11-25 04:49:12 +00:00
Makefile Add compat32 support for capsicum. 2016-09-18 22:03:07 +00:00
syscalls.conf
syscalls.master Add abstime kqueue(2) timers and expand struct kevent members. 2017-06-17 00:57:26 +00:00