diff options
| author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2010-11-19 16:58:45 -0500 |
|---|---|---|
| committer | Paul Mundt <lethal@linux-sh.org> | 2010-11-24 02:02:46 -0500 |
| commit | e7d828ab91c95e9fdc85f5167f236a8c85fb2445 (patch) | |
| tree | f6917b7bc121fa1b2f0ddf4fd013ec60bde79ca2 | |
| parent | f3fff7359415f3e6331fa727ab27e9a1556ee7e7 (diff) | |
sisfb: delete dead SIS_XORG_XF86 code
Delete code for compiling the driver for X.org/XFree86. The development
has forked, so there is no point keeping this code in the tree.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Cc: Thomas Winischhofer <thomas@winischhofer.net>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| -rw-r--r-- | drivers/video/sis/init.c | 537 | ||||
| -rw-r--r-- | drivers/video/sis/init.h | 40 | ||||
| -rw-r--r-- | drivers/video/sis/init301.c | 162 | ||||
| -rw-r--r-- | drivers/video/sis/init301.h | 14 | ||||
| -rw-r--r-- | drivers/video/sis/osdef.h | 20 | ||||
| -rw-r--r-- | drivers/video/sis/vgatypes.h | 9 | ||||
| -rw-r--r-- | drivers/video/sis/vstruct.h | 6 |
7 files changed, 0 insertions, 788 deletions
diff --git a/drivers/video/sis/init.c b/drivers/video/sis/init.c index c311ad3c3687..53e30ea56507 100644 --- a/drivers/video/sis/init.c +++ b/drivers/video/sis/init.c | |||
| @@ -340,9 +340,7 @@ SiSInitPtr(struct SiS_Private *SiS_Pr) | |||
| 340 | /* HELPER: Get ModeID */ | 340 | /* HELPER: Get ModeID */ |
| 341 | /*********************************************/ | 341 | /*********************************************/ |
| 342 | 342 | ||
| 343 | #ifndef SIS_XORG_XF86 | ||
| 344 | static | 343 | static |
| 345 | #endif | ||
| 346 | unsigned short | 344 | unsigned short |
| 347 | SiS_GetModeID(int VGAEngine, unsigned int VBFlags, int HDisplay, int VDisplay, | 345 | SiS_GetModeID(int VGAEngine, unsigned int VBFlags, int HDisplay, int VDisplay, |
| 348 | int Depth, bool FSTN, int LCDwidth, int LCDheight) | 346 | int Depth, bool FSTN, int LCDwidth, int LCDheight) |
| @@ -2999,11 +2997,6 @@ SiS_SetCRT1Group(struct SiS_Private *SiS_Pr, unsigned short ModeNo, unsigned sho | |||
| 2999 | SiS_Pr->SiS_SelectCRT2Rate = 0; | 2997 | SiS_Pr->SiS_SelectCRT2Rate = 0; |
| 3000 | SiS_Pr->SiS_SetFlag &= (~ProgrammingCRT2); | 2998 | SiS_Pr->SiS_SetFlag &= (~ProgrammingCRT2); |
| 3001 | 2999 | ||
| 3002 | #ifdef SIS_XORG_XF86 | ||
| 3003 | xf86DrvMsgVerb(0, X_PROBED, 4, "(init: VBType=0x%04x, VBInfo=0x%04x)\n", | ||
| 3004 | SiS_Pr->SiS_VBType, SiS_Pr->SiS_VBInfo); | ||
| 3005 | #endif | ||
| 3006 | |||
| 3007 | if(SiS_Pr->SiS_VBInfo & SetSimuScanMode) { | 3000 | if(SiS_Pr->SiS_VBInfo & SetSimuScanMode) { |
| 3008 | if(SiS_Pr->SiS_VBInfo & SetInSlaveMode) { | 3001 | if(SiS_Pr->SiS_VBInfo & SetInSlaveMode) { |
| 3009 | SiS_Pr->SiS_SetFlag |= ProgrammingCRT2; | 3002 | SiS_Pr->SiS_SetFlag |= ProgrammingCRT2; |
| @@ -3203,73 +3196,11 @@ SiS_Handle760(struct SiS_Private *SiS_Pr) | |||
| 3203 | } | 3196 | } |
| 3204 | 3197 | ||
| 3205 | /*********************************************/ | 3198 | /*********************************************/ |
| 3206 | /* X.org/XFree86: SET SCREEN PITCH */ | ||
| 3207 | /*********************************************/ | ||
| 3208 | |||
| 3209 | #ifdef SIS_XORG_XF86 | ||
| 3210 | static void | ||
| 3211 | SiS_SetPitchCRT1(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn) | ||
| 3212 | { | ||
| 3213 | SISPtr pSiS = SISPTR(pScrn); | ||
| 3214 | unsigned short HDisplay = pSiS->scrnPitch >> 3; | ||
| 3215 | |||
| 3216 | SiS_SetReg(SiS_Pr->SiS_P3d4,0x13,(HDisplay & 0xFF)); | ||
| 3217 | SiS_SetRegANDOR(SiS_Pr->SiS_P3c4,0x0E,0xF0,(HDisplay >> 8)); | ||
| 3218 | } | ||
| 3219 | |||
| 3220 | static void | ||
| 3221 | SiS_SetPitchCRT2(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn) | ||
| 3222 | { | ||
| 3223 | SISPtr pSiS = SISPTR(pScrn); | ||
| 3224 | unsigned short HDisplay = pSiS->scrnPitch2 >> 3; | ||
| 3225 | |||
| 3226 | /* Unlock CRT2 */ | ||
| 3227 | if(pSiS->VGAEngine == SIS_315_VGA) | ||
| 3228 | SiS_SetRegOR(SiS_Pr->SiS_Part1Port,0x2F, 0x01); | ||
| 3229 | else | ||
| 3230 | SiS_SetRegOR(SiS_Pr->SiS_Part1Port,0x24, 0x01); | ||
| 3231 | |||
| 3232 | SiS_SetReg(SiS_Pr->SiS_Part1Port,0x07,(HDisplay & 0xFF)); | ||
| 3233 | SiS_SetRegANDOR(SiS_Pr->SiS_Part1Port,0x09,0xF0,(HDisplay >> 8)); | ||
| 3234 | } | ||
| 3235 | |||
| 3236 | static void | ||
| 3237 | SiS_SetPitch(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn) | ||
| 3238 | { | ||
| 3239 | SISPtr pSiS = SISPTR(pScrn); | ||
| 3240 | bool isslavemode = false; | ||
| 3241 | |||
| 3242 | if( (pSiS->VBFlags2 & VB2_VIDEOBRIDGE) && | ||
| 3243 | ( ((pSiS->VGAEngine == SIS_300_VGA) && | ||
| 3244 | (SiS_GetReg(SiS_Pr->SiS_Part1Port,0x00) & 0xa0) == 0x20) || | ||
| 3245 | ((pSiS->VGAEngine == SIS_315_VGA) && | ||
| 3246 | (SiS_GetReg(SiS_Pr->SiS_Part1Port,0x00) & 0x50) == 0x10) ) ) { | ||
| 3247 | isslavemode = true; | ||
| 3248 | } | ||
| 3249 | |||
| 3250 | /* We need to set pitch for CRT1 if bridge is in slave mode, too */ | ||
| 3251 | if((pSiS->VBFlags & DISPTYPE_DISP1) || (isslavemode)) { | ||
| 3252 | SiS_SetPitchCRT1(SiS_Pr, pScrn); | ||
| 3253 | } | ||
| 3254 | /* We must not set the pitch for CRT2 if bridge is in slave mode */ | ||
| 3255 | if((pSiS->VBFlags & DISPTYPE_DISP2) && (!isslavemode)) { | ||
| 3256 | SiS_SetPitchCRT2(SiS_Pr, pScrn); | ||
| 3257 | } | ||
| 3258 | } | ||
| 3259 | #endif | ||
| 3260 | |||
| 3261 | /*********************************************/ | ||
| 3262 | /* SiSSetMode() */ | 3199 | /* SiSSetMode() */ |
| 3263 | /*********************************************/ | 3200 | /*********************************************/ |
| 3264 | 3201 | ||
| 3265 | #ifdef SIS_XORG_XF86 | ||
| 3266 | /* We need pScrn for setting the pitch correctly */ | ||
| 3267 | bool | ||
| 3268 | SiSSetMode(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn, unsigned short ModeNo, bool dosetpitch) | ||
| 3269 | #else | ||
| 3270 | bool | 3202 | bool |
| 3271 | SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short ModeNo) | 3203 | SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short ModeNo) |
| 3272 | #endif | ||
| 3273 | { | 3204 | { |
| 3274 | SISIOADDRESS BaseAddr = SiS_Pr->IOAddress; | 3205 | SISIOADDRESS BaseAddr = SiS_Pr->IOAddress; |
| 3275 | unsigned short RealModeNo, ModeIdIndex; | 3206 | unsigned short RealModeNo, ModeIdIndex; |
| @@ -3301,9 +3232,6 @@ SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short ModeNo) | |||
| 3301 | SiS_GetSysFlags(SiS_Pr); | 3232 | SiS_GetSysFlags(SiS_Pr); |
| 3302 | 3233 | ||
| 3303 | SiS_Pr->SiS_VGAINFO = 0x11; | 3234 | SiS_Pr->SiS_VGAINFO = 0x11; |
| 3304 | #if defined(SIS_XORG_XF86) && (defined(i386) || defined(__i386) || defined(__i386__) || defined(__AMD64__) || defined(__amd64__) || defined(__x86_64__)) | ||
| 3305 | if(pScrn) SiS_Pr->SiS_VGAINFO = SiS_GetSetBIOSScratch(pScrn, 0x489, 0xff); | ||
| 3306 | #endif | ||
| 3307 | 3235 | ||
| 3308 | #ifdef SIS_LINUX_KERNEL | 3236 | #ifdef SIS_LINUX_KERNEL |
| 3309 | KeepLockReg = SiS_GetReg(SiS_Pr->SiS_P3c4,0x05); | 3237 | KeepLockReg = SiS_GetReg(SiS_Pr->SiS_P3c4,0x05); |
| @@ -3424,18 +3352,6 @@ SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short ModeNo) | |||
| 3424 | } | 3352 | } |
| 3425 | } | 3353 | } |
| 3426 | 3354 | ||
| 3427 | #ifdef SIS_XORG_XF86 | ||
| 3428 | if(pScrn) { | ||
| 3429 | /* SetPitch: Adapt to virtual size & position */ | ||
| 3430 | if((ModeNo > 0x13) && (dosetpitch)) { | ||
| 3431 | SiS_SetPitch(SiS_Pr, pScrn); | ||
| 3432 | } | ||
| 3433 | |||
| 3434 | /* Backup/Set ModeNo in BIOS scratch area */ | ||
| 3435 | SiS_GetSetModeID(pScrn, ModeNo); | ||
| 3436 | } | ||
| 3437 | #endif | ||
| 3438 | |||
| 3439 | SiS_CloseCRTC(SiS_Pr); | 3355 | SiS_CloseCRTC(SiS_Pr); |
| 3440 | 3356 | ||
| 3441 | SiS_Handle760(SiS_Pr); | 3357 | SiS_Handle760(SiS_Pr); |
| @@ -3448,400 +3364,6 @@ SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short ModeNo) | |||
| 3448 | return true; | 3364 | return true; |
| 3449 | } | 3365 | } |
| 3450 | 3366 | ||
| 3451 | /*********************************************/ | ||
| 3452 | /* X.org/XFree86: SiSBIOSSetMode() */ | ||
| 3453 | /* for non-Dual-Head mode */ | ||
| 3454 | /*********************************************/ | ||
| 3455 | |||
| 3456 | #ifdef SIS_XORG_XF86 | ||
| 3457 | bool | ||
| 3458 | SiSBIOSSetMode(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn, | ||
| 3459 | DisplayModePtr mode, bool IsCustom) | ||
| 3460 | { | ||
| 3461 | SISPtr pSiS = SISPTR(pScrn); | ||
| 3462 | unsigned short ModeNo = 0; | ||
| 3463 | |||
| 3464 | SiS_Pr->UseCustomMode = false; | ||
| 3465 | |||
| 3466 | if((IsCustom) && (SiS_CheckBuildCustomMode(pScrn, mode, pSiS->VBFlags))) { | ||
| 3467 | |||
| 3468 | xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 3, "Setting custom mode %dx%d\n", | ||
| 3469 | SiS_Pr->CHDisplay, | ||
| 3470 | (mode->Flags & V_INTERLACE ? SiS_Pr->CVDisplay * 2 : | ||
| 3471 | (mode->Flags & V_DBLSCAN ? SiS_Pr->CVDisplay / 2 : | ||
| 3472 | SiS_Pr->CVDisplay))); | ||
| 3473 | |||
| 3474 | } else { | ||
| 3475 | |||
| 3476 | /* Don't need vbflags here; checks done earlier */ | ||
| 3477 | ModeNo = SiS_GetModeNumber(pScrn, mode, pSiS->VBFlags); | ||
| 3478 | if(!ModeNo) return false; | ||
| 3479 | |||
| 3480 | xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, 3, "Setting standard mode 0x%x\n", ModeNo); | ||
| 3481 | |||
| 3482 | } | ||
| 3483 | |||
| 3484 | return(SiSSetMode(SiS_Pr, pScrn, ModeNo, true)); | ||
| 3485 | } | ||
| 3486 | |||
| 3487 | /*********************************************/ | ||
| 3488 | /* X.org/XFree86: SiSBIOSSetModeCRT2() */ | ||
| 3489 | /* for Dual-Head modes */ | ||
| 3490 | /*********************************************/ | ||
| 3491 | |||
| 3492 | bool | ||
| 3493 | SiSBIOSSetModeCRT2(struct SiS_Private *SiS_Pr, ScrnInfoPtr pScrn, | ||
| 3494 | DisplayModePtr mode, bool IsCustom) | ||
| 3495 | { | ||
| 3496 | SISIOADDRESS BaseAddr = SiS_Pr->IOAddress; | ||
| 3497 | SISPtr pSiS = SISPTR(pScrn); | ||
| 3498 | #ifdef SISDUALHEAD | ||
| 3499 | SISEntPtr pSiSEnt = pSiS->entityPrivate; | ||
| 3500 | #endif | ||
| 3501 | unsigned short ModeIdIndex; | ||
| 3502 | unsigned short ModeNo = 0; | ||
| 3503 | unsigned char backupreg = 0; | ||
| 3504 | |||
| 3505 | SiS_Pr->UseCustomMode = false; | ||
| 3506 | |||
| 3507 | /* Remember: Custom modes for CRT2 are ONLY supported | ||
| 3508 | * -) on the 30x/B/C, and | ||
