Data Structures for Drivers kstatintr(9S)
NAME
kstatintr - structure for interrupt kstats
SYNOPSIS
#include
#include
#include
#include
INTERFACE LEVEL
Solaris DI specific (Solaris DI)
DESCRIPTION
Interrupt statistics are kept in the kstatintr structure.
When kstatcreate(9F) creates an interrupt kstat, the
ksdata field is a pointer to one of these structures. The
macro KSTATINTRPTR() is provided to retrieve this field.
It looks like this:
#define KSTATINTRPTR(kptr) ((kstatintrt *)(kptr)->ksdata)
An interrupt is a hard interrupt (sourced from the hardware
device itself), a soft interrupt (induced by the system
through the use of some system interrupt source), a watchdog
interrupt (induced by a periodic timer call), spurious (an
interrupt entry point was entered but there was no interrupt
to service), or multiple service (an interrupt was detected
and serviced just prior to returning from any of the other
types).
Drivers generally report only claimed hard interrupts and
soft interrupts from their handlers, but measurement of the
spurious class of interrupts is useful for auto-vectored
devices in order to pinpoint any interrupt latency problems
in a particular system configuration.
Devices that have more than one interrupt of the same type
should use multiple structures.
STRUCTURE MEMBERS
ulongt intrs[KSTATNUMINTRS]; /* interrupt counters */
The only member exposed to drivers is the intrs member. This
field is an array of counters. The driver must use the
appropriate counter in the array based on the type of
SunOS 5.11 Last change: 4 Apr 1994 1
Data Structures for Drivers kstatintr(9S)
interrupt condition.
The following indexes are supported:
KSTATINTRHARD Hard interrupt
KSTATINTRSOFT Soft interrupt
KSTATINTRWATCHDOG Watchdog interrupt
KSTATINTRSPURIOUS Spurious interrupt
KSTATINTRMULTSVC Multiple service interrupt
SEE ALSO
kstat(9S)
Writing Device Drivers
SunOS 5.11 Last change: 4 Apr 1994 2
|