summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Deucher <alex@t41p.hsd1.va.comcast.net>2007-05-09 14:48:17 +0200
committerAlex Deucher <alex@t41p.hsd1.va.comcast.net>2007-05-09 14:48:17 +0200
commit6a724dd798c1a7b461672993c02be83a7bccded6 (patch)
treee193730631b5392aff4d6c77a18c1aa4494e4c91
parent03860fed24b4f76cc7f1f4210ec8f8040fa04777 (diff)
minor cleanup
-rw-r--r--src/radeon_display.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/radeon_display.c b/src/radeon_display.c
index 5c84591b..c0750eba 100644
--- a/src/radeon_display.c
+++ b/src/radeon_display.c
@@ -943,7 +943,7 @@ void RADEONSetupConnectors(ScrnInfoPtr pScrn)
* The information should be correct even on a OEM card.
* If not, we may have problem -- need to use MonitorLayout option.
*/
- for (i = 0; i < 2; i++) {
+ for (i = 0; i < RADEON_MAX_CONNECTOR; i++) {
pRADEONEnt->PortInfo[i]->MonType = MT_UNKNOWN;
pRADEONEnt->PortInfo[i]->DDCType = DDC_NONE_DETECTED;
pRADEONEnt->PortInfo[i]->DACType = DAC_UNKNOWN;
@@ -2571,7 +2571,6 @@ Bool RADEONAllocateConnectors(ScrnInfoPtr pScrn)
/* for now always allocate max connectors */
for (i = 0 ; i < RADEON_MAX_CONNECTOR; i++) {
-
pRADEONEnt->pOutput[i] = xf86OutputCreate(pScrn, &radeon_output_funcs, OutputType[pRADEONEnt->PortInfo[i]->type]);
if (!pRADEONEnt->pOutput[i])
return FALSE;
@@ -2579,11 +2578,11 @@ Bool RADEONAllocateConnectors(ScrnInfoPtr pScrn)
pRADEONEnt->pOutput[i]->driver_private = pRADEONEnt->PortInfo[i];
pRADEONEnt->PortInfo[i]->num = i;
- pRADEONEnt->pOutput[i]->possible_crtcs = (1<<0);
+ pRADEONEnt->pOutput[i]->possible_crtcs = 1;
if (pRADEONEnt->PortInfo[i]->type != OUTPUT_LVDS)
- pRADEONEnt->pOutput[i]->possible_crtcs |= (1<<1);
+ pRADEONEnt->pOutput[i]->possible_crtcs |= 2;
- pRADEONEnt->pOutput[i]->possible_clones = 0;
+ pRADEONEnt->pOutput[i]->possible_clones = 1|2;
}
return TRUE;
@@ -2594,11 +2593,12 @@ Bool RADEONAllocateConnectors(ScrnInfoPtr pScrn)
xf86OutputPtr RADEONGetCrtcConnector(ScrnInfoPtr pScrn, int crtc_num)
{
RADEONEntPtr pRADEONEnt = RADEONEntPriv(pScrn);
+ int i;
- if (pRADEONEnt->PortInfo[0]->crtc_num == crtc_num)
- return pRADEONEnt->pOutput[0];
- else if (pRADEONEnt->PortInfo[1]->crtc_num == crtc_num)
- return pRADEONEnt->pOutput[1];
+ for (i = 0; i < RADEON_MAX_CONNECTOR; i++) {
+ if (pRADEONEnt->PortInfo[i]->crtc_num == crtc_num)
+ return pRADEONEnt->pOutput[i];
+ }
return NULL;
}