seL4/libsel4
Kofi Doku Atuah bebfcf6d27 SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging
This commit implements the body of SELFOUR-499. The API exposes the x86 DR0-7
and ARM coprocessor 14 features to userspace by virtualizing them as context-
switched registers in the TCB. Implemented as TCB invocations. This feature is
only built when CONFIG_HARDWARE_DEBUG_API is selected.

* Add low-level support routines for setting, unsetting, getting, enabling
  and disabling breakpoints.
* Add support for single-stepping as well.
  ^ Single-stepping is not supported on ARMv6 since the hardware
    doesn't have support.
  ^ ARM implements single-stepping as instruction breakpoints
    configured to fault on every instruction -- this is achieved through
    the "mismatch" mode, which is only supported from ARMv7 onwards.
* Also support explicit software break requests, a la "BKPT" and "INT $3".

* New invocations:
  * seL4_TCB_SetBreakpoint().
  * seL4_TCB_GetBreakpoint().
  * seL4_TCB_UnsetBreakpoint().
  * seL4_TCB_ConfigureSingleStepping().
* New constants:
  ^ Event types:
    ^ seL4_InstructionBreakpoint.
    ^ seL4_DataBreakpoint.
    ^ seL4_SoftwareBreakRequest.
  ^ Access types:
    ^ seL4_BreakOnRead.
    ^ seL4_BreakOnWrite.
    ^ seL4_BreakOnReadWrite.
  ^ Exports:
    ^ seL4_NumHWBreakpoints.
    ^ seL4_NumExclusiveBreakpoints.
    ^ seL4_NumExclusiveWatchpoints.
    ^ seL4_NumDualFunctionMonitors.
    ^ seL4_FirstBreakpoint.
    ^ seL4_FirstWatchpoint.
    ^ seL4_FirstDualFunctionMonitor.

See documentation in the seL4 API manual.
2016-10-10 13:53:21 +11:00
..
arch_include SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging 2016-10-10 13:53:21 +11:00
include SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging 2016-10-10 13:53:21 +11:00
sel4_arch_include SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging 2016-10-10 13:53:21 +11:00
sel4_plat_include SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging 2016-10-10 13:53:21 +11:00
src Streamline libsel4 and remove its libc dependencies. 2015-07-09 18:03:46 -07:00
tools SELFOUR-276: Add MCP field to threads. 2016-10-05 11:11:19 +11:00
Kbuild Streamline libsel4 and remove its libc dependencies. 2015-07-09 18:03:46 -07:00
Kconfig arm/libsel4: Refactor syscall functions 2016-10-04 17:22:48 +11:00
Makefile SELFOUR-499: X86, ARM: Add userspace invocations for hardware debugging 2016-10-10 13:53:21 +11:00