diff options
-rw-r--r-- | man/vesa.man | 17 | ||||
-rw-r--r-- | src/vesa.c | 25 | ||||
-rw-r--r-- | src/vesa.h | 1 |
3 files changed, 33 insertions, 10 deletions
diff --git a/man/vesa.man b/man/vesa.man index 5a9dfd5..2806565 100644 --- a/man/vesa.man +++ b/man/vesa.man @@ -1,4 +1,4 @@ -.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/vesa/vesa.man,v 1.3 2001/12/17 20:52:34 dawes Exp $ +.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/vesa/vesa.man,v 1.2 2001/01/27 18:20:56 dawes Exp $ .\" shorthand for double quote that works everywhere. .ds q \N'34' .TH VESA __drivermansuffix__ __vendorversion__ @@ -14,7 +14,7 @@ vesa \- Generic VESA video driver .fi .SH DESCRIPTION .B vesa -is an XFree86 driver for generic VESA video cards. It can drive most +is an __xservername__ driver for generic VESA video cards. It can drive most VESA-compatible video cards, but only makes use of the basic standard VESA core that is common to these cards. The driver supports depths 8, 15 16 and 24. @@ -24,7 +24,7 @@ The driver supports most VESA-compatible video cards. There are some known exceptions, and those should be listed here. .SH CONFIGURATION DETAILS -Please refer to XF86Config(__filemansuffix__) for general configuration +Please refer to __xconfigfile__(__filemansuffix__) for general configuration details. This section only covers configuration details specific to this driver. .PP @@ -46,7 +46,14 @@ are supported: Enable or disable use of the shadow framebuffer layer. Default: on. This option is recommended for performance reasons. +.TP +.BI "Option \*qModeSetClearScreen\*q \*q" boolean \*q +Clear the screen on mode set. Some BIOSes seem to be broken in the +sence that the newly set video mode is bogus if they are asked to +clear the screen during mode setting. If you experience problems try +to turn this option off. Default: on. + .SH "SEE ALSO" -XFree86(1), XF86Config(__filemansuffix__), xf86cfg(1), xf86config(1), Xserver(1), X(__miscmansuffix__) +__xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), xorgcfg(__appmansuffix__), xorgconfig(__appmansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__) .SH AUTHORS -Authors include: Paulo César Pereira de Andrade. +Authors include: Paulo Ce\'sar Pereira de Andrade. @@ -131,12 +131,15 @@ static IsaChipsets VESAISAchipsets[] = { typedef enum { OPTION_SHADOW_FB, - OPTION_DFLT_REFRESH + OPTION_DFLT_REFRESH, + OPTION_MODESET_CLEAR_SCREEN } VESAOpts; static const OptionInfoRec VESAOptions[] = { { OPTION_SHADOW_FB, "ShadowFB", OPTV_BOOLEAN, {0}, FALSE }, { OPTION_DFLT_REFRESH, "DefaultRefresh", OPTV_BOOLEAN, {0}, FALSE }, + { OPTION_MODESET_CLEAR_SCREEN, "ModeSetClearScreen", + OPTV_BOOLEAN, {0}, FALSE }, { -1, NULL, OPTV_NONE, {0}, FALSE } }; @@ -638,6 +641,10 @@ VESAPreInit(ScrnInfoPtr pScrn, int flags) if (xf86ReturnOptValBool(pVesa->Options, OPTION_DFLT_REFRESH, FALSE)) pVesa->defaultRefresh = TRUE; + if (xf86ReturnOptValBool(pVesa->Options, OPTION_MODESET_CLEAR_SCREEN, + TRUE)) + pVesa->ModeSetClearScreen = TRUE; + if (!pVesa->defaultRefresh) VBESetModeParameters(pScrn, pVesa->pVbe); @@ -1025,7 +1032,16 @@ VESACloseScreen(int scrnIndex, ScreenPtr pScreen) static Bool VESASwitchMode(int scrnIndex, DisplayModePtr pMode, int flags) { - return VESASetMode(xf86Screens[scrnIndex], pMode); + ScrnInfoPtr pScrn = xf86Screens[scrnIndex]; + VESAPtr pVesa = VESAGetRec(pScrn); + Bool ret; + + if (pVesa->ModeSetClearScreen) + pScrn->EnableDisableFBAccess(scrnIndex,FALSE); + ret = VESASetMode(xf86Screens[scrnIndex], pMode); + if (pVesa->ModeSetClearScreen) + pScrn->EnableDisableFBAccess(scrnIndex,TRUE); + return ret; } /* Set a graphics mode */ @@ -1039,8 +1055,7 @@ VESASetMode(ScrnInfoPtr pScrn, DisplayModePtr pMode) pVesa = VESAGetRec(pScrn); data = (VbeModeInfoData*)pMode->Private; - - mode = data->mode | (1 << 15); + mode = data->mode | ( pVesa->ModeSetClearScreen ? (1U << 15) : 0); /* enable linear addressing */ if (pVesa->mapPhys != 0xa0000) @@ -1071,7 +1086,7 @@ VESASetMode(ScrnInfoPtr pScrn, DisplayModePtr pMode) if (data->data->XResolution != pScrn->displayWidth) VBESetLogicalScanline(pVesa->pVbe, pScrn->displayWidth); - if (pScrn->bitsPerPixel >= 8 && pVesa->vbeInfo->Capabilities[0] & 0x01) + if (pScrn->bitsPerPixel == 8 && pVesa->vbeInfo->Capabilities[0] & 0x01) VBESetGetDACPaletteFormat(pVesa->pVbe, 8); pScrn->vtSema = TRUE; @@ -116,6 +116,7 @@ typedef struct _VESARec CloseScreenProcPtr CloseScreen; OptionInfoPtr Options; IOADDRESS ioBase; + Bool ModeSetClearScreen; } VESARec, *VESAPtr; |