|
Lines 1089-1095
Link Here
|
| 1089 |
xf86CollectOptions(pScrn, NULL); |
1089 |
xf86CollectOptions(pScrn, NULL); |
| 1090 |
|
1090 |
|
| 1091 |
if (pScrn->depth == 8) |
1091 |
if (pScrn->depth == 8) |
| 1092 |
pScrn->rgbBits = 8/*6*/; |
1092 |
pScrn->rgbBits = 8; |
| 1093 |
|
1093 |
|
| 1094 |
if (!(psav->Options = xalloc(sizeof(SavageOptions)))) |
1094 |
if (!(psav->Options = xalloc(sizeof(SavageOptions)))) |
| 1095 |
return FALSE; |
1095 |
return FALSE; |
|
Lines 2362-2375
Link Here
|
| 2362 |
VGAOUT8(vgaCRIndex, 0x67); |
2360 |
VGAOUT8(vgaCRIndex, 0x67); |
| 2363 |
VGAOUT8(vgaCRReg, restore->CR67); |
2361 |
VGAOUT8(vgaCRReg, restore->CR67); |
| 2364 |
|
2362 |
|
| 2365 |
/* Enable gamma correction. */ |
2363 |
/* Enable gamma correction, set CLUT to 8 bit */ |
| 2366 |
|
2364 |
|
| 2367 |
VGAOUT8(0x3c4, 0x1b); |
2365 |
VGAOUT8(0x3c4, 0x1b); |
| 2368 |
if( (pScrn->bitsPerPixel == 32) && !psav->DGAactive |
2366 |
if( (pScrn->bitsPerPixel == 32) && !psav->DGAactive |
| 2369 |
&& ! psav->FBStart2nd ) |
2367 |
&& ! psav->FBStart2nd ) |
| 2370 |
VGAOUT8(0x3c5, 0x28 ); |
2368 |
VGAOUT8(0x3c5, 0x78 ); |
| 2371 |
else |
2369 |
else |
| 2372 |
VGAOUT8(0x3c5, 0x00 ); |
2370 |
VGAOUT8(0x3c5, 0x10 ); |
| 2373 |
|
2371 |
|
| 2374 |
/* We may need TV/panel fixups here. See s3bios.c line 2904. */ |
2372 |
/* We may need TV/panel fixups here. See s3bios.c line 2904. */ |
| 2375 |
|
2373 |
|
|
Lines 2481-2486
Link Here
|
| 2481 |
} |
2479 |
} |
| 2482 |
} |
2480 |
} |
| 2483 |
|
2481 |
|
|
|
2482 |
VGAOUT8(0x3c4,0x1b); |
| 2483 |
if( psav->DGAactive ) |
| 2484 |
VGAOUT8(0x3c5, (VGAIN8(0x3C5) & ~0x28) | 0x50 ); |
| 2485 |
else |
| 2486 |
VGAOUT8(0x3c5, (VGAIN8(0x3C5)) | 0x50); |
| 2487 |
|
| 2484 |
SavageInitialize2DEngine(pScrn); |
2488 |
SavageInitialize2DEngine(pScrn); |
| 2485 |
|
2489 |
|
| 2486 |
VGAOUT16(vgaCRIndex, 0x0140); |
2490 |
VGAOUT16(vgaCRIndex, 0x0140); |
|
Lines 3590-3608
Link Here
|
| 3590 |
new->SR15 = 0x03 | 0x80; |
3595 |
new->SR15 = 0x03 | 0x80; |
| 3591 |
new->SR18 = 0x00; |
3596 |
new->SR18 = 0x00; |
| 3592 |
|
3597 |
|
| 3593 |
/* VGAOUT8(0x3c4, 0x1b); |
|
|
| 3594 |
new->SR1B = VGAIN8(0x3c5); |
| 3595 |
if( pScrn->depth == 24 ) |
| 3596 |
new->SR1B |= 0x28; |
| 3597 |
*/ |
| 3598 |
|
3598 |
|
| 3599 |
/* enable gamma correction */ |
3599 |
/* enable gamma correction */ |
| 3600 |
if( pScrn->depth == 24 ) |
3600 |
if( pScrn->depth == 24 ) |
| 3601 |
else |
3601 |
else |
| 3602 |
new->SR1B = 0x00; |
3602 |
new->SR1B = 0x00; |
| 3603 |
|
3603 |
|
| 3604 |
|
3604 |
/* set 8-bit CLUT */ |
|
|
3605 |
new->SR1B |= 0x50; |
| 3606 |
|
| 3605 |
new->CR43 = new->CR45 = new->CR65 = 0x00; |
3607 |
new->CR43 = new->CR45 = new->CR65 = 0x00; |
| 3606 |
|
3608 |
|
| 3607 |
VGAOUT8(vgaCRIndex, 0x40); |
3609 |
VGAOUT8(vgaCRIndex, 0x40); |
|
Lines 3990-3996
Link Here
|
| 3990 |
SavagePtr psav = SAVPTR(pScrn); |
3992 |
SavagePtr psav = SAVPTR(pScrn); |
| 3991 |
int i, index; |
3993 |
int i, index; |
| 3992 |
int updateKey = -1; |
3994 |
int updateKey = -1; |
| 3993 |
unsigned char byte; |
3995 |
unsigned char byte = 0; |
|
|
3996 |
|
| 3997 |
VGAOUT8(0x3c4, 0x1b); |
| 3998 |
ErrorF("SavageLoadPalette - SR1B: 0x%x\n",VGAIN8(0x3c5)); |
| 3994 |
|
3999 |
|
| 3995 |
/* choose CLUT */ |
4000 |
/* choose CLUT */ |
| 3996 |
if (psav->IsPrimary) { |
4001 |
if (psav->IsPrimary) { |
|
Lines 4062-4069
Link Here
|
| 4062 |
SavagePtr psav = SAVPTR(pScrn); |
4067 |
SavagePtr psav = SAVPTR(pScrn); |
| 4063 |
int i, index; |
4068 |
int i, index; |
| 4064 |
int updateKey = -1; |
4069 |
int updateKey = -1; |
| 4065 |
|
4070 |
|
| 4066 |
vgaHWPtr hwp = VGAHWPTR(pScrn); |
|
|
| 4067 |
VerticalRetraceWait(); |
4071 |
VerticalRetraceWait(); |
| 4068 |
|
4072 |
|
| 4069 |
for (i=0; i<numColors; i++) { |
4073 |
for (i=0; i<numColors; i++) { |