Back to index

libdrm  2.4.37
Classes | Defines
vmwgfx_drm.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  drm_vmw_getparam_arg
 struct drm_vmw_getparam_arg More...
struct  drm_vmw_extension_rep
 DRM_VMW_EXTENSION - Query device extensions. More...
union  drm_vmw_extension_arg
 union drm_vmw_extension_arg More...
struct  drm_vmw_context_arg
 DRM_VMW_CREATE_CONTEXT - Create a host context. More...
struct  drm_vmw_surface_create_req
 DRM_VMW_UNREF_CONTEXT - Create a host context. More...
struct  drm_vmw_surface_arg
 struct drm_wmv_surface_arg More...
struct  drm_vmw_size
 struct drm_vmw_size ioctl. More...
union  drm_vmw_surface_create_arg
 union drm_vmw_surface_create_arg More...
union  drm_vmw_surface_reference_arg
 DRM_VMW_REF_SURFACE - Reference a host surface. More...
struct  drm_vmw_execbuf_arg
struct  drm_vmw_fence_rep
 struct drm_vmw_fence_rep More...
struct  drm_vmw_alloc_dmabuf_req
 DRM_VMW_ALLOC_DMABUF. More...
struct  drm_vmw_dmabuf_rep
 struct drm_vmw_dmabuf_rep More...
union  drm_vmw_alloc_dmabuf_arg
 union drm_vmw_dmabuf_arg More...
struct  drm_vmw_unref_dmabuf_arg
 DRM_VMW_UNREF_DMABUF - Free a DMA buffer. More...
struct  drm_vmw_fifo_debug_arg
 DRM_VMW_FIFO_DEBUG - Get last FIFO submission. More...
struct  drm_vmw_fence_wait_arg
struct  drm_vmw_rect
 DRM_VMW_CONTROL_STREAM - Control overlays, aka streams. More...
struct  drm_vmw_control_stream_arg
 struct drm_vmw_control_stream_arg More...
struct  drm_vmw_cursor_bypass_arg
 struct drm_vmw_cursor_bypass_arg More...
struct  drm_vmw_stream_arg
 DRM_VMW_CLAIM_STREAM - Claim a single stream. More...
struct  drm_vmw_update_layout_arg
 DRM_VMW_UNREF_STREAM - Unclaim a stream. More...

Defines

#define DRM_VMW_MAX_SURFACE_FACES   6
#define DRM_VMW_MAX_MIP_LEVELS   24
#define DRM_VMW_EXT_NAME_LEN   128
#define DRM_VMW_GET_PARAM   0
#define DRM_VMW_ALLOC_DMABUF   1
#define DRM_VMW_UNREF_DMABUF   2
#define DRM_VMW_CURSOR_BYPASS   3
#define DRM_VMW_CONTROL_STREAM   4
#define DRM_VMW_CLAIM_STREAM   5
#define DRM_VMW_UNREF_STREAM   6
#define DRM_VMW_CREATE_CONTEXT   7
#define DRM_VMW_UNREF_CONTEXT   8
#define DRM_VMW_CREATE_SURFACE   9
#define DRM_VMW_UNREF_SURFACE   10
#define DRM_VMW_REF_SURFACE   11
#define DRM_VMW_EXECBUF   12
#define DRM_VMW_FIFO_DEBUG   13
#define DRM_VMW_FENCE_WAIT   14
#define DRM_VMW_UPDATE_LAYOUT   15
#define DRM_VMW_PARAM_NUM_STREAMS   0
 DRM_VMW_GET_PARAM - get device information.
#define DRM_VMW_PARAM_NUM_FREE_STREAMS   1
#define DRM_VMW_PARAM_3D   2
#define DRM_VMW_PARAM_FIFO_OFFSET   3
#define DRM_VMW_PARAM_HW_CAPS   4
#define DRM_VMW_PARAM_FIFO_CAPS   5
#define DRM_VMW_EXECBUF_VERSION   0
 DRM_VMW_UNREF_SURFACE - Unreference a host surface.
#define DRM_VMW_CURSOR_BYPASS_ALL   (1 << 0)
 DRM_VMW_CURSOR_BYPASS - Give extra information about cursor bypass.
#define DRM_VMW_CURSOR_BYPASS_FLAGS   (1)

Class Documentation

struct drm_vmw_getparam_arg

struct drm_vmw_getparam_arg

: Returned value. //Out

Parameters:
Parameter to query. //In.

Argument to the DRM_VMW_GET_PARAM Ioctl.

Definition at line 85 of file vmwgfx_drm.h.

Class Members
uint32_t pad64
uint32_t param
uint64_t value
struct drm_vmw_extension_rep

DRM_VMW_EXTENSION - Query device extensions.

struct drm_vmw_extension_rep

: The queried extension exists. : Ioctl number of the first ioctl in the extension. : Offset to any space in the DRI SAREA used by the extension. : Major version number of the extension. : Minor version number of the extension. : Patch level version number of the extension.

Output argument to the DRM_VMW_EXTENSION Ioctl.

Definition at line 110 of file vmwgfx_drm.h.

Class Members
uint32_t driver_ioctl_offset
uint32_t driver_sarea_offset
int32_t exists
uint32_t major
uint32_t minor
uint32_t pad64
uint32_t pl
union drm_vmw_extension_arg

union drm_vmw_extension_arg

- Ascii name of the extension to be queried. //In - Reply as defined above. //Out

Argument to the DRM_VMW_EXTENSION Ioctl.

Definition at line 129 of file vmwgfx_drm.h.

Class Members
char extension
struct drm_vmw_context_arg

DRM_VMW_CREATE_CONTEXT - Create a host context.

Allocates a device unique context id, and queues a create context command for the host. Does not wait for host completion. struct drm_vmw_context_arg

: Device unique context ID.

Output argument to the DRM_VMW_CREATE_CONTEXT Ioctl. Input argument to the DRM_VMW_UNREF_CONTEXT Ioctl.

Definition at line 151 of file vmwgfx_drm.h.

Class Members
int32_t cid
uint32_t pad64
struct drm_vmw_surface_create_req

DRM_VMW_UNREF_CONTEXT - Create a host context.

Frees a global context id, and queues a destroy host command for the host. Does not wait for host completion. The context ID can be used directly in the command stream and shows up as the same context ID on the host. DRM_VMW_CREATE_SURFACE - Create a host suface.

Allocates a device unique surface id, and queues a create surface command for the host. Does not wait for host completion. The surface ID can be used directly in the command stream and shows up as the same surface ID on the host. struct drm_wmv_surface_create_req

: Surface flags as understood by the host. : Surface format as understood by the host. : Number of mip levels for each face. An unused face should have 0 encoded. : Address of a user-space array of sruct drm_vmw_size cast to an uint64_t for 32-64 bit compatibility. The size of the array should equal the total number of mipmap levels. : Boolean whether other clients (as identified by file descriptors) may reference this surface. : Boolean whether the surface is intended to be used as a scanout.

Input data to the DRM_VMW_CREATE_SURFACE Ioctl. Output data from the DRM_VMW_REF_SURFACE Ioctl.

Definition at line 194 of file vmwgfx_drm.h.

Class Members
uint32_t flags
uint32_t format
uint32_t mip_levels
int32_t scanout
int32_t shareable
uint64_t size_addr
struct drm_vmw_surface_arg

struct drm_wmv_surface_arg

: Surface id of created surface or surface to destroy or reference.

Output data from the DRM_VMW_CREATE_SURFACE Ioctl. Input argument to the DRM_VMW_UNREF_SURFACE Ioctl. Input argument to the DRM_VMW_REF_SURFACE Ioctl.

Definition at line 213 of file vmwgfx_drm.h.

Class Members
uint32_t pad64
int32_t sid
struct drm_vmw_size

struct drm_vmw_size ioctl.

- mip level width - mip level height - mip level depth

Description of a mip level. Input data to the DRM_WMW_CREATE_SURFACE Ioctl.

Definition at line 229 of file vmwgfx_drm.h.

Class Members
uint32_t depth
uint32_t height
uint32_t pad64
uint32_t width
union drm_vmw_surface_create_arg

union drm_vmw_surface_create_arg

: Output data as described above. : Input data as described above.

Argument to the DRM_VMW_CREATE_SURFACE Ioctl.

Definition at line 245 of file vmwgfx_drm.h.

union drm_vmw_surface_reference_arg

DRM_VMW_REF_SURFACE - Reference a host surface.

Puts a reference on a host surface with a give sid, as previously returned by the DRM_VMW_CREATE_SURFACE ioctl. A reference will make sure the surface isn't destroyed while we hold it and will allow the calling client to use the surface ID in the command stream.

On successful return, the Ioctl returns the surface information given in the DRM_VMW_CREATE_SURFACE ioctl. union drm_vmw_surface_reference_arg

: Output data as described above. : Input data as described above.

Argument to the DRM_VMW_REF_SURFACE Ioctl.

Definition at line 273 of file vmwgfx_drm.h.

struct drm_vmw_execbuf_arg

Definition at line 318 of file vmwgfx_drm.h.

Class Members
uint32_t command_size
uint64_t commands
uint64_t fence_rep
uint32_t flags
uint32_t throttle_us
uint32_t version
struct drm_vmw_fence_rep

struct drm_vmw_fence_rep

: Fence sequence associated with a command submission. : This member should've been set to -EFAULT on submission. The following actions should be take on completion: error == -EFAULT: Fence communication failed. The host is synchronized. Use the last fence id read from the FIFO fence register. error != 0 && error != -EFAULT: Fence submission failed. The host is synchronized. Use the fence_seq member. error == 0: All is OK, The host may not be synchronized. Use the fence_seq member.

Input / Output data to the DRM_VMW_EXECBUF Ioctl.

Definition at line 343 of file vmwgfx_drm.h.

Class Members
int32_t error
uint64_t fence_seq
uint32_t pad64
struct drm_vmw_alloc_dmabuf_req

DRM_VMW_ALLOC_DMABUF.

Allocate a DMA buffer that is visible also to the host. NOTE: The buffer is identified by a handle and an offset, which are private to the guest, but useable in the command stream. The guest kernel may translate these and patch up the command stream accordingly. In the future, the offset may be zero at all times, or it may disappear from the interface before it is fixed.

The DMA buffer may stay user-space mapped in the guest at all times, and is thus suitable for sub-allocation.

DMA buffers are mapped using the mmap() syscall on the drm device. struct drm_vmw_alloc_dmabuf_req

: Required minimum size of the buffer.

Input data to the DRM_VMW_ALLOC_DMABUF Ioctl.

Definition at line 375 of file vmwgfx_drm.h.

Class Members
uint32_t pad64
uint32_t size
struct drm_vmw_dmabuf_rep

struct drm_vmw_dmabuf_rep

: Offset to use in the mmap() call used to map the buffer. : Handle unique to this buffer. Used for unreferencing. : GMR id to use in the command stream when this buffer is referenced. See not above. : Offset to use in the command stream when this buffer is referenced. See note above.

Output data from the DRM_VMW_ALLOC_DMABUF Ioctl.

Definition at line 393 of file vmwgfx_drm.h.

Class Members
uint32_t cur_gmr_id
uint32_t cur_gmr_offset
uint32_t handle
uint64_t map_handle
uint32_t pad64
union drm_vmw_alloc_dmabuf_arg

union drm_vmw_dmabuf_arg

: Input data as described above. : Output data as described above.

Argument to the DRM_VMW_ALLOC_DMABUF Ioctl.

Definition at line 410 of file vmwgfx_drm.h.

struct drm_vmw_unref_dmabuf_arg

DRM_VMW_UNREF_DMABUF - Free a DMA buffer.

struct drm_vmw_unref_dmabuf_arg

: Handle indicating what buffer to free. Obtained from the DRM_VMW_ALLOC_DMABUF Ioctl.

Argument to the DRM_VMW_UNREF_DMABUF Ioctl.

Definition at line 430 of file vmwgfx_drm.h.

Class Members
uint32_t handle
uint32_t pad64
struct drm_vmw_fifo_debug_arg

DRM_VMW_FIFO_DEBUG - Get last FIFO submission.

This IOCTL copies the last FIFO submission directly out of the FIFO buffer. struct drm_vmw_fifo_debug_arg

: User space address of a debug_buffer cast to an uint64_t //In : Size in bytes of debug buffer //In : Number of bytes copied to the buffer // Out : Boolean indicating that the fifo contents did not fit. //Out

Argument to the DRM_VMW_FIFO_DEBUG Ioctl.

Definition at line 453 of file vmwgfx_drm.h.

Class Members
uint64_t debug_buffer
uint32_t debug_buffer_size
int32_t did_not_fit
uint32_t pad64
uint32_t used_size
struct drm_vmw_fence_wait_arg

Definition at line 461 of file vmwgfx_drm.h.

Class Members
int32_t cookie_valid
uint64_t kernel_cookie
int32_t pad64
uint64_t sequence
struct drm_vmw_rect

DRM_VMW_CONTROL_STREAM - Control overlays, aka streams.

This IOCTL controls the overlay units of the svga device. The SVGA overlay units does not work like regular hardware units in that they do not automaticaly read back the contents of the given dma buffer. But instead only read back for each call to this ioctl, and at any point between this call being made and a following call that either changes the buffer or disables the stream. struct drm_vmw_rect

Defines a rectangle. Used in the overlay ioctl to define source and destination rectangle.

Definition at line 487 of file vmwgfx_drm.h.

Class Members
uint32_t h
uint32_t w
int32_t x
int32_t y
struct drm_vmw_control_stream_arg

struct drm_vmw_control_stream_arg

: Stearm to control : If false all following arguments are ignored. : Handle to buffer for getting data from. : Format of the overlay as understood by the host. : Width of the overlay. : Height of the overlay. : Size of the overlay in bytes. : Array of pitches, the two last are only used for YUV12 formats. : Offset from start of dma buffer to overlay. : Source rect, must be within the defined area above. : Destination rect, x and y may be negative.

Argument to the DRM_VMW_CONTROL_STREAM Ioctl.

Definition at line 512 of file vmwgfx_drm.h.

Class Members
uint32_t color_key
uint32_t enabled
uint32_t flags
int32_t format
uint32_t handle
uint32_t height
uint32_t offset
uint32_t pad64
uint32_t pitch
uint32_t size
uint32_t stream_id
uint32_t width
struct drm_vmw_cursor_bypass_arg

struct drm_vmw_cursor_bypass_arg

: Flags. : Crtc id, only used if DMR_CURSOR_BYPASS_ALL isn't passed. : X position of cursor. : Y position of cursor. : X hotspot. : Y hotspot.

Argument to the DRM_VMW_CURSOR_BYPASS Ioctl.

Definition at line 554 of file vmwgfx_drm.h.

Class Members
uint32_t crtc_id
uint32_t flags
int32_t xhot
int32_t xpos
int32_t yhot
int32_t ypos
struct drm_vmw_stream_arg

DRM_VMW_CLAIM_STREAM - Claim a single stream.

struct drm_vmw_context_arg

: Device unique context ID.

Output argument to the DRM_VMW_CREATE_CONTEXT Ioctl. Input argument to the DRM_VMW_UNREF_CONTEXT Ioctl.

Definition at line 577 of file vmwgfx_drm.h.

Class Members
uint32_t pad64
uint32_t stream_id
struct drm_vmw_update_layout_arg

DRM_VMW_UNREF_STREAM - Unclaim a stream.

Return a single stream that was claimed by this process. Also makes sure that the stream has been stopped. DRM_VMW_UPDATE_LAYOUT - Update layout

Updates the prefered modes and connection status for connectors. The command conisits of one drm_vmw_update_layout_arg pointing out a array of num_outputs drm_vmw_rect's. struct drm_vmw_update_layout_arg

: number of active : pointer to array of drm_vmw_rect

Input argument to the DRM_VMW_UPDATE_LAYOUT Ioctl.

Definition at line 608 of file vmwgfx_drm.h.

Class Members
uint32_t num_outputs
uint32_t pad64
uint64_t rects

Define Documentation

#define DRM_VMW_ALLOC_DMABUF   1

Definition at line 37 of file vmwgfx_drm.h.

#define DRM_VMW_CLAIM_STREAM   5

Definition at line 42 of file vmwgfx_drm.h.

#define DRM_VMW_CONTROL_STREAM   4

Definition at line 41 of file vmwgfx_drm.h.

#define DRM_VMW_CREATE_CONTEXT   7

Definition at line 45 of file vmwgfx_drm.h.

#define DRM_VMW_CREATE_SURFACE   9

Definition at line 47 of file vmwgfx_drm.h.

#define DRM_VMW_CURSOR_BYPASS   3

Definition at line 39 of file vmwgfx_drm.h.

#define DRM_VMW_CURSOR_BYPASS_ALL   (1 << 0)

DRM_VMW_CURSOR_BYPASS - Give extra information about cursor bypass.

Definition at line 538 of file vmwgfx_drm.h.

#define DRM_VMW_CURSOR_BYPASS_FLAGS   (1)

Definition at line 539 of file vmwgfx_drm.h.

#define DRM_VMW_EXECBUF   12

Definition at line 50 of file vmwgfx_drm.h.

#define DRM_VMW_EXECBUF_VERSION   0

DRM_VMW_UNREF_SURFACE - Unreference a host surface.

Clear a reference previously put on a host surface. When all references are gone, including the one implicitly placed on creation, a destroy surface command will be queued for the host. Does not wait for completion. DRM_VMW_EXECBUF

Submit a command buffer for execution on the host, and return a fence sequence that when signaled, indicates that the command buffer has executed. struct drm_vmw_execbuf_arg

: User-space address of a command buffer cast to an uint64_t. -size: Size in bytes of the command buffer. -us: Sleep until software is less than microseconds ahead of hardware. The driver may round this value to the nearest kernel tick. : User-space address of a struct drm_vmw_fence_rep cast to an uint64_t.

Version:
: Allows expanding the execbuf ioctl parameters without breaking backwards compatibility, since user-space will always tell the kernel which version it uses. : Execbuf flags. None currently.

Argument to the DRM_VMW_EXECBUF Ioctl.

Definition at line 316 of file vmwgfx_drm.h.

#define DRM_VMW_EXT_NAME_LEN   128

Definition at line 34 of file vmwgfx_drm.h.

#define DRM_VMW_FENCE_WAIT   14

Definition at line 52 of file vmwgfx_drm.h.

#define DRM_VMW_FIFO_DEBUG   13

Definition at line 51 of file vmwgfx_drm.h.

#define DRM_VMW_GET_PARAM   0

Definition at line 36 of file vmwgfx_drm.h.

#define DRM_VMW_MAX_MIP_LEVELS   24

Definition at line 32 of file vmwgfx_drm.h.

#define DRM_VMW_MAX_SURFACE_FACES   6

Definition at line 31 of file vmwgfx_drm.h.

#define DRM_VMW_PARAM_3D   2

Definition at line 71 of file vmwgfx_drm.h.

#define DRM_VMW_PARAM_FIFO_CAPS   5

Definition at line 74 of file vmwgfx_drm.h.

#define DRM_VMW_PARAM_FIFO_OFFSET   3

Definition at line 72 of file vmwgfx_drm.h.

#define DRM_VMW_PARAM_HW_CAPS   4

Definition at line 73 of file vmwgfx_drm.h.

Definition at line 70 of file vmwgfx_drm.h.

#define DRM_VMW_PARAM_NUM_STREAMS   0

DRM_VMW_GET_PARAM - get device information.

DRM_VMW_PARAM_FIFO_OFFSET: Offset to use to map the first page of the FIFO read-only. The fifo is mapped using the mmap() system call on the drm device.

DRM_VMW_PARAM_OVERLAY_IOCTL: Does the driver support the overlay ioctl.

Definition at line 69 of file vmwgfx_drm.h.

#define DRM_VMW_REF_SURFACE   11

Definition at line 49 of file vmwgfx_drm.h.

#define DRM_VMW_UNREF_CONTEXT   8

Definition at line 46 of file vmwgfx_drm.h.

#define DRM_VMW_UNREF_DMABUF   2

Definition at line 38 of file vmwgfx_drm.h.

#define DRM_VMW_UNREF_STREAM   6

Definition at line 43 of file vmwgfx_drm.h.

#define DRM_VMW_UNREF_SURFACE   10

Definition at line 48 of file vmwgfx_drm.h.

#define DRM_VMW_UPDATE_LAYOUT   15

Definition at line 54 of file vmwgfx_drm.h.