xf86-video-ati: Branch 'master'

Alex Deucher agd5f at kemper.freedesktop.org
Fri Sep 25 16:07:39 PDT 2009


 src/radeon_commonfuncs.c |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 7968e1fb89f6b59d1654df48249bf4b81990c008
Author: Alex Deucher <alexdeucher at gmail.com>
Date:   Fri Sep 25 19:05:38 2009 -0400

    radeon: fix segfault in MMIO path in RADEONInit3DEngine
    
    fixes fdo bug 24158.
    
    Signed-off-by: Alex Deucher <alexdeucher at gmail.com>

diff --git a/src/radeon_commonfuncs.c b/src/radeon_commonfuncs.c
index c0625c4..8c46235 100644
--- a/src/radeon_commonfuncs.c
+++ b/src/radeon_commonfuncs.c
@@ -82,7 +82,7 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn)
 	case 1: gb_tile_config |= R300_PIPE_COUNT_RV350; break;
 	}
 
-	if (info->dri->pKernelDRMVersion->version_major < 2) {
+	if (!info->cs) {
 	    size = (info->ChipFamily >= CHIP_FAMILY_R420) ? 5 : 4;
 	    BEGIN_ACCEL(size);
 	    OUT_ACCEL_REG(R300_GB_TILE_CONFIG, gb_tile_config);
@@ -95,8 +95,8 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn)
 	}
 
 	if (IS_R500_3D) {
-	    su_reg_dest = ((1 << info->accel_state->num_gb_pipes) - 1);
-	    if (info->dri->pKernelDRMVersion->version_major < 2) {
+	    if (!info->cs) {
+		su_reg_dest = ((1 << info->accel_state->num_gb_pipes) - 1);
 		BEGIN_ACCEL(2);
 		OUT_ACCEL_REG(R500_SU_REG_DEST, su_reg_dest);
 		OUT_ACCEL_REG(R500_VAP_INDEX_OFFSET, 0);
@@ -116,7 +116,7 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn)
 	OUT_ACCEL_REG(R300_RB3D_ZCACHE_CTLSTAT, R300_ZC_FLUSH | R300_ZC_FREE);
 	FINISH_ACCEL();
 
-	if (info->dri->pKernelDRMVersion->version_major < 2) {
+	if (!info->cs) {
 	    BEGIN_ACCEL(3);
 	    OUT_ACCEL_REG(R300_GB_MSPOS0, ((6 << R300_MS_X0_SHIFT) |
 					   (6 << R300_MS_Y0_SHIFT) |


More information about the xorg-commit mailing list