--- src/mga_driver.c.orig 2012-01-12 01:05:56.000000000 +0900 +++ src/mga_driver.c 2012-01-14 03:00:39.000000000 +0900 @@ -2193,7 +2193,11 @@ /* * Reset card if it isn't primary one */ +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12 + if ( (!pMga->Primary && !pMga->FBDev) || xf86IsPc98() ) +#else if ( (!pMga->Primary && !pMga->FBDev) ) +#endif MGASoftReset(pScrn); if (pScrn->videoRam == 0) { @@ -2895,6 +2899,13 @@ vgaHWProtect(pScrn, FALSE); } +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12 + if (xf86IsPc98()) { + if (pMga->Chipset == PCI_CHIP_MGA2064) outb(0xfac, 0x01); + else outb(0xfac, 0x02); + } +#endif + /* Reset tagfifo*/ if (pMga->is_G200ER) { @@ -3698,6 +3709,10 @@ MGARestore(pScrn); vgaHWLock(hwp); +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12 + if (xf86IsPc98()) outb(0xfac, 0x00); +#endif + #ifdef XF86DRI if (pMga->directRenderingEnabled) { pScreen = screenInfo.screens[scrnIndex]; @@ -3794,6 +3809,10 @@ pScrn->vtSema = FALSE; +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12 + if (xf86IsPc98()) outb(0xfac, 0x00); +#endif + xf86ClearPrimInitDone(pScrn->entityList[0]); if(pMga->BlockHandler) --- src/mga_merge.c.orig 2012-01-12 01:05:56.000000000 +0900 +++ src/mga_merge.c 2012-01-14 03:01:55.000000000 +0900 @@ -385,7 +385,11 @@ /* * Reset card if it isn't primary one */ +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 12 + if ( (!pMga->Primary && !pMga->FBDev) || xf86IsPc98() ) +#else if ( (!pMga->Primary && !pMga->FBDev) ) +#endif MGASoftReset(pScrn);