diff options
author | =?utf-8?q?Michel_D=C3=A4nzer?= <michel@tungstengraphics.com> | 2006-10-24 23:04:19 +1000 |
---|---|---|
committer | airlied <airlied@linux.ie> | 2006-12-07 15:53:28 +1100 |
commit | bea5679f9cb97b7e41786c8500df56665cd21e56 (patch) | |
tree | 8259fc9d75730be3db028892f0da991dec54e37e /drivers/char/drm/drm.h | |
parent | 68815bad7239989d92f315c10d9ef65a11945a75 (diff) |
drm: Add support for tracking drawable information to core
Actually make the existing ioctls for adding and removing drawables do
something useful, and add another ioctl for the X server to update drawable
information. The only kind of drawable information tracked so far is cliprects.
Only reallocate cliprect memory if the number of cliprects changes.
Also improve diagnostic output.
hook up drm ioctl update draw
export drm_get_drawable_info symbol
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/drm/drm.h')
-rw-r--r-- | drivers/char/drm/drm.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/drivers/char/drm/drm.h b/drivers/char/drm/drm.h index 077d0b1914a..07a699029c3 100644 --- a/drivers/char/drm/drm.h +++ b/drivers/char/drm/drm.h @@ -117,6 +117,14 @@ typedef struct drm_clip_rect { } drm_clip_rect_t; /** + * Drawable information. + */ +typedef struct drm_drawable_info { + unsigned int num_rects; + drm_clip_rect_t *rects; +} drm_drawable_info_t; + +/** * Texture region, */ typedef struct drm_tex_region { @@ -444,6 +452,20 @@ typedef struct drm_draw { } drm_draw_t; /** + * DRM_IOCTL_UPDATE_DRAW ioctl argument type. + */ +typedef enum { + DRM_DRAWABLE_CLIPRECTS, +} drm_drawable_info_type_t; + +typedef struct drm_update_draw { + drm_drawable_t handle; + unsigned int type; + unsigned int num; + unsigned long long data; +} drm_update_draw_t; + +/** * DRM_IOCTL_GET_MAGIC and DRM_IOCTL_AUTH_MAGIC ioctl argument type. */ typedef struct drm_auth { @@ -625,6 +647,8 @@ typedef struct drm_set_version { #define DRM_IOCTL_WAIT_VBLANK DRM_IOWR(0x3a, drm_wait_vblank_t) +#define DRM_IOCTL_UPDATE_DRAW DRM_IOW(0x3f, drm_update_draw_t) + /** * Device specific ioctls should only be in their respective headers * The device specific ioctl range is from 0x40 to 0x79. |