TTYCTRL

Tty control structure

Synopsis:

typedef struct chario_entry {
    dispatch_t			*dpp;
    int             		coid;
    int             		timerid;
    unsigned        		max_devs;
    unsigned        		num_devs;
    struct sigevent 		event;
    struct sigevent 		timer;
    struct ttydev_entry 	*timer_list;
    unsigned        		num_events;
    struct ttydev_entry 	**event_queue;
    intrspin_t      		lock;
    unsigned     		flags;
} TTYCTRL;

Description:

A character driver shares the TTYCTRL structure with the io-char library. This structure is used to coordinate events, timers, and so on.

The members include:

dpp
A dispatch handle, returned by dispatch_create(). Used only by io-char.
coid
The connection ID. Used only by io-char.
timerid
The timer ID. Used only by io-char.
max_devs
Used by io-char and the driver to define the maximum number of devices supported.
num_devs
Used only by io-char to define the current number of devices supported.
event
Used by the driver to send pulse events to io-char's event handler. Flags are used to indicate which event occurred. The driver must send the event to io-char. See the entry for TTYDEV.
timer
A pulse to call the timer handler. Used only by io-char.
timer_list
Used only by io-char, it provides a list of active timers.
num_events
Used by io-char and the driver, it displays the current number of events for processing.
event_queue
An array of TTYDEV structures used by io-char and the driver to queue events.
lock
A lock used to control access to this structure. Use the dev_lock() and dev_unlock() macros to access this member.
flags
Flags that indicate which event occurred. See the entry for TTYDEV.

Classification:

QNX Neutrino

See also:

ttc(), TTYDEV