--- src/savage_driver.c.savage-disable-dri-bug196011 2006-02-08 09:39:34.000000000 -0500 +++ src/savage_driver.c 2006-07-24 23:17:28.000000000 -0400 @@ -213,6 +213,7 @@ ,OPTION_DISABLE_XVMC ,OPTION_DISABLE_TILE ,OPTION_DISABLE_COB + ,OPTION_DRI ,OPTION_BCI_FOR_XV ,OPTION_DVI ,OPTION_BUS_TYPE @@ -243,8 +244,9 @@ { OPTION_DISABLE_XVMC, "DisableXVMC", OPTV_BOOLEAN, {0}, FALSE }, { OPTION_DISABLE_TILE, "DisableTile", OPTV_BOOLEAN, {0}, FALSE }, { OPTION_DISABLE_COB, "DisableCOB", OPTV_BOOLEAN, {0}, FALSE }, - { OPTION_BCI_FOR_XV, "BCIforXv", OPTV_BOOLEAN, {0}, FALSE }, - { OPTION_DVI, "DVI", OPTV_BOOLEAN, {0}, FALSE }, + { OPTION_DRI, "DRI", OPTV_BOOLEAN, {0}, FALSE }, + { OPTION_BCI_FOR_XV, "BCIforXv", OPTV_BOOLEAN, {0}, FALSE }, + { OPTION_DVI, "DVI", OPTV_BOOLEAN, {0}, FALSE }, #ifdef XF86DRI { OPTION_BUS_TYPE, "BusType", OPTV_ANYSTR, {0}, FALSE }, { OPTION_DMA_TYPE, "DmaType", OPTV_ANYSTR, {0}, FALSE }, @@ -1550,6 +1552,32 @@ xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "Option: %s the COB\n",(psav->disableCOB?"Disable":"Enable")); } + +#ifdef XF86DRI + psav->directRenderingEnabled = + !xf86ReturnOptValBool(psav->Options, OPTION_DRI, FALSE); + +/* Disable DRI by default on the following Savage chipsets for the following + * bug reports: + * + * https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=196011 + * https://bugs.freedesktop.org/show_bug.cgi?id=6357 + */ + + if (psav->directRenderingEnabled) { + if (psav->ChipId == PCI_CHIP_SUPSAV_IXCSDR || + psav->ChipId == PCI_CHIP_SUPSAV_IXCDDR || + psav->ChipId == PCI_CHIP_PROSAVAGE_DDRK || + psav->ChipId == PCI_CHIP_SAVAGE_IX_MV) { + xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "DRI is disabled by default " + "on this chipset as it is experimental and unstable.\n" + "Please refer to https://bugs.freedesktop.org/show_bug.cgi?id=6357 for more\n" + "details.\n"); + psav->directRenderingEnabled=FALSE; + } + } +#endif + if (psav->Chipset == S3_PROSAVAGE || psav->Chipset == S3_TWISTER || psav->Chipset == S3_PROSAVAGEDDR)