framebuf.7 (2010 09)
f
framebuf(7) framebuf(7)
image needs to be refreshed. The window image is then a superset of the rectangle
being updated, and might thus have different dimensions. The
skipcount
specifies the portion of the row in the larger window image that is excluded from the
rectangle. Thus, linelength plus skipcount would be the number of bytes in
each row of the larger window image array.
If a particular framebuffer device supports this system call, the
CRT_DMA_OUTPUT flag in the
crt_attributes
field of the
crt_frame_buffer_t
structure is set. Some framebuffer devices supporting
DMA might restrict alignment of the various parameters, and are specified in the
DEPENDENCIES section below. The kernel ensures that these restrictions are
obeyed, and if they are not the system call will fail and set
errno to [EINVAL].
It is the responsibility of the application to guarantee that the system’s physical
memory is up-to-date by flushing the processor’s data cache. One should use the
GCDMA_DATAFLUSH
ioctl to ensure that the data is consistent before initiating a
DMA transfer.
GCDMA_DATAFLUSH
Flush the specified data from the processor’s data cache to the system’s main
memory. This system call is intended to be used before DMA to ensure that an up-
to-date version of the data is transferred to the framebuffer or to control space.
The parameters for the flush are passed in a
crt_flush_t data structure, which
includes the following fields:
char *flush_addr; /* Starting address of data
to be flushed */
int flush_len; /* Number of bytes to flush */
The kernel ensures that the
flush_len bytes starting at flush_addr are con-
sistent in main memory with respect to the cache.
GCSLOT Provide pertinent information about the calling process’s participation in the
system-wide graphics locking mechanism (see the discussion under GCLOCK above).
The GCSLOT request does not carry out any actual locking functionality. The lock
information is returned to the calling process in a crt_gcslot_t data structure.
The parameter is defined as crt_gcslot_t *arg;. The crt_gcslot_t data
structure is defined in the file <sys/framebuf.h>
.
GCSTATIC_MAP Prevent the Internal Terminal Emulator (ITE) from modifying the device’s color
map.
GCVARIABLE_MAP Allow the Internal Terminal Emulator (ITE) to modify the device’s color map.
DEPENDENCIES
When requesting
GCMAP, the parameter arg is ignored and should be set to 0.
All supported ITEs ignore the frame buffer lock for output.
ERRORS
[EAGAIN] The operation would result in suspension of the calling process, but the request was
either
GCLOCK_NOWAIT or GCLOCK_BLOCKSIG_NOWAIT
.
[EBUSY] Attempted to lock the device, which is already locked by the same process.
[EINTR] A call to
ioctl() was interrupted by a signal.
[EINVAL] An invalid
ioctl() command was made.
[ENODEV] Attempted to use
read() or write() system calls on the device.
[ENOMEM] Sufficient memory for mapping could not be allocated.
[ENOSPC] Required resources for mapping could not be allocated.
[ENXIO] The minor number on the device file refers to a nonexistent device.
[EPERM] Requested
GCUNLOCK ioctl() command, but the device was locked by a different pro-
cess.
4 Hewlett-Packard Company − 4 − HP-UX 11i Version 3: September 2010