diff options
author | Alex Deucher <alexdeucher@gmail.com> | 2011-09-21 17:00:16 -0400 |
---|---|---|
committer | Alex Deucher <alexdeucher@gmail.com> | 2011-09-22 10:44:53 -0400 |
commit | a6b2bd2d184f10d4c56c4ee17186aedb238a36ec (patch) | |
tree | d4e96aaf98eb849700d0616199399b363b06d969 /src | |
parent | d78860ba53d9bfcf6c28e1cfd2d970709b5e20fa (diff) |
UMS: fix DDIA enable on some rs690 systems
DVOOutputControl checks the value of of bios scratch reg 3
on some tables and assumes the encoder is already enabled
if the DFP2_ACTIVE bit is set. Clear that bit so the table
sets the DDIA enable bit properly.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/atombios_output.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/atombios_output.c b/src/atombios_output.c index 0d0f48aa..bfaeb6ba 100644 --- a/src/atombios_output.c +++ b/src/atombios_output.c @@ -1465,6 +1465,8 @@ atombios_output_dpms(xf86OutputPtr output, int mode) unsigned char *space; int index = 0; Bool is_dig = FALSE; + unsigned char *RADEONMMIO = info->MMIO; + uint32_t reg = 0; if (radeon_encoder == NULL) return; @@ -1541,12 +1543,19 @@ atombios_output_dpms(xf86OutputPtr output, int mode) data.exec.dataSpace = (void *)&space; data.exec.pspace = &disp_data; + /* workaround for DVOOutputControl on some RS690 systems */ + if (radeon_encoder->encoder_id == ENCODER_OBJECT_ID_INTERNAL_DDI) { + reg = INREG(RADEON_BIOS_3_SCRATCH); + OUTREG(RADEON_BIOS_3_SCRATCH, reg & ~ATOM_S3_DFP2I_ACTIVE); + } if (RHDAtomBiosFunc(info->atomBIOS->scrnIndex, info->atomBIOS, ATOMBIOS_EXEC, &data) == ATOM_SUCCESS) ErrorF("Output %s enable success\n", device_name[radeon_get_device_index(radeon_output->active_device)]); else ErrorF("Output %s enable failed\n", device_name[radeon_get_device_index(radeon_output->active_device)]); + if (radeon_encoder->encoder_id == ENCODER_OBJECT_ID_INTERNAL_DDI) + OUTREG(RADEON_BIOS_3_SCRATCH, reg); } /* at least for TV atom fails to reassociate the correct crtc source at dpms on */ if (radeon_output->active_device & (ATOM_DEVICE_TV_SUPPORT)) |