summaryrefslogtreecommitdiff
path: root/src/via_driver.h
diff options
context:
space:
mode:
authorThomas Hellstrom <unichrome@shipmail.org>2004-09-02 08:30:43 +0000
committerThomas Hellstrom <unichrome@shipmail.org>2004-09-02 08:30:43 +0000
commit222c023790a1669bb25bbaf2ed3fe0a82a98944a (patch)
tree23c3fcc1d0137c58a2f3417bba7633273ab54549 /src/via_driver.h
parent363a6257f79ce7c85586be4347a0d3c5524f2821 (diff)
1. Temporarily disable the AGP ringbuffer init since it seems to be able to
wreak havoc among current dri OpenGL Clients. Use #define ENABLE_AGP_RINGBUF to enable 2. Make XAA save certain small parts of the 2D engine state in software to automatically restore it when it is used. DRI clients may alter it. Removed the old hacky context save used by XvMC. 3. Moved XAA to use command buffers. These are dispatched with AGP DMA if available, otherwise using PCI. See the define above. 4. Made XAA wait for engine idle before issuing commands over PCI. This will otherwise stall the processor until the video engine becomes idle, which is BAD for interrupt latency.
Diffstat (limited to 'src/via_driver.h')
-rw-r--r--src/via_driver.h25
1 files changed, 15 insertions, 10 deletions
diff --git a/src/via_driver.h b/src/via_driver.h
index 697d0ab..7176886 100644
--- a/src/via_driver.h
+++ b/src/via_driver.h
@@ -92,6 +92,7 @@
#endif /* X_USE_LINEARFB */
#define VIA_CURSOR_SIZE (4 * 1024)
#define VIA_VQ_SIZE (256 * 1024)
+#define VIA_CBUFFERSIZE 512
typedef struct {
unsigned char SR08, SR0A, SR0F;
@@ -161,14 +162,6 @@ typedef struct {
#define VIA_XVMC_MAX_CONTEXTS 4
#define VIA_XVMC_MAX_SURFACES 20
-typedef struct {
- CARD32 srcColorKey;
- CARD32 keyControl;
- CARD32 geMode;
- CARD32 srcBase;
- CARD32 dstBase;
- CARD32 pitch;
-} ViaXvMCBlitterContext;
typedef struct {
VIAMem memory_ref;
@@ -189,11 +182,20 @@ typedef struct {
unsigned sAreaSize;
drmAddress sAreaAddr;
unsigned activePorts;
- ViaXvMCBlitterContext bc;
}ViaXvMC, *ViaXvMCPtr;
#endif
+typedef struct _twodContext {
+ CARD32 mode;
+} ViaTwodContext;
+
+typedef struct{
+ unsigned curPos;
+ CARD32 buffer[VIA_CBUFFERSIZE];
+ int status;
+} ViaCBuffer;
+
typedef struct _VIA {
VIARegRec SavedReg;
VIARegRec ModeReg;
@@ -262,7 +264,10 @@ typedef struct _VIA {
CARD32 SavedPattern0;
CARD32 SavedPattern1;
CARD32 SavedPatternAddr;
-
+ int justSetup;
+ ViaTwodContext td;
+ ViaCBuffer cBuf;
+
/* BIOS Info Ptr */
VIABIOSInfoPtr pBIOSInfo;
struct ViaCardIdStruct* Id;