termio.7 (2010 09)

t
termio(7) termio(7)
tcdrain() wait until output has drained
tcflush() flush input or output queue or both
tcflow() suspend or resume input or output
tcgetpgrp() get foreground process group id
tcsetpgrp() set foreground process group id
tcgetsid() get session id
System Asynchronous I/O IOCTL Commands
The following
ioctl() system calls provide for system asynchronous I/O and have the form:
ioctl (fildes, command, arg)
int *arg;
Commands using this form are:
FIOSSAIOSTAT If the integer referenced by arg is non-zero, system asynchronous I/O is
enabled; that is, enable SIGIO to be sent to the process currently designated
with FIOSSAIOOWN (see below) whenever the terminal device file status
changes from "no read data available" to "read data available". If no process
has been designated with FIOSSAIOOWN, enable SIGIO
to be sent to the
first process that opened the terminal device file.
If the designated process has exited, the
SIGIO signal is not sent to any pro-
cess.
If the integer referenced by arg is 0, system asynchronous I/O is disabled.
The default on open of a terminal device file is that system asynchronous I/O
is disabled.
FIOGSAIOSTAT The integer referenced by arg is set to 1 if system asynchronous I/O is enabled.
Otherwise, the integer referenced by arg is set to 0.
FIOSSAIOOWN Set the process ID that will receive the SIGIO signals due to system asyn-
chronous I/O to the value of the integer referenced by arg. If no process can be
found corresponding to that specified by the integer referenced by arg, the call
returns −1 with
errno set to [ESRCH]. A user with appropriate privileges
can designate that any process receive the SIGIO signals. If the request is
not made by a user with appropriate privileges and the calling process does
not either designate that itself or another process whose real, saved, or
effective user ID matches its real or effective user ID or the calling process
does not designate a process that is a descendant of the calling process to
receive the SIGIO signals, the call returns −1 with errno set to [EPERM].
See privileges (5) for more information about privileged access on systems that
support fine-grained privileges.
If the designated process subsequently exits, the
SIGIO signal is not sent to
any process.
The default on open of a terminal device file is that the process performing the
first open is set to receive the
SIGIO signals.
FIOGSAIOOWN The integer referenced by arg is set to the process ID designated to receive
SIGIO signals.
Line Control IOCTL Commands
Several
ioctl() system calls control input and output. Some of these calls have the form:
ioctl (fildes, command, arg)
int arg;
Commands using this form are:
TCSBRK Wait for the output to drain. If arg is 0, send a break (zero bits for at least 0.25
seconds). The tcsendbreak() function performs the same function (see
tcsendbreak (3C)).
TCXONC Start/stop control. If arg is 0, suspend output; if 1, restart suspended output; if 2,
transmit a STOP character; if 3, transmit a START character. If any other value is
given for arg, the call returns −1 with errno set to [EINVAL]. The tcflow()
14 Hewlett-Packard Company − 14 − HP-UX 11i Version 3: September 2010