# --- T2-COPYRIGHT-NOTE-BEGIN --- # T2 SDE: package/*/xf86-video-tseng/hotfix-uncrash.patch # Copyright (C) 2024 The T2 SDE Project # # This Copyright note is generated by scripts/Create-CopyPatch, # more information can be found in the files COPYING and README. # # This patch file is dual-licensed. It is available under the license the # patched project is licensed under, as long as it is an OpenSource license # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms # of the GNU General Public License version 2 as used by the T2 SDE. # --- T2-COPYRIGHT-NOTE-END --- --- xf86-video-tseng-1.2.5/src/tseng_driver.c.orig 2012-07-17 07:21:17.000000000 +0200 +++ xf86-video-tseng-1.2.5/src/tseng_driver.c 2024-10-08 20:40:54.069655436 +0200 @@ -722,7 +723,7 @@ case 0x00: /* DRAM -- VERY unlikely on ET6000 cards, IMPOSSIBLE on ET6100 */ xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Video memory type: Standard DRAM.\n"); - ram = 1024 << (ET6000IORead(pTseng, 0x45) & 0x03); + ram = 2048 << (ET6000IORead(pTseng, 0x45) & 0x03); break; default: /* unknown RAM type */ xf86DrvMsg(pScrn->scrnIndex, X_WARNING, @@ -813,7 +814,7 @@ xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, pTseng->Options); from = X_DEFAULT; - pTseng->HWCursor = FALSE; /* default */ + pTseng->HWCursor = TRUE; /* default */ if (xf86GetOptValBool(pTseng->Options, OPTION_HW_CURSOR, &pTseng->HWCursor)) from = X_CONFIG; if (xf86ReturnOptValBool(pTseng->Options, OPTION_SW_CURSOR, FALSE)) { @@ -830,7 +831,7 @@ pTseng->HWCursor ? "HW" : "SW"); if (pScrn->bitsPerPixel >= 8) { - pTseng->UseAccel = TRUE; + pTseng->UseAccel = FALSE; /* XAA removed */ if (xf86ReturnOptValBool(pTseng->Options, OPTION_NOACCEL, FALSE)) { pTseng->UseAccel = FALSE; xf86DrvMsg(pScrn->scrnIndex, X_CONFIG, "Acceleration disabled\n"); @@ -979,6 +980,7 @@ if (!vgaHWGetHWRec(pScrn)) return FALSE; + vgaHWSetStdFuncs(VGAHWPTR(pScrn)); vgaHWGetIOBase(VGAHWPTR(pScrn)); /* * Since, the capabilities are determined by the chipset, the very first @@ -1006,7 +1023,7 @@ * Our default depth is 8, so pass it to the helper function. * Our preference for depth 24 is 24bpp, so tell it that too. */ - if (!xf86SetDepthBpp(pScrn, 8, 8, 8, Support24bppFb | Support32bppFb | + if (!xf86SetDepthBpp(pScrn, 16, 16, 16, Support24bppFb | Support32bppFb | SupportConvert32to24 | PreferConvert32to24)) { return FALSE; } else {