diff options
author | Luc Verhaegen <libv@skynet.be> | 2010-03-20 04:13:57 +0100 |
---|---|---|
committer | Luc Verhaegen <libv@skynet.be> | 2010-03-20 04:13:57 +0100 |
commit | 2d9ff0c54831fcd67e0ef0af460238099ecd7152 (patch) | |
tree | 2d8ebba85b0ffb6daf3a2b3bf8a41e19b0fbec6c | |
parent | 30fdda6c3ef81007fe72ef9da5430563f34e91e8 (diff) |
DRM: clean up unused structs and struct members.
-rw-r--r-- | dri/via_ioctl.c | 3 | ||||
-rw-r--r-- | drm/via_dmablit.c | 4 | ||||
-rw-r--r-- | drm/via_dmablit.h | 4 | ||||
-rw-r--r-- | drm/via_drm.h | 50 | ||||
-rw-r--r-- | drm/via_drv.h | 1 |
5 files changed, 4 insertions, 58 deletions
diff --git a/dri/via_ioctl.c b/dri/via_ioctl.c index 27895b6..d55d2bf 100644 --- a/dri/via_ioctl.c +++ b/dri/via_ioctl.c @@ -208,6 +208,9 @@ static void viaClear(GLcontext *ctx, GLbitfield mask) __DRIdrawablePrivate *dPriv = vmesa->driDrawable; struct via_renderbuffer *const vrb = (struct via_renderbuffer *) dPriv->driverPrivate; +#define VIA_FRONT 0x1 +#define VIA_BACK 0x2 +#define VIA_DEPTH 0x4 int flag = 0; GLuint i = 0; GLuint clear_depth_mask = 0xf << 28; diff --git a/drm/via_dmablit.c b/drm/via_dmablit.c index 045ad40..4de9d2f 100644 --- a/drm/via_dmablit.c +++ b/drm/via_dmablit.c @@ -196,9 +196,6 @@ via_free_sg_info(struct pci_dev *pdev, drm_via_sg_info_t *vsg) default: vsg->state = dr_via_sg_init; } - vfree(vsg->bounce_buffer); - vsg->bounce_buffer = NULL; - vsg->free_on_sequence = 0; } /* @@ -586,7 +583,6 @@ via_build_sg_info(struct drm_device *dev, drm_via_sg_info_t *vsg, drm_via_dmabli int ret = 0; vsg->direction = (draw) ? DMA_TO_DEVICE : DMA_FROM_DEVICE; - vsg->bounce_buffer = NULL; vsg->state = dr_via_sg_init; diff --git a/drm/via_dmablit.h b/drm/via_dmablit.h index 7408a54..5f17264 100644 --- a/drm/via_dmablit.h +++ b/drm/via_dmablit.h @@ -35,8 +35,6 @@ #define VIA_NUM_BLIT_ENGINES 2 #define VIA_NUM_BLIT_SLOTS 8 -struct _drm_via_descriptor; - typedef struct _drm_via_sg_info { struct page **pages; unsigned long num_pages; @@ -44,9 +42,7 @@ typedef struct _drm_via_sg_info { int num_desc_pages; int num_desc; enum dma_data_direction direction; - unsigned char *bounce_buffer; dma_addr_t chain_start; - uint32_t free_on_sequence; unsigned int descriptors_per_page; int aborted; enum { diff --git a/drm/via_drm.h b/drm/via_drm.h index 465b429..d69cb36 100644 --- a/drm/via_drm.h +++ b/drm/via_drm.h @@ -28,8 +28,6 @@ #define VIA_DRM_DRIVER_MINOR 0 #define VIA_DRM_DRIVER_PATCHLEVEL 0 -#include <linux/types.h> - /* WARNING: These defines must be the same as what the Xserver uses. * if you change them, you must change the defines in the Xserver. */ @@ -41,24 +39,8 @@ #define __user #endif -#define VIA_NR_SAREA_CLIPRECTS 8 -#define VIA_MAX_CACHELINE_SIZE 64 - -/* Each region is a minimum of 64k, and there are at most 64 of them. - */ -#define VIA_NR_TEX_REGIONS 64 -#define VIA_LOG_MIN_TEX_REGION_SIZE 16 #endif -#define VIA_UPLOAD_TEX0IMAGE 0x1 /* handled clientside */ -#define VIA_UPLOAD_TEX1IMAGE 0x2 /* handled clientside */ -#define VIA_UPLOAD_CTX 0x4 -#define VIA_UPLOAD_BUFFERS 0x8 -#define VIA_UPLOAD_TEX0 0x10 -#define VIA_UPLOAD_TEX1 0x20 -#define VIA_UPLOAD_CLIPRECTS 0x40 -#define VIA_UPLOAD_ALL 0xff - /* VIA specific ioctls */ #define DRM_VIA_ALLOCMEM 0x00 #define DRM_VIA_FREEMEM 0x01 @@ -92,19 +74,6 @@ #define DRM_IOCTL_VIA_DMA_BLIT DRM_IOW(DRM_COMMAND_BASE + DRM_VIA_DMA_BLIT, drm_via_dmablit_t) #define DRM_IOCTL_VIA_BLIT_SYNC DRM_IOW(DRM_COMMAND_BASE + DRM_VIA_BLIT_SYNC, drm_via_blitsync_t) -/* Indices into buf.Setup where various bits of state are mirrored per - * context and per buffer. These can be fired at the card as a unit, - * or in a piecewise fashion as required. - */ - -#define VIA_TEX_SETUP_SIZE 8 - -/* Flags for clear ioctl - */ -#define VIA_FRONT 0x1 -#define VIA_BACK 0x2 -#define VIA_DEPTH 0x4 -#define VIA_STENCIL 0x8 #define VIA_MEM_VIDEO 0 /* matches drm constant */ #define VIA_MEM_AGP 1 /* matches drm constant */ #define VIA_MEM_SYSTEM 2 @@ -158,26 +127,10 @@ typedef struct _drm_via_cmdbuffer { unsigned long size; } drm_via_cmdbuffer_t; -/* Warning: If you change the SAREA structure you must change the Xserver - * structure as well */ - -typedef struct _drm_via_tex_region { - unsigned char next, prev; /* indices to form a circular LRU */ - unsigned char inUse; /* owned by a client, or free? */ - int age; /* tracked by clients to update local LRU's */ -} drm_via_tex_region_t; - typedef struct _drm_via_sarea { - unsigned int dirty; - unsigned int nbox; - struct drm_clip_rect boxes[VIA_NR_SAREA_CLIPRECTS]; - drm_via_tex_region_t texList[VIA_NR_TEX_REGIONS + 1]; - int texAge; /* last time texture was uploaded */ int ctxOwner; /* last context to upload state */ - int vertexPrim; - /* Used by the 3d driver only at this point, for pageflipping: - */ + /* Used by the 3d driver only at this point, for pageflipping: */ unsigned int pfCurrentOffset; } drm_via_sarea_t; @@ -213,7 +166,6 @@ struct drm_via_wait_irq_request { unsigned irq; via_irq_seq_type_t type; __u32 sequence; - __u32 signal; }; typedef union drm_via_irqwait { diff --git a/drm/via_drv.h b/drm/via_drv.h index e4f7730..775d354 100644 --- a/drm/via_drv.h +++ b/drm/via_drv.h @@ -84,7 +84,6 @@ typedef struct drm_via_private { uint32_t irq_enable_mask; uint32_t irq_pending_mask; int *irq_map; - unsigned int idle_fault; struct drm_sman sman; int vram_initialized; int agp_initialized; |