HP-UX Reference (11i v2 03/08) - 5 Miscellaneous Topics, 7 Device (Special) Files, 9 General Information, Index (vol 9)

i
iomap(7) iomap(7)
[ENODEV] Read and write calls are unsupported.
[ENXIO] No such device at the address specified by the minor number.
[ENOSPC] Required resources for mapping could not be allocated.
[ENOTTY] Inappropriate ioctl request for this device type; fildes is not a file descriptor for an
iomap device file.
EXAMPLES
Consider the following code fragment:
#include <sys/iomap.h>
...
int fildes;
void *addr;
...
addr = REQUESTED_ADDRESS;
(void) ioctl(fildes, IOMAPMAP, &addr);
(void) printf("actual address = 0x%x\n", addr);
where fildes is an open file descriptor for the device special file and
REQUESTED_ADDRESS
is the
address originally requested by the program.
If
addr is a null pointer, the system selects a suitable address then returns the selected address in addr.
If the value in addr is not a null pointer, it is used as a specified address for allocating memory. If the
specified address cannot be used, an error is returned (see
ERRORS).
SEE ALSO
mknod(1M).
Section 7−−48 Hewlett-Packard Company − 2 − HP-UX 11i Version 2: August 2003