diff options
author | Alex Deucher <alex@t41p.hsd1.va.comcast.net> | 2007-05-20 21:03:10 -0400 |
---|---|---|
committer | Alex Deucher <alex@t41p.hsd1.va.comcast.net> | 2007-05-20 21:03:10 -0400 |
commit | 870c8043068a0f44b53d1148371b2cc1e3970a7b (patch) | |
tree | bcf353707c944f82f495365cc04da51aa6fc3305 /src/radeon_output.c | |
parent | 9a147fef8e0e2ede2a0008c4ecfbd9b00c8dc5f6 (diff) |
RADEON: several updates
- move output init from InitCrtc() functions to the output mode_set()
- take the crtc off the MC when blanking
- move EnableDisplay() to output commit()
- clean up some dead code
- don't enable dacs in initcrtc() functions, this is taken care of in EnableDisplay()
Diffstat (limited to 'src/radeon_output.c')
-rw-r--r-- | src/radeon_output.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/radeon_output.c b/src/radeon_output.c index a52b1fc9..c2bebf0a 100644 --- a/src/radeon_output.c +++ b/src/radeon_output.c @@ -215,13 +215,11 @@ radeon_dpms(xf86OutputPtr output, int mode) switch(mode) { case DPMSModeOn: RADEONEnableDisplay(output, TRUE); - /* RADEONDPMSSetOn(output);*/ break; case DPMSModeOff: case DPMSModeSuspend: case DPMSModeStandby: RADEONEnableDisplay(output, FALSE); - /*RADEONDPMSSetOff(output);*/ break; } } @@ -299,7 +297,18 @@ radeon_mode_set(xf86OutputPtr output, DisplayModePtr mode, { ScrnInfoPtr pScrn = output->scrn; RADEONInfoPtr info = RADEONPTR(pScrn); + xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn); RADEONOutputPrivatePtr radeon_output = output->driver_private; + int i; + + /* get the outputs connected to this CRTC */ + for (i = 0; i < xf86_config->num_crtc; i++) { + xf86CrtcPtr crtc = xf86_config->crtc[i]; + RADEONCrtcPrivatePtr radeon_crtc = crtc->driver_private; + if (output->crtc == crtc) { + RADEONInitOutputRegisters(pScrn, &info->ModeReg, adjusted_mode, output, radeon_crtc->crtc_id); + } + } switch(radeon_output->MonType) { case MT_LCD: @@ -312,12 +321,12 @@ radeon_mode_set(xf86OutputPtr output, DisplayModePtr mode, RADEONRestoreDACRegisters(pScrn, &info->ModeReg); } - RADEONEnableDisplay(output, TRUE); } static void radeon_mode_commit(xf86OutputPtr output) { + RADEONEnableDisplay(output, TRUE); } static xf86OutputStatus |