1450N/A/*
1450N/A * Copyright (c) 2006, 2011, Oracle and/or its affiliates. All rights reserved.
1450N/A */
1450N/A
1450N/A#ifndef _DRM_IO32_H_
1450N/A#define _DRM_IO32_H_
1450N/A
1450N/A#ifdef _MULTI_DATAMODEL
1450N/A
1450N/Atypedef struct drm_version_32 {
1450N/A int version_major; /* Major version */
1450N/A int version_minor; /* Minor version */
1450N/A int version_patchlevel; /* Patch level */
1450N/A uint32_t name_len; /* Length of name buffer */
1450N/A caddr32_t name; /* Name of driver */
1450N/A uint32_t date_len; /* Length of date buffer */
1450N/A caddr32_t date; /* User-space buffer to hold date */
1450N/A uint32_t desc_len; /* Length of desc buffer */
1450N/A caddr32_t desc; /* User-space buffer to hold desc */
1450N/A} drm_version_32_t;
1450N/A
1450N/Atypedef struct drm_unique_32 {
1450N/A uint32_t unique_len; /* Length of unique */
1450N/A caddr32_t unique; /* Unique name for driver instantiation */
1450N/A} drm_unique_32_t;
1450N/A
1450N/Atypedef struct drm_ctx_priv_map_32 {
1450N/A unsigned int ctx_id; /* Context requesting private mapping */
1450N/A caddr32_t handle; /* Handle of map */
1450N/A} drm_ctx_priv_map_32_t;
1450N/A
1450N/Atypedef struct drm_map_32 {
1450N/A unsigned long long offset;
1450N/A unsigned long long handle;
1450N/A uint32_t size;
1450N/A drm_map_type_t type;
1450N/A drm_map_flags_t flags;
1450N/A int mtrr;
1450N/A} drm_map_32_t;
1450N/A
1450N/A
1450N/Atypedef struct drm_client_32 {
1450N/A int idx; /* Which client desired? */
1450N/A int auth; /* Is client authenticated? */
1450N/A uint32_t pid; /* Process ID */
1450N/A uint32_t uid; /* User ID */
1450N/A uint32_t magic; /* Magic */
1450N/A uint32_t iocs; /* Ioctl count */
1450N/A} drm_client_32_t;
1450N/A
1450N/A
1450N/Atypedef struct drm_stats_32 {
1450N/A uint32_t count;
1450N/A struct {
1450N/A uint32_t value;
1450N/A drm_stat_type_t type;
1450N/A } data[15];
1450N/A} drm_stats_32_t;
1450N/A
1450N/A
1450N/Atypedef struct drm_buf_desc_32 {
1450N/A int count; /* Number of buffers of this size */
1450N/A int size; /* Size in bytes */
1450N/A int low_mark; /* Low water mark */
1450N/A int high_mark; /* High water mark */
1450N/A enum drm_buf_flag flags;
1450N/A
1450N/A /*
1450N/A * Start address of where the AGP buffers are
1450N/A * in the AGP aperture
1450N/A */
1450N/A uint32_t agp_start;
1450N/A
1450N/A} drm_buf_desc_32_t;
1450N/A
1450N/Atypedef struct drm_buf_free_32 {
1450N/A int count;
1450N/A uint32_t list;
1450N/A} drm_buf_free_32_t;
1450N/A
1450N/A/*
1450N/A * Used by DRM_IOCTL_MAP_BUFS_32
1450N/A */
1450N/Atypedef struct drm_buf_pub_32 {
1450N/A int idx; /* Index into the master buffer list */
1450N/A int total; /* Buffer size */
1450N/A int used; /* Amount of buffer in use (for DMA) */
1450N/A uint32_t address; /* Address of buffer */
1450N/A} drm_buf_pub_32_t;
1450N/A
1450N/Atypedef struct drm_buf_map_32 {
1450N/A int count; /* Length of the buffer list */
1450N/A#if defined(__cplusplus)
1450N/A uint32_t c_virtual;
1450N/A#else
1450N/A uint32_t virtual; /* Mmap'd area in user-virtual */
1450N/A#endif
1450N/A uint32_t list; /* Buffer information */
1450N/A int fd;
1450N/A} drm_buf_map_32_t;
1450N/A
1450N/Atypedef struct drm_agp_mode_32 {
1450N/A uint32_t mode; /* AGP mode */
1450N/A} drm_agp_mode_32_t;
1450N/A
1450N/Atypedef struct drm_agp_buffer32 {
1450N/A uint32_t size; /* In bytes -- will round to page boundary */
1450N/A uint32_t handle; /* Used for binding / unbinding */
1450N/A uint32_t type; /* Type of memory to allocate */
1450N/A uint32_t physical; /* Physical used by i810 */
1450N/A} drm_agp_buffer_32_t;
1450N/A
1450N/Atypedef struct drm_agp_binding_32 {
1450N/A uint32_t handle; /* From drm_agp_buffer */
1450N/A uint32_t offset; /* In bytes -- will round to page boundary */
1450N/A} drm_agp_binding_32_t;
1450N/A
1450N/Atypedef struct drm_agp_info_32 {
1450N/A int agp_version_major;
1450N/A int agp_version_minor;
1450N/A uint32_t mode;
1450N/A uint32_t aperture_base;
1450N/A uint32_t aperture_size;
1450N/A uint32_t memory_allowed;
1450N/A uint32_t memory_used;
1450N/A unsigned short id_vendor;
1450N/A unsigned short id_device;
1450N/A} drm_agp_info_32_t;
1450N/A
1450N/Atypedef struct drm_scatter_gather_32 {
1450N/A uint32_t size; /* In bytes -- will round to page boundary */
1450N/A uint32_t handle; /* Used for mapping/unmapping */
1450N/A} drm_scatter_gather_32_t;
1450N/A
1450N/Atypedef struct drm_ctx_res_32 {
1450N/A int count;
1450N/A caddr32_t contexts;
1450N/A} drm_ctx_res_32_t;
1450N/A
1450N/Astruct drm_wait_vblank_request_32 {
1450N/A drm_vblank_seq_type_t type;
1450N/A unsigned int sequence;
1450N/A unsigned long signal;
1450N/A};
1450N/Astruct drm_wait_vblank_reply_32 {
1450N/A drm_vblank_seq_type_t type;
1450N/A unsigned int sequence;
1450N/A long tval_sec;
1450N/A long tval_usec;
1450N/A};
1450N/A
1450N/A/*
1450N/A * DRM_IOCTL_WAIT_VBLANK ioctl argument type.
1450N/A *
1450N/A * \sa drmWaitVBlank().
1450N/A */
1450N/Atypedef union drm_wait_vblank_32 {
1450N/A struct drm_wait_vblank_request_32 request;
1450N/A struct drm_wait_vblank_reply_32 reply;
1450N/A} drm_wait_vblank_32_t;
1450N/A
1450N/A
1450N/A#endif /* _MULTI_DATAMODEL */
1450N/A
1450N/A#endif /* _DRM_IO32_H_ */