Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP1:GA
xf86-video-sis
U_Replace-xf86UnMapVidMem-with-pci_device_unmap...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File U_Replace-xf86UnMapVidMem-with-pci_device_unmap_range.patch of Package xf86-video-sis
From 339fb3bc032b9f35b07b90480ae82a0fd352e078 Mon Sep 17 00:00:00 2001 From: Jan Lindemann <jan@jannet.de> Date: Thu, 30 Aug 2012 20:09:10 +0200 Subject: [PATCH] Replace xf86UnMapVidMem with pci_device_unmap_range Mixing pci_device_map_range with xf86UnMapVidMem doesn't work too well. X.Org bug#18028 <https://bugs.freedesktop.org/show_bug.cgi?id=18028> Bug found by Bryan Henderson <bryanh@giraffe-data.com> Signed-off-by: Julien Cristau <jcristau@debian.org> --- src/sis_driver.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/sis_driver.c b/src/sis_driver.c index 61e8075..4c9b9cb 100644 --- a/src/sis_driver.c +++ b/src/sis_driver.c @@ -7344,7 +7344,11 @@ SISUnmapMem(ScrnInfoPtr pScrn) if(pSiSEnt->MapCountIOBase) { pSiSEnt->MapCountIOBase--; if((pSiSEnt->MapCountIOBase == 0) || (pSiSEnt->forceUnmapIOBase)) { +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiSEnt->IOBase, (pSiS->mmioSize * 1024)); +#else + pci_device_unmap_range(pSiS->PciInfo, pSiSEnt->IOBase, (pSiS->mmioSize * 1024)); +#endif pSiSEnt->IOBase = NULL; pSiSEnt->MapCountIOBase = 0; pSiSEnt->forceUnmapIOBase = FALSE; @@ -7355,7 +7359,11 @@ SISUnmapMem(ScrnInfoPtr pScrn) if(pSiSEnt->MapCountIOBaseDense) { pSiSEnt->MapCountIOBaseDense--; if((pSiSEnt->MapCountIOBaseDense == 0) || (pSiSEnt->forceUnmapIOBaseDense)) { +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiSEnt->IOBaseDense, (pSiS->mmioSize * 1024)); +#else + pci_device_unmap_range(pSiS->PciInfo, (pointer)pSiSEnt->IOBaseDense, (pSiS->mmioSize * 1024)); +#endif pSiSEnt->IOBaseDense = NULL; pSiSEnt->MapCountIOBaseDense = 0; pSiSEnt->forceUnmapIOBaseDense = FALSE; @@ -7366,7 +7374,11 @@ SISUnmapMem(ScrnInfoPtr pScrn) if(pSiSEnt->MapCountFbBase) { pSiSEnt->MapCountFbBase--; if((pSiSEnt->MapCountFbBase == 0) || (pSiSEnt->forceUnmapFbBase)) { +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiSEnt->RealFbBase, pSiS->FbMapSize); +#else + pci_device_unmap_range(pSiS->PciInfo, (pointer)pSiSEnt->RealFbBase, pSiS->FbMapSize); +#endif pSiSEnt->FbBase = pSiSEnt->RealFbBase = NULL; pSiSEnt->MapCountFbBase = 0; pSiSEnt->forceUnmapFbBase = FALSE; @@ -7376,13 +7388,25 @@ SISUnmapMem(ScrnInfoPtr pScrn) } } else { #endif +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiS->IOBase, (pSiS->mmioSize * 1024)); +#else + pci_device_unmap_range(pSiS->PciInfo, (pointer)pSiS->IOBase, (pSiS->mmioSize * 1024)); +#endif pSiS->IOBase = NULL; #ifdef __alpha__ +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiS->IOBaseDense, (pSiS->mmioSize * 1024)); +#else + pci_device_unmap_range(pSiS->PciInfo, (pointer)pSiS->IOBaseDense, (pSiS->mmioSize * 1024)); +#endif pSiS->IOBaseDense = NULL; #endif +#ifndef XSERVER_LIBPCIACCESS xf86UnMapVidMem(pScrn->scrnIndex, (pointer)pSiS->RealFbBase, pSiS->FbMapSize); +#else + pci_device_unmap_range(pSiS->PciInfo, (pointer)pSiS->RealFbBase, pSiS->FbMapSize); +#endif pSiS->FbBase = pSiS->RealFbBase = NULL; #ifdef SISDUALHEAD } -- 1.7.10.4
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor