From: Christoph Bill Date: Thu, 1 Mar 2007 19:45:04 +0000 (+0100) Subject: r300: Use reg definition when available & add missing reg definition. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0d2a68fc61ed6e47a7a8ae4197596b96bb11f886;p=mesa.git r300: Use reg definition when available & add missing reg definition. --- diff --git a/src/mesa/drivers/dri/r300/r300_ioctl.c b/src/mesa/drivers/dri/r300/r300_ioctl.c index c5ad0260457..6fa34ee482a 100644 --- a/src/mesa/drivers/dri/r300/r300_ioctl.c +++ b/src/mesa/drivers/dri/r300/r300_ioctl.c @@ -228,7 +228,7 @@ static void r300EmitClearState(GLcontext * ctx) e32(0); R300_STATECHANGE(r300, unk221C); - reg_start(0x221C, 0); + reg_start(R300_VAP_UNKNOWN_221C, 0); e32(R300_221C_CLEAR); R300_STATECHANGE(r300, ps); diff --git a/src/mesa/drivers/dri/r300/r300_reg.h b/src/mesa/drivers/dri/r300/r300_reg.h index 6abcfa45698..9de4c4d68b5 100644 --- a/src/mesa/drivers/dri/r300/r300_reg.h +++ b/src/mesa/drivers/dri/r300/r300_reg.h @@ -63,6 +63,12 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. #define R300_SE_VPORT_ZOFFSET 0x1DAC +/* + * Vertex Array Processing (VAP) Control + * Stolen from r200 code from Christoph Brill (It's a guess!) + */ +#define R300_VAP_CNTL 0x2080 + /* This register is written directly and also starts data section * in many 3d CP_PACKET3's */ @@ -135,7 +141,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. /* gap */ -#define R300_VAP_CNTL 0x2140 +#define R300_VAP_CNTL_STATUS 0x2140 # define R300_VC_NO_SWAP (0 << 0) # define R300_VC_16BIT_SWAP (1 << 0) # define R300_VC_32BIT_SWAP (2 << 0) diff --git a/src/mesa/drivers/dri/r300/radeon_mm.c b/src/mesa/drivers/dri/r300/radeon_mm.c index f86a1b4e72e..32ed1f43939 100644 --- a/src/mesa/drivers/dri/r300/radeon_mm.c +++ b/src/mesa/drivers/dri/r300/radeon_mm.c @@ -283,7 +283,7 @@ static void emit_lin_cp(r300ContextPtr rmesa, unsigned long dst, unsigned long s size -= cp_size; } - reg_start(0x4e4c,0); + reg_start(R300_RB3D_DSTCACHE_CTLSTAT,0); e32(0x0000000a); reg_start(0x342c,0);