From 457f84f373b33838355dbb059892c118bed51409 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Thu, 30 Jul 2009 11:19:35 +1000 Subject: apm: fix up ABI properly --- src/apm_driver.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/apm_driver.c b/src/apm_driver.c index 3939dac..8dc3b3e 100644 --- a/src/apm_driver.c +++ b/src/apm_driver.c @@ -6,6 +6,10 @@ #include "apm.h" #include "xf86cmap.h" #include "shadowfb.h" +#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6 +#include "xf86Resources.h" +#include "xf86RAC.h" +#endif #include "xf86int10.h" #include "vbe.h" @@ -786,6 +790,15 @@ ApmPreInit(ScrnInfoPtr pScrn, int flags) xf86FreeInt10(ptr); } +#ifndef XSERVER_LIBPCIACCESS + xf86RegisterResources(pEnt->index, NULL, ResNone); + xf86SetOperatingState(resVga, pEnt->index, ResDisableOpr); + pScrn->racMemFlags = 0; /* For noLinear, access to 0xA0000 */ + if (pApm->VGAMap) + pScrn->racIoFlags = 0; + else + pScrn->racIoFlags = RAC_COLORMAP | RAC_VIEWPORT; +#endif if (pEnt->device->videoRam != 0) { pScrn->videoRam = pEnt->device->videoRam; from = X_CONFIG; -- cgit v1.2.3