summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2008-02-27 13:27:51 +1000
committerDave Airlie <airlied@redhat.com>2008-02-27 13:27:51 +1000
commite9da23854dce210d72c209d971effabf41029853 (patch)
treec9e2268fddf620f1bca462fef62072245a7ae65e
parente8ee089bc9a46cca015994c95a4e7b2d950c4870 (diff)
neo: finish pciaccess conversion
-rw-r--r--src/neo_driver.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/neo_driver.c b/src/neo_driver.c
index 3d18916..5ce737a 100644
--- a/src/neo_driver.c
+++ b/src/neo_driver.c
@@ -2148,16 +2148,30 @@ neoUnmapMem(ScrnInfoPtr pScrn)
NEOPtr nPtr = NEOPTR(pScrn);
if (!nPtr->noLinear) {
+#ifndef XSERVER_LIBPCIACCESS
if (nPtr->NeoMMIOBase)
xf86UnMapVidMem(pScrn->scrnIndex, (pointer)nPtr->NeoMMIOBase,
0x200000L);
+#else
+ if (nPtr->NeoMMIOBase)
+ pci_device_unmap_range(nPtr->PciInfo, (pointer)nPtr->NeoMMIOBase, 0x200000L);
+#endif
nPtr->NeoMMIOBase = NULL;
+#ifndef XSERVER_LIBPCIACCESS
if (nPtr->NeoMMIOBase2)
xf86UnMapVidMem(pScrn->scrnIndex, (pointer)nPtr->NeoMMIOBase2,
0x100000L);
+#else
+ if (nPtr->NeoMMIOBase2)
+ pci_device_unmap_range(nPtr->PciInfo, (pointer)nPtr->NeoMMIOBase2, 0x100000L);
+#endif
nPtr->NeoMMIOBase2 = NULL;
+#ifndef XSERVER_LIBPCIACCESS
xf86UnMapVidMem(pScrn->scrnIndex, (pointer)nPtr->NeoFbBase,
nPtr->NeoFbMapSize);
+#else
+ pci_device_unmap_range(nPtr->PciInfo, (pointer)nPtr->NeoFbBase, nPtr->NeoFbMapSize);
+#endif
}
nPtr->NeoFbBase = NULL;