Присоединить псевдо-обработчик прерываний, который может принимать трассировочные события от диагностической версии ядра
#include <sys/neutrino.h>int InterruptHookTrace( const struct sigevent * (*handler)( int ),unsigned flags );
0
, or the following bit: _NTO_INTR_FLAGS_END.libc
The InterruptHookTrace() kernel call attaches the pseudo interrupt handler handle that the instrumented module uses.
![]() | This function requires the instrumented kernel. |
Before calling this function, the thread must request I/O privileges by calling:
ThreadCtl( _NTO_TCTL_IO, 0 );
The handler argument specifies the pseudo interrupt handler that receives trace events from the kernel. The integer that's passed to the handler is a combination of the buffer index and the sequence number; to extract each part, pass the integer to the _TRACE_GET_BUFFNUM()
and _TRACE_GET_BUFFSEQ()
macros defined in <sys/trace.h>
.
This call doesn't block.
An interrupt function ID.
Если возникла ошибка функция возвращает -1
, код ошибки записывается в errno.
ЗОСРВ «Нейтрино»
InterruptAttach(), TraceEvent()
Предыдущий раздел: Описание API системной библиотеки