diff options
author | Alex Deucher <alex@samba.(none)> | 2008-02-24 04:46:10 -0500 |
---|---|---|
committer | Alex Deucher <alex@samba.(none)> | 2008-02-24 04:46:10 -0500 |
commit | d4c20f33ad6a1f88615cd7e09ad3638896873f9e (patch) | |
tree | 62202d493cbf95558c3ece94be6ceb62bea33fb1 /src/radeon_commonfuncs.c | |
parent | e52f1c8d2647b81d891ec0728dd582941a76c83f (diff) |
R300: replace magic numbers in cache flush
Diffstat (limited to 'src/radeon_commonfuncs.c')
-rw-r--r-- | src/radeon_commonfuncs.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/radeon_commonfuncs.c b/src/radeon_commonfuncs.c index a626bbd4..8635dc04 100644 --- a/src/radeon_commonfuncs.c +++ b/src/radeon_commonfuncs.c @@ -59,9 +59,9 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn) if (IS_R300_VARIANT || IS_AVIVO_VARIANT) { BEGIN_ACCEL(3); - OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA); - OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, 0x3); - OUT_ACCEL_REG(R300_WAIT_UNTIL, 0x30000); + OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D | R300_DC_FREE_3D); + OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, R300_ZC_FLUSH | R300_ZC_FREE); + OUT_ACCEL_REG(R300_WAIT_UNTIL, R300_WAIT_2D_IDLECLEAN | R300_WAIT_3D_IDLECLEAN); FINISH_ACCEL(); BEGIN_ACCEL(3); @@ -71,15 +71,15 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn) FINISH_ACCEL(); BEGIN_ACCEL(3); - OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA); - OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, 0x3); - OUT_ACCEL_REG(R300_WAIT_UNTIL, 0x30000); + OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D | R300_DC_FREE_3D); + OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, R300_ZC_FLUSH | R300_ZC_FREE); + OUT_ACCEL_REG(R300_WAIT_UNTIL, R300_WAIT_2D_IDLECLEAN | R300_WAIT_3D_IDLECLEAN); FINISH_ACCEL(); BEGIN_ACCEL(5); OUT_ACCEL_REG(R300_GB_AA_CONFIG, 0x0); - OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA); - OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, 0x3); + OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D | R300_DC_FREE_3D); + OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, R300_ZC_FLUSH | R300_ZC_FREE); OUT_ACCEL_REG(R300_GB_MSPOS0, 0x78888888); OUT_ACCEL_REG(R300_GB_MSPOS1, 0x08888888); FINISH_ACCEL(); @@ -116,7 +116,7 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn) BEGIN_ACCEL(12); OUT_ACCEL_REG(R300_RB3D_ZSTENCILCNTL, 0x0); - OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, 0x3); + OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, R300_ZC_FLUSH | R300_ZC_FREE); OUT_ACCEL_REG(R300_RB3D_BW_CNTL, 0x0); OUT_ACCEL_REG(R300_RB3D_ZCNTL, 0x0); OUT_ACCEL_REG(R300_RB3D_ZTOP, 0x0); @@ -124,10 +124,10 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn) OUT_ACCEL_REG(R300_RB3D_AARESOLVE_CTL, 0x0); OUT_ACCEL_REG(R300_RB3D_COLOR_CHANNEL_MASK, 0xf); - OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA); + OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D | R300_DC_FREE_3D); OUT_ACCEL_REG(R300_RB3D_CCTL, 0x0); OUT_ACCEL_REG(R300_RB3D_DITHER_CTL, 0x0); - OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA); + OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D | R300_DC_FREE_3D); FINISH_ACCEL(); BEGIN_ACCEL(7); |