#include "vm_device_version.h"
#include "svga_modes.h"
+#ifndef HAVE_XORG_SERVER_1_5_0
+#include <xf86_ansic.h>
+#include <xf86_libc.h>
+#endif
+
#ifdef HaveDriverFuncs
#define VMWARE_DRIVER_FUNC HaveDriverFuncs
#else
VMWAREFreeRec(ScrnInfoPtr pScrn)
{
if (pScrn->driverPrivate) {
- xfree(pScrn->driverPrivate);
+ free(pScrn->driverPrivate);
pScrn->driverPrivate = NULL;
}
}
numOutputs, width, height, x, y);
numOutputs++;
- extents = xrealloc(extents, numOutputs * sizeof (xXineramaScreenInfo));
+ extents = realloc(extents, numOutputs * sizeof (xXineramaScreenInfo));
extents[numOutputs - 1].x_org = x;
extents[numOutputs - 1].y_org = y;
extents[numOutputs - 1].width = width;
error:
xf86DrvMsg(pScrn->scrnIndex, X_INFO, "Parsing static Xinerama topology: Failed.\n");
- xfree(extents);
+ free(extents);
extents = NULL;
numOutputs = 0;
#endif
xf86CollectOptions(pScrn, NULL);
- if (!(options = xalloc(sizeof(VMWAREOptions))))
+ if (!(options = malloc(sizeof(VMWAREOptions))))
return FALSE;
memcpy(options, VMWAREOptions, sizeof(VMWAREOptions));
xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, options);
pScrn->videoRam = pVMWARE->videoRam / 1024;
pScrn->memPhysBase = pVMWARE->memPhysBase;
- xfree(options);
+ free(options);
{
Gamma zeros = { 0.0, 0.0, 0.0 };
/* print error message */
VMWAREFreeRec(pScrn);
if (i > 0) {
- xfree(pciList);
+ free(pciList);
}
return FALSE;
}
*/
if (pVMWARE->xinerama && !pVMWARE->xineramaStatic) {
if (pVMWARE->xineramaNextState) {
- xfree(pVMWARE->xineramaState);
+ free(pVMWARE->xineramaState);
pVMWARE->xineramaState = pVMWARE->xineramaNextState;
pVMWARE->xineramaNumOutputs = pVMWARE->xineramaNextNumOutputs;
* follow a VMwareCtrlDoSetTopology call.
*/
VMWAREXineramaPtr basicState =
- (VMWAREXineramaPtr)xcalloc(1, sizeof (VMWAREXineramaRec));
+ (VMWAREXineramaPtr)calloc(1, sizeof (VMWAREXineramaRec));
if (basicState) {
basicState->x_org = 0;
basicState->y_org = 0;
basicState->width = vmwareReg->svga_reg_width;
basicState->height = vmwareReg->svga_reg_height;
- xfree(pVMWARE->xineramaState);
+ free(pVMWARE->xineramaState);
pVMWARE->xineramaState = basicState;
pVMWARE->xineramaNumOutputs = 1;
}
{
DisplayModeRec *mode;
- mode = xalloc(sizeof(DisplayModeRec));
+ mode = malloc(sizeof(DisplayModeRec));
memset(mode, 0, sizeof *mode);
- mode->name = xalloc(strlen(name) + 1);
+ mode->name = malloc(strlen(name) + 1);
strcpy(mode->name, name);
mode->status = MODE_OK;
mode->type = M_T_DEFAULT;
xf86CollectOptions(pScrn, NULL);
- if (!(options = xalloc(sizeof(VMWAREOptions))))
+ if (!(options = malloc(sizeof(VMWAREOptions))))
return FALSE;
memcpy(options, VMWAREOptions, sizeof(VMWAREOptions));
xf86ProcessOptions(pScrn->scrnIndex, pScrn->options, options);
pVMWARE->xineramaStatic = pVMWARE->xineramaState != NULL;
- xfree(topology);
+ free(topology);
}
}
- xfree(options);
+ free(options);
/* Initialise VMWARE_CTRL extension. */
VMwareCtrl_ExtInit(pScrn);
numUsed = xf86MatchPciInstances(VMWARE_NAME, PCI_VENDOR_VMWARE,
VMWAREChipsets, VMWAREPciChipsets, devSections,
numDevSections, drv, &usedChips);
- xfree(devSections);
+ free(devSections);
if (numUsed <= 0)
return FALSE;
if (flags & PROBE_DETECT)
foundScreen = TRUE;
}
}
- xfree(usedChips);
+ free(usedChips);
}
return foundScreen;
}
#include "vmware.h"
#include "vmwarectrlproto.h"
+#ifndef HAVE_XORG_SERVER_1_5_0
+#include <xf86_ansic.h>
+#include <xf86_libc.h>
+#endif
/*
*----------------------------------------------------------------------------
VmwareLog(("DoSetRes: %d %d\n", x, y));
if (resetXinerama) {
- xfree(pVMWARE->xineramaNextState);
+ free(pVMWARE->xineramaNextState);
pVMWARE->xineramaNextState = NULL;
pVMWARE->xineramaNextNumOutputs = 0;
}
VmwareLog(("DoSetTopology: %d %d\n", maxX, maxY));
- xineramaState = (VMWAREXineramaPtr)xcalloc(number, sizeof(VMWAREXineramaRec));
+ xineramaState = (VMWAREXineramaPtr)calloc(number, sizeof(VMWAREXineramaRec));
if (xineramaState) {
memcpy(xineramaState, extents, number * sizeof (VMWAREXineramaRec));
* will be no mode change. In this case, push it out
* immediately.
*/
- xfree(pVMWARE->xineramaNextState);
+ free(pVMWARE->xineramaNextState);
pVMWARE->xineramaNextState = xineramaState;
pVMWARE->xineramaNextNumOutputs = number;
#include <X11/extensions/Xv.h>
+#ifndef HAVE_XORG_SERVER_1_5_0
+#include <xf86_ansic.h>
+#include <xf86_libc.h>
+#endif
+
#define MAKE_ATOM(a) MakeAtom(a, sizeof(a) - 1, TRUE)
/*
return NULL;
}
- memptr = xalloc(sizeof(VMWAREOffscreenRec));
+ memptr = malloc(sizeof(VMWAREOffscreenRec));
if (!memptr) {
return NULL;
}
numAdaptors = 1;
overlayAdaptors = &newAdaptor;
} else {
- newAdaptors = xalloc((numAdaptors + 1) *
+ newAdaptors = malloc((numAdaptors + 1) *
sizeof(XF86VideoAdaptorPtr*));
if (!newAdaptors) {
xf86XVFreeVideoAdaptorRec(newAdaptor);
}
if (newAdaptors) {
- xfree(newAdaptors);
+ free(newAdaptors);
}
xf86DrvMsg(pScrn->scrnIndex, X_INFO,
VmwareLog(("Not enough memory\n"));
return NULL;
}
- du = xcalloc(1, VMWARE_VID_NUM_PORTS *
+ du = calloc(1, VMWARE_VID_NUM_PORTS *
(sizeof(DevUnion) + sizeof(VMWAREVideoRec)));
if (!du) {
TRACEPOINT
- fmtData = xcalloc(1, sizeof(VMWAREVideoFmtData));
+ fmtData = calloc(1, sizeof(VMWAREVideoFmtData));
if (!fmtData) {
return -1;
}