From ea944f38dcfd871b27345698afea1cb986ecb049 Mon Sep 17 00:00:00 2001 From: Alex Deucher Date: Wed, 27 Feb 2008 14:37:52 -0500 Subject: R300+: update RADEONCP_REFRESH() to reflect new location of scissor regs --- src/radeon.h | 17 ++++++++++++----- src/radeon_accel.c | 8 ++++++-- 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/src/radeon.h b/src/radeon.h index aba3c0f2..9c83a4fb 100644 --- a/src/radeon.h +++ b/src/radeon.h @@ -998,11 +998,18 @@ do { \ info->needCacheFlush = FALSE; \ } \ RADEON_WAIT_UNTIL_IDLE(); \ - BEGIN_RING(6); \ - OUT_RING_REG(RADEON_RE_TOP_LEFT, info->re_top_left); \ - OUT_RING_REG(RADEON_RE_WIDTH_HEIGHT, info->re_width_height); \ - OUT_RING_REG(RADEON_AUX_SC_CNTL, info->aux_sc_cntl); \ - ADVANCE_RING(); \ + if (info->ChipFamily <= CHIP_FAMILY_RV280) { \ + BEGIN_RING(6); \ + OUT_RING_REG(RADEON_RE_TOP_LEFT, info->re_top_left); \ + OUT_RING_REG(RADEON_RE_WIDTH_HEIGHT, info->re_width_height); \ + OUT_RING_REG(RADEON_AUX_SC_CNTL, info->aux_sc_cntl); \ + ADVANCE_RING(); \ + } else { \ + BEGIN_RING(4); \ + OUT_RING_REG(R300_SC_SCISSOR0, info->re_top_left); \ + OUT_RING_REG(R300_SC_SCISSOR1, info->re_width_height); \ + ADVANCE_RING(); \ + } \ info->CPInUse = TRUE; \ } \ } while (0) diff --git a/src/radeon_accel.c b/src/radeon_accel.c index 8b2f167f..015d1763 100644 --- a/src/radeon_accel.c +++ b/src/radeon_accel.c @@ -390,8 +390,12 @@ void RADEONEngineInit(ScrnInfoPtr pScrn) info->sc_bottom = RADEON_DEFAULT_SC_BOTTOM_MAX; info->re_top_left = 0x00000000; - info->re_width_height = ((0x7ff << RADEON_RE_WIDTH_SHIFT) | - (0x7ff << RADEON_RE_HEIGHT_SHIFT)); + if (info->ChipFamily <= CHIP_FAMILY_RV280) + info->re_width_height = ((0x7ff << RADEON_RE_WIDTH_SHIFT) | + (0x7ff << RADEON_RE_HEIGHT_SHIFT)); + else + info->re_width_height = ((8191 << R300_SCISSOR_X_SHIFT) | + (8191 << R300_SCISSOR_Y_SHIFT)); info->aux_sc_cntl = 0x00000000; #endif -- cgit v1.2.3