[Previous]
[Contents]
[Next]

dev_osize()

set the output trigger threshold

Synopsis:

#include <sys/dev.h>
int dev_osize (int fd, int size);

Description:

This function changes the output threshold to the given size. When the output buffer has room for this many characters (the default is 1), any sending proxies waiting on _DEV_EVENT_OUTPUT are triggered.

Returns:

The previous value of the output trigger threshold. If an error occurs, it returns -1, and sets errno.

Errors:

ENOSYS
The function isn't supported.
EINVAL
size is greater than the output buffer size.

Examples:

/* Wake up when there's room to transmit at least
   10 more characters. */

dev_osize (fd, 10);
dev_arm (fd, proxy, _DEV_EVENT_OUTPUT);

Classification:

QNX

Safety:
Interrupt handler No
Signal handler Yes, but modifies errno
Thread Yes

See also:

dev_arm()


[Previous]
[Contents]
[Next]