xf86-video-intel: src/i830_driver.c
Eric Anholt
anholt at kemper.freedesktop.org
Thu Jun 5 11:48:00 PDT 2008
src/i830_driver.c | 5 -----
1 file changed, 5 deletions(-)
New commits:
commit 65306cdd71dad71e4ca7229764f81a0880dd70bf
Author: Eric Anholt <eric at anholt.net>
Date: Thu Jun 5 11:26:02 2008 -0700
Just remove the mprotect kludge.
Besides not being #ifdef __linux__ed as requested, some linux kernels break
in exciting new ways when you try to mprotect from PROT_NONE back to
PROT_READ|PROT_WRITE. Yes, there are bugs in the code we're calling in a
bug-exploiting bug workaround.
If you want this workaround for the original bug exposed when moving to
libpciaccess, it's already in libpciaccess.
diff --git a/src/i830_driver.c b/src/i830_driver.c
index 426b20f..49f8db9 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -692,11 +692,6 @@ I830MapMem(ScrnInfoPtr pScrn)
(void **) &pI830->FbBase);
if (err)
return FALSE;
- /* KLUDGE ALERT -- rewrite the PTEs to turn off the CD and WT bits */
-#if HAVE_MPROTECT
- mprotect (pI830->FbBase, pI830->FbMapSize, PROT_NONE);
- mprotect (pI830->FbBase, pI830->FbMapSize, PROT_READ|PROT_WRITE);
-#endif
#else
pI830->FbBase = xf86MapPciMem(pScrn->scrnIndex, VIDMEM_FRAMEBUFFER,
pI830->PciTag,
More information about the xorg-commit
mailing list