xf86-video-ati: Branch 'atombios-support' - 2 commits

Alex Deucher agd5f at kemper.freedesktop.org
Wed Nov 21 14:09:30 PST 2007


 src/atombios_crtc.c |   24 ++++++++++++++++++++----
 1 file changed, 20 insertions(+), 4 deletions(-)

New commits:
commit 0cc7e94849c1525750fabd04cf58f2dee88372e0
Author: Alex Deucher <alex at botch2.(none)>
Date:   Wed Nov 21 17:06:17 2007 -0500

    RADEON: reorder crtc/pll setup

diff --git a/src/atombios_crtc.c b/src/atombios_crtc.c
index 0bd6c80..9615b20 100644
--- a/src/atombios_crtc.c
+++ b/src/atombios_crtc.c
@@ -504,11 +504,11 @@ atombios_crtc_mode_set(xf86CrtcPtr crtc,
 	OUTREG(AVIVO_D1GRPH_ENABLE + radeon_crtc->crtc_offset, 1);
     }
 
-    atombios_set_crtc_source(crtc);
+    atombios_crtc_set_pll(crtc, adjusted_mode);
 
     atombios_set_crtc_timing(info->atomBIOS, &crtc_timing);
 
-    atombios_crtc_set_pll(crtc, adjusted_mode);
+    atombios_set_crtc_source(crtc);
 
     if (info->tilingEnabled != tilingOld) {
 	/* need to redraw front buffer, I guess this can be considered a hack ? */
commit d56bde98efceaa8344e62f8e98db90c4bb642331
Author: Alex Deucher <alex at botch2.(none)>
Date:   Wed Nov 21 17:03:39 2007 -0500

    RADEON: fix crtc to output routing
    
    Thanks to AMD for the information

diff --git a/src/atombios_crtc.c b/src/atombios_crtc.c
index 5188ec3..0bd6c80 100644
--- a/src/atombios_crtc.c
+++ b/src/atombios_crtc.c
@@ -353,6 +353,7 @@ atombios_set_crtc_source(xf86CrtcPtr crtc)
         xf86OutputPtr output = xf86_config->output[i];
         RADEONOutputPrivatePtr radeon_output = output->driver_private;
 
+	/* doesn't seem to support cloning via atom */
 	if (output->crtc == crtc) {
 	    switch(major) {
 	    case 1: {
@@ -360,7 +361,22 @@ atombios_set_crtc_source(xf86CrtcPtr crtc)
 		case 0:
 		case 1:
 		default:
-		    crtc_src_param.ucDevice = radeon_output->output_id;
+		    if (radeon_output->MonType == MT_CRT) {
+                        if (radeon_output->devices & ATOM_DEVICE_CRT1_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_CRT1_INDEX;
+                        else if (radeon_output->devices & ATOM_DEVICE_CRT2_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_CRT2_INDEX;
+                    } else if (radeon_output->MonType == MT_DFP) {
+                        if (radeon_output->devices & ATOM_DEVICE_DFP1_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_DFP1_INDEX;
+                        else if (radeon_output->devices & ATOM_DEVICE_DFP2_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_DFP2_INDEX;
+                        else if (radeon_output->devices & ATOM_DEVICE_DFP3_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_DFP3_INDEX;
+                    } else if (radeon_output->MonType == MT_LCD) {
+                        if (radeon_output->devices & ATOM_DEVICE_LCD1_SUPPORT)
+                            crtc_src_param.ucDevice = ATOM_DEVICE_LCD1_INDEX;
+                    }
 		    break;
 		}
 		break;
@@ -371,7 +387,7 @@ atombios_set_crtc_source(xf86CrtcPtr crtc)
 	}
     }
 
-    ErrorF("devices sourced: 0x%x\n", crtc_src_param.ucDevice);
+    ErrorF("device sourced: 0x%x\n", crtc_src_param.ucDevice);
 
     data.exec.index = index;
     data.exec.dataSpace = (void *)&space;


More information about the xorg-commit mailing list