aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2014-01-15 21:37:10 +0100
committermarha <marha@users.sourceforge.net>2014-01-15 21:37:10 +0100
commitb7f01cb1f6cfd1ec301f650a073436c91ec614aa (patch)
tree1dbf32344313ad7e5884e6686251cad398a231fa /xorg-server/hw
parent7b4b94b4449aec056c4c92f5cacc2f89a292a80e (diff)
parent1b0fcca503ae9cf2d462b60770f96c794dfbb27a (diff)
downloadvcxsrv-b7f01cb1f6cfd1ec301f650a073436c91ec614aa.tar.gz
vcxsrv-b7f01cb1f6cfd1ec301f650a073436c91ec614aa.tar.bz2
vcxsrv-b7f01cb1f6cfd1ec301f650a073436c91ec614aa.zip
Merge remote-tracking branch 'origin/released'
* origin/released: mesa xkeyboard-config xserver git update 15 jan 2014 randrproto libfontenc mesa xserver git update 10 Jan 2014 randsrproto fontconfig libX11 git update 6 Jan 2014 Conflicts: mesalib/src/glsl/builtin_functions.cpp mesalib/src/glsl/ir_builder.h xorg-server/Xext/xres.c xorg-server/dix/dispatch.c xorg-server/dix/dixfonts.c xorg-server/hw/xwin/wingc.c xorg-server/hw/xwin/winwindowswm.c xorg-server/include/gc.h xorg-server/os/access.c
Diffstat (limited to 'xorg-server/hw')
-rw-r--r--xorg-server/hw/dmx/config/Canvas.c8
-rw-r--r--xorg-server/hw/dmx/config/xdmxconfig.c6
-rw-r--r--xorg-server/hw/dmx/dmx.c4
-rw-r--r--xorg-server/hw/dmx/dmxclient.h11
-rw-r--r--xorg-server/hw/dmx/dmxextension.c32
-rw-r--r--xorg-server/hw/dmx/dmxfont.c2
-rw-r--r--xorg-server/hw/dmx/dmxgc.c2
-rw-r--r--xorg-server/hw/dmx/dmxgc.h2
-rw-r--r--xorg-server/hw/dmx/dmxgcops.c8
-rw-r--r--xorg-server/hw/dmx/dmxgcops.h4
-rw-r--r--xorg-server/hw/dmx/dmxpict.c20
-rw-r--r--xorg-server/hw/dmx/dmxpict.h2
-rw-r--r--xorg-server/hw/dmx/dmxstat.c2
-rw-r--r--xorg-server/hw/dmx/dmxsync.c6
-rw-r--r--xorg-server/hw/dmx/dmxwindow.c6
-rw-r--r--xorg-server/hw/dmx/glxProxy/glxcmds.c86
-rw-r--r--xorg-server/hw/dmx/glxProxy/glxext.c6
-rw-r--r--xorg-server/hw/dmx/glxProxy/glxswap.c4
-rw-r--r--xorg-server/hw/dmx/input/dmxbackend.c10
-rw-r--r--xorg-server/hw/dmx/input/dmxbackend.h10
-rw-r--r--xorg-server/hw/dmx/input/dmxcommon.c8
-rw-r--r--xorg-server/hw/dmx/input/dmxcommon.h6
-rw-r--r--xorg-server/hw/dmx/input/dmxconsole.c16
-rw-r--r--xorg-server/hw/dmx/input/dmxconsole.h12
-rw-r--r--xorg-server/hw/dmx/input/dmxevents.c3
-rw-r--r--xorg-server/hw/dmx/input/dmxinputinit.c25
-rw-r--r--xorg-server/hw/dmx/input/dmxinputinit.h26
-rw-r--r--xorg-server/hw/dmx/input/lnx-keyboard.c12
-rw-r--r--xorg-server/hw/dmx/input/lnx-keyboard.h12
-rw-r--r--xorg-server/hw/dmx/input/lnx-ms.c8
-rw-r--r--xorg-server/hw/dmx/input/lnx-ms.h8
-rw-r--r--xorg-server/hw/dmx/input/lnx-ps2.c8
-rw-r--r--xorg-server/hw/dmx/input/lnx-ps2.h8
-rw-r--r--xorg-server/hw/dmx/input/usb-common.c4
-rw-r--r--xorg-server/hw/dmx/input/usb-common.h4
-rw-r--r--xorg-server/hw/kdrive/ephyr/ephyr.c8
-rw-r--r--xorg-server/hw/kdrive/ephyr/ephyrinit.c2
-rw-r--r--xorg-server/hw/kdrive/ephyr/ephyrvideo.c40
-rw-r--r--xorg-server/hw/kdrive/ephyr/hostx.c2
-rw-r--r--xorg-server/hw/kdrive/linux/linux.c4
-rw-r--r--xorg-server/hw/kdrive/src/kcmap.c8
-rw-r--r--xorg-server/hw/kdrive/src/kdrive.c2
-rw-r--r--xorg-server/hw/kdrive/src/kdrive.h8
-rw-r--r--xorg-server/hw/kdrive/src/kinput.c6
-rw-r--r--xorg-server/hw/kdrive/src/kxv.c6
-rw-r--r--xorg-server/hw/kdrive/src/kxv.h20
-rw-r--r--xorg-server/hw/vfb/InitOutput.c8
-rw-r--r--xorg-server/hw/xfree86/Makefile.am2
-rw-r--r--xorg-server/hw/xfree86/common/dgaproc.h2
-rw-r--r--xorg-server/hw/xfree86/common/vidmodeproc.h32
-rw-r--r--xorg-server/hw/xfree86/common/xf86.h59
-rw-r--r--xorg-server/hw/xfree86/common/xf86AutoConfig.c4
-rw-r--r--xorg-server/hw/xfree86/common/xf86Bus.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86Bus.h2
-rw-r--r--xorg-server/hw/xfree86/common/xf86Config.c54
-rw-r--r--xorg-server/hw/xfree86/common/xf86Config.h8
-rw-r--r--xorg-server/hw/xfree86/common/xf86Configure.c44
-rw-r--r--xorg-server/hw/xfree86/common/xf86DGA.c12
-rw-r--r--xorg-server/hw/xfree86/common/xf86DPMS.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86Events.c30
-rw-r--r--xorg-server/hw/xfree86/common/xf86Extensions.c1
-rw-r--r--xorg-server/hw/xfree86/common/xf86Helper.c38
-rw-r--r--xorg-server/hw/xfree86/common/xf86InPriv.h3
-rw-r--r--xorg-server/hw/xfree86/common/xf86Init.c12
-rw-r--r--xorg-server/hw/xfree86/common/xf86Mode.c4
-rw-r--r--xorg-server/hw/xfree86/common/xf86Module.h20
-rw-r--r--xorg-server/hw/xfree86/common/xf86Opt.h4
-rw-r--r--xorg-server/hw/xfree86/common/xf86Option.c5
-rw-r--r--xorg-server/hw/xfree86/common/xf86Optionstr.h6
-rw-r--r--xorg-server/hw/xfree86/common/xf86PM.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86Priv.h6
-rw-r--r--xorg-server/hw/xfree86/common/xf86Privstr.h4
-rw-r--r--xorg-server/hw/xfree86/common/xf86VGAarbiter.c12
-rw-r--r--xorg-server/hw/xfree86/common/xf86VGAarbiterPriv.h16
-rw-r--r--xorg-server/hw/xfree86/common/xf86VidMode.c40
-rw-r--r--xorg-server/hw/xfree86/common/xf86Xinput.c14
-rw-r--r--xorg-server/hw/xfree86/common/xf86Xinput.h12
-rw-r--r--xorg-server/hw/xfree86/common/xf86cmap.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86fbman.c18
-rw-r--r--xorg-server/hw/xfree86/common/xf86fbman.h16
-rw-r--r--xorg-server/hw/xfree86/common/xf86pciBus.c12
-rw-r--r--xorg-server/hw/xfree86/common/xf86pciBus.h2
-rw-r--r--xorg-server/hw/xfree86/common/xf86platformBus.c2
-rw-r--r--xorg-server/hw/xfree86/common/xf86sbusBus.h14
-rw-r--r--xorg-server/hw/xfree86/common/xf86str.h94
-rw-r--r--xorg-server/hw/xfree86/common/xf86vmode.c18
-rw-r--r--xorg-server/hw/xfree86/common/xf86xv.c8
-rw-r--r--xorg-server/hw/xfree86/common/xf86xv.h30
-rw-r--r--xorg-server/hw/xfree86/common/xf86xvmc.h2
-rw-r--r--xorg-server/hw/xfree86/ddc/ddc.c2
-rw-r--r--xorg-server/hw/xfree86/dixmods/glxmodule.c4
-rw-r--r--xorg-server/hw/xfree86/dri/dri.c61
-rw-r--r--xorg-server/hw/xfree86/dri/dri.h18
-rw-r--r--xorg-server/hw/xfree86/dri2/dri2.c6
-rw-r--r--xorg-server/hw/xfree86/exa/examodule.c2
-rw-r--r--xorg-server/hw/xfree86/fbdevhw/fbdevhw.c8
-rw-r--r--xorg-server/hw/xfree86/i2c/bt829.c17
-rw-r--r--xorg-server/hw/xfree86/i2c/fi1236.c2
-rw-r--r--xorg-server/hw/xfree86/i2c/msp3430.c6
-rw-r--r--xorg-server/hw/xfree86/i2c/xf86i2c.h2
-rw-r--r--xorg-server/hw/xfree86/int10/generic.c54
-rw-r--r--xorg-server/hw/xfree86/int10/helper_exec.c208
-rw-r--r--xorg-server/hw/xfree86/int10/helper_mem.c2
-rw-r--r--xorg-server/hw/xfree86/int10/stub.c2
-rw-r--r--xorg-server/hw/xfree86/int10/xf86int10.h76
-rw-r--r--xorg-server/hw/xfree86/int10/xf86x86emu.c12
-rw-r--r--xorg-server/hw/xfree86/loader/loaderProcs.h4
-rw-r--r--xorg-server/hw/xfree86/loader/loadmod.c22
-rw-r--r--xorg-server/hw/xfree86/modes/xf86Crtc.c31
-rw-r--r--xorg-server/hw/xfree86/modes/xf86Modes.c6
-rw-r--r--xorg-server/hw/xfree86/modes/xf86RandR12.c14
-rw-r--r--xorg-server/hw/xfree86/modes/xf86Rotate.c9
-rw-r--r--xorg-server/hw/xfree86/modes/xf86cvt.c5
-rw-r--r--xorg-server/hw/xfree86/modes/xf86gtf.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/alpha_video.c98
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/arm_video.c48
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/bsd_apm.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/bsd_ev56.c48
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/bsd_kqueue_apm.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/i386_video.c32
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/ppc_video.c10
-rw-r--r--xorg-server/hw/xfree86/os-support/bsd/sparc64_video.c10
-rw-r--r--xorg-server/hw/xfree86/os-support/bus/Sbus.c16
-rw-r--r--xorg-server/hw/xfree86/os-support/bus/nobus.c5
-rw-r--r--xorg-server/hw/xfree86/os-support/hurd/hurd_video.c6
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/int10/linux.c26
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_acpi.c11
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_apm.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_ev56.c36
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_init.c4
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_kmod.c4
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_video.c102
-rw-r--r--xorg-server/hw/xfree86/os-support/shared/vidmem.c14
-rw-r--r--xorg-server/hw/xfree86/os-support/solaris/sun_apm.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/solaris/sun_init.c2
-rw-r--r--xorg-server/hw/xfree86/os-support/solaris/sun_vid.c6
-rw-r--r--xorg-server/hw/xfree86/os-support/xf86OSpriv.h10
-rw-r--r--xorg-server/hw/xfree86/os-support/xf86_OSproc.h4
-rw-r--r--xorg-server/hw/xfree86/parser/Configint.h2
-rw-r--r--xorg-server/hw/xfree86/parser/Files.c3
-rw-r--r--xorg-server/hw/xfree86/parser/Flags.c14
-rw-r--r--xorg-server/hw/xfree86/parser/InputClass.c24
-rw-r--r--xorg-server/hw/xfree86/parser/Module.c2
-rw-r--r--xorg-server/hw/xfree86/parser/configProcs.h4
-rw-r--r--xorg-server/hw/xfree86/parser/scan.c15
-rw-r--r--xorg-server/hw/xfree86/parser/xf86Parser.h94
-rw-r--r--xorg-server/hw/xfree86/ramdac/xf86CursorPriv.h2
-rw-r--r--xorg-server/hw/xfree86/ramdac/xf86HWCurs.c12
-rw-r--r--xorg-server/hw/xfree86/sdksyms.sh1
-rw-r--r--xorg-server/hw/xfree86/shadowfb/shadow.c16
-rw-r--r--xorg-server/hw/xfree86/utils/cvt/cvt.c8
-rw-r--r--xorg-server/hw/xfree86/vbe/vbe.c12
-rw-r--r--xorg-server/hw/xfree86/vbe/vbe.h6
-rw-r--r--xorg-server/hw/xfree86/vbe/vbeModes.c6
-rw-r--r--xorg-server/hw/xfree86/vbe/vbeModes.h2
-rw-r--r--xorg-server/hw/xfree86/vgahw/vgaCmap.c2
-rw-r--r--xorg-server/hw/xfree86/vgahw/vgaHW.h10
-rw-r--r--xorg-server/hw/xfree86/x86emu/ops.c4
-rw-r--r--xorg-server/hw/xfree86/x86emu/x86emu/regs.h5
-rw-r--r--xorg-server/hw/xnest/Color.c22
-rw-r--r--xorg-server/hw/xnest/Font.c4
-rw-r--r--xorg-server/hw/xnest/GC.c6
-rw-r--r--xorg-server/hw/xnest/GCOps.c4
-rw-r--r--xorg-server/hw/xnest/GCOps.h4
-rw-r--r--xorg-server/hw/xnest/Handlers.c4
-rw-r--r--xorg-server/hw/xnest/Handlers.h6
-rw-r--r--xorg-server/hw/xnest/Keyboard.c2
-rw-r--r--xorg-server/hw/xnest/Keyboard.h2
-rw-r--r--xorg-server/hw/xnest/Pixmap.c2
-rw-r--r--xorg-server/hw/xnest/Window.c10
-rw-r--r--xorg-server/hw/xnest/XNGC.h2
-rw-r--r--xorg-server/hw/xnest/XNPixmap.h2
-rw-r--r--xorg-server/hw/xquartz/applewm.c24
-rw-r--r--xorg-server/hw/xquartz/quartzCommon.h4
-rw-r--r--xorg-server/hw/xquartz/xpr/dri.c8
-rw-r--r--xorg-server/hw/xquartz/xpr/dri.h2
-rw-r--r--xorg-server/hw/xquartz/xpr/driWrap.c4
-rw-r--r--xorg-server/hw/xwin/glx/indirect.c2
-rw-r--r--xorg-server/hw/xwin/win.h8
-rw-r--r--xorg-server/hw/xwin/winblock.c2
-rw-r--r--xorg-server/hw/xwin/wincmap.c2
-rw-r--r--xorg-server/hw/xwin/winconfig.c16
-rw-r--r--xorg-server/hw/xwin/winconfig.h26
-rwxr-xr-x[-rw-r--r--]xorg-server/hw/xwin/wingc.c0
-rw-r--r--xorg-server/hw/xwin/winkeybd.c4
-rw-r--r--xorg-server/hw/xwin/winmultiwindowwindow.c6
-rw-r--r--xorg-server/hw/xwin/winpfbdd.c2
-rw-r--r--xorg-server/hw/xwin/winpixmap.c2
-rw-r--r--xorg-server/hw/xwin/winshaddd.c2
-rw-r--r--xorg-server/hw/xwin/winshadddnl.c2
-rw-r--r--xorg-server/hw/xwin/winshadgdi.c2
-rw-r--r--xorg-server/hw/xwin/winwakeup.c2
-rw-r--r--xorg-server/hw/xwin/winwindow.c4
-rwxr-xr-x[-rw-r--r--]xorg-server/hw/xwin/winwindowswm.c24
194 files changed, 1348 insertions, 1364 deletions
diff --git a/xorg-server/hw/dmx/config/Canvas.c b/xorg-server/hw/dmx/config/Canvas.c
index f0586e509..103103346 100644
--- a/xorg-server/hw/dmx/config/Canvas.c
+++ b/xorg-server/hw/dmx/config/Canvas.c
@@ -98,10 +98,10 @@ static XtResource resources[] = {
{XtNcallback, XtCCallback, XtRCallback,
sizeof(XtCallbackList), offset(input_callback), XtRCallback, NULL}
,
- {XtNcanvasExposeCallback, XtCcanvasExposeCallback, XtRCallback,
+ {(char *) XtNcanvasExposeCallback, (char *) XtCcanvasExposeCallback, XtRCallback,
sizeof(XtCallbackList), offset(expose_callback), XtRCallback, NULL}
,
- {XtNcanvasResizeCallback, XtCcanvasResizeCallback, XtRCallback,
+ {(char *) XtNcanvasResizeCallback, (char *) XtCcanvasResizeCallback, XtRCallback,
sizeof(XtCallbackList), offset(resize_callback), XtRCallback, NULL}
,
};
@@ -109,7 +109,7 @@ static XtResource resources[] = {
#undef offset
static XtActionsRec actions[] = {
- {"canvas", CanvasAction},
+ {(char *) "canvas", CanvasAction},
};
static char translations[] = "<Key>: canvas()\n\
@@ -123,7 +123,7 @@ CanvasClassRec canvasClassRec = {
/* core */
{
(WidgetClass) Superclass, /* superclass */
- "Canvas", /* class_name */
+ (char *) "Canvas", /* class_name */
sizeof(CanvasRec), /* widget_size */
NULL, /* class_initialize */
NULL, /* class_part_initialize */
diff --git a/xorg-server/hw/dmx/config/xdmxconfig.c b/xorg-server/hw/dmx/config/xdmxconfig.c
index 2121dd781..2b7b9683b 100644
--- a/xorg-server/hw/dmx/config/xdmxconfig.c
+++ b/xorg-server/hw/dmx/config/xdmxconfig.c
@@ -974,9 +974,9 @@ main(int argc, char **argv)
const char *canvastrans =
"<Btn3Down>: placeMenu() XtMenuPopup(buttonpopup)";
XtActionsRec actiontable[] = {
- {"openOk", dmxConfigOkAction},
- {"placeMenu", dmxConfigPlaceMenu},
- {"noop", NULL}
+ {(char *) "openOk", dmxConfigOkAction},
+ {(char *) "placeMenu", dmxConfigPlaceMenu},
+ {(char *) "noop", NULL}
};
dmxConfigFilename = XtNewString((argc >= 2) ? argv[1] : "");
diff --git a/xorg-server/hw/dmx/dmx.c b/xorg-server/hw/dmx/dmx.c
index 0f7cb5c64..99e970cb9 100644
--- a/xorg-server/hw/dmx/dmx.c
+++ b/xorg-server/hw/dmx/dmx.c
@@ -268,7 +268,7 @@ ProcDMXForceWindowCreation(ClientPtr client)
PanoramiXRes *win;
int i;
- if (Success != dixLookupResourceByType((pointer *) &win,
+ if (Success != dixLookupResourceByType((void **) &win,
stuff->window, XRT_WINDOW,
client, DixReadAccess))
return -1; /* BadWindow */
@@ -556,7 +556,7 @@ dmxPopulatePanoramiX(ClientPtr client, Window window,
int count = 0;
DMXWindowAttributesRec attr;
- if (Success != dixLookupResourceByType((pointer *) &win,
+ if (Success != dixLookupResourceByType((void **) &win,
window, XRT_WINDOW,
client, DixReadAccess))
return -1; /* BadWindow */
diff --git a/xorg-server/hw/dmx/dmxclient.h b/xorg-server/hw/dmx/dmxclient.h
index 19dfdbe16..be8116f14 100644
--- a/xorg-server/hw/dmx/dmxclient.h
+++ b/xorg-server/hw/dmx/dmxclient.h
@@ -118,17 +118,6 @@ typedef XID KeySym64;
#undef KeySym
#endif
-/* These are in exglobals.h, but that conflicts with xkbsrv.h */
-extern int ProximityIn;
-extern int ProximityOut;
-extern int DeviceValuator;
-extern int DeviceMotionNotify;
-extern int DeviceFocusIn;
-extern int DeviceFocusOut;
-extern int DeviceStateNotify;
-extern int DeviceMappingNotify;
-extern int ChangeDeviceNotify;
-
/* Some protocol gets included last, after undefines. */
#include <X11/XKBlib.h>
#include <X11/extensions/XKBproto.h>
diff --git a/xorg-server/hw/dmx/dmxextension.c b/xorg-server/hw/dmx/dmxextension.c
index c6c6a8e6d..fcc97e3df 100644
--- a/xorg-server/hw/dmx/dmxextension.c
+++ b/xorg-server/hw/dmx/dmxextension.c
@@ -728,7 +728,7 @@ static Bool FoundPixImage;
* another screen with the same image. If so, copy the pixmap image
* from the existing screen to the newly created pixmap. */
static void
-dmxBERestorePixmapImage(pointer value, XID id, RESTYPE type, pointer p)
+dmxBERestorePixmapImage(void *value, XID id, RESTYPE type, void *p)
{
if ((type & TypeMask) == (XRT_PIXMAP & TypeMask)) {
PixmapPtr pDst = (PixmapPtr) p;
@@ -737,7 +737,7 @@ dmxBERestorePixmapImage(pointer value, XID id, RESTYPE type, pointer p)
PixmapPtr pPix;
int i;
- dixLookupResourceByType((pointer *) &pPix, pXinPix->info[idx].id,
+ dixLookupResourceByType((void **) &pPix, pXinPix->info[idx].id,
RT_PIXMAP, NullClient, DixUnknownAccess);
if (pPix != pDst)
return; /* Not a match.... Next! */
@@ -749,7 +749,7 @@ dmxBERestorePixmapImage(pointer value, XID id, RESTYPE type, pointer p)
if (i == idx)
continue; /* Self replication is bad */
- dixLookupResourceByType((pointer *) &pSrc, pXinPix->info[i].id,
+ dixLookupResourceByType((void **) &pSrc, pXinPix->info[i].id,
RT_PIXMAP, NullClient, DixUnknownAccess);
pSrcPriv = DMX_GET_PIXMAP_PRIV(pSrc);
if (pSrcPriv->pixmap) {
@@ -828,7 +828,7 @@ dmxBERestorePixmap(PixmapPtr pPixmap)
for (i = currentMaxClients; --i >= 0;)
if (clients[i])
FindAllClientResources(clients[i], dmxBERestorePixmapImage,
- (pointer) pPixmap);
+ (void *) pPixmap);
/* No corresponding pixmap image was found on other screens, so we
* need to copy it from the saved image when the screen was detached
@@ -895,7 +895,7 @@ dmxBERestorePixmap(PixmapPtr pPixmap)
* number passed in as \a n and calls the appropriate DMX function to
* create the associated resource on the back-end server. */
static void
-dmxBECreateResources(pointer value, XID id, RESTYPE type, pointer n)
+dmxBECreateResources(void *value, XID id, RESTYPE type, void *n)
{
int scrnNum = (uintptr_t) n;
ScreenPtr pScreen = screenInfo.screens[scrnNum];
@@ -1121,7 +1121,7 @@ dmxCompareScreens(DMXScreenInfo * new, DMXScreenInfo * old)
/** Restore Render's picture */
static void
-dmxBERestoreRenderPict(pointer value, XID id, pointer n)
+dmxBERestoreRenderPict(void *value, XID id, void *n)
{
PicturePtr pPicture = value; /* The picture */
DrawablePtr pDraw = pPicture->pDrawable; /* The picture's drawable */
@@ -1145,7 +1145,7 @@ dmxBERestoreRenderPict(pointer value, XID id, pointer n)
/** Restore Render's glyphs */
static void
-dmxBERestoreRenderGlyph(pointer value, XID id, pointer n)
+dmxBERestoreRenderGlyph(void *value, XID id, void *n)
{
GlyphSetPtr glyphSet = value;
int scrnNum = (uintptr_t) n;
@@ -1340,7 +1340,7 @@ dmxAttachScreen(int idx, DMXScreenAttributesPtr attr)
for (i = currentMaxClients; --i >= 0;)
if (clients[i])
FindAllClientResources(clients[i], dmxBECreateResources,
- (pointer) (uintptr_t) idx);
+ (void *) (uintptr_t) idx);
/* Create window hierarchy (top down) */
dmxBECreateWindowTree(idx);
@@ -1350,14 +1350,14 @@ dmxAttachScreen(int idx, DMXScreenAttributesPtr attr)
if (clients[i])
FindClientResourcesByType(clients[i], PictureType,
dmxBERestoreRenderPict,
- (pointer) (uintptr_t) idx);
+ (void *) (uintptr_t) idx);
/* Restore the glyph state for RENDER */
for (i = currentMaxClients; --i >= 0;)
if (clients[i])
FindClientResourcesByType(clients[i], GlyphSetType,
dmxBERestoreRenderGlyph,
- (pointer) (uintptr_t) idx);
+ (void *) (uintptr_t) idx);
/* Refresh screen by generating exposure events for all windows */
dmxForceExposures(idx);
@@ -1425,7 +1425,7 @@ dmxAttachScreen(int idx, DMXScreenAttributesPtr attr)
/** Search the Xinerama XRT_PIXMAP resources for the pixmap that needs
* to have its image saved. */
static void
-dmxBEFindPixmapImage(pointer value, XID id, RESTYPE type, pointer p)
+dmxBEFindPixmapImage(void *value, XID id, RESTYPE type, void *p)
{
if ((type & TypeMask) == (XRT_PIXMAP & TypeMask)) {
PixmapPtr pDst = (PixmapPtr) p;
@@ -1434,7 +1434,7 @@ dmxBEFindPixmapImage(pointer value, XID id, RESTYPE type, pointer p)
PixmapPtr pPix;
int i;
- dixLookupResourceByType((pointer *) &pPix, pXinPix->info[idx].id,
+ dixLookupResourceByType((void **) &pPix, pXinPix->info[idx].id,
RT_PIXMAP, NullClient, DixUnknownAccess);
if (pPix != pDst)
return; /* Not a match.... Next! */
@@ -1446,7 +1446,7 @@ dmxBEFindPixmapImage(pointer value, XID id, RESTYPE type, pointer p)
if (i == idx)
continue; /* Self replication is bad */
- dixLookupResourceByType((pointer *) &pSrc, pXinPix->info[i].id,
+ dixLookupResourceByType((void **) &pSrc, pXinPix->info[i].id,
RT_PIXMAP, NullClient, DixUnknownAccess);
pSrcPriv = DMX_GET_PIXMAP_PRIV(pSrc);
if (pSrcPriv->pixmap) {
@@ -1482,7 +1482,7 @@ dmxBESavePixmap(PixmapPtr pPixmap)
for (i = currentMaxClients; --i >= 0;)
if (clients[i])
FindAllClientResources(clients[i], dmxBEFindPixmapImage,
- (pointer) pPixmap);
+ (void *) pPixmap);
/* Save the image only if there is no other screens that have a
* pixmap that corresponds to the one we are trying to save. */
@@ -1522,7 +1522,7 @@ dmxBESavePixmap(PixmapPtr pPixmap)
* number passed in as \a n and calls the appropriate DMX function to
* free the associated resource on the back-end server. */
static void
-dmxBEDestroyResources(pointer value, XID id, RESTYPE type, pointer n)
+dmxBEDestroyResources(void *value, XID id, RESTYPE type, void *n)
{
int scrnNum = (uintptr_t) n;
ScreenPtr pScreen = screenInfo.screens[scrnNum];
@@ -1683,7 +1683,7 @@ dmxDetachScreen(int idx)
for (i = currentMaxClients; --i >= 0;)
if (clients[i])
FindAllClientResources(clients[i], dmxBEDestroyResources,
- (pointer) (uintptr_t) idx);
+ (void *) (uintptr_t) idx);
/* Free scratch GCs */
dmxBEDestroyScratchGCs(idx);
diff --git a/xorg-server/hw/dmx/dmxfont.c b/xorg-server/hw/dmx/dmxfont.c
index 7ef7ad971..6b81826c9 100644
--- a/xorg-server/hw/dmx/dmxfont.c
+++ b/xorg-server/hw/dmx/dmxfont.c
@@ -460,7 +460,7 @@ dmxRealizeFont(ScreenPtr pScreen, FontPtr pFont)
pFontPriv->refcnt = 0;
}
- FontSetPrivate(pFont, dmxFontPrivateIndex, (pointer) pFontPriv);
+ FontSetPrivate(pFont, dmxFontPrivateIndex, (void *) pFontPriv);
if (dmxScreen->beDisplay) {
if (!dmxBELoadFont(pScreen, pFont))
diff --git a/xorg-server/hw/dmx/dmxgc.c b/xorg-server/hw/dmx/dmxgc.c
index 703aeb336..2d61ea2f7 100644
--- a/xorg-server/hw/dmx/dmxgc.c
+++ b/xorg-server/hw/dmx/dmxgc.c
@@ -378,7 +378,7 @@ dmxDestroyGC(GCPtr pGC)
/** Change the clip rects for a GC. */
void
-dmxChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects)
+dmxChangeClip(GCPtr pGC, int type, void *pvalue, int nrects)
{
ScreenPtr pScreen = pGC->pScreen;
DMXScreenInfo *dmxScreen = &dmxScreens[pScreen->myNum];
diff --git a/xorg-server/hw/dmx/dmxgc.h b/xorg-server/hw/dmx/dmxgc.h
index 7b99d88c6..c8ecb53a0 100644
--- a/xorg-server/hw/dmx/dmxgc.h
+++ b/xorg-server/hw/dmx/dmxgc.h
@@ -55,7 +55,7 @@ extern void dmxValidateGC(GCPtr pGC, unsigned long changes,
extern void dmxChangeGC(GCPtr pGC, unsigned long mask);
extern void dmxCopyGC(GCPtr pGCSrc, unsigned long changes, GCPtr pGCDst);
extern void dmxDestroyGC(GCPtr pGC);
-extern void dmxChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects);
+extern void dmxChangeClip(GCPtr pGC, int type, void *pvalue, int nrects);
extern void dmxDestroyClip(GCPtr pGC);
extern void dmxCopyClip(GCPtr pGCDst, GCPtr pGCSrc);
diff --git a/xorg-server/hw/dmx/dmxgcops.c b/xorg-server/hw/dmx/dmxgcops.c
index 19330668a..aa7c8eb54 100644
--- a/xorg-server/hw/dmx/dmxgcops.c
+++ b/xorg-server/hw/dmx/dmxgcops.c
@@ -508,7 +508,7 @@ dmxImageText16(DrawablePtr pDrawable, GCPtr pGC,
void
dmxImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC,
int x, int y, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase)
+ CharInfoPtr * ppci, void *pglyphBase)
{
/* Error -- this should never happen! */
}
@@ -517,7 +517,7 @@ dmxImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC,
void
dmxPolyGlyphBlt(DrawablePtr pDrawable, GCPtr pGC,
int x, int y, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase)
+ CharInfoPtr * ppci, void *pglyphBase)
{
/* Error -- this should never happen! */
}
@@ -551,7 +551,7 @@ dmxFindAlternatePixmap(DrawablePtr pDrawable, XID *draw)
if (pDrawable->type != DRAWABLE_PIXMAP)
return NULL;
- if (Success != dixLookupResourceByType((pointer *) &pXinPix,
+ if (Success != dixLookupResourceByType((void **) &pXinPix,
pDrawable->id, XRT_PIXMAP,
NullClient, DixUnknownAccess))
return NULL;
@@ -562,7 +562,7 @@ dmxFindAlternatePixmap(DrawablePtr pDrawable, XID *draw)
PixmapPtr pSrc;
dmxPixPrivPtr pSrcPriv;
- dixLookupResourceByType((pointer *) &pSrc, pXinPix->info[i].id,
+ dixLookupResourceByType((void **) &pSrc, pXinPix->info[i].id,
RT_PIXMAP, NullClient, DixUnknownAccess);
pSrcPriv = DMX_GET_PIXMAP_PRIV(pSrc);
if (pSrcPriv->pixmap) {
diff --git a/xorg-server/hw/dmx/dmxgcops.h b/xorg-server/hw/dmx/dmxgcops.h
index 4ba0ad500..529b6ffc6 100644
--- a/xorg-server/hw/dmx/dmxgcops.h
+++ b/xorg-server/hw/dmx/dmxgcops.h
@@ -78,10 +78,10 @@ extern void dmxImageText16(DrawablePtr pDrawable, GCPtr pGC,
int x, int y, int count, unsigned short *chars);
extern void dmxImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC,
int x, int y, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase);
+ CharInfoPtr * ppci, void *pglyphBase);
extern void dmxPolyGlyphBlt(DrawablePtr pDrawable, GCPtr pGC,
int x, int y, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase);
+ CharInfoPtr * ppci, void *pglyphBase);
extern void dmxPushPixels(GCPtr pGC, PixmapPtr pBitMap, DrawablePtr pDst,
int w, int h, int x, int y);
diff --git a/xorg-server/hw/dmx/dmxpict.c b/xorg-server/hw/dmx/dmxpict.c
index c9762c2f1..64d0ae150 100644
--- a/xorg-server/hw/dmx/dmxpict.c
+++ b/xorg-server/hw/dmx/dmxpict.c
@@ -285,7 +285,7 @@ dmxProcRenderCreateGlyphSet(ClientPtr client)
/* Store glyphsets from backends in glyphSet->devPrivate ????? */
/* Make sure we handle all errors here!! */
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
stuff->gsid, GlyphSetType,
client, DixDestroyAccess);
@@ -332,7 +332,7 @@ dmxProcRenderFreeGlyphSet(ClientPtr client)
REQUEST(xRenderFreeGlyphSetReq);
REQUEST_SIZE_MATCH(xRenderFreeGlyphSetReq);
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
stuff->glyphset, GlyphSetType,
client, DixDestroyAccess);
@@ -378,7 +378,7 @@ dmxProcRenderAddGlyphs(ClientPtr client)
CARD8 *bits;
int nbytes;
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
stuff->glyphset, GlyphSetType,
client, DixReadAccess);
glyphPriv = DMX_GET_GLYPH_PRIV(glyphSet);
@@ -423,7 +423,7 @@ dmxProcRenderFreeGlyphs(ClientPtr client)
REQUEST(xRenderFreeGlyphsReq);
REQUEST_AT_LEAST_SIZE(xRenderFreeGlyphsReq);
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
stuff->glyphset, GlyphSetType,
client, DixWriteAccess);
@@ -498,14 +498,14 @@ dmxProcRenderCompositeGlyphs(ClientPtr client)
GlyphSetPtr glyphSet;
dmxGlyphPrivPtr glyphPriv;
- dixLookupResourceByType((pointer *) &pSrc,
+ dixLookupResourceByType((void **) &pSrc,
stuff->src, PictureType, client, DixReadAccess);
pSrcPriv = DMX_GET_PICT_PRIV(pSrc);
if (!pSrcPriv->pict)
return ret;
- dixLookupResourceByType((pointer *) &pDst,
+ dixLookupResourceByType((void **) &pDst,
stuff->dst, PictureType,
client, DixWriteAccess);
@@ -524,7 +524,7 @@ dmxProcRenderCompositeGlyphs(ClientPtr client)
return ret;
if (stuff->maskFormat)
- dixLookupResourceByType((pointer *) &pFmt,
+ dixLookupResourceByType((void **) &pFmt,
stuff->maskFormat, PictFormatType,
client, DixReadAccess);
else
@@ -585,7 +585,7 @@ dmxProcRenderCompositeGlyphs(ClientPtr client)
curGlyph = glyphs;
curElt = elts;
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
stuff->glyphset, GlyphSetType,
client, DixReadAccess);
glyphPriv = DMX_GET_GLYPH_PRIV(glyphSet);
@@ -595,7 +595,7 @@ dmxProcRenderCompositeGlyphs(ClientPtr client)
buffer += sizeof(xGlyphElt);
if (elt->len == 0xff) {
- dixLookupResourceByType((pointer *) &glyphSet,
+ dixLookupResourceByType((void **) &glyphSet,
*((CARD32 *) buffer),
GlyphSetType, client, DixReadAccess);
glyphPriv = DMX_GET_GLYPH_PRIV(glyphSet);
@@ -894,7 +894,7 @@ dmxDestroyPicture(PicturePtr pPicture)
/** Change the picture's list of clip rectangles. */
int
-dmxChangePictureClip(PicturePtr pPicture, int clipType, pointer value, int n)
+dmxChangePictureClip(PicturePtr pPicture, int clipType, void *value, int n)
{
ScreenPtr pScreen = pPicture->pDrawable->pScreen;
DMXScreenInfo *dmxScreen = &dmxScreens[pScreen->myNum];
diff --git a/xorg-server/hw/dmx/dmxpict.h b/xorg-server/hw/dmx/dmxpict.h
index 6c37be924..080da3bef 100644
--- a/xorg-server/hw/dmx/dmxpict.h
+++ b/xorg-server/hw/dmx/dmxpict.h
@@ -65,7 +65,7 @@ extern Bool dmxDestroyPictureList(WindowPtr pWindow);
extern int dmxCreatePicture(PicturePtr pPicture);
extern void dmxDestroyPicture(PicturePtr pPicture);
extern int dmxChangePictureClip(PicturePtr pPicture, int clipType,
- pointer value, int n);
+ void *value, int n);
extern void dmxDestroyPictureClip(PicturePtr pPicture);
extern void dmxChangePicture(PicturePtr pPicture, Mask mask);
extern void dmxValidatePicture(PicturePtr pPicture, Mask mask);
diff --git a/xorg-server/hw/dmx/dmxstat.c b/xorg-server/hw/dmx/dmxstat.c
index 0d8c22a9e..0ae5107a4 100644
--- a/xorg-server/hw/dmx/dmxstat.c
+++ b/xorg-server/hw/dmx/dmxstat.c
@@ -175,7 +175,7 @@ dmxStatSync(DMXScreenInfo * dmxScreen,
/* Actually do the work of printing out the human-readable message. */
static CARD32
-dmxStatCallback(OsTimerPtr timer, CARD32 t, pointer arg)
+dmxStatCallback(OsTimerPtr timer, CARD32 t, void *arg)
{
int i, j;
static int header = 0;
diff --git a/xorg-server/hw/dmx/dmxsync.c b/xorg-server/hw/dmx/dmxsync.c
index bf28584b4..81dbbc64d 100644
--- a/xorg-server/hw/dmx/dmxsync.c
+++ b/xorg-server/hw/dmx/dmxsync.c
@@ -82,7 +82,7 @@ dmxDoSync(DMXScreenInfo * dmxScreen)
}
static CARD32
-dmxSyncCallback(OsTimerPtr timer, CARD32 time, pointer arg)
+dmxSyncCallback(OsTimerPtr timer, CARD32 time, void *arg)
{
int i;
@@ -99,13 +99,13 @@ dmxSyncCallback(OsTimerPtr timer, CARD32 time, pointer arg)
}
static void
-dmxSyncBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadMask)
+dmxSyncBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadMask)
{
TimerForce(dmxSyncTimer);
}
static void
-dmxSyncWakeupHandler(pointer blockData, int result, pointer pReadMask)
+dmxSyncWakeupHandler(void *blockData, int result, void *pReadMask)
{
}
diff --git a/xorg-server/hw/dmx/dmxwindow.c b/xorg-server/hw/dmx/dmxwindow.c
index 9b8a3840e..1c235273c 100644
--- a/xorg-server/hw/dmx/dmxwindow.c
+++ b/xorg-server/hw/dmx/dmxwindow.c
@@ -86,7 +86,7 @@ dmxCreateRootWindow(WindowPtr pWindow)
parent = dmxScreen->scrnWin; /* This is our "Screen" window */
visual = dmxScreen->beVisuals[dmxScreen->beDefVisualIndex].visual;
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWindow),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWindow),
RT_COLORMAP, NullClient, DixUnknownAccess);
pCmapPriv = DMX_GET_COLORMAP_PRIV(pCmap);
@@ -192,7 +192,7 @@ dmxGetDefaultWindowAttributes(WindowPtr pWindow,
ColormapPtr pCmap;
dmxColormapPrivPtr pCmapPriv;
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWindow),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWindow),
RT_COLORMAP, NullClient, DixUnknownAccess);
pCmapPriv = DMX_GET_COLORMAP_PRIV(pCmap);
*cmap = pCmapPriv->cmap;
@@ -561,7 +561,7 @@ dmxDoChangeWindowAttributes(WindowPtr pWindow,
ColormapPtr pCmap;
dmxColormapPrivPtr pCmapPriv;
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWindow),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWindow),
RT_COLORMAP, NullClient, DixUnknownAccess);
pCmapPriv = DMX_GET_COLORMAP_PRIV(pCmap);
attribs->colormap = pCmapPriv->cmap;
diff --git a/xorg-server/hw/dmx/glxProxy/glxcmds.c b/xorg-server/hw/dmx/glxProxy/glxcmds.c
index 190eeefe2..964db4069 100644
--- a/xorg-server/hw/dmx/glxProxy/glxcmds.c
+++ b/xorg-server/hw/dmx/glxProxy/glxcmds.c
@@ -195,7 +195,7 @@ CreateContext(__GLXclientState * cl,
shareglxc = NULL;
}
else {
- dixLookupResourceByType((pointer *) &shareglxc, shareList,
+ dixLookupResourceByType((void **) &shareglxc, shareList,
__glXContextRes, NullClient, DixUnknownAccess);
if (!shareglxc) {
client->errorValue = shareList;
@@ -425,7 +425,7 @@ CreateContext(__GLXclientState * cl,
/*
** Register this context as a resource.
*/
- if (!AddResource(gcId, __glXContextRes, (pointer) glxc)) {
+ if (!AddResource(gcId, __glXContextRes, (void *) glxc)) {
free(glxc->real_ids);
free(glxc->real_vids);
free(glxc);
@@ -511,14 +511,14 @@ __glXBindSwapBarrierSGIX(__GLXclientState * cl, GLbyte * pc)
rc = dixLookupDrawable(&pDraw, req->drawable, client, 0, DixGetAttrAccess);
if (rc != Success) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, req->drawable,
+ dixLookupResourceByType((void **) &pGlxPixmap, req->drawable,
__glXPixmapRes, NullClient, DixUnknownAccess);
if (pGlxPixmap)
pDraw = pGlxPixmap->pDraw;
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, req->drawable,
+ dixLookupResourceByType((void **) &pGlxWindow, req->drawable,
__glXWindowRes, NullClient, DixUnknownAccess);
if (pGlxWindow)
pDraw = pGlxWindow->pDraw;
@@ -544,14 +544,14 @@ __glXJoinSwapGroupSGIX(__GLXclientState * cl, GLbyte * pc)
rc = dixLookupDrawable(&pDraw, req->drawable, client, 0, DixManageAccess);
if (rc != Success) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, req->drawable,
+ dixLookupResourceByType((void **) &pGlxPixmap, req->drawable,
__glXPixmapRes, NullClient, DixUnknownAccess);
if (pGlxPixmap)
pDraw = pGlxPixmap->pDraw;
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, req->drawable,
+ dixLookupResourceByType((void **) &pGlxWindow, req->drawable,
__glXWindowRes, NullClient, DixUnknownAccess);
if (pGlxWindow)
pDraw = pGlxWindow->pDraw;
@@ -566,7 +566,7 @@ __glXJoinSwapGroupSGIX(__GLXclientState * cl, GLbyte * pc)
rc = dixLookupDrawable(&pMember, req->member, client, 0,
DixGetAttrAccess);
if (rc != Success) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, req->member,
+ dixLookupResourceByType((void **) &pGlxPixmap, req->member,
__glXPixmapRes, NullClient,
DixUnknownAccess);
if (pGlxPixmap)
@@ -574,7 +574,7 @@ __glXJoinSwapGroupSGIX(__GLXclientState * cl, GLbyte * pc)
}
if (!pMember && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, req->member,
+ dixLookupResourceByType((void **) &pGlxWindow, req->member,
__glXWindowRes, NullClient,
DixUnknownAccess);
if (pGlxWindow)
@@ -605,7 +605,7 @@ __glXDestroyContext(__GLXclientState * cl, GLbyte * pc)
int to_screen = 0;
int s;
- dixLookupResourceByType((pointer *) &glxc, gcId, __glXContextRes,
+ dixLookupResourceByType((void **) &glxc, gcId, __glXContextRes,
NullClient, DixUnknownAccess);
if (glxc) {
/*
@@ -880,7 +880,7 @@ MakeCurrent(__GLXclientState * cl,
** Lookup new context. It must not be current for someone else.
*/
if (contextId != None) {
- dixLookupResourceByType((pointer *) &glxc, contextId, __glXContextRes,
+ dixLookupResourceByType((void **) &glxc, contextId, __glXContextRes,
NullClient, DixUnknownAccess);
if (!glxc) {
client->errorValue = contextId;
@@ -935,7 +935,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pDraw) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, drawId,
+ dixLookupResourceByType((void **) &pGlxPixmap, drawId,
__glXPixmapRes, NullClient,
DixUnknownAccess);
if (pGlxPixmap) {
@@ -960,7 +960,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, drawId,
+ dixLookupResourceByType((void **) &pGlxWindow, drawId,
__glXWindowRes, NullClient,
DixUnknownAccess);
if (pGlxWindow) {
@@ -983,7 +983,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxPbuffer, drawId,
+ dixLookupResourceByType((void **) &pGlxPbuffer, drawId,
__glXPbufferRes, NullClient,
DixUnknownAccess);
if (pGlxPbuffer) {
@@ -1050,7 +1050,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pReadDraw) {
- dixLookupResourceByType((pointer *) &pReadGlxPixmap, readId,
+ dixLookupResourceByType((void **) &pReadGlxPixmap, readId,
__glXPixmapRes, NullClient,
DixUnknownAccess);
if (pReadGlxPixmap) {
@@ -1072,7 +1072,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pReadDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxReadWindow, readId,
+ dixLookupResourceByType((void **) &pGlxReadWindow, readId,
__glXWindowRes, NullClient,
DixUnknownAccess);
if (pGlxReadWindow) {
@@ -1094,7 +1094,7 @@ MakeCurrent(__GLXclientState * cl,
}
if (!pReadDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxReadPbuffer, readId,
+ dixLookupResourceByType((void **) &pGlxReadPbuffer, readId,
__glXPbufferRes, NullClient,
DixUnknownAccess);
if (pGlxReadPbuffer) {
@@ -1236,14 +1236,14 @@ MakeCurrent(__GLXclientState * cl,
to_screen = screenInfo.numScreens - 1;
if (pDraw && new_reply.writeType != GLX_PBUFFER_TYPE) {
- dixLookupResourceByClass((pointer *) &pXinDraw,
+ dixLookupResourceByClass((void **) &pXinDraw,
pDraw->id, XRC_DRAWABLE,
client, DixReadAccess);
}
if (pReadDraw && pReadDraw != pDraw &&
new_reply.readType != GLX_PBUFFER_TYPE) {
- dixLookupResourceByClass((pointer *) &pXinReadDraw,
+ dixLookupResourceByClass((void **) &pXinReadDraw,
pReadDraw->id, XRC_DRAWABLE,
client, DixReadAccess);
}
@@ -1460,7 +1460,7 @@ __glXIsDirect(__GLXclientState * cl, GLbyte * pc)
/*
** Find the GL context.
*/
- dixLookupResourceByType((pointer *) &glxc, req->context, __glXContextRes,
+ dixLookupResourceByType((void **) &glxc, req->context, __glXContextRes,
NullClient, DixUnknownAccess);
if (!glxc) {
client->errorValue = req->context;
@@ -1619,13 +1619,13 @@ __glXCopyContext(__GLXclientState * cl, GLbyte * pc)
/*
** Check that each context exists.
*/
- dixLookupResourceByType((pointer *) &src, source, __glXContextRes,
+ dixLookupResourceByType((void **) &src, source, __glXContextRes,
NullClient, DixUnknownAccess);
if (!src) {
client->errorValue = source;
return __glXBadContext;
}
- dixLookupResourceByType((pointer *) &dst, dest, __glXContextRes,
+ dixLookupResourceByType((void **) &dst, dest, __glXContextRes,
NullClient, DixUnknownAccess);
if (!dst) {
client->errorValue = dest;
@@ -1925,7 +1925,7 @@ CreateGLXPixmap(__GLXclientState * cl,
from_screen = 0;
to_screen = screenInfo.numScreens - 1;
- dixLookupResourceByClass((pointer *) &pXinDraw,
+ dixLookupResourceByClass((void **) &pXinDraw,
pDraw->id, XRC_DRAWABLE,
client, DixReadAccess);
}
@@ -2055,7 +2055,7 @@ __glXDestroyGLXPixmap(__GLXclientState * cl, GLbyte * pc)
/*
** Check if it's a valid GLX pixmap.
*/
- dixLookupResourceByType((pointer *) &pGlxPixmap, glxpixmap,
+ dixLookupResourceByType((void **) &pGlxPixmap, glxpixmap,
__glXPixmapRes, NullClient, DixUnknownAccess);
if (!pGlxPixmap) {
client->errorValue = glxpixmap;
@@ -2141,7 +2141,7 @@ __glXDoSwapBuffers(__GLXclientState * cl, XID drawId, GLXContextTag tag)
}
if (!pDraw) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, drawId,
+ dixLookupResourceByType((void **) &pGlxPixmap, drawId,
__glXPixmapRes, NullClient, DixUnknownAccess);
if (pGlxPixmap) {
/*
@@ -2153,7 +2153,7 @@ __glXDoSwapBuffers(__GLXclientState * cl, XID drawId, GLXContextTag tag)
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, drawId,
+ dixLookupResourceByType((void **) &pGlxWindow, drawId,
__glXWindowRes, NullClient, DixUnknownAccess);
if (pGlxWindow) {
/*
@@ -2183,7 +2183,7 @@ __glXDoSwapBuffers(__GLXclientState * cl, XID drawId, GLXContextTag tag)
if (!noPanoramiXExtension) {
from_screen = 0;
to_screen = screenInfo.numScreens - 1;
- dixLookupResourceByClass((pointer *) &pXinDraw,
+ dixLookupResourceByClass((void **) &pXinDraw,
pDraw->id, XRC_DRAWABLE,
client, DixReadAccess);
}
@@ -2291,7 +2291,7 @@ __glXSwapBuffers(__GLXclientState * cl, GLbyte * pc)
}
if (!pDraw) {
- dixLookupResourceByType((pointer *) &pGlxPixmap, drawId,
+ dixLookupResourceByType((void **) &pGlxPixmap, drawId,
__glXPixmapRes, NullClient, DixUnknownAccess);
if (pGlxPixmap) {
/*
@@ -2302,7 +2302,7 @@ __glXSwapBuffers(__GLXclientState * cl, GLbyte * pc)
}
if (!pDraw && __GLX_IS_VERSION_SUPPORTED(1, 3)) {
- dixLookupResourceByType((pointer *) &pGlxWindow, drawId,
+ dixLookupResourceByType((void **) &pGlxWindow, drawId,
__glXWindowRes, NullClient, DixUnknownAccess);
if (pGlxWindow) {
/*
@@ -2817,12 +2817,12 @@ __glXUseXFont(__GLXclientState * cl, GLbyte * pc)
** Font can actually be either the ID of a font or the ID of a GC
** containing a font.
*/
- dixLookupResourceByType((pointer *) &pFont, req->font, RT_FONT,
+ dixLookupResourceByType((void **) &pFont, req->font, RT_FONT,
NullClient, DixUnknownAccess);
if (!pFont) {
GC *pGC;
- dixLookupResourceByType((pointer *) &pGC, req->font,
+ dixLookupResourceByType((void **) &pGC, req->font,
RT_GC, NullClient, DixUnknownAccess);
if (!pGC) {
client->errorValue = req->font;
@@ -3082,7 +3082,7 @@ __glXCreateWindow(__GLXclientState * cl, GLbyte * pc)
VisualPtr pVisual;
VisualID visId;
int i, rc;
- pointer val;
+ void *val;
/*
** Check if windowId is valid
@@ -3184,7 +3184,7 @@ __glXDestroyWindow(__GLXclientState * cl, GLbyte * pc)
ClientPtr client = cl->client;
xGLXDestroyWindowReq *req = (xGLXDestroyWindowReq *) pc;
XID glxwindow = req->glxwindow;
- pointer val;
+ void *val;
/*
** Check if it's a valid GLX window.
@@ -3216,7 +3216,7 @@ __glXQueryContext(__GLXclientState * cl, GLbyte * pc)
int nReplyBytes;
req = (xGLXQueryContextReq *) pc;
- dixLookupResourceByType((pointer *) &ctx, req->context, __glXContextRes,
+ dixLookupResourceByType((void **) &ctx, req->context, __glXContextRes,
NullClient, DixUnknownAccess);
if (!ctx) {
client->errorValue = req->context;
@@ -3266,7 +3266,7 @@ __glXQueryContextInfoEXT(__GLXclientState * cl, GLbyte * pc)
int nReplyBytes;
req = (xGLXQueryContextInfoEXTReq *) pc;
- dixLookupResourceByType((pointer *) &ctx,
+ dixLookupResourceByType((void **) &ctx,
req->context, __glXContextRes,
client, DixReadAccess);
@@ -3439,7 +3439,7 @@ __glXDestroyPbuffer(__GLXclientState * cl, GLbyte * pc)
/*
** Check if it's a valid Pbuffer
*/
- dixLookupResourceByType((pointer *) &pGlxPbuffer, pbuffer,
+ dixLookupResourceByType((void **) &pGlxPbuffer, pbuffer,
__glXPbufferRes, NullClient, DixUnknownAccess);
if (!pGlxPbuffer) {
client->errorValue = pbuffer;
@@ -3514,7 +3514,7 @@ __glXGetDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__GLXpixmap *pGlxPixmap;
- dixLookupResourceByType((pointer *) &pGlxPixmap,
+ dixLookupResourceByType((void **) &pGlxPixmap,
drawId, __glXPixmapRes,
NullClient, DixUnknownAccess);
if (pGlxPixmap) {
@@ -3527,7 +3527,7 @@ __glXGetDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__glXWindow *pGlxWindow;
- dixLookupResourceByType((pointer *) &pGlxWindow,
+ dixLookupResourceByType((void **) &pGlxWindow,
drawId, __glXWindowRes,
NullClient, DixUnknownAccess);
if (pGlxWindow) {
@@ -3540,7 +3540,7 @@ __glXGetDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__glXPbuffer *pGlxPbuffer;
- dixLookupResourceByType((pointer *) &pGlxPbuffer,
+ dixLookupResourceByType((void **) &pGlxPbuffer,
drawId, __glXPbufferRes,
NullClient, DixUnknownAccess);
if (pGlxPbuffer) {
@@ -3567,7 +3567,7 @@ __glXGetDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
#ifdef PANORAMIX
if (!noPanoramiXExtension) {
- if (Success != dixLookupResourceByClass((pointer *) &pXinDraw,
+ if (Success != dixLookupResourceByClass((void **) &pXinDraw,
pDraw->id, XRC_DRAWABLE,
client, DixReadAccess)) {
client->errorValue = drawId;
@@ -3676,7 +3676,7 @@ __glXChangeDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__GLXpixmap *pGlxPixmap;
- dixLookupResourceByType((pointer *) &pGlxPixmap,
+ dixLookupResourceByType((void **) &pGlxPixmap,
drawId, __glXPixmapRes,
NullClient, DixUnknownAccess);
if (pGlxPixmap) {
@@ -3689,7 +3689,7 @@ __glXChangeDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__glXWindow *pGlxWindow;
- dixLookupResourceByType((pointer *) &pGlxWindow,
+ dixLookupResourceByType((void **) &pGlxWindow,
drawId, __glXWindowRes,
NullClient, DixUnknownAccess);
if (pGlxWindow) {
@@ -3702,7 +3702,7 @@ __glXChangeDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!pDraw) {
__glXPbuffer *pGlxPbuffer;
- dixLookupResourceByType((pointer *) &pGlxPbuffer,
+ dixLookupResourceByType((void **) &pGlxPbuffer,
drawId, __glXPbufferRes,
NullClient, DixUnknownAccess);
if (pGlxPbuffer) {
@@ -3731,7 +3731,7 @@ __glXChangeDrawableAttributes(__GLXclientState * cl, GLbyte * pc)
if (!noPanoramiXExtension) {
PanoramiXRes *pXinDraw;
- if (Success != dixLookupResourceByClass((pointer *) &pXinDraw,
+ if (Success != dixLookupResourceByClass((void **) &pXinDraw,
pDraw->id, XRC_DRAWABLE,
client, DixReadAccess)) {
client->errorValue = drawId;
diff --git a/xorg-server/hw/dmx/glxProxy/glxext.c b/xorg-server/hw/dmx/glxProxy/glxext.c
index b46970864..3c5a14bc7 100644
--- a/xorg-server/hw/dmx/glxProxy/glxext.c
+++ b/xorg-server/hw/dmx/glxProxy/glxext.c
@@ -182,7 +182,7 @@ __glXFreeGLXWindow(__glXWindow * pGlxWindow)
WindowPtr pWindow = (WindowPtr) pGlxWindow->pDraw;
WindowPtr ret;
- dixLookupResourceByType((pointer) &ret,
+ dixLookupResourceByType((void *) &ret,
pWindow->drawable.id, RT_WINDOW,
NullClient, DixUnknownAccess);
if (ret == pWindow) {
@@ -414,7 +414,7 @@ __glXDispatch(ClientPtr client)
*/
XID xid = FakeClientID(client->index);
- if (!AddResource(xid, __glXClientRes, (pointer) (long) client->index)) {
+ if (!AddResource(xid, __glXClientRes, (void *) (long) client->index)) {
return BadAlloc;
}
ResetClientState(client->index);
@@ -468,7 +468,7 @@ __glXSwapDispatch(ClientPtr client)
*/
XID xid = FakeClientID(client->index);
- if (!AddResource(xid, __glXClientRes, (pointer) (long) client->index)) {
+ if (!AddResource(xid, __glXClientRes, (void *) (long) client->index)) {
return BadAlloc;
}
ResetClientState(client->index);
diff --git a/xorg-server/hw/dmx/glxProxy/glxswap.c b/xorg-server/hw/dmx/glxProxy/glxswap.c
index 87a748621..5f565010d 100644
--- a/xorg-server/hw/dmx/glxProxy/glxswap.c
+++ b/xorg-server/hw/dmx/glxProxy/glxswap.c
@@ -110,7 +110,7 @@ SwapGroupIsReadyToSwap(SwapGroupPtr pSwap)
}
static Bool
-SGSwapCleanup(ClientPtr client, pointer closure)
+SGSwapCleanup(ClientPtr client, void *closure)
{
/* SwapGroupPtr pSwap = (SwapGroupPtr)closure; */
@@ -154,7 +154,7 @@ SGSwapBuffers(__GLXclientState * cl, XID drawId, GLXContextTag tag,
else {
/* The swap group/barrier is not yet ready to swap, so put
* client to sleep until the rest are ready to swap */
- ClientSleep(cl->client, SGSwapCleanup, (pointer) pWin);
+ ClientSleep(cl->client, SGSwapCleanup, (void *) pWin);
pCur->sleeping = TRUE;
}
diff --git a/xorg-server/hw/dmx/input/dmxbackend.c b/xorg-server/hw/dmx/input/dmxbackend.c
index 807e02328..56abe8013 100644
--- a/xorg-server/hw/dmx/input/dmxbackend.c
+++ b/xorg-server/hw/dmx/input/dmxbackend.c
@@ -101,7 +101,7 @@ typedef struct _myPrivate {
#endif
/** Create and return a private data structure. */
-pointer
+void *
dmxBackendCreatePrivate(DeviceIntPtr pDevice)
{
GETDMXLOCALFROMPDEVICE;
@@ -115,7 +115,7 @@ dmxBackendCreatePrivate(DeviceIntPtr pDevice)
* verify that the structure was actually created by
* #dmxBackendCreatePrivate. */
void
-dmxBackendDestroyPrivate(pointer private)
+dmxBackendDestroyPrivate(void *private)
{
free(private);
}
@@ -262,7 +262,7 @@ dmxBackendOffscreen(int screen, int x, int y)
/** This routine is called from #dmxCoreMotion for each motion
* event. \a x and \a y are global coordinants. */
void
-dmxBackendUpdatePosition(pointer private, int x, int y)
+dmxBackendUpdatePosition(void *private, int x, int y)
{
GETPRIVFROMPRIVATE;
int screen = miPointerGetScreen(inputInfo.pointer)->myNum;
@@ -500,7 +500,7 @@ dmxBackendCollectEvents(DevicePtr pDev,
* event processing actually takes place here, but this is a convenient
* place to update the pointer. */
void
-dmxBackendProcessInput(pointer private)
+dmxBackendProcessInput(void *private)
{
GETPRIVFROMPRIVATE;
@@ -650,7 +650,7 @@ dmxBackendKbdGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info)
/** Process #DMXFunctionType functions. The only function handled here
* is to acknowledge a pending server shutdown. */
int
-dmxBackendFunctions(pointer private, DMXFunctionType function)
+dmxBackendFunctions(void *private, DMXFunctionType function)
{
switch (function) {
case DMX_FUNCTION_TERMINATE:
diff --git a/xorg-server/hw/dmx/input/dmxbackend.h b/xorg-server/hw/dmx/input/dmxbackend.h
index 6a49a56d6..a60857369 100644
--- a/xorg-server/hw/dmx/input/dmxbackend.h
+++ b/xorg-server/hw/dmx/input/dmxbackend.h
@@ -38,8 +38,8 @@
#ifndef _DMXBACKEND_H_
#define _DMXBACKEND_H_
-extern pointer dmxBackendCreatePrivate(DeviceIntPtr pDevice);
-extern void dmxBackendDestroyPrivate(pointer private);
+extern void *dmxBackendCreatePrivate(DeviceIntPtr pDevice);
+extern void dmxBackendDestroyPrivate(void *private);
extern void dmxBackendInit(DevicePtr pDev);
extern void dmxBackendLateReInit(DevicePtr pDev);
extern void dmxBackendMouGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
@@ -49,8 +49,8 @@ extern void dmxBackendCollectEvents(DevicePtr pDev,
dmxEnqueueProcPtr enqueue,
dmxCheckSpecialProcPtr checkspecial,
DMXBlockType block);
-extern void dmxBackendProcessInput(pointer private);
-extern int dmxBackendFunctions(pointer private, DMXFunctionType function);
-extern void dmxBackendUpdatePosition(pointer private, int x, int y);
+extern void dmxBackendProcessInput(void *private);
+extern int dmxBackendFunctions(void *private, DMXFunctionType function);
+extern void dmxBackendUpdatePosition(void *private, int x, int y);
#endif
diff --git a/xorg-server/hw/dmx/input/dmxcommon.c b/xorg-server/hw/dmx/input/dmxcommon.c
index db558b55f..90154ef3e 100644
--- a/xorg-server/hw/dmx/input/dmxcommon.c
+++ b/xorg-server/hw/dmx/input/dmxcommon.c
@@ -339,7 +339,7 @@ dmxCommonOthOn(DevicePtr pDev)
if (!(priv->xi = XOpenDevice(priv->display, dmxLocal->deviceId))) {
dmxLog(dmxWarning, "Cannot open %s device (id=%d) on %s\n",
dmxLocal->deviceName ? dmxLocal->deviceName : "(unknown)",
- dmxLocal->deviceId, dmxInput->name);
+ (int) dmxLocal->deviceId, dmxInput->name);
return -1;
}
ADD(DeviceKeyPress);
@@ -558,7 +558,7 @@ dmxFindPointerScreen(int x, int y)
* (e.g., when a keyboard and mouse form a pair that should share the
* same private area). If the requested private area cannot be located,
* then NULL is returned. */
-pointer
+void *
dmxCommonCopyPrivate(DeviceIntPtr pDevice)
{
GETDMXLOCALFROMPDEVICE;
@@ -583,7 +583,7 @@ dmxCommonCopyPrivate(DeviceIntPtr pDevice)
* server startup and server shutdown).
*/
void
-dmxCommonSaveState(pointer private)
+dmxCommonSaveState(void *private)
{
GETPRIVFROMPRIVATE;
XKeyboardState ks;
@@ -641,7 +641,7 @@ dmxCommonSaveState(pointer private)
/** This routine restores all the information saved by #dmxCommonSaveState. */
void
-dmxCommonRestoreState(pointer private)
+dmxCommonRestoreState(void *private)
{
GETPRIVFROMPRIVATE;
int retcode = -1;
diff --git a/xorg-server/hw/dmx/input/dmxcommon.h b/xorg-server/hw/dmx/input/dmxcommon.h
index d4f8d3c89..ed04287a5 100644
--- a/xorg-server/hw/dmx/input/dmxcommon.h
+++ b/xorg-server/hw/dmx/input/dmxcommon.h
@@ -118,7 +118,7 @@ extern void dmxCommonOthOff(DevicePtr pDev);
extern void dmxCommonOthGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
/* helper functions */
-extern pointer dmxCommonCopyPrivate(DeviceIntPtr pDevice);
-extern void dmxCommonSaveState(pointer private);
-extern void dmxCommonRestoreState(pointer private);
+extern void *dmxCommonCopyPrivate(DeviceIntPtr pDevice);
+extern void dmxCommonSaveState(void *private);
+extern void dmxCommonRestoreState(void *private);
#endif
diff --git a/xorg-server/hw/dmx/input/dmxconsole.c b/xorg-server/hw/dmx/input/dmxconsole.c
index 600a70553..f33a0ebd3 100644
--- a/xorg-server/hw/dmx/input/dmxconsole.c
+++ b/xorg-server/hw/dmx/input/dmxconsole.c
@@ -141,7 +141,7 @@ unscaley(myPrivate * priv, int y)
}
/** Create the private area for \a pDevice. */
-pointer
+void *
dmxConsoleCreatePrivate(DeviceIntPtr pDevice)
{
GETDMXLOCALFROMPDEVICE;
@@ -153,7 +153,7 @@ dmxConsoleCreatePrivate(DeviceIntPtr pDevice)
/** If \a private is non-NULL, free its associated memory. */
void
-dmxConsoleDestroyPrivate(pointer private)
+dmxConsoleDestroyPrivate(void *private)
{
free(private);
}
@@ -193,7 +193,7 @@ dmxConsoleDrawFineCursor(myPrivate * priv, XRectangle * rect)
}
static void
-dmxConsoleDrawWindows(pointer private)
+dmxConsoleDrawWindows(void *private)
{
GETONLYPRIVFROMPRIVATE;
Display *dpy = priv->display;
@@ -391,7 +391,7 @@ dmxConsoleUpdateFineCursor(myPrivate * priv)
* fashion: the actual layout of the windows of the screen might not
* have had any human-visible changes. */
void
-dmxConsoleUpdateInfo(pointer private, DMXUpdateType type, WindowPtr pWindow)
+dmxConsoleUpdateInfo(void *private, DMXUpdateType type, WindowPtr pWindow)
{
GETONLYPRIVFROMPRIVATE;
dmxConsoleDraw(priv, 1, 1);
@@ -436,7 +436,7 @@ dmxConsoleMoveRelative(myPrivate * priv, int x, int y,
* allows the console's notion of the cursor postion to change when
* another input device actually caused the change. */
void
-dmxConsoleUpdatePosition(pointer private, int x, int y)
+dmxConsoleUpdatePosition(void *private, int x, int y)
{
GETONLYPRIVFROMPRIVATE;
int tmpX, tmpY;
@@ -825,8 +825,8 @@ dmxConsoleInit(DevicePtr pDev)
/* Set up properties */
XStoreName(dpy, win, DMX_CONSOLE_NAME);
- class_hints.res_name = DMX_RES_NAME;
- class_hints.res_class = DMX_RES_CLASS;
+ class_hints.res_name = (char *) DMX_RES_NAME;
+ class_hints.res_class = (char *) DMX_RES_CLASS;
XSetClassHint(dpy, win, &class_hints);
/* Map the window */
@@ -941,7 +941,7 @@ dmxConsoleKbdGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info)
/** Handle special console-only keys. */
int
-dmxConsoleFunctions(pointer private, DMXFunctionType function)
+dmxConsoleFunctions(void *private, DMXFunctionType function)
{
GETONLYPRIVFROMPRIVATE;
XRectangle rect;
diff --git a/xorg-server/hw/dmx/input/dmxconsole.h b/xorg-server/hw/dmx/input/dmxconsole.h
index 1c5261101..ea6033c3a 100644
--- a/xorg-server/hw/dmx/input/dmxconsole.h
+++ b/xorg-server/hw/dmx/input/dmxconsole.h
@@ -37,8 +37,8 @@
#ifndef _DMXCONSOLE_H_
#define _DMXCONSOLE_H_
-extern pointer dmxConsoleCreatePrivate(DeviceIntPtr pDevice);
-extern void dmxConsoleDestroyPrivate(pointer private);
+extern void *dmxConsoleCreatePrivate(DeviceIntPtr pDevice);
+extern void dmxConsoleDestroyPrivate(void *private);
extern void dmxConsoleInit(DevicePtr pDev);
extern void dmxConsoleReInit(DevicePtr pDev);
extern void dmxConsoleMouGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
@@ -48,12 +48,12 @@ extern void dmxConsoleCollectEvents(DevicePtr pDev,
dmxEnqueueProcPtr enqueue,
dmxCheckSpecialProcPtr checkspecial,
DMXBlockType block);
-extern int dmxConsoleFunctions(pointer private, DMXFunctionType function);
-extern void dmxConsoleUpdatePosition(pointer private, int x, int y);
-extern void dmxConsoleKbdSetCtrl(pointer private, KeybdCtrl * ctrl);
+extern int dmxConsoleFunctions(void *private, DMXFunctionType function);
+extern void dmxConsoleUpdatePosition(void *private, int x, int y);
+extern void dmxConsoleKbdSetCtrl(void *private, KeybdCtrl * ctrl);
extern void dmxConsoleCapture(DMXInputInfo * dmxInput);
extern void dmxConsoleUncapture(DMXInputInfo * dmxInput);
-extern void dmxConsoleUpdateInfo(pointer private,
+extern void dmxConsoleUpdateInfo(void *private,
DMXUpdateType, WindowPtr pWindow);
#endif
diff --git a/xorg-server/hw/dmx/input/dmxevents.c b/xorg-server/hw/dmx/input/dmxevents.c
index bcb5c2ed8..14ac05f5c 100644
--- a/xorg-server/hw/dmx/input/dmxevents.c
+++ b/xorg-server/hw/dmx/input/dmxevents.c
@@ -701,7 +701,6 @@ dmxEnqueue(DevicePtr pDev, int type, int detail, KeySym keySym,
XEvent * e, DMXBlockType block)
{
GETDMXINPUTFROMPDEV;
- xEvent xE;
DeviceIntPtr p = dmxLocal->pDevice;
int valuators[3];
ValuatorMask mask;
@@ -716,7 +715,7 @@ dmxEnqueue(DevicePtr pDev, int type, int detail, KeySym keySym,
if (dmxCheckFunctionKeys(dmxLocal, type, keySym))
return;
if (dmxLocal->sendsCore && dmxLocal != dmxLocalCoreKeyboard)
- xE.u.u.detail = dmxFixup(pDev, detail, keySym);
+ detail = dmxFixup(pDev, detail, keySym);
/*ErrorF("KEY %d sym %d\n", detail, (int) keySym); */
QueueKeyboardEvents(p, type, detail, NULL);
diff --git a/xorg-server/hw/dmx/input/dmxinputinit.c b/xorg-server/hw/dmx/input/dmxinputinit.c
index b22a41f56..abb6a8551 100644
--- a/xorg-server/hw/dmx/input/dmxinputinit.c
+++ b/xorg-server/hw/dmx/input/dmxinputinit.c
@@ -225,7 +225,7 @@ dmxKbdCtrl(DeviceIntPtr pDevice, KeybdCtrl * ctrl)
/* taken from kdrive/src/kinput.c: */
static void
-dmxBell(int volume, DeviceIntPtr pDev, pointer arg, int something)
+dmxBell(int volume, DeviceIntPtr pDev, void *arg, int something)
{
#if 0
KeybdCtrl *ctrl = arg;
@@ -336,7 +336,7 @@ _dmxKeyboardBellProc(DMXLocalInputInfoPtr dmxLocal, int percent)
* sound the bell on all of the devices that send core events. */
void
dmxKeyboardBellProc(int percent, DeviceIntPtr pDevice,
- pointer ctrl, int unknown)
+ void *ctrl, int unknown)
{
GETDMXLOCALFROMPDEVICE;
int i, j;
@@ -633,7 +633,7 @@ dmxCollectAll(DMXInputInfo * dmxInput)
}
static void
-dmxBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadMask)
+dmxBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadMask)
{
DMXInputInfo *dmxInput = &dmxInputs[(uintptr_t) blockData];
static unsigned long generation = 0;
@@ -645,7 +645,7 @@ dmxBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadMask)
}
static void
-dmxSwitchReturn(pointer p)
+dmxSwitchReturn(void *p)
{
DMXInputInfo *dmxInput = p;
int i;
@@ -662,7 +662,7 @@ dmxSwitchReturn(pointer p)
}
static void
-dmxWakeupHandler(pointer blockData, int result, pointer pReadMask)
+dmxWakeupHandler(void *blockData, int result, void *pReadMask)
{
DMXInputInfo *dmxInput = &dmxInputs[(uintptr_t) blockData];
int i;
@@ -921,7 +921,7 @@ dmxInputScanForExtensions(DMXInputInfo * dmxInput, int doXI)
break;
}
dmxLogInput(dmxInput, " %2d %-10.10s %-16.16s\n",
- devices[i].id,
+ (int) devices[i].id,
devices[i].name ? devices[i].name : "", use);
}
@@ -993,7 +993,6 @@ dmxInputLateReInit(DMXInputInfo * dmxInput)
void
dmxInputInit(DMXInputInfo * dmxInput)
{
- DeviceIntPtr pPointer = NULL, pKeyboard = NULL;
dmxArg a;
const char *name;
int i;
@@ -1108,12 +1107,6 @@ dmxInputInit(DMXInputInfo * dmxInput)
DMXLocalInputInfoPtr dmxLocal = dmxInput->devs[i];
dmxLocal->pDevice = dmxAddDevice(dmxLocal);
- if (dmxLocal->isCore) {
- if (dmxLocal->type == DMX_LOCAL_MOUSE)
- pPointer = dmxLocal->pDevice;
- if (dmxLocal->type == DMX_LOCAL_KEYBOARD)
- pKeyboard = dmxLocal->pDevice;
- }
}
dmxInput->processInputEvents = dmxProcessInputEvents;
@@ -1136,7 +1129,7 @@ dmxInputFreeLocal(DMXLocalInputInfoRec * local)
local->destroy_private(local->private);
free(local->history);
free(local->valuators);
- free(local->deviceName);
+ free((void *) local->deviceName);
local->private = NULL;
local->history = NULL;
local->deviceName = NULL;
@@ -1164,7 +1157,7 @@ dmxInputFree(DMXInputInfo * dmxInput)
dmxInput->devs = NULL;
dmxInput->numDevs = 0;
if (dmxInput->freename)
- free(dmxInput->name);
+ free((void *) dmxInput->name);
dmxInput->name = NULL;
}
@@ -1218,7 +1211,7 @@ dmxInputLogDevices(void)
dmxLogCont(dmxInfo, "\t[i%d/%*.*s",
dmxInput->inputIdx, len, len, dmxInput->name);
if (dmxInput->devs[i]->deviceId >= 0)
- dmxLogCont(dmxInfo, "/id%d", dmxInput->devs[i]->deviceId);
+ dmxLogCont(dmxInfo, "/id%d", (int) dmxInput->devs[i]->deviceId);
if (dmxInput->devs[i]->deviceName)
dmxLogCont(dmxInfo, "=%s", dmxInput->devs[i]->deviceName);
dmxLogCont(dmxInfo, "] %s\n",
diff --git a/xorg-server/hw/dmx/input/dmxinputinit.h b/xorg-server/hw/dmx/input/dmxinputinit.h
index 94ec1019b..11af2ca82 100644
--- a/xorg-server/hw/dmx/input/dmxinputinit.h
+++ b/xorg-server/hw/dmx/input/dmxinputinit.h
@@ -127,8 +127,8 @@ typedef struct _DMXLocalInitInfo {
KeySym *symbols; /**< Key symbols */
} DMXLocalInitInfo, *DMXLocalInitInfoPtr;
-typedef pointer (*dmxCreatePrivateProcPtr) (DeviceIntPtr);
-typedef void (*dmxDestroyPrivateProcPtr) (pointer);
+typedef void *(*dmxCreatePrivateProcPtr) (DeviceIntPtr);
+typedef void (*dmxDestroyPrivateProcPtr) (void *);
typedef void (*dmxInitProcPtr) (DevicePtr);
typedef void (*dmxReInitProcPtr) (DevicePtr);
@@ -136,13 +136,13 @@ typedef void (*dmxLateReInitProcPtr) (DevicePtr);
typedef void (*dmxGetInfoProcPtr) (DevicePtr, DMXLocalInitInfoPtr);
typedef int (*dmxOnProcPtr) (DevicePtr);
typedef void (*dmxOffProcPtr) (DevicePtr);
-typedef void (*dmxUpdatePositionProcPtr) (pointer, int x, int y);
+typedef void (*dmxUpdatePositionProcPtr) (void *, int x, int y);
-typedef void (*dmxVTPreSwitchProcPtr) (pointer); /* Turn I/O Off */
-typedef void (*dmxVTPostSwitchProcPtr) (pointer); /* Turn I/O On */
-typedef void (*dmxVTSwitchReturnProcPtr) (pointer);
-typedef int (*dmxVTSwitchProcPtr) (pointer, int vt,
- dmxVTSwitchReturnProcPtr, pointer);
+typedef void (*dmxVTPreSwitchProcPtr) (void *); /* Turn I/O Off */
+typedef void (*dmxVTPostSwitchProcPtr) (void *); /* Turn I/O On */
+typedef void (*dmxVTSwitchReturnProcPtr) (void *);
+typedef int (*dmxVTSwitchProcPtr) (void *, int vt,
+ dmxVTSwitchReturnProcPtr, void *);
typedef void (*dmxMotionProcPtr) (DevicePtr,
int *valuators,
@@ -157,9 +157,9 @@ typedef void (*dmxCollectEventsProcPtr) (DevicePtr,
dmxMotionProcPtr,
dmxEnqueueProcPtr,
dmxCheckSpecialProcPtr, DMXBlockType);
-typedef void (*dmxProcessInputProcPtr) (pointer);
-typedef void (*dmxUpdateInfoProcPtr) (pointer, DMXUpdateType, WindowPtr);
-typedef int (*dmxFunctionsProcPtr) (pointer, DMXFunctionType);
+typedef void (*dmxProcessInputProcPtr) (void *);
+typedef void (*dmxUpdateInfoProcPtr) (void *, DMXUpdateType, WindowPtr);
+typedef int (*dmxFunctionsProcPtr) (void *, DMXFunctionType);
typedef void (*dmxKBCtrlProcPtr) (DevicePtr, KeybdCtrl * ctrl);
typedef void (*dmxMCtrlProcPtr) (DevicePtr, PtrCtrl * ctrl);
@@ -223,7 +223,7 @@ typedef struct _DMXLocalInputInfo {
dmxKBCtrlProcPtr kCtrl; /**< Keyboard control */
dmxKBBellProcPtr kBell; /**< Bell control */
- pointer private; /**< Device-dependent private */
+ void *private; /**< Device-dependent private */
int isCore; /**< Is a DMX core device */
int sendsCore; /**< Sends DMX core events */
KeybdCtrl kctrl; /**< Keyboard control */
@@ -269,7 +269,7 @@ extern DMXLocalInputInfoPtr dmxInputCopyLocal(DMXInputInfo * dmxInput,
extern void dmxChangePointerControl(DeviceIntPtr pDevice, PtrCtrl * ctrl);
extern void dmxKeyboardKbdCtrlProc(DeviceIntPtr pDevice, KeybdCtrl * ctrl);
extern void dmxKeyboardBellProc(int percent, DeviceIntPtr pDevice,
- pointer ctrl, int unknown);
+ void *ctrl, int unknown);
extern int dmxInputExtensionErrorHandler(Display * dsp, _Xconst char *name,
_Xconst char *reason);
diff --git a/xorg-server/hw/dmx/input/lnx-keyboard.c b/xorg-server/hw/dmx/input/lnx-keyboard.c
index ecf4f591c..1a4d01f36 100644
--- a/xorg-server/hw/dmx/input/lnx-keyboard.c
+++ b/xorg-server/hw/dmx/input/lnx-keyboard.c
@@ -361,7 +361,7 @@ static unsigned char at2lnx[NUM_KEYCODES] = {
};
/** Create a private structure for use within this file. */
-pointer
+void *
kbdLinuxCreatePrivate(DeviceIntPtr pKeyboard)
{
myPrivate *priv = calloc(1, sizeof(*priv));
@@ -373,7 +373,7 @@ kbdLinuxCreatePrivate(DeviceIntPtr pKeyboard)
/** Destroy a private structure. */
void
-kbdLinuxDestroyPrivate(pointer priv)
+kbdLinuxDestroyPrivate(void *priv)
{
free(priv);
}
@@ -466,13 +466,13 @@ static int kbdLinuxActivate(int fd, int vtno, int setSig);
/** Currently unused hook called prior to an VT switch. */
void
-kbdLinuxVTPreSwitch(pointer p)
+kbdLinuxVTPreSwitch(void *p)
{
}
/** Currently unused hook called after returning from a VT switch. */
void
-kbdLinuxVTPostSwitch(pointer p)
+kbdLinuxVTPostSwitch(void *p)
{
}
@@ -481,8 +481,8 @@ kbdLinuxVTPostSwitch(pointer p)
* switched back to the pre-switch VT (i.e., the user returns to the DMX
* session). */
int
-kbdLinuxVTSwitch(pointer p, int vt,
- void (*switch_return) (pointer), pointer switch_return_data)
+kbdLinuxVTSwitch(void *p, int vt,
+ void (*switch_return) (void *), void *switch_return_data)
{
myPrivate *priv = p;
diff --git a/xorg-server/hw/dmx/input/lnx-keyboard.h b/xorg-server/hw/dmx/input/lnx-keyboard.h
index 891c6a9a4..857ea11b1 100644
--- a/xorg-server/hw/dmx/input/lnx-keyboard.h
+++ b/xorg-server/hw/dmx/input/lnx-keyboard.h
@@ -37,19 +37,19 @@
#ifndef _LNX_KEYBOARD_H_
#define _LNX_KEYBOARD_H_
-extern pointer kbdLinuxCreatePrivate(DeviceIntPtr pKeyboard);
-extern void kbdLinuxDestroyPrivate(pointer private);
+extern void *kbdLinuxCreatePrivate(DeviceIntPtr pKeyboard);
+extern void kbdLinuxDestroyPrivate(void *private);
extern void kbdLinuxInit(DevicePtr pDev);
extern void kbdLinuxGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
extern int kbdLinuxOn(DevicePtr pDev);
extern void kbdLinuxOff(DevicePtr pDev);
-extern void kbdLinuxVTPreSwitch(pointer p);
-extern void kbdLinuxVTPostSwitch(pointer p);
-extern int kbdLinuxVTSwitch(pointer p, int vt,
+extern void kbdLinuxVTPreSwitch(void *p);
+extern void kbdLinuxVTPostSwitch(void *p);
+extern int kbdLinuxVTSwitch(void *p, int vt,
dmxVTSwitchReturnProcPtr switch_return,
- pointer switch_return_data);
+ void *switch_return_data);
extern void kbdLinuxRead(DevicePtr pDev,
dmxMotionProcPtr motion,
diff --git a/xorg-server/hw/dmx/input/lnx-ms.c b/xorg-server/hw/dmx/input/lnx-ms.c
index 7e1acf450..210f6de22 100644
--- a/xorg-server/hw/dmx/input/lnx-ms.c
+++ b/xorg-server/hw/dmx/input/lnx-ms.c
@@ -302,18 +302,18 @@ msLinuxGetMap(DevicePtr pDev, unsigned char *map, int *nButtons)
/** Currently unused hook called prior to an VT switch. */
void
-msLinuxVTPreSwitch(pointer p)
+msLinuxVTPreSwitch(void *p)
{
}
/** Currently unused hook called after returning from a VT switch. */
void
-msLinuxVTPostSwitch(pointer p)
+msLinuxVTPostSwitch(void *p)
{
}
/** Create a private structure for use within this file. */
-pointer
+void *
msLinuxCreatePrivate(DeviceIntPtr pMouse)
{
myPrivate *priv = calloc(1, sizeof(*priv));
@@ -325,7 +325,7 @@ msLinuxCreatePrivate(DeviceIntPtr pMouse)
/** Destroy a private structure. */
void
-msLinuxDestroyPrivate(pointer priv)
+msLinuxDestroyPrivate(void *priv)
{
free(priv);
}
diff --git a/xorg-server/hw/dmx/input/lnx-ms.h b/xorg-server/hw/dmx/input/lnx-ms.h
index 28ed09557..7f3ba4ead 100644
--- a/xorg-server/hw/dmx/input/lnx-ms.h
+++ b/xorg-server/hw/dmx/input/lnx-ms.h
@@ -37,8 +37,8 @@
#ifndef _LNX_MS_H_
#define _LNX_MS_H_
-extern pointer msLinuxCreatePrivate(DeviceIntPtr pMouse);
-extern void msLinuxDestroyPrivate(pointer priv);
+extern void *msLinuxCreatePrivate(DeviceIntPtr pMouse);
+extern void msLinuxDestroyPrivate(void *priv);
extern void msLinuxRead(DevicePtr pDev,
dmxMotionProcPtr motion,
dmxEnqueueProcPtr enqueue,
@@ -49,7 +49,7 @@ extern void msLinuxGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
extern int msLinuxOn(DevicePtr pDev);
extern void msLinuxOff(DevicePtr pDev);
extern void msLinuxCtrl(DevicePtr pDev, PtrCtrl * ctrl);
-extern void msLinuxVTPreSwitch(pointer p);
-extern void msLinuxVTPostSwitch(pointer p);
+extern void msLinuxVTPreSwitch(void *p);
+extern void msLinuxVTPostSwitch(void *p);
#endif
diff --git a/xorg-server/hw/dmx/input/lnx-ps2.c b/xorg-server/hw/dmx/input/lnx-ps2.c
index 67c73a0c5..dd70cb8ea 100644
--- a/xorg-server/hw/dmx/input/lnx-ps2.c
+++ b/xorg-server/hw/dmx/input/lnx-ps2.c
@@ -272,18 +272,18 @@ ps2LinuxGetMap(DevicePtr pDev, unsigned char *map, int *nButtons)
/** Currently unused hook called prior to an VT switch. */
void
-ps2LinuxVTPreSwitch(pointer p)
+ps2LinuxVTPreSwitch(void *p)
{
}
/** Currently unused hook called after returning from a VT switch. */
void
-ps2LinuxVTPostSwitch(pointer p)
+ps2LinuxVTPostSwitch(void *p)
{
}
/** Create a private structure for use within this file. */
-pointer
+void *
ps2LinuxCreatePrivate(DeviceIntPtr pMouse)
{
myPrivate *priv = calloc(1, sizeof(*priv));
@@ -295,7 +295,7 @@ ps2LinuxCreatePrivate(DeviceIntPtr pMouse)
/** Destroy a private structure. */
void
-ps2LinuxDestroyPrivate(pointer priv)
+ps2LinuxDestroyPrivate(void *priv)
{
free(priv);
}
diff --git a/xorg-server/hw/dmx/input/lnx-ps2.h b/xorg-server/hw/dmx/input/lnx-ps2.h
index 93f0f0219..339f3538c 100644
--- a/xorg-server/hw/dmx/input/lnx-ps2.h
+++ b/xorg-server/hw/dmx/input/lnx-ps2.h
@@ -37,8 +37,8 @@
#ifndef _LNX_PS2_H_
#define _LNX_PS2_H_
-extern pointer ps2LinuxCreatePrivate(DeviceIntPtr pMouse);
-extern void ps2LinuxDestroyPrivate(pointer priv);
+extern void *ps2LinuxCreatePrivate(DeviceIntPtr pMouse);
+extern void ps2LinuxDestroyPrivate(void *priv);
extern void ps2LinuxRead(DevicePtr pDev,
dmxMotionProcPtr motion,
dmxEnqueueProcPtr enqueue,
@@ -49,7 +49,7 @@ extern void ps2LinuxGetInfo(DevicePtr pDev, DMXLocalInitInfoPtr info);
extern int ps2LinuxOn(DevicePtr pDev);
extern void ps2LinuxOff(DevicePtr pDev);
extern void ps2LinuxCtrl(DevicePtr pDev, PtrCtrl * ctrl);
-extern void ps2LinuxVTPreSwitch(pointer p);
-extern void ps2LinuxVTPostSwitch(pointer p);
+extern void ps2LinuxVTPreSwitch(void *p);
+extern void ps2LinuxVTPostSwitch(void *p);
#endif
diff --git a/xorg-server/hw/dmx/input/usb-common.c b/xorg-server/hw/dmx/input/usb-common.c
index c7c166cce..67aa07e0a 100644
--- a/xorg-server/hw/dmx/input/usb-common.c
+++ b/xorg-server/hw/dmx/input/usb-common.c
@@ -474,7 +474,7 @@ usbOff(DevicePtr pDev)
}
/** Create a private structure for use within this file. */
-pointer
+void *
usbCreatePrivate(DeviceIntPtr pDevice)
{
myPrivate *priv = calloc(1, sizeof(*priv));
@@ -486,7 +486,7 @@ usbCreatePrivate(DeviceIntPtr pDevice)
/** Destroy a private structure. */
void
-usbDestroyPrivate(pointer priv)
+usbDestroyPrivate(void *priv)
{
free(priv);
}
diff --git a/xorg-server/hw/dmx/input/usb-common.h b/xorg-server/hw/dmx/input/usb-common.h
index eea98afbe..71593765f 100644
--- a/xorg-server/hw/dmx/input/usb-common.h
+++ b/xorg-server/hw/dmx/input/usb-common.h
@@ -43,8 +43,8 @@ typedef enum {
usbOther
} usbType;
-extern pointer usbCreatePrivate(DeviceIntPtr pDevice);
-extern void usbDestroyPrivate(pointer priv);
+extern void *usbCreatePrivate(DeviceIntPtr pDevice);
+extern void usbDestroyPrivate(void *priv);
extern void usbRead(DevicePtr pDev,
dmxMotionProcPtr motion,
dmxEnqueueProcPtr enqueue,
diff --git a/xorg-server/hw/kdrive/ephyr/ephyr.c b/xorg-server/hw/kdrive/ephyr/ephyr.c
index ac988b2bc..6cf007602 100644
--- a/xorg-server/hw/kdrive/ephyr/ephyr.c
+++ b/xorg-server/hw/kdrive/ephyr/ephyr.c
@@ -344,7 +344,7 @@ ephyrInternalDamageRedisplay(ScreenPtr pScreen)
}
static void
-ephyrInternalDamageBlockHandler(pointer data, OSTimePtr pTimeout, pointer pRead)
+ephyrInternalDamageBlockHandler(void *data, OSTimePtr pTimeout, void *pRead)
{
ScreenPtr pScreen = (ScreenPtr) data;
@@ -352,7 +352,7 @@ ephyrInternalDamageBlockHandler(pointer data, OSTimePtr pTimeout, pointer pRead)
}
static void
-ephyrInternalDamageWakeupHandler(pointer data, int i, pointer LastSelectMask)
+ephyrInternalDamageWakeupHandler(void *data, int i, void *LastSelectMask)
{
/* FIXME: Not needed ? */
}
@@ -371,7 +371,7 @@ ephyrSetInternalDamage(ScreenPtr pScreen)
if (!RegisterBlockAndWakeupHandlers(ephyrInternalDamageBlockHandler,
ephyrInternalDamageWakeupHandler,
- (pointer) pScreen))
+ (void *) pScreen))
return FALSE;
pPixmap = (*pScreen->GetScreenPixmap) (pScreen);
@@ -392,7 +392,7 @@ ephyrUnsetInternalDamage(ScreenPtr pScreen)
RemoveBlockAndWakeupHandlers(ephyrInternalDamageBlockHandler,
ephyrInternalDamageWakeupHandler,
- (pointer) pScreen);
+ (void *) pScreen);
}
#ifdef RANDR
diff --git a/xorg-server/hw/kdrive/ephyr/ephyrinit.c b/xorg-server/hw/kdrive/ephyr/ephyrinit.c
index 218e3b00c..20e8033a9 100644
--- a/xorg-server/hw/kdrive/ephyr/ephyrinit.c
+++ b/xorg-server/hw/kdrive/ephyr/ephyrinit.c
@@ -150,8 +150,6 @@ ddxUseMsg(void)
ErrorF
("-title [title] set the window title in the WM_NAME property\n");
ErrorF("\n");
-
- exit(1);
}
#endif
diff --git a/xorg-server/hw/kdrive/ephyr/ephyrvideo.c b/xorg-server/hw/kdrive/ephyr/ephyrvideo.c
index 4a05721af..c6728351f 100644
--- a/xorg-server/hw/kdrive/ephyr/ephyrvideo.c
+++ b/xorg-server/hw/kdrive/ephyr/ephyrvideo.c
@@ -84,15 +84,15 @@ static Bool ephyrXVPrivSaveImageToPortPriv(EphyrPortPriv * a_port_priv,
int a_image_len);
static void ephyrStopVideo(KdScreenInfo * a_info,
- pointer a_xv_priv, Bool a_exit);
+ void *a_xv_priv, Bool a_exit);
static int ephyrSetPortAttribute(KdScreenInfo * a_info,
Atom a_attr_name,
- int a_attr_value, pointer a_port_priv);
+ int a_attr_value, void *a_port_priv);
static int ephyrGetPortAttribute(KdScreenInfo * a_screen_info,
Atom a_attr_name,
- int *a_attr_value, pointer a_port_priv);
+ int *a_attr_value, void *a_port_priv);
static void ephyrQueryBestSize(KdScreenInfo * a_info,
Bool a_motion,
@@ -101,7 +101,7 @@ static void ephyrQueryBestSize(KdScreenInfo * a_info,
short a_drw_w,
short a_drw_h,
unsigned int *a_prefered_w,
- unsigned int *a_prefered_h, pointer a_port_priv);
+ unsigned int *a_prefered_h, void *a_port_priv);
static int ephyrPutImage(KdScreenInfo * a_info,
DrawablePtr a_drawable,
@@ -118,13 +118,13 @@ static int ephyrPutImage(KdScreenInfo * a_info,
short a_width,
short a_height,
Bool a_sync,
- RegionPtr a_clipping_region, pointer a_port_priv);
+ RegionPtr a_clipping_region, void *a_port_priv);
static int ephyrReputImage(KdScreenInfo * a_info,
DrawablePtr a_drawable,
short a_drw_x,
short a_drw_y,
- RegionPtr a_clipping_region, pointer a_port_priv);
+ RegionPtr a_clipping_region, void *a_port_priv);
static int ephyrPutVideo(KdScreenInfo * a_info,
DrawablePtr a_drawable,
@@ -132,7 +132,7 @@ static int ephyrPutVideo(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clip_region, pointer a_port_priv);
+ RegionPtr a_clip_region, void *a_port_priv);
static int ephyrGetVideo(KdScreenInfo * a_info,
DrawablePtr a_drawable,
@@ -140,7 +140,7 @@ static int ephyrGetVideo(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clip_region, pointer a_port_priv);
+ RegionPtr a_clip_region, void *a_port_priv);
static int ephyrPutStill(KdScreenInfo * a_info,
DrawablePtr a_drawable,
@@ -148,7 +148,7 @@ static int ephyrPutStill(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clip_region, pointer a_port_priv);
+ RegionPtr a_clip_region, void *a_port_priv);
static int ephyrGetStill(KdScreenInfo * a_info,
DrawablePtr a_drawable,
@@ -156,7 +156,7 @@ static int ephyrGetStill(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clip_region, pointer a_port_priv);
+ RegionPtr a_clip_region, void *a_port_priv);
static int ephyrQueryImageAttributes(KdScreenInfo * a_info,
int a_id,
@@ -744,7 +744,7 @@ ephyrXVPrivSaveImageToPortPriv(EphyrPortPriv * a_port_priv,
}
static void
-ephyrStopVideo(KdScreenInfo * a_info, pointer a_port_priv, Bool a_exit)
+ephyrStopVideo(KdScreenInfo * a_info, void *a_port_priv, Bool a_exit)
{
xcb_connection_t *conn = hostx_get_xcbconn();
EphyrPortPriv *port_priv = a_port_priv;
@@ -759,7 +759,7 @@ ephyrStopVideo(KdScreenInfo * a_info, pointer a_port_priv, Bool a_exit)
static int
ephyrSetPortAttribute(KdScreenInfo * a_info,
- Atom a_attr_name, int a_attr_value, pointer a_port_priv)
+ Atom a_attr_name, int a_attr_value, void *a_port_priv)
{
xcb_connection_t *conn = hostx_get_xcbconn();
int res = Success, host_atom = 0;
@@ -814,7 +814,7 @@ ephyrSetPortAttribute(KdScreenInfo * a_info,
static int
ephyrGetPortAttribute(KdScreenInfo * a_screen_info,
- Atom a_attr_name, int *a_attr_value, pointer a_port_priv)
+ Atom a_attr_name, int *a_attr_value, void *a_port_priv)
{
xcb_connection_t *conn = hostx_get_xcbconn();
int res = Success, host_atom = 0;
@@ -862,7 +862,7 @@ ephyrQueryBestSize(KdScreenInfo * a_info,
short a_drw_w,
short a_drw_h,
unsigned int *a_prefered_w,
- unsigned int *a_prefered_h, pointer a_port_priv)
+ unsigned int *a_prefered_h, void *a_port_priv)
{
xcb_connection_t *conn = hostx_get_xcbconn();
EphyrPortPriv *port_priv = a_port_priv;
@@ -992,7 +992,7 @@ ephyrPutImage(KdScreenInfo * a_info,
unsigned char *a_buf,
short a_width,
short a_height,
- Bool a_sync, RegionPtr a_clipping_region, pointer a_port_priv)
+ Bool a_sync, RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrPortPriv *port_priv = a_port_priv;
Bool is_ok = FALSE;
@@ -1064,7 +1064,7 @@ static int
ephyrReputImage(KdScreenInfo * a_info,
DrawablePtr a_drawable,
short a_drw_x,
- short a_drw_y, RegionPtr a_clipping_region, pointer a_port_priv)
+ short a_drw_y, RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrPortPriv *port_priv = a_port_priv;
int result = BadImplementation;
@@ -1107,7 +1107,7 @@ ephyrPutVideo(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clipping_region, pointer a_port_priv)
+ RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrScrPriv *scrpriv = a_info->driver;
xcb_connection_t *conn = hostx_get_xcbconn();
@@ -1138,7 +1138,7 @@ ephyrGetVideo(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clipping_region, pointer a_port_priv)
+ RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrScrPriv *scrpriv = a_info->driver;
xcb_connection_t *conn = hostx_get_xcbconn();
@@ -1170,7 +1170,7 @@ ephyrPutStill(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clipping_region, pointer a_port_priv)
+ RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrScrPriv *scrpriv = a_info->driver;
xcb_connection_t *conn = hostx_get_xcbconn();
@@ -1201,7 +1201,7 @@ ephyrGetStill(KdScreenInfo * a_info,
short a_drw_x, short a_drw_y,
short a_vid_w, short a_vid_h,
short a_drw_w, short a_drw_h,
- RegionPtr a_clipping_region, pointer a_port_priv)
+ RegionPtr a_clipping_region, void *a_port_priv)
{
EphyrScrPriv *scrpriv = a_info->driver;
xcb_connection_t *conn = hostx_get_xcbconn();
diff --git a/xorg-server/hw/kdrive/ephyr/hostx.c b/xorg-server/hw/kdrive/ephyr/hostx.c
index 873033373..dcf7af006 100644
--- a/xorg-server/hw/kdrive/ephyr/hostx.c
+++ b/xorg-server/hw/kdrive/ephyr/hostx.c
@@ -87,8 +87,6 @@ static int HostXWantDamageDebug = 0;
extern EphyrKeySyms ephyrKeySyms;
-extern int monitorResolution;
-
extern Bool EphyrWantResize;
char *ephyrResName = NULL;
diff --git a/xorg-server/hw/kdrive/linux/linux.c b/xorg-server/hw/kdrive/linux/linux.c
index 00de2ae0e..6284de576 100644
--- a/xorg-server/hw/kdrive/linux/linux.c
+++ b/xorg-server/hw/kdrive/linux/linux.c
@@ -167,14 +167,14 @@ LinuxSetSwitchMode(int mode)
}
static void
-LinuxApmBlock(pointer blockData, OSTimePtr pTimeout, pointer pReadmask)
+LinuxApmBlock(void *blockData, OSTimePtr pTimeout, void *pReadmask)
{
}
static Bool LinuxApmRunning;
static void
-LinuxApmWakeup(pointer blockData, int result, pointer pReadmask)
+LinuxApmWakeup(void *blockData, int result, void *pReadmask)
{
fd_set *readmask = (fd_set *) pReadmask;
diff --git a/xorg-server/hw/kdrive/src/kcmap.c b/xorg-server/hw/kdrive/src/kcmap.c
index c93c2f4d3..0970064f6 100644
--- a/xorg-server/hw/kdrive/src/kcmap.c
+++ b/xorg-server/hw/kdrive/src/kcmap.c
@@ -138,7 +138,7 @@ KdInstallColormap(ColormapPtr pCmap)
/* Tell X clients that the installed colormap is going away. */
if (pScreenPriv->pInstalledmap)
WalkTree(pScreenPriv->pInstalledmap->pScreen, TellLostMap,
- (pointer) &(pScreenPriv->pInstalledmap->mid));
+ (void *) &(pScreenPriv->pInstalledmap->mid));
/* Take note of the new installed colorscreen-> */
pScreenPriv->pInstalledmap = pCmap;
@@ -146,7 +146,7 @@ KdInstallColormap(ColormapPtr pCmap)
KdSetColormap(pCmap->pScreen);
/* Tell X clients of the new colormap */
- WalkTree(pCmap->pScreen, TellGainedMap, (pointer) &(pCmap->mid));
+ WalkTree(pCmap->pScreen, TellGainedMap, (void *) &(pCmap->mid));
}
/*
@@ -173,13 +173,13 @@ KdUninstallColormap(ColormapPtr pCmap)
return;
/* install default */
- dixLookupResourceByType((pointer *) &defMap, defMapID, RT_COLORMAP,
+ dixLookupResourceByType((void **) &defMap, defMapID, RT_COLORMAP,
serverClient, DixInstallAccess);
if (defMap)
(*pCmap->pScreen->InstallColormap) (defMap);
else {
/* uninstall and clear colormap pointer */
- WalkTree(pCmap->pScreen, TellLostMap, (pointer) &(pCmap->mid));
+ WalkTree(pCmap->pScreen, TellLostMap, (void *) &(pCmap->mid));
pScreenPriv->pInstalledmap = 0;
}
}
diff --git a/xorg-server/hw/kdrive/src/kdrive.c b/xorg-server/hw/kdrive/src/kdrive.c
index d56ba8fc5..d55bcd0d4 100644
--- a/xorg-server/hw/kdrive/src/kdrive.c
+++ b/xorg-server/hw/kdrive/src/kdrive.c
@@ -667,7 +667,7 @@ KdCloseScreen(ScreenPtr pScreen)
pScreenPriv->screen->pScreen = 0;
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
return ret;
}
diff --git a/xorg-server/hw/kdrive/src/kdrive.h b/xorg-server/hw/kdrive/src/kdrive.h
index f52072003..5b2f3378b 100644
--- a/xorg-server/hw/kdrive/src/kdrive.h
+++ b/xorg-server/hw/kdrive/src/kdrive.h
@@ -526,11 +526,11 @@ void
KdSetLed(KdKeyboardInfo * ki, int led, Bool on);
void
- KdSetPointerMatrix(KdPointerMatrix * pointer);
+ KdSetPointerMatrix(KdPointerMatrix *pointer);
void
-KdComputePointerMatrix(KdPointerMatrix * pointer, Rotation randr, int width,
+KdComputePointerMatrix(KdPointerMatrix *pointer, Rotation randr, int width,
int height);
void
@@ -538,11 +538,11 @@ void
void
-KdBlockHandler(ScreenPtr pScreen, pointer timeout, pointer readmask);
+KdBlockHandler(ScreenPtr pScreen, void *timeout, void *readmask);
void
-KdWakeupHandler(ScreenPtr pScreen, unsigned long result, pointer readmask);
+KdWakeupHandler(ScreenPtr pScreen, unsigned long result, void *readmask);
void
KdDisableInput(void);
diff --git a/xorg-server/hw/kdrive/src/kinput.c b/xorg-server/hw/kdrive/src/kinput.c
index d5171a7f7..9ecd73013 100644
--- a/xorg-server/hw/kdrive/src/kinput.c
+++ b/xorg-server/hw/kdrive/src/kinput.c
@@ -555,7 +555,7 @@ LegalModifier(unsigned int key, DeviceIntPtr pDev)
#endif
static void
-KdBell(int volume, DeviceIntPtr pDev, pointer arg, int something)
+KdBell(int volume, DeviceIntPtr pDev, void *arg, int something)
{
KeybdCtrl *ctrl = arg;
KdKeyboardInfo *ki = NULL;
@@ -1963,7 +1963,7 @@ _KdEnqueuePointerEvent(KdPointerInfo * pi, int type, int x, int y, int z,
}
void
-KdBlockHandler(ScreenPtr pScreen, pointer timeout, pointer readmask)
+KdBlockHandler(ScreenPtr pScreen, void *timeout, void *readmask)
{
KdPointerInfo *pi;
int myTimeout = 0;
@@ -1989,7 +1989,7 @@ KdBlockHandler(ScreenPtr pScreen, pointer timeout, pointer readmask)
}
void
-KdWakeupHandler(ScreenPtr pScreen, unsigned long lresult, pointer readmask)
+KdWakeupHandler(ScreenPtr pScreen, unsigned long lresult, void *readmask)
{
int result = (int) lresult;
fd_set *pReadmask = (fd_set *) readmask;
diff --git a/xorg-server/hw/kdrive/src/kxv.c b/xorg-server/hw/kdrive/src/kxv.c
index 22639728d..9e76eadf0 100644
--- a/xorg-server/hw/kdrive/src/kxv.c
+++ b/xorg-server/hw/kdrive/src/kxv.c
@@ -208,7 +208,7 @@ KdXVScreenInit(ScreenPtr pScreen, KdVideoAdaptorPtr * adaptors, int num)
sure that I appreciate that. */
ScreenPriv = malloc(sizeof(KdXVScreenRec));
- pxvs->devPriv.ptr = (pointer) ScreenPriv;
+ pxvs->devPriv.ptr = (void *) ScreenPriv;
if (!ScreenPriv)
return FALSE;
@@ -487,7 +487,7 @@ KdXVInitAdaptors(ScreenPtr pScreen, KdVideoAdaptorPtr * infoPtr, int number)
adaptorPriv->PutImage = adaptorPtr->PutImage;
adaptorPriv->ReputImage = adaptorPtr->ReputImage;
- pa->devPriv.ptr = (pointer) adaptorPriv;
+ pa->devPriv.ptr = (void *) adaptorPriv;
if (!(pPort = calloc(adaptorPtr->nPorts, sizeof(XvPortRec)))) {
KdXVFreeAdaptor(pa);
@@ -874,7 +874,7 @@ KdXVReputImage(XvPortRecPrivatePtr portPriv)
}
static int
-KdXVReputAllVideo(WindowPtr pWin, pointer data)
+KdXVReputAllVideo(WindowPtr pWin, void *data)
{
KdXVWindowPtr WinPriv;
diff --git a/xorg-server/hw/kdrive/src/kxv.h b/xorg-server/hw/kdrive/src/kxv.h
index 29118bc96..4f644c246 100644
--- a/xorg-server/hw/kdrive/src/kxv.h
+++ b/xorg-server/hw/kdrive/src/kxv.h
@@ -98,41 +98,41 @@ typedef int (*PutVideoFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short vid_x, short vid_y, short drw_x,
short drw_y, short vid_w, short vid_h,
short drw_w, short drw_h, RegionPtr clipBoxes,
- pointer data);
+ void *data);
typedef int (*PutStillFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short vid_x, short vid_y, short drw_x,
short drw_y, short vid_w, short vid_h,
short drw_w, short drw_h, RegionPtr clipBoxes,
- pointer data);
+ void *data);
typedef int (*GetVideoFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short vid_x, short vid_y, short drw_x,
short drw_y, short vid_w, short vid_h,
short drw_w, short drw_h, RegionPtr clipBoxes,
- pointer data);
+ void *data);
typedef int (*GetStillFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short vid_x, short vid_y, short drw_x,
short drw_y, short vid_w, short vid_h,
short drw_w, short drw_h, RegionPtr clipBoxes,
- pointer data);
-typedef void (*StopVideoFuncPtr) (KdScreenInfo * screen, pointer data,
+ void *data);
+typedef void (*StopVideoFuncPtr) (KdScreenInfo * screen, void *data,
Bool Exit);
typedef int (*SetPortAttributeFuncPtr) (KdScreenInfo * screen, Atom attribute,
- int value, pointer data);
+ int value, void *data);
typedef int (*GetPortAttributeFuncPtr) (KdScreenInfo * screen, Atom attribute,
- int *value, pointer data);
+ int *value, void *data);
typedef void (*QueryBestSizeFuncPtr) (KdScreenInfo * screen, Bool motion,
short vid_w, short vid_h, short drw_w,
short drw_h, unsigned int *p_w,
- unsigned int *p_h, pointer data);
+ unsigned int *p_h, void *data);
typedef int (*PutImageFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short src_x, short src_y, short drw_x,
short drw_y, short src_w, short src_h,
short drw_w, short drw_h, int image,
unsigned char *buf, short width, short height,
- Bool Sync, RegionPtr clipBoxes, pointer data);
+ Bool Sync, RegionPtr clipBoxes, void *data);
typedef int (*ReputImageFuncPtr) (KdScreenInfo * screen, DrawablePtr pDraw,
short drw_x, short drw_y, RegionPtr clipBoxes,
- pointer data);
+ void *data);
typedef int (*QueryImageAttributesFuncPtr) (KdScreenInfo * screen, int image,
unsigned short *width,
unsigned short *height,
diff --git a/xorg-server/hw/vfb/InitOutput.c b/xorg-server/hw/vfb/InitOutput.c
index 97eccfd4e..d10272244 100644
--- a/xorg-server/hw/vfb/InitOutput.c
+++ b/xorg-server/hw/vfb/InitOutput.c
@@ -404,7 +404,6 @@ vfbInstallColormap(ColormapPtr pmap)
if (pmap != oldpmap) {
int entries;
XWDFileHeader *pXWDHeader;
- XWDColor *pXWDCmap;
VisualPtr pVisual;
Pixel *ppix;
xrgb *prgb;
@@ -419,7 +418,6 @@ vfbInstallColormap(ColormapPtr pmap)
entries = pmap->pVisual->ColormapEntries;
pXWDHeader = vfbScreens[pmap->pScreen->myNum].pXWDHeader;
- pXWDCmap = vfbScreens[pmap->pScreen->myNum].pXWDCmap;
pVisual = pmap->pVisual;
swapcopy32(pXWDHeader->visual_class, pVisual->class);
@@ -460,7 +458,7 @@ vfbUninstallColormap(ColormapPtr pmap)
if (pmap == curpmap) {
if (pmap->mid != pmap->pScreen->defColormap) {
- dixLookupResourceByType((pointer *) &curpmap,
+ dixLookupResourceByType((void **) &curpmap,
pmap->pScreen->defColormap,
RT_COLORMAP, serverClient,
DixInstallAccess);
@@ -508,7 +506,7 @@ vfbSaveScreen(ScreenPtr pScreen, int on)
/* this flushes any changes to the screens out to the mmapped file */
static void
-vfbBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadmask)
+vfbBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadmask)
{
int i;
@@ -529,7 +527,7 @@ vfbBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadmask)
}
static void
-vfbWakeupHandler(pointer blockData, int result, pointer pReadmask)
+vfbWakeupHandler(void *blockData, int result, void *pReadmask)
{
}
diff --git a/xorg-server/hw/xfree86/Makefile.am b/xorg-server/hw/xfree86/Makefile.am
index 15670d01d..96729043d 100644
--- a/xorg-server/hw/xfree86/Makefile.am
+++ b/xorg-server/hw/xfree86/Makefile.am
@@ -121,7 +121,7 @@ sdksyms.dep sdksyms.c: sdksyms.sh
$(AM_V_GEN)CPP='$(CPP)' AWK='$(AWK)' $(SHELL) $(srcdir)/sdksyms.sh $(top_srcdir) $(CFLAGS) $(AM_CFLAGS) $(AM_CPPFLAGS)
SDKSYMS_DEP = sdksyms.dep
-include $(SDKSYMS_DEP)
+-include $(SDKSYMS_DEP)
i2c/libi2c.la:
$(AM_V_at)cd i2c && $(MAKE) libi2c.la
diff --git a/xorg-server/hw/xfree86/common/dgaproc.h b/xorg-server/hw/xfree86/common/dgaproc.h
index e824d3094..87e923f26 100644
--- a/xorg-server/hw/xfree86/common/dgaproc.h
+++ b/xorg-server/hw/xfree86/common/dgaproc.h
@@ -24,7 +24,7 @@
typedef struct {
int num; /* A unique identifier for the mode (num > 0) */
- char *name; /* name of mode given in the XF86Config */
+ const char *name; /* name of mode given in the XF86Config */
int VSync_num;
int VSync_den;
int flags; /* DGA_CONCURRENT_ACCESS, etc... */
diff --git a/xorg-server/hw/xfree86/common/vidmodeproc.h b/xorg-server/hw/xfree86/common/vidmodeproc.h
index 311d35c7b..cff340c47 100644
--- a/xorg-server/hw/xfree86/common/vidmodeproc.h
+++ b/xorg-server/hw/xfree86/common/vidmodeproc.h
@@ -34,7 +34,7 @@ typedef enum {
} VidModeSelectMonitor;
typedef union {
- pointer ptr;
+ const void *ptr;
int i;
float f;
} vidMonitorValue;
@@ -42,38 +42,38 @@ typedef union {
extern Bool VidModeExtensionInit(ScreenPtr pScreen);
extern _X_EXPORT Bool VidModeAvailable(int scrnIndex);
-extern _X_EXPORT Bool VidModeGetCurrentModeline(int scrnIndex, pointer *mode,
+extern _X_EXPORT Bool VidModeGetCurrentModeline(int scrnIndex, void **mode,
int *dotClock);
-extern _X_EXPORT Bool VidModeGetFirstModeline(int scrnIndex, pointer *mode,
+extern _X_EXPORT Bool VidModeGetFirstModeline(int scrnIndex, void **mode,
int *dotClock);
-extern _X_EXPORT Bool VidModeGetNextModeline(int scrnIndex, pointer *mode,
+extern _X_EXPORT Bool VidModeGetNextModeline(int scrnIndex, void **mode,
int *dotClock);
-extern _X_EXPORT Bool VidModeDeleteModeline(int scrnIndex, pointer mode);
+extern _X_EXPORT Bool VidModeDeleteModeline(int scrnIndex, void *mode);
extern _X_EXPORT Bool VidModeZoomViewport(int scrnIndex, int zoom);
extern _X_EXPORT Bool VidModeGetViewPort(int scrnIndex, int *x, int *y);
extern _X_EXPORT Bool VidModeSetViewPort(int scrnIndex, int x, int y);
-extern _X_EXPORT Bool VidModeSwitchMode(int scrnIndex, pointer mode);
+extern _X_EXPORT Bool VidModeSwitchMode(int scrnIndex, void *mode);
extern _X_EXPORT Bool VidModeLockZoom(int scrnIndex, Bool lock);
-extern _X_EXPORT Bool VidModeGetMonitor(int scrnIndex, pointer *monitor);
+extern _X_EXPORT Bool VidModeGetMonitor(int scrnIndex, void **monitor);
extern _X_EXPORT int VidModeGetNumOfClocks(int scrnIndex, Bool *progClock);
extern _X_EXPORT Bool VidModeGetClocks(int scrnIndex, int *Clocks);
extern _X_EXPORT ModeStatus VidModeCheckModeForMonitor(int scrnIndex,
- pointer mode);
+ void *mode);
extern _X_EXPORT ModeStatus VidModeCheckModeForDriver(int scrnIndex,
- pointer mode);
-extern _X_EXPORT void VidModeSetCrtcForMode(int scrnIndex, pointer mode);
-extern _X_EXPORT Bool VidModeAddModeline(int scrnIndex, pointer mode);
+ void *mode);
+extern _X_EXPORT void VidModeSetCrtcForMode(int scrnIndex, void *mode);
+extern _X_EXPORT Bool VidModeAddModeline(int scrnIndex, void *mode);
extern _X_EXPORT int VidModeGetDotClock(int scrnIndex, int Clock);
extern _X_EXPORT int VidModeGetNumOfModes(int scrnIndex);
extern _X_EXPORT Bool VidModeSetGamma(int scrnIndex, float red, float green,
float blue);
extern _X_EXPORT Bool VidModeGetGamma(int scrnIndex, float *red, float *green,
float *blue);
-extern _X_EXPORT pointer VidModeCreateMode(void);
-extern _X_EXPORT void VidModeCopyMode(pointer modefrom, pointer modeto);
-extern _X_EXPORT int VidModeGetModeValue(pointer mode, int valtyp);
-extern _X_EXPORT void VidModeSetModeValue(pointer mode, int valtyp, int val);
-extern _X_EXPORT vidMonitorValue VidModeGetMonitorValue(pointer monitor,
+extern _X_EXPORT void *VidModeCreateMode(void);
+extern _X_EXPORT void VidModeCopyMode(void *modefrom, void *modeto);
+extern _X_EXPORT int VidModeGetModeValue(void *mode, int valtyp);
+extern _X_EXPORT void VidModeSetModeValue(void *mode, int valtyp, int val);
+extern _X_EXPORT vidMonitorValue VidModeGetMonitorValue(void *monitor,
int valtyp, int indx);
extern _X_EXPORT Bool VidModeSetGammaRamp(int, int, CARD16 *, CARD16 *,
CARD16 *);
diff --git a/xorg-server/hw/xfree86/common/xf86.h b/xorg-server/hw/xfree86/common/xf86.h
index eada01cf9..89025fe11 100644
--- a/xorg-server/hw/xfree86/common/xf86.h
+++ b/xorg-server/hw/xfree86/common/xf86.h
@@ -128,7 +128,7 @@ extern _X_EXPORT ScrnInfoPtr xf86ConfigPciEntity(ScrnInfoPtr pScrn,
void *dummy, EntityProc init,
EntityProc enter,
EntityProc leave,
- pointer private);
+ void *private);
/* Obsolete! don't use */
extern _X_EXPORT Bool xf86ConfigActivePciEntity(ScrnInfoPtr pScrn,
int entityIndex,
@@ -136,7 +136,7 @@ extern _X_EXPORT Bool xf86ConfigActivePciEntity(ScrnInfoPtr pScrn,
void *dummy, EntityProc init,
EntityProc enter,
EntityProc leave,
- pointer private);
+ void *private);
#else
#define xf86VGAarbiterInit() do {} while (0)
#define xf86VGAarbiterFini() do {} while (0)
@@ -166,7 +166,7 @@ extern _X_EXPORT void xf86RemoveEntityFromScreen(ScrnInfoPtr pScrn,
extern _X_EXPORT EntityInfoPtr xf86GetEntityInfo(int entityIndex);
extern _X_EXPORT Bool xf86SetEntityFuncs(int entityIndex, EntityProc init,
EntityProc enter, EntityProc leave,
- pointer);
+ void *);
extern _X_EXPORT Bool xf86IsEntityPrimary(int entityIndex);
extern _X_EXPORT ScrnInfoPtr xf86FindScreenForEntity(int entityIndex);
@@ -203,11 +203,6 @@ extern _X_EXPORT void xf86ReconfigureLayout(void);
extern _X_EXPORT Bool xf86DPMSInit(ScreenPtr pScreen, DPMSSetProcPtr set,
int flags);
-#ifdef DPMSExtension
-extern _X_EXPORT int DPMSSet(ClientPtr client, int level);
-extern _X_EXPORT Bool DPMSSupported(void);
-#endif
-
/* xf86DGA.c */
#ifdef XFreeXDGA
@@ -221,18 +216,18 @@ extern _X_EXPORT xf86SetDGAModeProc xf86SetDGAMode;
/* xf86Events.c */
extern _X_EXPORT void SetTimeSinceLastInputEvent(void);
-extern _X_EXPORT pointer xf86AddInputHandler(int fd, InputHandlerProc proc,
- pointer data);
-extern _X_EXPORT int xf86RemoveInputHandler(pointer handler);
-extern _X_EXPORT void xf86DisableInputHandler(pointer handler);
-extern _X_EXPORT void xf86EnableInputHandler(pointer handler);
-extern _X_EXPORT pointer xf86AddGeneralHandler(int fd, InputHandlerProc proc,
- pointer data);
-extern _X_EXPORT int xf86RemoveGeneralHandler(pointer handler);
-extern _X_EXPORT void xf86DisableGeneralHandler(pointer handler);
-extern _X_EXPORT void xf86EnableGeneralHandler(pointer handler);
+extern _X_EXPORT void *xf86AddInputHandler(int fd, InputHandlerProc proc,
+ void *data);
+extern _X_EXPORT int xf86RemoveInputHandler(void *handler);
+extern _X_EXPORT void xf86DisableInputHandler(void *handler);
+extern _X_EXPORT void xf86EnableInputHandler(void *handler);
+extern _X_EXPORT void *xf86AddGeneralHandler(int fd, InputHandlerProc proc,
+ void *data);
+extern _X_EXPORT int xf86RemoveGeneralHandler(void *handler);
+extern _X_EXPORT void xf86DisableGeneralHandler(void *handler);
+extern _X_EXPORT void xf86EnableGeneralHandler(void *handler);
extern _X_EXPORT InputHandlerProc xf86SetConsoleHandler(InputHandlerProc
- handler, pointer data);
+ handler, void *data);
extern _X_EXPORT void xf86InterceptSignals(int *signo);
extern _X_EXPORT void xf86InterceptSigIll(void (*sigillhandler) (void));
extern _X_EXPORT Bool xf86EnableVTSwitch(Bool new);
@@ -242,7 +237,7 @@ extern _X_EXPORT Bool xf86VTOwner(void);
/* xf86Helper.c */
-extern _X_EXPORT void xf86AddDriver(DriverPtr driver, pointer module,
+extern _X_EXPORT void xf86AddDriver(DriverPtr driver, void *module,
int flags);
extern _X_EXPORT void xf86DeleteDriver(int drvIndex);
extern _X_EXPORT ScrnInfoPtr xf86AllocateScreen(DriverPtr drv, int flags);
@@ -333,36 +328,36 @@ xf86DisableRandR(void);
extern _X_EXPORT CARD32
xorgGetVersion(void);
extern _X_EXPORT CARD32
-xf86GetModuleVersion(pointer module);
-extern _X_EXPORT pointer
+xf86GetModuleVersion(void *module);
+extern _X_EXPORT void *
xf86LoadDrvSubModule(DriverPtr drv, const char *name);
-extern _X_EXPORT pointer
+extern _X_EXPORT void *
xf86LoadSubModule(ScrnInfoPtr pScrn, const char *name);
-extern _X_EXPORT pointer
-xf86LoadOneModule(char *name, pointer optlist);
+extern _X_EXPORT void *
+xf86LoadOneModule(const char *name, void *optlist);
extern _X_EXPORT void
-xf86UnloadSubModule(pointer mod);
+xf86UnloadSubModule(void *mod);
extern _X_EXPORT Bool
xf86LoaderCheckSymbol(const char *name);
extern _X_EXPORT void
xf86SetBackingStore(ScreenPtr pScreen);
extern _X_EXPORT void
xf86SetSilkenMouse(ScreenPtr pScreen);
-extern _X_EXPORT pointer
-xf86FindXvOptions(ScrnInfoPtr pScrn, int adapt_index, char *port_name,
- char **adaptor_name, pointer *adaptor_options);
+extern _X_EXPORT void *
+xf86FindXvOptions(ScrnInfoPtr pScrn, int adapt_index, const char *port_name,
+ const char **adaptor_name, void **adaptor_options);
extern _X_EXPORT void
xf86GetOS(const char **name, int *major, int *minor, int *teeny);
extern _X_EXPORT ScrnInfoPtr
xf86ConfigFbEntity(ScrnInfoPtr pScrn, int scrnFlag,
int entityIndex, EntityProc init,
- EntityProc enter, EntityProc leave, pointer private);
+ EntityProc enter, EntityProc leave, void *private);
extern _X_EXPORT Bool
xf86IsScreenPrimary(ScrnInfoPtr pScrn);
extern _X_EXPORT int
xf86RegisterRootWindowProperty(int ScrnIndex, Atom property, Atom type,
- int format, unsigned long len, pointer value);
+ int format, unsigned long len, void *value);
extern _X_EXPORT Bool
xf86IsUnblank(int mode);
@@ -394,7 +389,7 @@ extern _X_EXPORT ModeStatus
xf86CheckModeForDriver(ScrnInfoPtr scrp, DisplayModePtr mode, int flags);
extern _X_EXPORT int
xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
- char **modeNames, ClockRangePtr clockRanges,
+ const char **modeNames, ClockRangePtr clockRanges,
int *linePitches, int minPitch, int maxPitch,
int minHeight, int maxHeight, int pitchInc,
int virtualX, int virtualY, int apertureSize,
diff --git a/xorg-server/hw/xfree86/common/xf86AutoConfig.c b/xorg-server/hw/xfree86/common/xf86AutoConfig.c
index af2b7f8f2..4eb86de22 100644
--- a/xorg-server/hw/xfree86/common/xf86AutoConfig.c
+++ b/xorg-server/hw/xfree86/common/xf86AutoConfig.c
@@ -300,6 +300,7 @@ copyScreen(confScreenPtr oscreen, GDevPtr odev, int i, char *driver)
{
confScreenPtr nscreen;
GDevPtr cptr = NULL;
+ char *identifier;
nscreen = malloc(sizeof(confScreenRec));
if (!nscreen)
@@ -313,13 +314,14 @@ copyScreen(confScreenPtr oscreen, GDevPtr odev, int i, char *driver)
}
memcpy(cptr, odev, sizeof(GDevRec));
- if (asprintf(&cptr->identifier, "Autoconfigured Video Device %s", driver)
+ if (asprintf(&identifier, "Autoconfigured Video Device %s", driver)
== -1) {
free(cptr);
free(nscreen);
return FALSE;
}
cptr->driver = driver;
+ cptr->identifier = identifier;
xf86ConfigLayout.screens[i].screen = nscreen;
diff --git a/xorg-server/hw/xfree86/common/xf86Bus.c b/xorg-server/hw/xfree86/common/xf86Bus.c
index d463e9196..507c57dbc 100644
--- a/xorg-server/hw/xfree86/common/xf86Bus.c
+++ b/xorg-server/hw/xfree86/common/xf86Bus.c
@@ -288,7 +288,7 @@ xf86IsEntityPrimary(int entityIndex)
Bool
xf86SetEntityFuncs(int entityIndex, EntityProc init, EntityProc enter,
- EntityProc leave, pointer private)
+ EntityProc leave, void *private)
{
if (entityIndex >= xf86NumEntities)
return FALSE;
diff --git a/xorg-server/hw/xfree86/common/xf86Bus.h b/xorg-server/hw/xfree86/common/xf86Bus.h
index e83ba780a..c59625db6 100644
--- a/xorg-server/hw/xfree86/common/xf86Bus.h
+++ b/xorg-server/hw/xfree86/common/xf86Bus.h
@@ -51,7 +51,7 @@ typedef struct {
EntityProc entityInit;
EntityProc entityEnter;
EntityProc entityLeave;
- pointer private;
+ void *private;
Bool active;
Bool inUse;
BusRec bus;
diff --git a/xorg-server/hw/xfree86/common/xf86Config.c b/xorg-server/hw/xfree86/common/xf86Config.c
index b5efc02af..5be1693d8 100644
--- a/xorg-server/hw/xfree86/common/xf86Config.c
+++ b/xorg-server/hw/xfree86/common/xf86Config.c
@@ -171,7 +171,7 @@ xf86GetPathElem(char **pnt)
static char *
xf86ValidateFontPath(char *path)
{
- char *tmp_path, *out_pnt, *path_elem, *next, *p1, *dir_elem;
+ char *next, *tmp_path, *out_pnt, *path_elem, *p1, *dir_elem;
struct stat stat_buf;
int flag;
int dirlen;
@@ -236,17 +236,17 @@ xf86ValidateFontPath(char *path)
* use the datastructure that the parser provides and pick out the parts
* that we need at this point
*/
-char **
-xf86ModulelistFromConfig(pointer **optlist)
+const char **
+xf86ModulelistFromConfig(void ***optlist)
{
int count = 0, i = 0;
- char **modulearray;
+ const char **modulearray;
const char *ignore[] = { "GLcore", "speedo", "bitmap", "drm",
"freetype", "type1",
NULL
};
- pointer *optarray;
+ void **optarray;
XF86LoadPtr modp;
Bool found;
@@ -352,7 +352,7 @@ xf86ModulelistFromConfig(pointer **optlist)
* allocate the memory and walk the list again to fill in the pointers
*/
modulearray = xnfalloc((count + 1) * sizeof(char *));
- optarray = xnfalloc((count + 1) * sizeof(pointer));
+ optarray = xnfalloc((count + 1) * sizeof(void *));
count = 0;
if (xf86configptr->conf_modules) {
modp = xf86configptr->conf_modules->mod_load_lst;
@@ -374,12 +374,12 @@ xf86ModulelistFromConfig(pointer **optlist)
return modulearray;
}
-char **
+const char **
xf86DriverlistFromConfig(void)
{
int count = 0;
int j;
- char **modulearray;
+ const char **modulearray;
screenLayoutPtr slp;
/*
@@ -446,11 +446,11 @@ xf86DriverlistFromConfig(void)
return modulearray;
}
-char **
+const char **
xf86InputDriverlistFromConfig(void)
{
int count = 0;
- char **modulearray;
+ const char **modulearray;
InputInfoPtr *idp;
/*
@@ -505,11 +505,11 @@ xf86InputDriverlistFromConfig(void)
}
static void
-fixup_video_driver_list(char **drivers)
+fixup_video_driver_list(const char **drivers)
{
static const char *fallback[4] = { "fbdev", "vesa", "wsfb", NULL };
- char **end, **drv;
- char *x;
+ const char **end, **drv;
+ const char *x;
int i;
/* walk to the end of the list */
@@ -533,10 +533,10 @@ fixup_video_driver_list(char **drivers)
}
}
-static char **
+static const char **
GenerateDriverlist(const char *dirname)
{
- char **ret;
+ const char **ret;
const char *subdirs[] = { dirname, NULL };
static const char *patlist[] = { "(.*)_drv\\.so", NULL };
ret = LoaderListDirs(subdirs, patlist);
@@ -548,10 +548,10 @@ GenerateDriverlist(const char *dirname)
return ret;
}
-char **
+const char **
xf86DriverlistFromCompile(void)
{
- static char **driverlist = NULL;
+ static const char **driverlist = NULL;
if (!driverlist)
driverlist = GenerateDriverlist("drivers");
@@ -589,33 +589,35 @@ configFiles(XF86ConfFilesPtr fileconf)
/* FontPath */
must_copy = TRUE;
- temp_path = defaultFontPath ? defaultFontPath : "";
+ temp_path = defaultFontPath ? (char *) defaultFontPath : (char *) "";
if (xf86fpFlag)
pathFrom = X_CMDLINE;
else if (fileconf && fileconf->file_fontpath) {
pathFrom = X_CONFIG;
if (xf86Info.useDefaultFontPath) {
- if (asprintf(&defaultFontPath, "%s%s%s", fileconf->file_fontpath,
+ char *new_font_path;
+ if (asprintf(&new_font_path, "%s%s%s", fileconf->file_fontpath,
*temp_path ? "," : "", temp_path) == -1)
- defaultFontPath = NULL;
+ new_font_path = NULL;
else
must_copy = FALSE;
+ defaultFontPath = new_font_path;
}
else
defaultFontPath = fileconf->file_fontpath;
}
else
pathFrom = X_DEFAULT;
- temp_path = defaultFontPath ? defaultFontPath : "";
+ temp_path = defaultFontPath ? (char *) defaultFontPath : (char *) "";
/* xf86ValidateFontPath modifies its argument, but returns a copy of it. */
- temp_path = must_copy ? xnfstrdup(defaultFontPath) : defaultFontPath;
+ temp_path = must_copy ? xnfstrdup(defaultFontPath) : (char *) defaultFontPath;
defaultFontPath = xf86ValidateFontPath(temp_path);
free(temp_path);
/* make fontpath more readable in the logfiles */
countDirs = 1;
- temp_path = defaultFontPath;
+ temp_path = (char *) defaultFontPath;
while ((temp_path = index(temp_path, ',')) != NULL) {
countDirs++;
temp_path++;
@@ -623,7 +625,7 @@ configFiles(XF86ConfFilesPtr fileconf)
log_buf = xnfalloc(strlen(defaultFontPath) + (2 * countDirs) + 1);
temp_path = log_buf;
- start = defaultFontPath;
+ start = (char *) defaultFontPath;
while ((end = index(start, ',')) != NULL) {
size = (end - start) + 1;
*(temp_path++) = '\t';
@@ -2349,7 +2351,7 @@ checkInput(serverLayoutPtr layout, Bool implicit_layout)
ConfigStatus
xf86HandleConfigFile(Bool autoconfig)
{
- char *scanptr;
+ const char *scanptr;
Bool singlecard = 0;
Bool implicit_layout = FALSE;
@@ -2444,7 +2446,7 @@ xf86HandleConfigFile(Bool autoconfig)
else {
if (xf86configptr->conf_flags != NULL) {
char *dfltlayout = NULL;
- pointer optlist = xf86configptr->conf_flags->flg_option_lst;
+ void *optlist = xf86configptr->conf_flags->flg_option_lst;
if (optlist && xf86FindOption(optlist, "defaultserverlayout"))
dfltlayout =
diff --git a/xorg-server/hw/xfree86/common/xf86Config.h b/xorg-server/hw/xfree86/common/xf86Config.h
index de06677c3..23fb383c3 100644
--- a/xorg-server/hw/xfree86/common/xf86Config.h
+++ b/xorg-server/hw/xfree86/common/xf86Config.h
@@ -59,10 +59,10 @@ typedef struct _ModuleDefault {
/*
* prototypes
*/
-char **xf86ModulelistFromConfig(pointer **);
-char **xf86DriverlistFromConfig(void);
-char **xf86DriverlistFromCompile(void);
-char **xf86InputDriverlistFromConfig(void);
+const char **xf86ModulelistFromConfig(void ***);
+const char **xf86DriverlistFromConfig(void);
+const char **xf86DriverlistFromCompile(void);
+const char **xf86InputDriverlistFromConfig(void);
Bool xf86BuiltinInputDriver(const char *);
ConfigStatus xf86HandleConfigFile(Bool);
diff --git a/xorg-server/hw/xfree86/common/xf86Configure.c b/xorg-server/hw/xfree86/common/xf86Configure.c
index 91e8df93d..1348b2753 100644
--- a/xorg-server/hw/xfree86/common/xf86Configure.c
+++ b/xorg-server/hw/xfree86/common/xf86Configure.c
@@ -81,6 +81,7 @@ xf86AddBusDeviceToConfigure(const char *driver, BusType bus, void *busData,
int chipset)
{
int ret, i, j;
+ char *lower_driver;
if (!xf86DoConfigure || !xf86DoConfigurePass1)
return NULL;
@@ -117,8 +118,9 @@ xf86AddBusDeviceToConfigure(const char *driver, BusType bus, void *busData,
DevToConfig[i].iDriver = CurrentDriver;
/* Fill in what we know, converting the driver name to lower case */
- DevToConfig[i].GDev.driver = xnfalloc(strlen(driver) + 1);
- for (j = 0; (DevToConfig[i].GDev.driver[j] = tolower(driver[j])); j++);
+ lower_driver = xnfalloc(strlen(driver) + 1);
+ for (j = 0; (lower_driver[j] = tolower(driver[j])); j++);
+ DevToConfig[i].GDev.driver = lower_driver;
switch (bus) {
#ifdef XSERVER_LIBPCIACCESS
@@ -193,11 +195,15 @@ configureScreenSection(int screennum)
{
int i;
int depths[] = { 1, 4, 8, 15, 16, 24 /*, 32 */ };
+ char *tmp;
parsePrologue(XF86ConfScreenPtr, XF86ConfScreenRec)
- XNFasprintf(&ptr->scrn_identifier, "Screen%d", screennum);
- XNFasprintf(&ptr->scrn_monitor_str, "Monitor%d", screennum);
- XNFasprintf(&ptr->scrn_device_str, "Card%d", screennum);
+ XNFasprintf(&tmp, "Screen%d", screennum);
+ ptr->scrn_identifier = tmp;
+ XNFasprintf(&tmp, "Monitor%d", screennum);
+ ptr->scrn_monitor_str = tmp;
+ XNFasprintf(&tmp, "Card%d", screennum);
+ ptr->scrn_device_str = tmp;
for (i = 0; i < sizeof(depths) / sizeof(depths[0]); i++) {
XF86ConfDisplayPtr display;
@@ -246,12 +252,14 @@ configureDeviceSection(int screennum)
{
OptionInfoPtr p;
int i = 0;
+ char *identifier;
parsePrologue(XF86ConfDevicePtr, XF86ConfDeviceRec)
/* Move device info to parser structure */
- if (asprintf(&ptr->dev_identifier, "Card%d", screennum) == -1)
- ptr->dev_identifier = NULL;
+ if (asprintf(&identifier, "Card%d", screennum) == -1)
+ identifier = NULL;
+ ptr->dev_identifier = identifier;
ptr->dev_chipset = DevToConfig[screennum].GDev.chipset;
ptr->dev_busid = DevToConfig[screennum].GDev.busID;
ptr->dev_driver = DevToConfig[screennum].GDev.driver;
@@ -353,20 +361,24 @@ configureLayoutSection(void)
for (scrnum = 0; scrnum < nDevToConfig; scrnum++) {
XF86ConfAdjacencyPtr aptr;
+ char *tmp;
aptr = malloc(sizeof(XF86ConfAdjacencyRec));
aptr->list.next = NULL;
aptr->adj_x = 0;
aptr->adj_y = 0;
aptr->adj_scrnum = scrnum;
- XNFasprintf(&aptr->adj_screen_str, "Screen%d", scrnum);
+ XNFasprintf(&tmp, "Screen%d", scrnum);
+ aptr->adj_screen_str = tmp;
if (scrnum == 0) {
aptr->adj_where = CONF_ADJ_ABSOLUTE;
aptr->adj_refscreen = NULL;
}
else {
+ char *tmp;
aptr->adj_where = CONF_ADJ_RIGHTOF;
- XNFasprintf(&aptr->adj_refscreen, "Screen%d", scrnum - 1);
+ XNFasprintf(&tmp, "Screen%d", scrnum - 1);
+ aptr->adj_refscreen = tmp;
}
ptr->lay_adjacency_lst =
(XF86ConfAdjacencyPtr) xf86addListItem((glp) ptr->lay_adjacency_lst,
@@ -387,7 +399,7 @@ configureFlagsSection(void)
static XF86ConfModulePtr
configureModuleSection(void)
{
- char **elist, **el;
+ const char **elist, **el;
/* Find the list of extension & font modules. */
const char *esubdirs[] = {
@@ -430,9 +442,11 @@ configureFilesSection(void)
static XF86ConfMonitorPtr
configureMonitorSection(int screennum)
{
+ char *tmp;
parsePrologue(XF86ConfMonitorPtr, XF86ConfMonitorRec)
- XNFasprintf(&ptr->mon_identifier, "Monitor%d", screennum);
+ XNFasprintf(&tmp, "Monitor%d", screennum);
+ ptr->mon_identifier = tmp;
ptr->mon_vendor = strdup("Monitor Vendor");
ptr->mon_modelname = strdup("Monitor Model");
@@ -472,10 +486,12 @@ configureDDCMonitorSection(int screennum)
#define displaySizeMaxLen 80
char displaySize_string[displaySizeMaxLen];
int displaySizeLen;
+ char *tmp;
parsePrologue(XF86ConfMonitorPtr, XF86ConfMonitorRec)
- XNFasprintf(&ptr->mon_identifier, "Monitor%d", screennum);
+ XNFasprintf(&tmp, "Monitor%d", screennum);
+ ptr->mon_identifier = tmp;
ptr->mon_vendor = strdup(ConfiguredMonitor->vendor.name);
XNFasprintf(&ptr->mon_modelname, "%x", ConfiguredMonitor->vendor.prod_id);
@@ -528,7 +544,7 @@ DoConfigure(void)
char filename[PATH_MAX];
const char *addslash = "";
XF86ConfigPtr xf86config = NULL;
- char **vlist, **vl;
+ const char **vlist, **vl;
int *dev2screen;
vlist = xf86DriverlistFromCompile();
@@ -766,7 +782,7 @@ void
DoShowOptions(void)
{
int i = 0;
- char **vlist = 0;
+ const char **vlist = NULL;
char *pSymbol = 0;
XF86ModuleData *initData = 0;
diff --git a/xorg-server/hw/xfree86/common/xf86DGA.c b/xorg-server/hw/xfree86/common/xf86DGA.c
index 6a05ce536..b9e1e3f88 100644
--- a/xorg-server/hw/xfree86/common/xf86DGA.c
+++ b/xorg-server/hw/xfree86/common/xf86DGA.c
@@ -450,7 +450,7 @@ xf86SetDGAMode(ScrnInfoPtr pScrn, int num, DGADevicePtr devRet)
pMode->pixmapHeight, pMode->depth,
pMode->bitsPerPixel,
pMode->bytesPerScanline,
- (pointer) (pMode->address));
+ (void *) (pMode->address));
}
}
@@ -1214,7 +1214,7 @@ DGAHandleEvent(int screen_num, InternalEvent *ev, DeviceIntPtr device)
static void XDGAResetProc(ExtensionEntry * extEntry);
-static void DGAClientStateChange(CallbackListPtr *, pointer, pointer);
+static void DGAClientStateChange(CallbackListPtr *, void *, void *);
static DevPrivateKeyRec DGAScreenPrivateKeyRec;
@@ -1404,7 +1404,7 @@ ProcXDGAQueryModes(ClientPtr client)
}
static void
-DGAClientStateChange(CallbackListPtr *pcbl, pointer nulldata, pointer calldata)
+DGAClientStateChange(CallbackListPtr *pcbl, void *nulldata, void *calldata)
{
NewClientInfoRec *pci = (NewClientInfoRec *) calldata;
ClientPtr client = NULL;
@@ -1484,7 +1484,7 @@ ProcXDGASetMode(ClientPtr client)
DGA_SETCLIENT(stuff->screen, client);
if (pPix) {
- if (AddResource(stuff->pid, RT_PIXMAP, (pointer) (pPix))) {
+ if (AddResource(stuff->pid, RT_PIXMAP, (void *) (pPix))) {
pPix->drawable.id = (int) stuff->pid;
rep.flags = DGA_PIXMAP_AVAILABLE;
}
@@ -1562,7 +1562,7 @@ ProcXDGAInstallColormap(ClientPtr client)
REQUEST_SIZE_MATCH(xXDGAInstallColormapReq);
- rc = dixLookupResourceByType((pointer *) &cmap, stuff->cmap, RT_COLORMAP,
+ rc = dixLookupResourceByType((void **) &cmap, stuff->cmap, RT_COLORMAP,
client, DixInstallAccess);
if (rc != Success)
return rc;
@@ -1991,7 +1991,7 @@ ProcXF86DGAInstallColormap(ClientPtr client)
if (!DGAActive(stuff->screen))
return DGAErrorBase + XF86DGADirectNotActivated;
- rc = dixLookupResourceByType((pointer *) &pcmp, stuff->id, RT_COLORMAP,
+ rc = dixLookupResourceByType((void **) &pcmp, stuff->id, RT_COLORMAP,
client, DixInstallAccess);
if (rc == Success) {
DGAInstallCmap(pcmp);
diff --git a/xorg-server/hw/xfree86/common/xf86DPMS.c b/xorg-server/hw/xfree86/common/xf86DPMS.c
index 881cb2773..14d1f4545 100644
--- a/xorg-server/hw/xfree86/common/xf86DPMS.c
+++ b/xorg-server/hw/xfree86/common/xf86DPMS.c
@@ -60,7 +60,7 @@ xf86DPMSInit(ScreenPtr pScreen, DPMSSetProcPtr set, int flags)
#ifdef DPMSExtension
ScrnInfoPtr pScrn = xf86ScreenToScrn(pScreen);
DPMSPtr pDPMS;
- pointer DPMSOpt;
+ void *DPMSOpt;
MessageType enabled_from;
DPMSKey = &DPMSKeyRec;
diff --git a/xorg-server/hw/xfree86/common/xf86Events.c b/xorg-server/hw/xfree86/common/xf86Events.c
index d0b14314b..cae78732c 100644
--- a/xorg-server/hw/xfree86/common/xf86Events.c
+++ b/xorg-server/hw/xfree86/common/xf86Events.c
@@ -114,7 +114,7 @@ static void xf86VTSwitch(void);
typedef struct x_IHRec {
int fd;
InputHandlerProc ihproc;
- pointer data;
+ void *data;
Bool enabled;
Bool is_input;
struct x_IHRec *next;
@@ -243,7 +243,7 @@ xf86ProcessActionEvent(ActionEvent action, void *arg)
/* ARGSUSED */
void
-xf86Wakeup(pointer blockData, int err, pointer pReadmask)
+xf86Wakeup(void *blockData, int err, void *pReadmask)
{
fd_set *LastSelectMask = (fd_set *) pReadmask;
fd_set devicesWithInput;
@@ -583,8 +583,8 @@ xf86VTSwitch(void)
/* Input handler registration */
-static pointer
-addInputHandler(int fd, InputHandlerProc proc, pointer data)
+static void *
+addInputHandler(int fd, InputHandlerProc proc, void *data)
{
IHPtr ih;
@@ -606,8 +606,8 @@ addInputHandler(int fd, InputHandlerProc proc, pointer data)
return ih;
}
-pointer
-xf86AddInputHandler(int fd, InputHandlerProc proc, pointer data)
+void *
+xf86AddInputHandler(int fd, InputHandlerProc proc, void *data)
{
IHPtr ih = addInputHandler(fd, proc, data);
@@ -618,8 +618,8 @@ xf86AddInputHandler(int fd, InputHandlerProc proc, pointer data)
return ih;
}
-pointer
-xf86AddGeneralHandler(int fd, InputHandlerProc proc, pointer data)
+void *
+xf86AddGeneralHandler(int fd, InputHandlerProc proc, void *data)
{
IHPtr ih = addInputHandler(fd, proc, data);
@@ -634,7 +634,7 @@ xf86AddGeneralHandler(int fd, InputHandlerProc proc, pointer data)
* proc may be NULL if the server should not handle events on the console.
*/
InputHandlerProc
-xf86SetConsoleHandler(InputHandlerProc proc, pointer data)
+xf86SetConsoleHandler(InputHandlerProc proc, void *data)
{
static IHPtr handler = NULL;
InputHandlerProc old_proc = NULL;
@@ -667,7 +667,7 @@ removeInputHandler(IHPtr ih)
}
int
-xf86RemoveInputHandler(pointer handler)
+xf86RemoveInputHandler(void *handler)
{
IHPtr ih;
int fd;
@@ -686,7 +686,7 @@ xf86RemoveInputHandler(pointer handler)
}
int
-xf86RemoveGeneralHandler(pointer handler)
+xf86RemoveGeneralHandler(void *handler)
{
IHPtr ih;
int fd;
@@ -705,7 +705,7 @@ xf86RemoveGeneralHandler(pointer handler)
}
void
-xf86DisableInputHandler(pointer handler)
+xf86DisableInputHandler(void *handler)
{
IHPtr ih;
@@ -719,7 +719,7 @@ xf86DisableInputHandler(pointer handler)
}
void
-xf86DisableGeneralHandler(pointer handler)
+xf86DisableGeneralHandler(void *handler)
{
IHPtr ih;
@@ -733,7 +733,7 @@ xf86DisableGeneralHandler(pointer handler)
}
void
-xf86EnableInputHandler(pointer handler)
+xf86EnableInputHandler(void *handler)
{
IHPtr ih;
@@ -747,7 +747,7 @@ xf86EnableInputHandler(pointer handler)
}
void
-xf86EnableGeneralHandler(pointer handler)
+xf86EnableGeneralHandler(void *handler)
{
IHPtr ih;
diff --git a/xorg-server/hw/xfree86/common/xf86Extensions.c b/xorg-server/hw/xfree86/common/xf86Extensions.c
index f9e791607..c80de34e6 100644
--- a/xorg-server/hw/xfree86/common/xf86Extensions.c
+++ b/xorg-server/hw/xfree86/common/xf86Extensions.c
@@ -89,7 +89,6 @@ load_extension_config(void)
{
XF86ConfModulePtr mod_con = xf86configptr->conf_modules;
XF86LoadPtr modp;
- int i;
/* Only the best. */
if (!mod_con)
diff --git a/xorg-server/hw/xfree86/common/xf86Helper.c b/xorg-server/hw/xfree86/common/xf86Helper.c
index f1e6783a7..0916deccf 100644
--- a/xorg-server/hw/xfree86/common/xf86Helper.c
+++ b/xorg-server/hw/xfree86/common/xf86Helper.c
@@ -67,7 +67,7 @@ static int xf86ScrnInfoPrivateCount = 0;
/* Add a pointer to a new DriverRec to xf86DriverList */
void
-xf86AddDriver(DriverPtr driver, pointer module, int flags)
+xf86AddDriver(DriverPtr driver, void *module, int flags)
{
/* Don't add null entries */
if (!driver)
@@ -107,7 +107,7 @@ xf86DeleteDriver(int drvIndex)
/* Add a pointer to a new InputDriverRec to xf86InputDriverList */
void
-xf86AddInputDriver(InputDriverPtr driver, pointer module, int flags)
+xf86AddInputDriver(InputDriverPtr driver, void *module, int flags)
{
/* Don't add null entries */
if (!driver)
@@ -1068,9 +1068,7 @@ void
xf86EnableDisableFBAccess(ScrnInfoPtr pScrnInfo, Bool enable)
{
ScreenPtr pScreen = pScrnInfo->pScreen;
- PixmapPtr pspix;
- pspix = (*pScreen->GetScreenPixmap) (pScreen);
if (enable) {
/*
* Restore all of the clip lists on the screen
@@ -1531,15 +1529,15 @@ xf86DisableRandR(void)
}
CARD32
-xf86GetModuleVersion(pointer module)
+xf86GetModuleVersion(void *module)
{
return (CARD32) LoaderGetModuleVersion(module);
}
-pointer
+void *
xf86LoadDrvSubModule(DriverPtr drv, const char *name)
{
- pointer ret;
+ void *ret;
int errmaj = 0, errmin = 0;
ret = LoadSubModule(drv->module, name, NULL, NULL, NULL, NULL,
@@ -1549,10 +1547,10 @@ xf86LoadDrvSubModule(DriverPtr drv, const char *name)
return ret;
}
-pointer
+void *
xf86LoadSubModule(ScrnInfoPtr pScrn, const char *name)
{
- pointer ret;
+ void *ret;
int errmaj = 0, errmin = 0;
ret = LoadSubModule(pScrn->module, name, NULL, NULL, NULL, NULL,
@@ -1565,12 +1563,12 @@ xf86LoadSubModule(ScrnInfoPtr pScrn, const char *name)
/*
* xf86LoadOneModule loads a single module.
*/
-pointer
-xf86LoadOneModule(char *name, pointer opt)
+void *
+xf86LoadOneModule(const char *name, void *opt)
{
int errmaj, errmin;
char *Name;
- pointer mod;
+ void *mod;
if (!name)
return NULL;
@@ -1594,7 +1592,7 @@ xf86LoadOneModule(char *name, pointer opt)
}
void
-xf86UnloadSubModule(pointer mod)
+xf86UnloadSubModule(void *mod)
{
UnloadSubModule(mod);
}
@@ -1697,9 +1695,9 @@ xf86SetSilkenMouse(ScreenPtr pScreen)
/* Wrote this function for the PM2 Xv driver, preliminary. */
-pointer
-xf86FindXvOptions(ScrnInfoPtr pScrn, int adaptor_index, char *port_name,
- char **adaptor_name, pointer *adaptor_options)
+void *
+xf86FindXvOptions(ScrnInfoPtr pScrn, int adaptor_index, const char *port_name,
+ const char **adaptor_name, void **adaptor_options)
{
confXvAdaptorPtr adaptor;
int i;
@@ -1731,7 +1729,7 @@ xf86FindXvOptions(ScrnInfoPtr pScrn, int adaptor_index, char *port_name,
static void
xf86ConfigFbEntityInactive(EntityInfoPtr pEnt, EntityProc init,
- EntityProc enter, EntityProc leave, pointer private)
+ EntityProc enter, EntityProc leave, void *private)
{
ScrnInfoPtr pScrn;
@@ -1743,7 +1741,7 @@ xf86ConfigFbEntityInactive(EntityInfoPtr pEnt, EntityProc init,
ScrnInfoPtr
xf86ConfigFbEntity(ScrnInfoPtr pScrn, int scrnFlag, int entityIndex,
EntityProc init, EntityProc enter, EntityProc leave,
- pointer private)
+ void *private)
{
EntityInfoPtr pEnt = xf86GetEntityInfo(entityIndex);
@@ -1785,7 +1783,7 @@ xf86IsScreenPrimary(ScrnInfoPtr pScrn)
int
xf86RegisterRootWindowProperty(int ScrnIndex, Atom property, Atom type,
- int format, unsigned long len, pointer value)
+ int format, unsigned long len, void *value)
{
RootWinPropPtr pNewProp = NULL, pRegProp;
Bool existing = FALSE;
@@ -1817,7 +1815,7 @@ xf86RegisterRootWindowProperty(int ScrnIndex, Atom property, Atom type,
pNewProp->next = NULL;
}
else {
- free(pNewProp->name);
+ free((void *) pNewProp->name);
existing = TRUE;
}
diff --git a/xorg-server/hw/xfree86/common/xf86InPriv.h b/xorg-server/hw/xfree86/common/xf86InPriv.h
index 5826ac388..b8229d2c1 100644
--- a/xorg-server/hw/xfree86/common/xf86InPriv.h
+++ b/xorg-server/hw/xfree86/common/xf86InPriv.h
@@ -37,7 +37,4 @@
extern InputDriverPtr *xf86InputDriverList;
extern int xf86NumInputDrivers;
-/* xf86Helper.c */
-InputDriverPtr xf86LookupInputDriver(const char *name);
-
#endif /* _xf86InPriv_h */
diff --git a/xorg-server/hw/xfree86/common/xf86Init.c b/xorg-server/hw/xfree86/common/xf86Init.c
index 91ec4c8bb..7c72aa964 100644
--- a/xorg-server/hw/xfree86/common/xf86Init.c
+++ b/xorg-server/hw/xfree86/common/xf86Init.c
@@ -395,8 +395,8 @@ void
InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
{
int i, j, k, scr_index;
- char **modulelist;
- pointer *optionlist;
+ const char **modulelist;
+ void **optionlist;
Pix24Flags screenpix24, pix24;
MessageType pix24From = X_DEFAULT;
Bool pix24Fail = FALSE;
@@ -623,7 +623,9 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
for (i = 0; i < xf86NumScreens; i++) {
if (xf86Screens[i]->name == NULL) {
- XNFasprintf(&xf86Screens[i]->name, "screen%d", i);
+ char *tmp;
+ XNFasprintf(&tmp, "screen%d", i);
+ xf86Screens[i]->name = tmp;
xf86MsgVerb(X_WARNING, 0,
"Screen driver %d has no name set, using `%s'.\n",
i, xf86Screens[i]->name);
@@ -1536,10 +1538,10 @@ ddxUseMsg(void)
* xf86LoadModules iterates over a list that is being passed in.
*/
Bool
-xf86LoadModules(char **list, pointer *optlist)
+xf86LoadModules(const char **list, void **optlist)
{
int errmaj, errmin;
- pointer opt;
+ void *opt;
int i;
char *name;
Bool failed = FALSE;
diff --git a/xorg-server/hw/xfree86/common/xf86Mode.c b/xorg-server/hw/xfree86/common/xf86Mode.c
index 706ab64fc..44bc55953 100644
--- a/xorg-server/hw/xfree86/common/xf86Mode.c
+++ b/xorg-server/hw/xfree86/common/xf86Mode.c
@@ -1354,7 +1354,7 @@ scanLineWidth(unsigned int xsize, /* pixels */
int
xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
- char **modeNames, ClockRangePtr clockRanges,
+ const char **modeNames, ClockRangePtr clockRanges,
int *linePitches, int minPitch, int maxPitch, int pitchInc,
int minHeight, int maxHeight, int virtualX, int virtualY,
int apertureSize, LookupModeFlags strategy)
@@ -1998,7 +1998,7 @@ xf86DeleteMode(DisplayModePtr * modeList, DisplayModePtr mode)
mode->next->prev = mode->prev;
}
- free(mode->name);
+ free((void *) mode->name);
free(mode);
}
diff --git a/xorg-server/hw/xfree86/common/xf86Module.h b/xorg-server/hw/xfree86/common/xf86Module.h
index 265b55348..b6ec19d13 100644
--- a/xorg-server/hw/xfree86/common/xf86Module.h
+++ b/xorg-server/hw/xfree86/common/xf86Module.h
@@ -170,13 +170,13 @@ typedef struct {
#define INITARGS void
/* Prototypes for Loader functions that are exported to modules */
-extern _X_EXPORT pointer LoadSubModule(pointer, const char *, const char **,
- const char **, pointer,
+extern _X_EXPORT void *LoadSubModule(void *, const char *, const char **,
+ const char **, void *,
const XF86ModReqInfo *, int *, int *);
-extern _X_EXPORT void UnloadSubModule(pointer);
-extern _X_EXPORT void UnloadModule(pointer);
-extern _X_EXPORT pointer LoaderSymbol(const char *);
-extern _X_EXPORT char **LoaderListDirs(const char **, const char **);
+extern _X_EXPORT void UnloadSubModule(void *);
+extern _X_EXPORT void UnloadModule(void *);
+extern _X_EXPORT void *LoaderSymbol(const char *);
+extern _X_EXPORT const char **LoaderListDirs(const char **, const char **);
extern _X_EXPORT void LoaderFreeDirList(char **);
extern _X_EXPORT void LoaderErrorMsg(const char *, const char *, int, int);
extern _X_EXPORT void LoaderGetOS(const char **name, int *major, int *minor,
@@ -184,11 +184,11 @@ extern _X_EXPORT void LoaderGetOS(const char **name, int *major, int *minor,
extern _X_EXPORT Bool LoaderShouldIgnoreABI(void);
extern _X_EXPORT int LoaderGetABIVersion(const char *abiclass);
-typedef pointer (*ModuleSetupProc) (pointer, pointer, int *, int *);
-typedef void (*ModuleTearDownProc) (pointer);
+typedef void *(*ModuleSetupProc) (void *, void *, int *, int *);
+typedef void (*ModuleTearDownProc) (void *);
-#define MODULESETUPPROTO(func) pointer func(pointer, pointer, int*, int*)
-#define MODULETEARDOWNPROTO(func) void func(pointer)
+#define MODULESETUPPROTO(func) void *func(void *, void *, int*, int*)
+#define MODULETEARDOWNPROTO(func) void func(void *)
typedef struct {
XF86ModuleVersionInfo *vers;
diff --git a/xorg-server/hw/xfree86/common/xf86Opt.h b/xorg-server/hw/xfree86/common/xf86Opt.h
index c3ba2d75c..3be2a0fc7 100644
--- a/xorg-server/hw/xfree86/common/xf86Opt.h
+++ b/xorg-server/hw/xfree86/common/xf86Opt.h
@@ -39,7 +39,7 @@ typedef struct {
typedef union {
unsigned long num;
- char *str;
+ const char *str;
double realnum;
Bool bool;
OptFrequency freq;
@@ -123,7 +123,7 @@ extern _X_EXPORT OptionInfoPtr xf86TokenToOptinfo(const OptionInfoRec * table,
extern _X_EXPORT const char *xf86TokenToOptName(const OptionInfoRec * table,
int token);
extern _X_EXPORT Bool xf86IsOptionSet(const OptionInfoRec * table, int token);
-extern _X_EXPORT char *xf86GetOptValString(const OptionInfoRec * table,
+extern _X_EXPORT const char *xf86GetOptValString(const OptionInfoRec * table,
int token);
extern _X_EXPORT Bool xf86GetOptValInteger(const OptionInfoRec * table,
int token, int *value);
diff --git a/xorg-server/hw/xfree86/common/xf86Option.c b/xorg-server/hw/xfree86/common/xf86Option.c
index 607c33354..0e8bc1f83 100644
--- a/xorg-server/hw/xfree86/common/xf86Option.c
+++ b/xorg-server/hw/xfree86/common/xf86Option.c
@@ -478,7 +478,8 @@ static Bool
ParseOptionValue(int scrnIndex, XF86OptionPtr options, OptionInfoPtr p,
Bool markUsed)
{
- char *s, *end;
+ const char *s;
+ char *end;
Bool wasUsed = FALSE;
if ((s = xf86findOptionValue(options, p->name)) != NULL) {
@@ -755,7 +756,7 @@ xf86IsOptionSet(const OptionInfoRec * table, int token)
return p && p->found;
}
-char *
+const char *
xf86GetOptValString(const OptionInfoRec * table, int token)
{
OptionInfoPtr p;
diff --git a/xorg-server/hw/xfree86/common/xf86Optionstr.h b/xorg-server/hw/xfree86/common/xf86Optionstr.h
index c38499cb5..4ef917dee 100644
--- a/xorg-server/hw/xfree86/common/xf86Optionstr.h
+++ b/xorg-server/hw/xfree86/common/xf86Optionstr.h
@@ -31,10 +31,10 @@
*/
typedef struct _XF86OptionRec {
GenericListRec list;
- char *opt_name;
- char *opt_val;
+ const char *opt_name;
+ const char *opt_val;
int opt_used;
- char *opt_comment;
+ const char *opt_comment;
} XF86OptionRec;
typedef struct _InputOption *XF86OptionPtr;
diff --git a/xorg-server/hw/xfree86/common/xf86PM.c b/xorg-server/hw/xfree86/common/xf86PM.c
index 15257cb81..9e49e8eaf 100644
--- a/xorg-server/hw/xfree86/common/xf86PM.c
+++ b/xorg-server/hw/xfree86/common/xf86PM.c
@@ -196,7 +196,7 @@ DoApmEvent(pmEvent event, Bool undo)
#define MAX_NO_EVENTS 8
void
-xf86HandlePMEvents(int fd, pointer data)
+xf86HandlePMEvents(int fd, void *data)
{
pmEvent events[MAX_NO_EVENTS];
int i, n;
diff --git a/xorg-server/hw/xfree86/common/xf86Priv.h b/xorg-server/hw/xfree86/common/xf86Priv.h
index 58cfe0a1a..6e374eb7e 100644
--- a/xorg-server/hw/xfree86/common/xf86Priv.h
+++ b/xorg-server/hw/xfree86/common/xf86Priv.h
@@ -139,11 +139,11 @@ DoShowOptions(void)
/* xf86Events.c */
extern _X_EXPORT void
-xf86Wakeup(pointer blockData, int err, pointer pReadmask);
+xf86Wakeup(void *blockData, int err, void *pReadmask);
extern _X_HIDDEN int
xf86SigWrapper(int signo);
extern _X_EXPORT void
-xf86HandlePMEvents(int fd, pointer data);
+xf86HandlePMEvents(int fd, void *data);
extern _X_EXPORT int (*xf86PMGetEventFromOs) (int fd, pmEvent * events,
int num);
extern _X_EXPORT pmWait (*xf86PMConfirmEventToOs) (int fd, pmEvent event);
@@ -156,7 +156,7 @@ xf86CloseLog(enum ExitCode error);
/* xf86Init.c */
extern _X_EXPORT Bool
-xf86LoadModules(char **list, pointer *optlist);
+xf86LoadModules(const char **list, void **optlist);
extern _X_EXPORT int
xf86SetVerbosity(int verb);
extern _X_EXPORT int
diff --git a/xorg-server/hw/xfree86/common/xf86Privstr.h b/xorg-server/hw/xfree86/common/xf86Privstr.h
index e20be03a9..f7a9c9f1c 100644
--- a/xorg-server/hw/xfree86/common/xf86Privstr.h
+++ b/xorg-server/hw/xfree86/common/xf86Privstr.h
@@ -136,11 +136,11 @@ typedef struct {
/* Information for root window properties. */
typedef struct _RootWinProp {
struct _RootWinProp *next;
- char *name;
+ const char *name;
Atom type;
short format;
long size;
- pointer data;
+ void *data;
} RootWinProp, *RootWinPropPtr;
/* ISC's cc can't handle ~ of UL constants, so explicitly type cast them. */
diff --git a/xorg-server/hw/xfree86/common/xf86VGAarbiter.c b/xorg-server/hw/xfree86/common/xf86VGAarbiter.c
index 225fff06e..5cc24298b 100644
--- a/xorg-server/hw/xfree86/common/xf86VGAarbiter.c
+++ b/xorg-server/hw/xfree86/common/xf86VGAarbiter.c
@@ -257,7 +257,7 @@ VGAarbiterCloseScreen(ScreenPtr pScreen)
UNWRAP_SCREEN_INFO(FreeScreen);
UNWRAP_SPRITE;
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
xf86VGAarbiterLock(xf86ScreenToScrn(pScreen));
val = (*pScreen->CloseScreen) (pScreen);
xf86VGAarbiterUnlock(xf86ScreenToScrn(pScreen));
@@ -266,7 +266,7 @@ VGAarbiterCloseScreen(ScreenPtr pScreen)
static void
VGAarbiterBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadmask)
+ void *pTimeout, void *pReadmask)
{
SCREEN_PROLOG(BlockHandler);
VGAGet(pScreen);
@@ -277,7 +277,7 @@ VGAarbiterBlockHandler(ScreenPtr pScreen,
static void
VGAarbiterWakeupHandler(ScreenPtr pScreen, unsigned long result,
- pointer pReadmask)
+ void *pReadmask)
{
SCREEN_PROLOG(WakeupHandler);
VGAGet(pScreen);
@@ -586,7 +586,7 @@ VGAarbiterCopyGC(GCPtr pGCSrc, unsigned long mask, GCPtr pGCDst)
}
static void
-VGAarbiterChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects)
+VGAarbiterChangeClip(GCPtr pGC, int type, void *pvalue, int nrects)
{
GC_UNWRAP(pGC);
(*pGC->funcs->ChangeClip) (pGC, type, pvalue, nrects);
@@ -860,7 +860,7 @@ VGAarbiterImageGlyphBlt(DrawablePtr pDraw,
GCPtr pGC,
int xInit, int yInit,
unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase)
+ CharInfoPtr * ppci, void *pglyphBase)
{
ScreenPtr pScreen = pGC->pScreen;
@@ -877,7 +877,7 @@ VGAarbiterPolyGlyphBlt(DrawablePtr pDraw,
GCPtr pGC,
int xInit, int yInit,
unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase)
+ CharInfoPtr * ppci, void *pglyphBase)
{
ScreenPtr pScreen = pGC->pScreen;
diff --git a/xorg-server/hw/xfree86/common/xf86VGAarbiterPriv.h b/xorg-server/hw/xfree86/common/xf86VGAarbiterPriv.h
index ba6edfcc3..ec21bc2f2 100644
--- a/xorg-server/hw/xfree86/common/xf86VGAarbiterPriv.h
+++ b/xorg-server/hw/xfree86/common/xf86VGAarbiterPriv.h
@@ -137,15 +137,15 @@ typedef struct _VGAarbiterScreen {
} VGAarbiterScreenRec, *VGAarbiterScreenPtr;
typedef struct _VGAarbiterGC {
- GCOps *wrapOps;
- GCFuncs *wrapFuncs;
+ const GCOps *wrapOps;
+ const GCFuncs *wrapFuncs;
} VGAarbiterGCRec, *VGAarbiterGCPtr;
/* Screen funcs */
-static void VGAarbiterBlockHandler(ScreenPtr pScreen, pointer pTimeout,
- pointer pReadmask);
+static void VGAarbiterBlockHandler(ScreenPtr pScreen, void *pTimeout,
+ void *pReadmask);
static void VGAarbiterWakeupHandler(ScreenPtr pScreen,
- unsigned long result, pointer pReadmask);
+ unsigned long result, void *pReadmask);
static Bool VGAarbiterCloseScreen(ScreenPtr pScreen);
static void VGAarbiterGetImage(DrawablePtr pDrawable, int sx, int sy, int w,
int h, unsigned int format,
@@ -188,7 +188,7 @@ static void VGAarbiterValidateGC(GCPtr pGC, unsigned long changes,
static void VGAarbiterChangeGC(GCPtr pGC, unsigned long mask);
static void VGAarbiterCopyGC(GCPtr pGCSrc, unsigned long mask, GCPtr pGCDst);
static void VGAarbiterDestroyGC(GCPtr pGC);
-static void VGAarbiterChangeClip(GCPtr pGC, int type, pointer pvalue,
+static void VGAarbiterChangeClip(GCPtr pGC, int type, void *pvalue,
int nrects);
static void VGAarbiterDestroyClip(GCPtr pGC);
static void VGAarbiterCopyClip(GCPtr pgcDst, GCPtr pgcSrc);
@@ -236,10 +236,10 @@ static void VGAarbiterImageText16(DrawablePtr pDraw, GCPtr pGC, int x, int y,
int count, unsigned short *chars);
static void VGAarbiterImageGlyphBlt(DrawablePtr pDraw, GCPtr pGC, int xInit,
int yInit, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase);
+ CharInfoPtr * ppci, void *pglyphBase);
static void VGAarbiterPolyGlyphBlt(DrawablePtr pDraw, GCPtr pGC, int xInit,
int yInit, unsigned int nglyph,
- CharInfoPtr * ppci, pointer pglyphBase);
+ CharInfoPtr * ppci, void *pglyphBase);
static void VGAarbiterPushPixels(GCPtr pGC, PixmapPtr pBitMap, DrawablePtr
pDraw, int dx, int dy, int xOrg, int yOrg);
diff --git a/xorg-server/hw/xfree86/common/xf86VidMode.c b/xorg-server/hw/xfree86/common/xf86VidMode.c
index a7d1c25bf..e708b2792 100644
--- a/xorg-server/hw/xfree86/common/xf86VidMode.c
+++ b/xorg-server/hw/xfree86/common/xf86VidMode.c
@@ -138,7 +138,7 @@ VidModeAvailable(int scrnIndex)
}
Bool
-VidModeGetCurrentModeline(int scrnIndex, pointer *mode, int *dotClock)
+VidModeGetCurrentModeline(int scrnIndex, void **mode, int *dotClock)
{
ScrnInfoPtr pScrn;
@@ -148,7 +148,7 @@ VidModeGetCurrentModeline(int scrnIndex, pointer *mode, int *dotClock)
pScrn = xf86Screens[scrnIndex];
if (pScrn->currentMode) {
- *mode = (pointer) (pScrn->currentMode);
+ *mode = (void *) (pScrn->currentMode);
*dotClock = pScrn->currentMode->Clock;
return TRUE;
@@ -211,7 +211,7 @@ VidModeGetClocks(int scrnIndex, int *Clocks)
}
Bool
-VidModeGetFirstModeline(int scrnIndex, pointer *mode, int *dotClock)
+VidModeGetFirstModeline(int scrnIndex, void **mode, int *dotClock)
{
ScrnInfoPtr pScrn;
VidModePtr pVidMode;
@@ -228,7 +228,7 @@ VidModeGetFirstModeline(int scrnIndex, pointer *mode, int *dotClock)
pVidMode->Next = pVidMode->First->next;
if (pVidMode->First->status == MODE_OK) {
- *mode = (pointer) (pVidMode->First);
+ *mode = (void *) (pVidMode->First);
*dotClock = VidModeGetDotClock(scrnIndex, pVidMode->First->Clock);
return TRUE;
}
@@ -237,7 +237,7 @@ VidModeGetFirstModeline(int scrnIndex, pointer *mode, int *dotClock)
}
Bool
-VidModeGetNextModeline(int scrnIndex, pointer *mode, int *dotClock)
+VidModeGetNextModeline(int scrnIndex, void **mode, int *dotClock)
{
ScrnInfoPtr pScrn;
VidModePtr pVidMode;
@@ -252,7 +252,7 @@ VidModeGetNextModeline(int scrnIndex, pointer *mode, int *dotClock)
for (p = pVidMode->Next; p != NULL && p != pVidMode->First; p = p->next) {
if (p->status == MODE_OK) {
pVidMode->Next = p->next;
- *mode = (pointer) p;
+ *mode = (void *) p;
*dotClock = VidModeGetDotClock(scrnIndex, p->Clock);
return TRUE;
}
@@ -262,7 +262,7 @@ VidModeGetNextModeline(int scrnIndex, pointer *mode, int *dotClock)
}
Bool
-VidModeDeleteModeline(int scrnIndex, pointer mode)
+VidModeDeleteModeline(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
@@ -323,7 +323,7 @@ VidModeGetViewPort(int scrnIndex, int *x, int *y)
}
Bool
-VidModeSwitchMode(int scrnIndex, pointer mode)
+VidModeSwitchMode(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
DisplayModePtr pTmpMode;
@@ -362,7 +362,7 @@ VidModeLockZoom(int scrnIndex, Bool lock)
}
Bool
-VidModeGetMonitor(int scrnIndex, pointer *monitor)
+VidModeGetMonitor(int scrnIndex, void **monitor)
{
ScrnInfoPtr pScrn;
@@ -370,13 +370,13 @@ VidModeGetMonitor(int scrnIndex, pointer *monitor)
return FALSE;
pScrn = xf86Screens[scrnIndex];
- *monitor = (pointer) (pScrn->monitor);
+ *monitor = (void *) (pScrn->monitor);
return TRUE;
}
ModeStatus
-VidModeCheckModeForMonitor(int scrnIndex, pointer mode)
+VidModeCheckModeForMonitor(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
@@ -389,7 +389,7 @@ VidModeCheckModeForMonitor(int scrnIndex, pointer mode)
}
ModeStatus
-VidModeCheckModeForDriver(int scrnIndex, pointer mode)
+VidModeCheckModeForDriver(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
@@ -402,7 +402,7 @@ VidModeCheckModeForDriver(int scrnIndex, pointer mode)
}
void
-VidModeSetCrtcForMode(int scrnIndex, pointer mode)
+VidModeSetCrtcForMode(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
DisplayModePtr ScreenModes;
@@ -421,7 +421,7 @@ VidModeSetCrtcForMode(int scrnIndex, pointer mode)
}
Bool
-VidModeAddModeline(int scrnIndex, pointer mode)
+VidModeAddModeline(int scrnIndex, void *mode)
{
ScrnInfoPtr pScrn;
@@ -444,7 +444,7 @@ VidModeAddModeline(int scrnIndex, pointer mode)
int
VidModeGetNumOfModes(int scrnIndex)
{
- pointer mode = NULL;
+ void *mode = NULL;
int dotClock = 0, nummodes = 0;
if (!VidModeGetFirstModeline(scrnIndex, &mode, &dotClock))
@@ -526,7 +526,7 @@ VidModeGetGammaRampSize(int scrnIndex)
return xf86GetGammaRampSize(xf86Screens[scrnIndex]->pScreen);
}
-pointer
+void *
VidModeCreateMode(void)
{
DisplayModePtr mode;
@@ -543,13 +543,13 @@ VidModeCreateMode(void)
}
void
-VidModeCopyMode(pointer modefrom, pointer modeto)
+VidModeCopyMode(void *modefrom, void *modeto)
{
memcpy(modeto, modefrom, sizeof(DisplayModeRec));
}
int
-VidModeGetModeValue(pointer mode, int valtyp)
+VidModeGetModeValue(void *mode, int valtyp)
{
int ret = 0;
@@ -592,7 +592,7 @@ VidModeGetModeValue(pointer mode, int valtyp)
}
void
-VidModeSetModeValue(pointer mode, int valtyp, int val)
+VidModeSetModeValue(void *mode, int valtyp, int val)
{
switch (valtyp) {
case VIDMODE_H_DISPLAY:
@@ -633,7 +633,7 @@ VidModeSetModeValue(pointer mode, int valtyp, int val)
}
vidMonitorValue
-VidModeGetMonitorValue(pointer monitor, int valtyp, int indx)
+VidModeGetMonitorValue(void *monitor, int valtyp, int indx)
{
vidMonitorValue ret = { NULL, };
diff --git a/xorg-server/hw/xfree86/common/xf86Xinput.c b/xorg-server/hw/xfree86/common/xf86Xinput.c
index 26c03c6c3..3a0151374 100644
--- a/xorg-server/hw/xfree86/common/xf86Xinput.c
+++ b/xorg-server/hw/xfree86/common/xf86Xinput.c
@@ -107,7 +107,7 @@ static int
* Eval config and modify DeviceVelocityRec accordingly
*/
static void
-ProcessVelocityConfiguration(DeviceIntPtr pDev, char *devname, pointer list,
+ProcessVelocityConfiguration(DeviceIntPtr pDev, const char *devname, void *list,
DeviceVelocityPtr s)
{
int tempi;
@@ -539,7 +539,7 @@ MatchAttrToken(const char *attr, struct xorg_list *patterns,
* match. Each list entry is a separate Match line of the same type.
*/
xorg_list_for_each_entry(group, patterns, entry) {
- char *const *cur;
+ const char *const *cur;
Bool match = FALSE;
for (cur = group->values; *cur; cur++)
@@ -598,7 +598,7 @@ InputClassMatches(const XF86ConfInputClassPtr iclass, const InputInfoPtr idev,
* See if any of the device's tags match any of the MatchTag tokens.
*/
if (!xorg_list_is_empty(&iclass->match_tag)) {
- char *const *tag;
+ const char *const *tag;
Bool match;
if (!attrs->tags)
@@ -661,7 +661,7 @@ MergeInputClasses(const InputInfoPtr idev, const InputAttributes * attrs)
/* Collect class options and driver settings */
classopts = xf86optionListDup(cl->option_lst);
if (cl->driver) {
- free(idev->driver);
+ free((void *) idev->driver);
idev->driver = xstrdup(cl->driver);
if (!idev->driver) {
xf86Msg(X_ERROR, "Failed to allocate memory while merging "
@@ -773,8 +773,8 @@ xf86DeleteInput(InputInfoPtr pInp, int flags)
/* Else the entry wasn't in the xf86InputDevs list (ignore this). */
}
- free(pInp->driver);
- free(pInp->name);
+ free((void *) pInp->driver);
+ free((void *) pInp->name);
xf86optionListFree(pInp->options);
free(pInp);
}
@@ -1067,7 +1067,7 @@ xf86CheckMotionEvent4DGA(DeviceIntPtr device, int is_absolute,
#if XFreeXDGA
ScreenPtr scr = NULL;
- int idx, i;
+ int idx = 0, i;
/* The evdev driver may not always send all axes across. */
if (valuator_mask_isset(mask, 0) || valuator_mask_isset(mask, 1)) {
diff --git a/xorg-server/hw/xfree86/common/xf86Xinput.h b/xorg-server/hw/xfree86/common/xf86Xinput.h
index 35c38a554..f94261a01 100644
--- a/xorg-server/hw/xfree86/common/xf86Xinput.h
+++ b/xorg-server/hw/xfree86/common/xf86Xinput.h
@@ -74,7 +74,7 @@ typedef struct _InputDriverRec {
struct _InputInfoRec * pInfo, int flags);
void (*UnInit) (struct _InputDriverRec * drv,
struct _InputInfoRec * pInfo, int flags);
- pointer module;
+ void *module;
const char **default_options;
} InputDriverRec, *InputDriverPtr;
@@ -82,8 +82,8 @@ typedef struct _InputDriverRec {
typedef struct _InputInfoRec {
struct _InputInfoRec *next;
- char *name;
- char *driver;
+ const char *name;
+ const char *driver;
int flags;
@@ -97,10 +97,10 @@ typedef struct _InputInfoRec {
int fd;
DeviceIntPtr dev;
- pointer private;
+ void *private;
const char *type_name;
InputDriverPtr drv;
- pointer module;
+ void *module;
XF86OptionPtr options;
InputAttributes *attrs;
} *InputInfoPtr;
@@ -178,7 +178,7 @@ int xf86NewInputDevice(InputInfoPtr pInfo, DeviceIntPtr *pdev, BOOL is_auto);
InputInfoPtr xf86AllocateInput(void);
/* xf86Helper.c */
-extern _X_EXPORT void xf86AddInputDriver(InputDriverPtr driver, pointer module,
+extern _X_EXPORT void xf86AddInputDriver(InputDriverPtr driver, void *module,
int flags);
extern _X_EXPORT void xf86DeleteInputDriver(int drvIndex);
extern _X_EXPORT InputDriverPtr xf86LookupInputDriver(const char *name);
diff --git a/xorg-server/hw/xfree86/common/xf86cmap.c b/xorg-server/hw/xfree86/common/xf86cmap.c
index 85f35f8db..3f9c88035 100644
--- a/xorg-server/hw/xfree86/common/xf86cmap.c
+++ b/xorg-server/hw/xfree86/common/xf86cmap.c
@@ -224,7 +224,7 @@ xf86HandleColormaps(ScreenPtr pScreen,
ComputeGamma(pScreenPriv);
/* get the default map */
- dixLookupResourceByType((pointer *) &pDefMap, pScreen->defColormap,
+ dixLookupResourceByType((void **) &pDefMap, pScreen->defColormap,
RT_COLORMAP, serverClient, DixInstallAccess);
if (!CMapAllocateColormapPrivate(pDefMap)) {
diff --git a/xorg-server/hw/xfree86/common/xf86fbman.c b/xorg-server/hw/xfree86/common/xf86fbman.c
index 4da6af2b6..dafaad304 100644
--- a/xorg-server/hw/xfree86/common/xf86fbman.c
+++ b/xorg-server/hw/xfree86/common/xf86fbman.c
@@ -74,7 +74,7 @@ xf86FBManagerRunning(ScreenPtr pScreen)
Bool
xf86RegisterFreeBoxCallback(ScreenPtr pScreen,
FreeBoxCallbackProcPtr FreeBoxCallback,
- pointer devPriv)
+ void *devPriv)
{
FBManagerFuncsPtr funcs;
@@ -93,7 +93,7 @@ xf86AllocateOffscreenArea(ScreenPtr pScreen,
int w, int h,
int gran,
MoveAreaCallbackProcPtr moveCB,
- RemoveAreaCallbackProcPtr removeCB, pointer privData)
+ RemoveAreaCallbackProcPtr removeCB, void *privData)
{
FBManagerFuncsPtr funcs;
@@ -113,7 +113,7 @@ xf86AllocateOffscreenLinear(ScreenPtr pScreen,
int gran,
MoveLinearCallbackProcPtr moveCB,
RemoveLinearCallbackProcPtr removeCB,
- pointer privData)
+ void *privData)
{
FBManagerFuncsPtr funcs;
@@ -309,7 +309,7 @@ SendCallFreeBoxCallbacks(FBManagerPtr offman)
static Bool
localRegisterFreeBoxCallback(ScreenPtr pScreen,
FreeBoxCallbackProcPtr FreeBoxCallback,
- pointer devPriv)
+ void *devPriv)
{
FBManagerPtr offman;
FreeBoxCallbackProcPtr *newCallbacks;
@@ -346,7 +346,7 @@ AllocateArea(FBManagerPtr offman,
int w, int h,
int granularity,
MoveAreaCallbackProcPtr moveCB,
- RemoveAreaCallbackProcPtr removeCB, pointer privData)
+ RemoveAreaCallbackProcPtr removeCB, void *privData)
{
ScreenPtr pScreen = offman->pScreen;
FBLinkPtr link = NULL;
@@ -436,7 +436,7 @@ localAllocateOffscreenArea(ScreenPtr pScreen,
int w, int h,
int gran,
MoveAreaCallbackProcPtr moveCB,
- RemoveAreaCallbackProcPtr removeCB, pointer privData)
+ RemoveAreaCallbackProcPtr removeCB, void *privData)
{
FBManagerPtr offman;
FBAreaPtr area = NULL;
@@ -824,7 +824,7 @@ DumpDebug(FBLinearLinkPtr pLink)
}
static FBLinearPtr
-AllocateLinear(FBManagerPtr offman, int size, int granularity, pointer privData)
+AllocateLinear(FBManagerPtr offman, int size, int granularity, void *privData)
{
ScreenPtr pScreen = offman->pScreen;
FBLinearLinkPtr linear = NULL;
@@ -903,7 +903,7 @@ localAllocateOffscreenLinear(ScreenPtr pScreen,
int gran,
MoveLinearCallbackProcPtr moveCB,
RemoveLinearCallbackProcPtr removeCB,
- pointer privData)
+ void *privData)
{
FBManagerPtr offman;
FBLinearLinkPtr link;
@@ -1394,7 +1394,7 @@ xf86AllocateLinearOffscreenArea(ScreenPtr pScreen,
int gran,
MoveAreaCallbackProcPtr moveCB,
RemoveAreaCallbackProcPtr removeCB,
- pointer privData)
+ void *privData)
{
FBManagerFuncsPtr funcs;
FBManagerPtr offman;
diff --git a/xorg-server/hw/xfree86/common/xf86fbman.h b/xorg-server/hw/xfree86/common/xf86fbman.h
index 99bf9917b..092c2e2dd 100644
--- a/xorg-server/hw/xfree86/common/xf86fbman.h
+++ b/xorg-server/hw/xfree86/common/xf86fbman.h
@@ -60,7 +60,7 @@ typedef struct _FBLinear {
DevUnion devPrivate;
} FBLinear, *FBLinearPtr;
-typedef void (*FreeBoxCallbackProcPtr) (ScreenPtr, RegionPtr, pointer);
+typedef void (*FreeBoxCallbackProcPtr) (ScreenPtr, RegionPtr, void *);
typedef void (*MoveAreaCallbackProcPtr) (FBAreaPtr, FBAreaPtr);
typedef void (*RemoveAreaCallbackProcPtr) (FBAreaPtr);
@@ -73,7 +73,7 @@ typedef struct {
int granularity,
MoveAreaCallbackProcPtr moveCB,
RemoveAreaCallbackProcPtr removeCB,
- pointer privData);
+ void *privData);
void (*FreeOffscreenArea) (FBAreaPtr area);
Bool (*ResizeOffscreenArea) (FBAreaPtr area, int w, int h);
Bool (*QueryLargestOffscreenArea) (ScreenPtr pScreen,
@@ -82,14 +82,14 @@ typedef struct {
int preferences, int priority);
Bool (*RegisterFreeBoxCallback) (ScreenPtr pScreen,
FreeBoxCallbackProcPtr FreeBoxCallback,
- pointer devPriv);
+ void *devPriv);
/* linear functions */
FBLinearPtr(*AllocateOffscreenLinear) (ScreenPtr pScreen,
int size,
int granularity,
MoveLinearCallbackProcPtr moveCB,
RemoveLinearCallbackProcPtr
- removeCB, pointer privData);
+ removeCB, void *privData);
void (*FreeOffscreenLinear) (FBLinearPtr area);
Bool (*ResizeOffscreenLinear) (FBLinearPtr area, int size);
Bool (*QueryLargestOffscreenLinear) (ScreenPtr pScreen,
@@ -121,7 +121,7 @@ xf86AllocateOffscreenArea(ScreenPtr pScreen,
int w, int h,
int granularity,
MoveAreaCallbackProcPtr moveCB,
- RemoveAreaCallbackProcPtr removeCB, pointer privData);
+ RemoveAreaCallbackProcPtr removeCB, void *privData);
extern _X_EXPORT FBAreaPtr
xf86AllocateLinearOffscreenArea(ScreenPtr pScreen,
@@ -129,7 +129,7 @@ xf86AllocateLinearOffscreenArea(ScreenPtr pScreen,
int granularity,
MoveAreaCallbackProcPtr moveCB,
RemoveAreaCallbackProcPtr removeCB,
- pointer privData);
+ void *privData);
extern _X_EXPORT FBLinearPtr
xf86AllocateOffscreenLinear(ScreenPtr pScreen,
@@ -137,7 +137,7 @@ xf86AllocateOffscreenLinear(ScreenPtr pScreen,
int granularity,
MoveLinearCallbackProcPtr moveCB,
RemoveLinearCallbackProcPtr removeCB,
- pointer privData);
+ void *privData);
extern _X_EXPORT void xf86FreeOffscreenArea(FBAreaPtr area);
extern _X_EXPORT void xf86FreeOffscreenLinear(FBLinearPtr area);
@@ -152,7 +152,7 @@ extern _X_EXPORT Bool
xf86RegisterFreeBoxCallback(ScreenPtr pScreen,
FreeBoxCallbackProcPtr FreeBoxCallback,
- pointer devPriv);
+ void *devPriv);
extern _X_EXPORT Bool
xf86PurgeUnlockedOffscreenAreas(ScreenPtr pScreen);
diff --git a/xorg-server/hw/xfree86/common/xf86pciBus.c b/xorg-server/hw/xfree86/common/xf86pciBus.c
index 258988a84..0f76a03ee 100644
--- a/xorg-server/hw/xfree86/common/xf86pciBus.c
+++ b/xorg-server/hw/xfree86/common/xf86pciBus.c
@@ -575,7 +575,7 @@ xf86PciProbeDev(DriverPtr drvp)
}
void
-xf86PciIsolateDevice(char *argument)
+xf86PciIsolateDevice(const char *argument)
{
int bus, device, func;
@@ -1013,7 +1013,7 @@ xf86MatchPciInstances(const char *driverName, int vendorID,
static void
xf86ConfigPciEntityInactive(EntityInfoPtr pEnt, PciChipsets * p_chip,
EntityProc init, EntityProc enter,
- EntityProc leave, pointer private)
+ EntityProc leave, void *private)
{
ScrnInfoPtr pScrn;
@@ -1027,7 +1027,7 @@ xf86ConfigPciEntityInactive(EntityInfoPtr pEnt, PciChipsets * p_chip,
ScrnInfoPtr
xf86ConfigPciEntity(ScrnInfoPtr pScrn, int scrnFlag, int entityIndex,
PciChipsets * p_chip, void *dummy, EntityProc init,
- EntityProc enter, EntityProc leave, pointer private)
+ EntityProc enter, EntityProc leave, void *private)
{
EntityInfoPtr pEnt = xf86GetEntityInfo(entityIndex);
@@ -1068,7 +1068,7 @@ xf86ConfigPciEntity(ScrnInfoPtr pScrn, int scrnFlag, int entityIndex,
Bool
xf86ConfigActivePciEntity(ScrnInfoPtr pScrn, int entityIndex,
PciChipsets * p_chip, void *dummy, EntityProc init,
- EntityProc enter, EntityProc leave, pointer private)
+ EntityProc enter, EntityProc leave, void *private)
{
EntityInfoPtr pEnt = xf86GetEntityInfo(entityIndex);
@@ -1484,6 +1484,7 @@ xf86PciConfigureNewDev(void *busData, struct pci_device *pVideo,
GDevRec * GDev, int *chipset)
{
char busnum[8];
+ char *tmp;
pVideo = (struct pci_device *) busData;
@@ -1493,8 +1494,9 @@ xf86PciConfigureNewDev(void *busData, struct pci_device *pVideo,
snprintf(busnum, sizeof(busnum), "%d@%d",
pVideo->bus & 0x00ff, pVideo->bus >> 8);
- XNFasprintf(&GDev->busID, "PCI:%s:%d:%d",
+ XNFasprintf(&tmp, "PCI:%s:%d:%d",
busnum, pVideo->dev, pVideo->func);
+ GDev->busID = tmp;
GDev->chipID = pVideo->device_id;
GDev->chipRev = pVideo->revision;
diff --git a/xorg-server/hw/xfree86/common/xf86pciBus.h b/xorg-server/hw/xfree86/common/xf86pciBus.h
index 4972c3688..b497a7f2d 100644
--- a/xorg-server/hw/xfree86/common/xf86pciBus.h
+++ b/xorg-server/hw/xfree86/common/xf86pciBus.h
@@ -36,7 +36,7 @@
void xf86PciProbe(void);
Bool xf86PciAddMatchingDev(DriverPtr drvp);
Bool xf86PciProbeDev(DriverPtr drvp);
-void xf86PciIsolateDevice(char *argument);
+void xf86PciIsolateDevice(const char *argument);
int xf86PciMatchDriver(char *matches[], int nmatches);
Bool xf86PciConfigure(void *busData, struct pci_device *pDev);
void xf86PciConfigureNewDev(void *busData, struct pci_device *pVideo,
diff --git a/xorg-server/hw/xfree86/common/xf86platformBus.c b/xorg-server/hw/xfree86/common/xf86platformBus.c
index 33b2b7dd8..5875a9136 100644
--- a/xorg-server/hw/xfree86/common/xf86platformBus.c
+++ b/xorg-server/hw/xfree86/common/xf86platformBus.c
@@ -400,7 +400,7 @@ xf86platformAddDevice(int index)
DriverPtr drvp = NULL;
int entity;
screenLayoutPtr layout;
- static char *hotplug_driver_name = "modesetting";
+ static const char *hotplug_driver_name = "modesetting";
/* force load the driver for now */
xf86LoadOneModule(hotplug_driver_name, NULL);
diff --git a/xorg-server/hw/xfree86/common/xf86sbusBus.h b/xorg-server/hw/xfree86/common/xf86sbusBus.h
index a4d9c6cde..9cfcbc574 100644
--- a/xorg-server/hw/xfree86/common/xf86sbusBus.h
+++ b/xorg-server/hw/xfree86/common/xf86sbusBus.h
@@ -52,16 +52,16 @@ typedef struct sbus_device {
int fd;
int width, height;
sbusPromNode node;
- char *descr;
- char *device;
+ const char *descr;
+ const char *device;
} sbusDevice, *sbusDevicePtr;
struct sbus_devtable {
int devId;
int fbType;
- char *promName;
- char *driverName;
- char *descr;
+ const char *promName;
+ const char *driverName;
+ const char *descr;
};
extern _X_EXPORT void xf86SbusProbe(void);
@@ -76,10 +76,10 @@ extern _X_EXPORT sbusDevicePtr xf86GetSbusInfoForEntity(int entityIndex);
extern _X_EXPORT int xf86GetEntityForSbusInfo(sbusDevicePtr psdp);
extern _X_EXPORT void xf86SbusUseBuiltinMode(ScrnInfoPtr pScrn,
sbusDevicePtr psdp);
-extern _X_EXPORT pointer xf86MapSbusMem(sbusDevicePtr psdp,
+extern _X_EXPORT void *xf86MapSbusMem(sbusDevicePtr psdp,
unsigned long offset,
unsigned long size);
-extern _X_EXPORT void xf86UnmapSbusMem(sbusDevicePtr psdp, pointer addr,
+extern _X_EXPORT void xf86UnmapSbusMem(sbusDevicePtr psdp, void *addr,
unsigned long size);
extern _X_EXPORT void xf86SbusHideOsHwCursor(sbusDevicePtr psdp);
extern _X_EXPORT void xf86SbusSetOsHwCursorCmap(sbusDevicePtr psdp, int bg,
diff --git a/xorg-server/hw/xfree86/common/xf86str.h b/xorg-server/hw/xfree86/common/xf86str.h
index 4c2d147a2..b164b7f21 100644
--- a/xorg-server/hw/xfree86/common/xf86str.h
+++ b/xorg-server/hw/xfree86/common/xf86str.h
@@ -145,7 +145,7 @@ typedef enum {
typedef struct _DisplayModeRec {
struct _DisplayModeRec *prev;
struct _DisplayModeRec *next;
- char *name; /* identifier for the mode */
+ const char *name; /* identifier for the mode */
ModeStatus status;
int type;
@@ -212,9 +212,9 @@ typedef struct {
#define GAMMA_ZERO (GAMMA_MIN / 100.0)
typedef struct {
- char *id;
- char *vendor;
- char *model;
+ const char *id;
+ const char *vendor;
+ const char *model;
int nHsync;
range hsync[MAX_HSYNC];
int nVrefresh;
@@ -224,8 +224,8 @@ typedef struct {
Gamma gamma; /* Gamma of the monitor */
int widthmm;
int heightmm;
- pointer options;
- pointer DDC;
+ void *options;
+ void *DDC;
Bool reducedblanking; /* Allow CVT reduced blanking modes? */
int maxPixClock; /* in kHz, like mode->Clock */
} MonRec, *MonPtr;
@@ -259,7 +259,7 @@ typedef enum {
GET_REQUIRED_HW_INTERFACES = 10
} xorgDriverFuncOp;
-typedef Bool xorgDriverFuncProc(ScrnInfoPtr, xorgDriverFuncOp, pointer);
+typedef Bool xorgDriverFuncProc(ScrnInfoPtr, xorgDriverFuncOp, void *);
/* RR_GET_INFO, RR_SET_CONFIG */
typedef struct {
@@ -299,11 +299,11 @@ struct _DriverRec;
typedef struct {
int driverVersion;
- char *driverName;
+ const char *driverName;
void (*Identify) (int flags);
Bool (*Probe) (struct _DriverRec * drv, int flags);
const OptionInfoRec *(*AvailableOptions) (int chipid, int bustype);
- pointer module;
+ void *module;
int refCount;
} DriverRec1;
@@ -315,11 +315,11 @@ struct xf86_platform_device;
typedef struct _DriverRec {
int driverVersion;
- char *driverName;
+ const char *driverName;
void (*Identify) (int flags);
Bool (*Probe) (struct _DriverRec * drv, int flags);
const OptionInfoRec *(*AvailableOptions) (int chipid, int bustype);
- pointer module;
+ void *module;
int refCount;
xorgDriverFuncProc *driverFunc;
@@ -386,19 +386,19 @@ typedef enum {
} DacSpeedIndex;
typedef struct {
- char *identifier;
- char *vendor;
- char *board;
- char *chipset;
- char *ramdac;
- char *driver;
+ const char *identifier;
+ const char *vendor;
+ const char *board;
+ const char *chipset;
+ const char *ramdac;
+ const char *driver;
struct _confscreenrec *myScreenSection;
Bool claimed;
int dacSpeeds[MAXDACSPEEDS];
int numclocks;
int clock[MAXCLOCKS];
- char *clockchip;
- char *busID;
+ const char *clockchip;
+ const char *busID;
Bool active;
Bool inUse;
int videoRam;
@@ -408,7 +408,7 @@ typedef struct {
unsigned long IOBase;
int chipID;
int chipRev;
- pointer options;
+ void *options;
int irq;
int screen; /* For multi-CRTC cards */
} GDevRec, *GDevPtr;
@@ -424,24 +424,24 @@ typedef struct {
rgb blackColour;
rgb whiteColour;
int defaultVisual;
- char **modes;
- pointer options;
+ const char **modes;
+ void *options;
} DispRec, *DispPtr;
typedef struct _confxvportrec {
- char *identifier;
- pointer options;
+ const char *identifier;
+ void *options;
} confXvPortRec, *confXvPortPtr;
typedef struct _confxvadaptrec {
- char *identifier;
+ const char *identifier;
int numports;
confXvPortPtr ports;
- pointer options;
+ void *options;
} confXvAdaptorRec, *confXvAdaptorPtr;
typedef struct _confscreenrec {
- char *id;
+ const char *id;
int screennum;
int defaultdepth;
int defaultbpp;
@@ -452,7 +452,7 @@ typedef struct _confscreenrec {
DispPtr displays;
int numxvadaptors;
confXvAdaptorPtr xvadaptors;
- pointer options;
+ void *options;
} confScreenRec, *confScreenPtr;
typedef enum {
@@ -467,29 +467,29 @@ typedef enum {
typedef struct _screenlayoutrec {
confScreenPtr screen;
- char *topname;
+ const char *topname;
confScreenPtr top;
- char *bottomname;
+ const char *bottomname;
confScreenPtr bottom;
- char *leftname;
+ const char *leftname;
confScreenPtr left;
- char *rightname;
+ const char *rightname;
confScreenPtr right;
PositionType where;
int x;
int y;
- char *refname;
+ const char *refname;
confScreenPtr refscreen;
} screenLayoutRec, *screenLayoutPtr;
typedef struct _InputInfoRec InputInfoRec;
typedef struct _serverlayoutrec {
- char *id;
+ const char *id;
screenLayoutPtr screens;
GDevPtr inactives;
InputInfoRec **inputs; /* NULL terminated */
- pointer options;
+ void *options;
} serverLayoutRec, *serverLayoutPtr;
typedef struct _confdribufferrec {
@@ -512,7 +512,7 @@ typedef struct _confdrirec {
#define NUM_RESERVED_POINTERS 14
#define NUM_RESERVED_FUNCS 10
-typedef pointer (*funcPointer) (void);
+typedef void *(*funcPointer) (void);
/* flags for depth 24 pixmap options */
typedef enum {
@@ -581,7 +581,7 @@ typedef struct _PciChipsets {
} PciChipsets;
/* Entity properties */
-typedef void (*EntityProc) (int entityIndex, pointer private);
+typedef void (*EntityProc) (int entityIndex, void *private);
typedef struct _entityInfo {
int index;
@@ -671,7 +671,7 @@ typedef void xf86ModeSetProc(ScrnInfoPtr);
typedef struct _ScrnInfoRec {
int driverVersion;
- char *driverName; /* canonical name used in */
+ const char *driverName; /* canonical name used in */
/* the config file */
ScreenPtr pScreen; /* Pointer to the ScreenRec */
int scrnIndex; /* Number of this screen */
@@ -730,20 +730,20 @@ typedef struct _ScrnInfoRec {
int heightmm;
int xDpi; /* width DPI */
int yDpi; /* height DPI */
- char *name; /* Name to prefix messages */
- pointer driverPrivate; /* Driver private area */
+ const char *name; /* Name to prefix messages */
+ void *driverPrivate; /* Driver private area */
DevUnion *privates; /* Other privates can hook in
* here */
DriverPtr drv; /* xf86DriverList[] entry */
- pointer module; /* Pointer to module head */
+ void *module; /* Pointer to module head */
int colorKey;
int overlayFlags;
/* Some of these may be moved out of here into the driver private area */
- char *chipset; /* chipset name */
- char *ramdac; /* ramdac name */
- char *clockchip; /* clock name */
+ const char *chipset; /* chipset name */
+ const char *ramdac; /* ramdac name */
+ const char *clockchip; /* clock name */
Bool progClock; /* clock is programmable */
int numClocks; /* number of clocks */
int clock[MAXCLOCKS]; /* list of clock frequencies */
@@ -754,7 +754,7 @@ typedef struct _ScrnInfoRec {
int memClk; /* memory clock */
int textClockFreq; /* clock of text mode */
Bool flipPixels; /* swap default black/white */
- pointer options;
+ void *options;
int chipID;
int chipRev;
@@ -779,7 +779,7 @@ typedef struct _ScrnInfoRec {
int *entityInstanceList;
struct pci_device *vgaDev;
- pointer reservedPtr[NUM_RESERVED_POINTERS];
+ void *reservedPtr[NUM_RESERVED_POINTERS];
/*
* Driver entry points.
@@ -864,7 +864,7 @@ typedef enum {
typedef void (*DPMSSetProcPtr) (ScrnInfoPtr, int, int);
/* Input handler proc */
-typedef void (*InputHandlerProc) (int fd, pointer data);
+typedef void (*InputHandlerProc) (int fd, void *data);
/* These are used by xf86GetClocks */
#define CLK_REG_SAVE -1
diff --git a/xorg-server/hw/xfree86/common/xf86vmode.c b/xorg-server/hw/xfree86/common/xf86vmode.c
index cad0e6a21..2b07833ad 100644
--- a/xorg-server/hw/xfree86/common/xf86vmode.c
+++ b/xorg-server/hw/xfree86/common/xf86vmode.c
@@ -216,7 +216,7 @@ setEventMask(ScreenPtr pScreen, ClientPtr client, unsigned long mask)
}
static int
-XF86VidModeFreeEvents(pointer value, XID id)
+XF86VidModeFreeEvents(void *value, XID id)
{
XF86VidModeEventPtr pOld = (XF86VidModeEventPtr) value;
ScreenPtr pScreen = pOld->screen;
@@ -314,7 +314,7 @@ ProcXF86VidModeGetModeLine(ClientPtr client)
.type = X_Reply,
.sequenceNumber = client->sequence
};
- pointer mode;
+ void *mode;
int dotClock;
int ver;
@@ -413,7 +413,7 @@ ProcXF86VidModeGetAllModeLines(ClientPtr client)
{
REQUEST(xXF86VidModeGetAllModeLinesReq);
xXF86VidModeGetAllModeLinesReply rep;
- pointer mode;
+ void *mode;
int modecount, dotClock;
int ver;
@@ -524,7 +524,7 @@ ProcXF86VidModeAddModeLine(ClientPtr client)
xXF86OldVidModeAddModeLineReq *oldstuff =
(xXF86OldVidModeAddModeLineReq *) client->requestBuffer;
xXF86VidModeAddModeLineReq newstuff;
- pointer mode;
+ void *mode;
int len;
int dotClock;
int ver;
@@ -688,7 +688,7 @@ ProcXF86VidModeDeleteModeLine(ClientPtr client)
xXF86OldVidModeDeleteModeLineReq *oldstuff =
(xXF86OldVidModeDeleteModeLineReq *) client->requestBuffer;
xXF86VidModeDeleteModeLineReq newstuff;
- pointer mode;
+ void *mode;
int len, dotClock;
int ver;
@@ -813,7 +813,7 @@ ProcXF86VidModeModModeLine(ClientPtr client)
xXF86OldVidModeModModeLineReq *oldstuff =
(xXF86OldVidModeModModeLineReq *) client->requestBuffer;
xXF86VidModeModModeLineReq newstuff;
- pointer mode, modetmp;
+ void *mode, *modetmp;
int len, dotClock;
int ver;
@@ -942,7 +942,7 @@ ProcXF86VidModeValidateModeLine(ClientPtr client)
(xXF86OldVidModeValidateModeLineReq *) client->requestBuffer;
xXF86VidModeValidateModeLineReq newstuff;
xXF86VidModeValidateModeLineReply rep;
- pointer mode, modetmp = NULL;
+ void *mode, *modetmp = NULL;
int len, status, dotClock;
int ver;
@@ -1080,7 +1080,7 @@ ProcXF86VidModeSwitchToMode(ClientPtr client)
xXF86OldVidModeSwitchToModeReq *oldstuff =
(xXF86OldVidModeSwitchToModeReq *) client->requestBuffer;
xXF86VidModeSwitchToModeReq newstuff;
- pointer mode;
+ void *mode;
int len, dotClock;
int ver;
@@ -1205,7 +1205,7 @@ ProcXF86VidModeGetMonitor(ClientPtr client)
};
CARD32 *hsyncdata, *vsyncdata;
int i, nHsync, nVrefresh;
- pointer monitor;
+ void *monitor;
DEBUG_P("XF86VidModeGetMonitor");
diff --git a/xorg-server/hw/xfree86/common/xf86xv.c b/xorg-server/hw/xfree86/common/xf86xv.c
index 92d0f6da2..b16cb5df3 100644
--- a/xorg-server/hw/xfree86/common/xf86xv.c
+++ b/xorg-server/hw/xfree86/common/xf86xv.c
@@ -261,7 +261,7 @@ xf86XVScreenInit(ScreenPtr pScreen, XF86VideoAdaptorPtr * adaptors, int num)
sure that I appreciate that. */
ScreenPriv = malloc(sizeof(XF86XVScreenRec));
- pxvs->devPriv.ptr = (pointer) ScreenPriv;
+ pxvs->devPriv.ptr = (void *) ScreenPriv;
if (!ScreenPriv)
return FALSE;
@@ -551,7 +551,7 @@ xf86XVInitAdaptors(ScreenPtr pScreen, XF86VideoAdaptorPtr * infoPtr, int number)
adaptorPriv->PutImage = adaptorPtr->PutImage;
adaptorPriv->ReputImage = adaptorPtr->ReputImage; /* image/still */
- pa->devPriv.ptr = (pointer) adaptorPriv;
+ pa->devPriv.ptr = (void *) adaptorPriv;
if (!(pPort = calloc(adaptorPtr->nPorts, sizeof(XvPortRec)))) {
xf86XVFreeAdaptor(pa);
@@ -957,7 +957,7 @@ xf86XVReputImage(XvPortRecPrivatePtr portPriv)
}
static int
-xf86XVReputAllVideo(WindowPtr pWin, pointer data)
+xf86XVReputAllVideo(WindowPtr pWin, void *data)
{
XF86XVWindowPtr WinPriv = GET_XF86XV_WINDOW(pWin);
@@ -1922,7 +1922,7 @@ xf86XVFillKeyHelper(ScreenPtr pScreen, CARD32 key, RegionPtr fillboxes)
}
void
-xf86XVFillKeyHelperPort(DrawablePtr pDraw, pointer data, CARD32 key,
+xf86XVFillKeyHelperPort(DrawablePtr pDraw, void *data, CARD32 key,
RegionPtr clipboxes, Bool fillEverything)
{
WindowPtr pWin = (WindowPtr) pDraw;
diff --git a/xorg-server/hw/xfree86/common/xf86xv.h b/xorg-server/hw/xfree86/common/xf86xv.h
index 091efcaa9..8986e2e57 100644
--- a/xorg-server/hw/xfree86/common/xf86xv.h
+++ b/xorg-server/hw/xfree86/common/xf86xv.h
@@ -84,47 +84,47 @@ typedef int (*PutVideoFuncPtr) (ScrnInfoPtr pScrn,
short vid_x, short vid_y, short drw_x,
short drw_y, short vid_w, short vid_h,
short drw_w, short drw_h, RegionPtr clipBoxes,
- pointer data, DrawablePtr pDraw);
+ void *data, DrawablePtr pDraw);
typedef int (*PutStillFuncPtr) (ScrnInfoPtr pScrn, short vid_x, short vid_y,
short drw_x, short drw_y, short vid_w,
short vid_h, short drw_w, short drw_h,
- RegionPtr clipBoxes, pointer data,
+ RegionPtr clipBoxes, void *data,
DrawablePtr pDraw);
typedef int (*GetVideoFuncPtr) (ScrnInfoPtr pScrn, short vid_x, short vid_y,
short drw_x, short drw_y, short vid_w,
short vid_h, short drw_w, short drw_h,
- RegionPtr clipBoxes, pointer data,
+ RegionPtr clipBoxes, void *data,
DrawablePtr pDraw);
typedef int (*GetStillFuncPtr) (ScrnInfoPtr pScrn, short vid_x, short vid_y,
short drw_x, short drw_y, short vid_w,
short vid_h, short drw_w, short drw_h,
- RegionPtr clipBoxes, pointer data,
+ RegionPtr clipBoxes, void *data,
DrawablePtr pDraw);
-typedef void (*StopVideoFuncPtr) (ScrnInfoPtr pScrn, pointer data, Bool Exit);
+typedef void (*StopVideoFuncPtr) (ScrnInfoPtr pScrn, void *data, Bool Exit);
typedef int (*SetPortAttributeFuncPtr) (ScrnInfoPtr pScrn, Atom attribute,
- INT32 value, pointer data);
+ INT32 value, void *data);
typedef int (*GetPortAttributeFuncPtr) (ScrnInfoPtr pScrn, Atom attribute,
- INT32 *value, pointer data);
+ INT32 *value, void *data);
typedef void (*QueryBestSizeFuncPtr) (ScrnInfoPtr pScrn, Bool motion,
short vid_w, short vid_h, short drw_w,
short drw_h, unsigned int *p_w,
- unsigned int *p_h, pointer data);
+ unsigned int *p_h, void *data);
typedef int (*PutImageFuncPtr) (ScrnInfoPtr pScrn, short src_x, short src_y,
short drw_x, short drw_y, short src_w,
short src_h, short drw_w, short drw_h,
int image, unsigned char *buf, short width,
short height, Bool Sync, RegionPtr clipBoxes,
- pointer data, DrawablePtr pDraw);
+ void *data, DrawablePtr pDraw);
typedef int (*ReputImageFuncPtr) (ScrnInfoPtr pScrn, short src_x, short src_y,
short drw_x, short drw_y, short src_w,
short src_h, short drw_w, short drw_h,
- RegionPtr clipBoxes, pointer data,
+ RegionPtr clipBoxes, void *data,
DrawablePtr pDraw);
typedef int (*QueryImageAttributesFuncPtr) (ScrnInfoPtr pScrn, int image,
unsigned short *width,
unsigned short *height,
int *pitches, int *offsets);
-typedef void (*ClipNotifyFuncPtr) (ScrnInfoPtr pScrn, pointer data,
+typedef void (*ClipNotifyFuncPtr) (ScrnInfoPtr pScrn, void *data,
WindowPtr window, int dx, int dy);
typedef enum {
@@ -137,7 +137,7 @@ typedef enum {
typedef struct {
int id;
- char *name;
+ const char *name;
unsigned short width, height;
XvRationalRec rate;
} XF86VideoEncodingRec, *XF86VideoEncodingPtr;
@@ -151,13 +151,13 @@ typedef struct {
int flags;
int min_value;
int max_value;
- char *name;
+ const char *name;
} XF86AttributeRec, *XF86AttributePtr;
typedef struct {
unsigned int type;
int flags;
- char *name;
+ const char *name;
int nEncodings;
XF86VideoEncodingPtr pEncodings;
int nFormats;
@@ -238,7 +238,7 @@ xf86XVFillKeyHelperDrawable(DrawablePtr pDraw, CARD32 key, RegionPtr clipboxes);
extern _X_EXPORT void
-xf86XVFillKeyHelperPort(DrawablePtr pDraw, pointer data, CARD32 key,
+xf86XVFillKeyHelperPort(DrawablePtr pDraw, void *data, CARD32 key,
RegionPtr clipboxes, Bool fillEverything);
extern _X_EXPORT Bool
diff --git a/xorg-server/hw/xfree86/common/xf86xvmc.h b/xorg-server/hw/xfree86/common/xf86xvmc.h
index 2478fe344..aaa4e65f0 100644
--- a/xorg-server/hw/xfree86/common/xf86xvmc.h
+++ b/xorg-server/hw/xfree86/common/xf86xvmc.h
@@ -109,7 +109,7 @@ typedef void (*xf86XvMCDestroySubpictureProcPtr) (ScrnInfoPtr pScrn,
XvMCSubpicturePtr subpicture);
typedef struct {
- char *name;
+ const char *name;
int num_surfaces;
XF86MCSurfaceInfoPtr *surfaces;
int num_subpictures;
diff --git a/xorg-server/hw/xfree86/ddc/ddc.c b/xorg-server/hw/xfree86/ddc/ddc.c
index 44c1d535c..04d1a09c5 100644
--- a/xorg-server/hw/xfree86/ddc/ddc.c
+++ b/xorg-server/hw/xfree86/ddc/ddc.c
@@ -299,7 +299,7 @@ xf86DoEDID_DDC1(ScrnInfoPtr pScrn, DDC1SetSpeedProc DDC1SetSpeed,
/* DDC2 */
static I2CDevPtr
-DDC2MakeDevice(I2CBusPtr pBus, int address, char *name)
+DDC2MakeDevice(I2CBusPtr pBus, int address, const char *name)
{
I2CDevPtr dev = NULL;
diff --git a/xorg-server/hw/xfree86/dixmods/glxmodule.c b/xorg-server/hw/xfree86/dixmods/glxmodule.c
index 133a2a65d..bf7d182a2 100644
--- a/xorg-server/hw/xfree86/dixmods/glxmodule.c
+++ b/xorg-server/hw/xfree86/dixmods/glxmodule.c
@@ -68,8 +68,8 @@ static XF86ModuleVersionInfo VersRec = {
_X_EXPORT XF86ModuleData glxModuleData = { &VersRec, glxSetup, NULL };
-static pointer
-glxSetup(pointer module, pointer opts, int *errmaj, int *errmin)
+static void *
+glxSetup(void *module, void *opts, int *errmaj, int *errmin)
{
static Bool setupDone = FALSE;
__GLXprovider *provider;
diff --git a/xorg-server/hw/xfree86/dri/dri.c b/xorg-server/hw/xfree86/dri/dri.c
index 6292e87cc..38bfc1def 100644
--- a/xorg-server/hw/xfree86/dri/dri.c
+++ b/xorg-server/hw/xfree86/dri/dri.c
@@ -100,6 +100,11 @@ drmServerInfo DRIDRMServerInfo;
* easily changed here.
*/
#define DRI_MSG_VERBOSITY 1
+
+static void
+DRIDrvMsg(int scrnIndex, MessageType type, const char *format, ...)
+ _X_ATTRIBUTE_PRINTF(3,4);
+
static void
DRIDrvMsg(int scrnIndex, MessageType type, const char *format, ...)
{
@@ -400,7 +405,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
}
DRIDrvMsg(pScreen->myNum, X_INFO,
"[drm] added %d byte SAREA at %p\n",
- pDRIPriv->pDriverInfo->SAREASize, pDRIPriv->hSAREA);
+ (int) pDRIPriv->pDriverInfo->SAREASize, (void *) (uintptr_t) pDRIPriv->hSAREA);
/* Backwards compat. */
if (drmMap(pDRIPriv->drmFD,
@@ -414,7 +419,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
return FALSE;
}
DRIDrvMsg(pScreen->myNum, X_INFO, "[drm] mapped SAREA %p to %p\n",
- pDRIPriv->hSAREA, pDRIPriv->pSAREA);
+ (void *) (uintptr_t) pDRIPriv->hSAREA, pDRIPriv->pSAREA);
memset(pDRIPriv->pSAREA, 0, pDRIPriv->pDriverInfo->SAREASize);
}
else {
@@ -442,7 +447,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
return FALSE;
}
DRIDrvMsg(pScreen->myNum, X_INFO, "[drm] framebuffer handle = %p\n",
- pDRIPriv->pDriverInfo->hFrameBuffer);
+ (void *) (uintptr_t) pDRIPriv->pDriverInfo->hFrameBuffer);
}
else {
DRIDrvMsg(pScreen->myNum, X_INFO,
@@ -513,7 +518,7 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
pDRIPriv->myContextPriv = pDRIContextPriv;
DRIDrvMsg(pScreen->myNum, X_INFO,
- "X context handle = %p\n", pDRIPriv->myContext);
+ "X context handle = %p\n", (void *) (uintptr_t) pDRIPriv->myContext);
/* Now that we have created the X server's context, we can grab the
* hardware lock for the X server.
@@ -731,13 +736,13 @@ DRICloseScreen(ScreenPtr pScreen)
if (closeMaster || pDRIPriv->hSAREA != pDRIEntPriv->hLSAREA) {
DRIDrvMsg(pScreen->myNum, X_INFO,
"[drm] unmapping %d bytes of SAREA %p at %p\n",
- pDRIInfo->SAREASize, pDRIPriv->hSAREA, pDRIPriv->pSAREA);
+ (int) pDRIInfo->SAREASize, (void *) (uintptr_t) pDRIPriv->hSAREA, pDRIPriv->pSAREA);
if (drmUnmap(pDRIPriv->pSAREA, pDRIInfo->SAREASize)) {
DRIDrvMsg(pScreen->myNum, X_ERROR,
"[drm] unable to unmap %d bytes"
" of SAREA %p at %p\n",
- pDRIInfo->SAREASize,
- pDRIPriv->hSAREA, pDRIPriv->pSAREA);
+ (int) pDRIInfo->SAREASize,
+ (void *) (uintptr_t) pDRIPriv->hSAREA, pDRIPriv->pSAREA);
}
}
else {
@@ -761,6 +766,10 @@ DRICloseScreen(ScreenPtr pScreen)
static int
dri_drm_debug_print(const char *format, va_list ap)
+ _X_ATTRIBUTE_PRINTF(1,0);
+
+static int
+dri_drm_debug_print(const char *format, va_list ap)
{
xf86VDrvMsgVerb(-1, X_NONE, DRM_MSG_VERBOSITY, format, ap);
return 0;
@@ -1043,7 +1052,7 @@ DRICreateContext(ScreenPtr pScreen, VisualPtr visual,
}
/* track this in case the client dies before cleanup */
- AddResource(context, DRIContextPrivResType, (pointer) pDRIContextPriv);
+ AddResource(context, DRIContextPrivResType, (void *) pDRIContextPriv);
return TRUE;
}
@@ -1058,7 +1067,7 @@ DRIDestroyContext(ScreenPtr pScreen, XID context)
/* DRIContextPrivDelete is called by the resource manager. */
Bool
-DRIContextPrivDelete(pointer pResource, XID id)
+DRIContextPrivDelete(void *pResource, XID id)
{
DRIContextPrivPtr pDRIContextPriv = (DRIContextPrivPtr) pResource;
DRIScreenPrivPtr pDRIPriv;
@@ -1141,7 +1150,7 @@ DRITransitionTo2d(ScreenPtr pScreen)
}
static int
-DRIDCNTreeTraversal(WindowPtr pWin, pointer data)
+DRIDCNTreeTraversal(WindowPtr pWin, void *data)
{
DRIDrawablePrivPtr pDRIDrawablePriv = DRI_DRAWABLE_PRIV_FROM_WINDOW(pWin);
@@ -1180,7 +1189,7 @@ DRIDriverClipNotify(ScreenPtr pScreen)
if (pDRIPriv->nrWindows > 0) {
pDRIPriv->nrWalked = 0;
TraverseTree(pScreen->root, DRIDCNTreeTraversal,
- (pointer) pDRIWindows);
+ (void *) pDRIWindows);
}
pDRIInfo->ClipNotify(pScreen, pDRIWindows, pDRIPriv->nrWindows);
@@ -1275,7 +1284,7 @@ DRICreateDrawable(ScreenPtr pScreen, ClientPtr client, DrawablePtr pDrawable,
/* track this in case the client dies */
AddResource(FakeClientID(client->index), DRIDrawablePrivResType,
- (pointer) (intptr_t) pDrawable->id);
+ (void *) (intptr_t) pDrawable->id);
if (pDRIDrawablePriv->hwDrawable) {
drmUpdateDrawableInfo(pDRIPriv->drmFD,
@@ -1328,7 +1337,7 @@ DRIDrawablePrivDestroy(WindowPtr pWin)
}
static Bool
-DRIDestroyDrawableCB(pointer value, XID id, pointer data)
+DRIDestroyDrawableCB(void *value, XID id, void *data)
{
if (value == data) {
/* This calls back DRIDrawablePrivDelete which frees private area */
@@ -1346,7 +1355,7 @@ DRIDestroyDrawable(ScreenPtr pScreen, ClientPtr client, DrawablePtr pDrawable)
if (pDrawable->type == DRAWABLE_WINDOW) {
LookupClientResourceComplex(client, DRIDrawablePrivResType,
DRIDestroyDrawableCB,
- (pointer) (intptr_t) pDrawable->id);
+ (void *) (intptr_t) pDrawable->id);
}
else { /* pixmap (or for GLX 1.3, a PBuffer) */
/* NOT_DONE */
@@ -1357,7 +1366,7 @@ DRIDestroyDrawable(ScreenPtr pScreen, ClientPtr client, DrawablePtr pDrawable)
}
Bool
-DRIDrawablePrivDelete(pointer pResource, XID id)
+DRIDrawablePrivDelete(void *pResource, XID id)
{
WindowPtr pWin;
int rc;
@@ -1616,7 +1625,7 @@ DRIDestroyInfoRec(DRIInfoPtr DRIInfo)
}
void
-DRIWakeupHandler(pointer wakeupData, int result, pointer pReadmask)
+DRIWakeupHandler(void *wakeupData, int result, void *pReadmask)
{
int i;
@@ -1631,7 +1640,7 @@ DRIWakeupHandler(pointer wakeupData, int result, pointer pReadmask)
}
void
-DRIBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadmask)
+DRIBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadmask)
{
int i;
@@ -1647,7 +1656,7 @@ DRIBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadmask)
void
DRIDoWakeupHandler(ScreenPtr pScreen,
- unsigned long result, pointer pReadmask)
+ unsigned long result, void *pReadmask)
{
DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pScreen);
@@ -1665,7 +1674,7 @@ DRIDoWakeupHandler(ScreenPtr pScreen,
void
DRIDoBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadmask)
+ void *pTimeout, void *pReadmask)
{
DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pScreen);
@@ -1868,7 +1877,7 @@ DRIWindowExposures(WindowPtr pWin, RegionPtr prgn, RegionPtr bsreg)
}
static int
-DRITreeTraversal(WindowPtr pWin, pointer data)
+DRITreeTraversal(WindowPtr pWin, void *data)
{
DRIDrawablePrivPtr pDRIDrawablePriv = DRI_DRAWABLE_PRIV_FROM_WINDOW(pWin);
@@ -1928,7 +1937,7 @@ DRICopyWindow(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
RegionNull(&reg);
pDRIPriv->nrWalked = 0;
- TraverseTree(pWin, DRITreeTraversal, (pointer) (&reg));
+ TraverseTree(pWin, DRITreeTraversal, (void *) (&reg));
if (RegionNotEmpty(&reg)) {
RegionTranslate(&reg, ptOldOrg.x - pWin->drawable.x,
@@ -2214,9 +2223,9 @@ DRILock(ScreenPtr pScreen, int flags)
else if (*pDRIPriv->pLockingContext != pDRIPriv->myContext) {
DRIDrvMsg(pScreen->myNum, X_ERROR,
"[DRI] Locking deadlock.\n"
- "\tAlready locked with context %d,\n"
- "\ttrying to lock with context %d.\n",
- pDRIPriv->pLockingContext, pDRIPriv->myContext);
+ "\tAlready locked with context %p,\n"
+ "\ttrying to lock with context %p.\n",
+ pDRIPriv->pLockingContext, (void *) (uintptr_t) pDRIPriv->myContext);
}
(*pDRIPriv->pLockRefCount)++;
}
@@ -2233,8 +2242,8 @@ DRIUnlock(ScreenPtr pScreen)
if (pDRIPriv->myContext != *pDRIPriv->pLockingContext) {
DRIDrvMsg(pScreen->myNum, X_ERROR,
"[DRI] Unlocking inconsistency:\n"
- "\tContext %d trying to unlock lock held by context %d\n",
- pDRIPriv->pLockingContext, pDRIPriv->myContext);
+ "\tContext %p trying to unlock lock held by context %p\n",
+ pDRIPriv->pLockingContext, (void *) (uintptr_t) pDRIPriv->myContext);
}
(*pDRIPriv->pLockRefCount)--;
}
diff --git a/xorg-server/hw/xfree86/dri/dri.h b/xorg-server/hw/xfree86/dri/dri.h
index 4bfaf1679..64cd7c9d4 100644
--- a/xorg-server/hw/xfree86/dri/dri.h
+++ b/xorg-server/hw/xfree86/dri/dri.h
@@ -151,7 +151,7 @@ typedef struct {
int ddxDriverMajorVersion;
int ddxDriverMinorVersion;
int ddxDriverPatchVersion;
- pointer frameBufferPhysicalAddress;
+ void *frameBufferPhysicalAddress;
long frameBufferSize;
long frameBufferStride;
long SAREASize;
@@ -224,7 +224,7 @@ extern _X_EXPORT Bool DRICreateContext(ScreenPtr pScreen,
extern _X_EXPORT Bool DRIDestroyContext(ScreenPtr pScreen, XID context);
-extern _X_EXPORT Bool DRIContextPrivDelete(pointer pResource, XID id);
+extern _X_EXPORT Bool DRIContextPrivDelete(void *pResource, XID id);
extern _X_EXPORT Bool DRICreateDrawable(ScreenPtr pScreen,
ClientPtr client,
@@ -235,7 +235,7 @@ extern _X_EXPORT Bool DRIDestroyDrawable(ScreenPtr pScreen,
ClientPtr client,
DrawablePtr pDrawable);
-extern _X_EXPORT Bool DRIDrawablePrivDelete(pointer pResource, XID id);
+extern _X_EXPORT Bool DRIDrawablePrivDelete(void *pResource, XID id);
extern _X_EXPORT Bool DRIGetDrawableInfo(ScreenPtr pScreen,
DrawablePtr pDrawable,
@@ -265,18 +265,18 @@ extern _X_EXPORT void DRIDestroyInfoRec(DRIInfoPtr DRIInfo);
extern _X_EXPORT Bool DRIFinishScreenInit(ScreenPtr pScreen);
-extern _X_EXPORT void DRIWakeupHandler(pointer wakeupData,
- int result, pointer pReadmask);
+extern _X_EXPORT void DRIWakeupHandler(void *wakeupData,
+ int result, void *pReadmask);
-extern _X_EXPORT void DRIBlockHandler(pointer blockData,
- OSTimePtr pTimeout, pointer pReadmask);
+extern _X_EXPORT void DRIBlockHandler(void *blockData,
+ OSTimePtr pTimeout, void *pReadmask);
extern _X_EXPORT void DRIDoWakeupHandler(ScreenPtr pScreen,
unsigned long result,
- pointer pReadmask);
+ void *pReadmask);
extern _X_EXPORT void DRIDoBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadmask);
+ void *pTimeout, void *pReadmask);
extern _X_EXPORT void DRISwapContext(int drmFD, void *oldctx, void *newctx);
diff --git a/xorg-server/hw/xfree86/dri2/dri2.c b/xorg-server/hw/xfree86/dri2/dri2.c
index 0b047f025..729a323da 100644
--- a/xorg-server/hw/xfree86/dri2/dri2.c
+++ b/xorg-server/hw/xfree86/dri2/dri2.c
@@ -354,7 +354,7 @@ DRI2CreateDrawable(ClientPtr client, DrawablePtr pDraw, XID id,
}
static int
-DRI2DrawableGone(pointer p, XID id)
+DRI2DrawableGone(void *p, XID id)
{
DRI2DrawablePtr pPriv = p;
DRI2DrawableRefPtr ref, next;
@@ -754,7 +754,7 @@ static inline PixmapPtr GetDrawablePixmap(DrawablePtr drawable)
* pixmap
*/
static int
-DRI2InvalidateWalk(WindowPtr pWin, pointer data)
+DRI2InvalidateWalk(WindowPtr pWin, void *data)
{
if (pWin->drawable.pScreen->GetWindowPixmap(pWin) != data)
return WT_DONTWALKCHILDREN;
@@ -1563,8 +1563,6 @@ DRI2CloseScreen(ScreenPtr pScreen)
dixSetPrivate(&pScreen->devPrivates, dri2ScreenPrivateKey, NULL);
}
-extern Bool DRI2ModuleSetup(void);
-
/* Called by InitExtensions() */
Bool
DRI2ModuleSetup(void)
diff --git a/xorg-server/hw/xfree86/exa/examodule.c b/xorg-server/hw/xfree86/exa/examodule.c
index 4e809ea37..76f780ab6 100644
--- a/xorg-server/hw/xfree86/exa/examodule.c
+++ b/xorg-server/hw/xfree86/exa/examodule.c
@@ -128,7 +128,7 @@ exaDDXDriverInit(ScreenPtr pScreen)
if (pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) {
if (!(pExaScr->info->flags & EXA_HANDLES_PIXMAPS) &&
pExaScr->info->offScreenBase < pExaScr->info->memorySize) {
- char *heuristicName;
+ const char *heuristicName;
heuristicName = xf86GetOptValString(pScreenPriv->options,
EXAOPT_MIGRATION_HEURISTIC);
diff --git a/xorg-server/hw/xfree86/fbdevhw/fbdevhw.c b/xorg-server/hw/xfree86/fbdevhw/fbdevhw.c
index cbb40930b..0450822ee 100644
--- a/xorg-server/hw/xfree86/fbdevhw/fbdevhw.c
+++ b/xorg-server/hw/xfree86/fbdevhw/fbdevhw.c
@@ -81,15 +81,13 @@ typedef struct {
Bool
fbdevHWGetRec(ScrnInfoPtr pScrn)
{
- fbdevHWPtr fPtr;
-
if (fbdevHWPrivateIndex < 0)
fbdevHWPrivateIndex = xf86AllocateScrnInfoPrivateIndex();
if (FBDEVHWPTR(pScrn) != NULL)
return TRUE;
- fPtr = FBDEVHWPTRLVAL(pScrn) = xnfcalloc(sizeof(fbdevHWRec), 1);
+ FBDEVHWPTRLVAL(pScrn) = xnfcalloc(sizeof(fbdevHWRec), 1);
return TRUE;
}
@@ -301,7 +299,7 @@ fbdev_open_pci(struct pci_device *pPci, char **namep)
}
static int
-fbdev_open(int scrnIndex, char *dev, char **namep)
+fbdev_open(int scrnIndex, const char *dev, char **namep)
{
struct fb_fix_screeninfo fix;
int fd;
@@ -497,7 +495,7 @@ fbdevHWSetMode(ScrnInfoPtr pScrn, DisplayModePtr mode, Bool check)
void
fbdevHWSetVideoModes(ScrnInfoPtr pScrn)
{
- char **modename;
+ const char **modename;
DisplayModePtr mode, this, last = pScrn->modes;
if (NULL == pScrn->display->modes)
diff --git a/xorg-server/hw/xfree86/i2c/bt829.c b/xorg-server/hw/xfree86/i2c/bt829.c
index 070cb2044..991c26eab 100644
--- a/xorg-server/hw/xfree86/i2c/bt829.c
+++ b/xorg-server/hw/xfree86/i2c/bt829.c
@@ -500,6 +500,7 @@ bt829_Detect(I2CBusPtr b, I2CSlaveAddr addr)
{
BT829Ptr bt;
I2CByte a;
+ char *devname;
bt = calloc(1, sizeof(BT829Rec));
if (bt == NULL)
@@ -520,31 +521,31 @@ bt829_Detect(I2CBusPtr b, I2CSlaveAddr addr)
bt->id = btread(bt, IDCODE);
- free(bt->d.DevName);
- bt->d.DevName = calloc(200, sizeof(char));
+ free((void *) bt->d.DevName);
+ bt->d.DevName = devname = calloc(200, sizeof(char));
switch (BTVERSION) {
case BT815:
- sprintf(bt->d.DevName, "bt815a video decoder, revision %d",
+ sprintf(devname, "bt815a video decoder, revision %d",
bt->id & 0xf);
break;
case BT817:
- sprintf(bt->d.DevName, "bt817a video decoder, revision %d",
+ sprintf(devname, "bt817a video decoder, revision %d",
bt->id & 0xf);
break;
case BT819:
- sprintf(bt->d.DevName, "bt819a video decoder, revision %d",
+ sprintf(devname, "bt819a video decoder, revision %d",
bt->id & 0xf);
break;
case BT827:
- sprintf(bt->d.DevName, "bt827a/b video decoder, revision %d",
+ sprintf(devname, "bt827a/b video decoder, revision %d",
bt->id & 0xf);
break;
case BT829:
- sprintf(bt->d.DevName, "bt829a/b video decoder, revision %d",
+ sprintf(devname, "bt829a/b video decoder, revision %d",
bt->id & 0xf);
break;
default:
- sprintf(bt->d.DevName,
+ sprintf(devname,
"bt8xx/unknown video decoder version %d, revision %d",
bt->id >> 4, bt->id & 0xf);
break;
diff --git a/xorg-server/hw/xfree86/i2c/fi1236.c b/xorg-server/hw/xfree86/i2c/fi1236.c
index 2eb27ba6d..ebd14547d 100644
--- a/xorg-server/hw/xfree86/i2c/fi1236.c
+++ b/xorg-server/hw/xfree86/i2c/fi1236.c
@@ -545,7 +545,7 @@ FI1236_set_tuner_type(FI1236Ptr f, int type)
}
static CARD32
-AFC_TimerCallback(OsTimerPtr timer, CARD32 time, pointer data)
+AFC_TimerCallback(OsTimerPtr timer, CARD32 time, void *data)
{
FI1236Ptr f = (FI1236Ptr) data;
diff --git a/xorg-server/hw/xfree86/i2c/msp3430.c b/xorg-server/hw/xfree86/i2c/msp3430.c
index 312a2d1d1..a501489ee 100644
--- a/xorg-server/hw/xfree86/i2c/msp3430.c
+++ b/xorg-server/hw/xfree86/i2c/msp3430.c
@@ -163,7 +163,7 @@ DetectMSP3430(I2CBusPtr b, I2CSlaveAddr addr)
m->d.ByteTimeout = b->ByteTimeout;
if (!I2C_WriteRead(&(m->d), NULL, 0, &a, 1)) {
- free(m->d.DevName);
+ free((void *) m->d.DevName);
free(m);
return NULL;
}
@@ -250,12 +250,12 @@ DetectMSP3430(I2CBusPtr b, I2CSlaveAddr addr)
supported ? "" : " (unsupported)", rom_version, m->chip_id);
if (!supported) {
- free(m->d.DevName);
+ free((void *) m->d.DevName);
free(m);
return NULL;
}
if (!I2CDevInit(&(m->d))) {
- free(m->d.DevName);
+ free((void *) m->d.DevName);
free(m);
return NULL;
}
diff --git a/xorg-server/hw/xfree86/i2c/xf86i2c.h b/xorg-server/hw/xfree86/i2c/xf86i2c.h
index e296d7d81..26303ff6f 100644
--- a/xorg-server/hw/xfree86/i2c/xf86i2c.h
+++ b/xorg-server/hw/xfree86/i2c/xf86i2c.h
@@ -66,7 +66,7 @@ extern _X_EXPORT int xf86I2CGetScreenBuses(int scrnIndex,
/* I2C slave devices */
typedef struct _I2CDevRec {
- char *DevName;
+ const char *DevName;
int BitTimeout; /* usec */
int ByteTimeout; /* usec */
diff --git a/xorg-server/hw/xfree86/int10/generic.c b/xorg-server/hw/xfree86/int10/generic.c
index d7594def2..abbd36f3c 100644
--- a/xorg-server/hw/xfree86/int10/generic.c
+++ b/xorg-server/hw/xfree86/int10/generic.c
@@ -20,12 +20,12 @@
#define ALLOC_ENTRIES(x) ((V_RAM / x) - 1)
-static CARD8 read_b(xf86Int10InfoPtr pInt, int addr);
-static CARD16 read_w(xf86Int10InfoPtr pInt, int addr);
-static CARD32 read_l(xf86Int10InfoPtr pInt, int addr);
-static void write_b(xf86Int10InfoPtr pInt, int addr, CARD8 val);
-static void write_w(xf86Int10InfoPtr pInt, int addr, CARD16 val);
-static void write_l(xf86Int10InfoPtr pInt, int addr, CARD32 val);
+static uint8_t read_b(xf86Int10InfoPtr pInt, int addr);
+static uint16_t read_w(xf86Int10InfoPtr pInt, int addr);
+static uint32_t read_l(xf86Int10InfoPtr pInt, int addr);
+static void write_b(xf86Int10InfoPtr pInt, int addr, uint8_t val);
+static void write_w(xf86Int10InfoPtr pInt, int addr, uint16_t val);
+static void write_l(xf86Int10InfoPtr pInt, int addr, uint32_t val);
/*
* the emulator cannot pass a pointer to the current xf86Int10InfoRec
@@ -87,8 +87,8 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
if (!xf86Int10ExecSetup(pInt))
goto error0;
pInt->mem = &genericMem;
- pInt->private = (pointer) xnfcalloc(1, sizeof(genericInt10Priv));
- INTPriv(pInt)->alloc = (pointer) xnfcalloc(1, ALLOC_ENTRIES(getpagesize()));
+ pInt->private = (void *) xnfcalloc(1, sizeof(genericInt10Priv));
+ INTPriv(pInt)->alloc = (void *) xnfcalloc(1, ALLOC_ENTRIES(getpagesize()));
pInt->pScrn = pScrn;
base = INTPriv(pInt)->base = xnfalloc(SYS_BIOS);
@@ -339,39 +339,39 @@ xf86Int10FreePages(xf86Int10InfoPtr pInt, void *pbase, int num)
#define VRAM(addr) ((addr >= V_RAM) && (addr < (V_RAM + VRAM_SIZE)))
#define V_ADDR_RB(addr) \
- (VRAM(addr)) ? MMIO_IN8((CARD8*)VRAM_BASE,VRAM_ADDR(addr)) \
- : *(CARD8*) V_ADDR(addr)
+ (VRAM(addr)) ? MMIO_IN8((uint8_t*)VRAM_BASE,VRAM_ADDR(addr)) \
+ : *(uint8_t*) V_ADDR(addr)
#define V_ADDR_RW(addr) \
- (VRAM(addr)) ? MMIO_IN16((CARD16*)VRAM_BASE,VRAM_ADDR(addr)) \
- : ldw_u((pointer)V_ADDR(addr))
+ (VRAM(addr)) ? MMIO_IN16((uint16_t*)VRAM_BASE,VRAM_ADDR(addr)) \
+ : ldw_u((void *)V_ADDR(addr))
#define V_ADDR_RL(addr) \
- (VRAM(addr)) ? MMIO_IN32((CARD32*)VRAM_BASE,VRAM_ADDR(addr)) \
- : ldl_u((pointer)V_ADDR(addr))
+ (VRAM(addr)) ? MMIO_IN32((uint32_t*)VRAM_BASE,VRAM_ADDR(addr)) \
+ : ldl_u((void *)V_ADDR(addr))
#define V_ADDR_WB(addr,val) \
if(VRAM(addr)) \
- MMIO_OUT8((CARD8*)VRAM_BASE,VRAM_ADDR(addr),val); \
+ MMIO_OUT8((uint8_t*)VRAM_BASE,VRAM_ADDR(addr),val); \
else \
- *(CARD8*) V_ADDR(addr) = val;
+ *(uint8_t*) V_ADDR(addr) = val;
#define V_ADDR_WW(addr,val) \
if(VRAM(addr)) \
- MMIO_OUT16((CARD16*)VRAM_BASE,VRAM_ADDR(addr),val); \
+ MMIO_OUT16((uint16_t*)VRAM_BASE,VRAM_ADDR(addr),val); \
else \
- stw_u((val),(pointer)(V_ADDR(addr)));
+ stw_u((val),(void *)(V_ADDR(addr)));
#define V_ADDR_WL(addr,val) \
if (VRAM(addr)) \
- MMIO_OUT32((CARD32*)VRAM_BASE,VRAM_ADDR(addr),val); \
+ MMIO_OUT32((uint32_t*)VRAM_BASE,VRAM_ADDR(addr),val); \
else \
- stl_u(val,(pointer)(V_ADDR(addr)));
+ stl_u(val,(void *)(V_ADDR(addr)));
-static CARD8
+static uint8_t
read_b(xf86Int10InfoPtr pInt, int addr)
{
return V_ADDR_RB(addr);
}
-static CARD16
+static uint16_t
read_w(xf86Int10InfoPtr pInt, int addr)
{
#if X_BYTE_ORDER == X_LITTLE_ENDIAN
@@ -381,7 +381,7 @@ read_w(xf86Int10InfoPtr pInt, int addr)
return V_ADDR_RB(addr) | (V_ADDR_RB(addr + 1) << 8);
}
-static CARD32
+static uint32_t
read_l(xf86Int10InfoPtr pInt, int addr)
{
#if X_BYTE_ORDER == X_LITTLE_ENDIAN
@@ -394,7 +394,7 @@ read_l(xf86Int10InfoPtr pInt, int addr)
}
static void
-write_b(xf86Int10InfoPtr pInt, int addr, CARD8 val)
+write_b(xf86Int10InfoPtr pInt, int addr, uint8_t val)
{
V_ADDR_WB(addr, val);
}
@@ -412,7 +412,7 @@ write_w(xf86Int10InfoPtr pInt, int addr, CARD16 val)
}
static void
-write_l(xf86Int10InfoPtr pInt, int addr, CARD32 val)
+write_l(xf86Int10InfoPtr pInt, int addr, uint32_t val)
{
#if X_BYTE_ORDER == X_LITTLE_ENDIAN
if (OFF(addr + 3) > 2) {
@@ -425,8 +425,8 @@ write_l(xf86Int10InfoPtr pInt, int addr, CARD32 val)
V_ADDR_WB(addr + 3, val >> 24);
}
-pointer
-xf86int10Addr(xf86Int10InfoPtr pInt, CARD32 addr)
+void *
+xf86int10Addr(xf86Int10InfoPtr pInt, uint32_t addr)
{
return V_ADDR(addr);
}
diff --git a/xorg-server/hw/xfree86/int10/helper_exec.c b/xorg-server/hw/xfree86/int10/helper_exec.c
index 1c58cf7ae..6a83f422e 100644
--- a/xorg-server/hw/xfree86/int10/helper_exec.c
+++ b/xorg-server/hw/xfree86/int10/helper_exec.c
@@ -37,12 +37,12 @@
#endif
#include <pciaccess.h>
-static int pciCfg1in(CARD16 addr, CARD32 *val);
-static int pciCfg1out(CARD16 addr, CARD32 val);
-static int pciCfg1inw(CARD16 addr, CARD16 *val);
-static int pciCfg1outw(CARD16 addr, CARD16 val);
-static int pciCfg1inb(CARD16 addr, CARD8 *val);
-static int pciCfg1outb(CARD16 addr, CARD8 val);
+static int pciCfg1in(uint16_t addr, uint32_t *val);
+static int pciCfg1out(uint16_t addr, uint32_t val);
+static int pciCfg1inw(uint16_t addr, uint16_t *val);
+static int pciCfg1outw(uint16_t addr, uint16_t val);
+static int pciCfg1inb(uint16_t addr, uint8_t *val);
+static int pciCfg1outb(uint16_t addr, uint8_t val);
#if defined (_PC)
static void SetResetBIOSVars(xf86Int10InfoPtr pInt, Bool set);
@@ -58,13 +58,13 @@ setup_int(xf86Int10InfoPtr pInt)
return -1;
Int10Current = pInt;
}
- X86_EAX = (CARD32) pInt->ax;
- X86_EBX = (CARD32) pInt->bx;
- X86_ECX = (CARD32) pInt->cx;
- X86_EDX = (CARD32) pInt->dx;
- X86_ESI = (CARD32) pInt->si;
- X86_EDI = (CARD32) pInt->di;
- X86_EBP = (CARD32) pInt->bp;
+ X86_EAX = (uint32_t) pInt->ax;
+ X86_EBX = (uint32_t) pInt->bx;
+ X86_ECX = (uint32_t) pInt->cx;
+ X86_EDX = (uint32_t) pInt->dx;
+ X86_ESI = (uint32_t) pInt->si;
+ X86_EDI = (uint32_t) pInt->di;
+ X86_EBP = (uint32_t) pInt->bp;
X86_ESP = 0x1000;
X86_SS = pInt->stackseg >> 4;
X86_EIP = 0x0600;
@@ -86,15 +86,15 @@ void
finish_int(xf86Int10InfoPtr pInt, int sig)
{
OsReleaseSignals();
- pInt->ax = (CARD32) X86_EAX;
- pInt->bx = (CARD32) X86_EBX;
- pInt->cx = (CARD32) X86_ECX;
- pInt->dx = (CARD32) X86_EDX;
- pInt->si = (CARD32) X86_ESI;
- pInt->di = (CARD32) X86_EDI;
- pInt->es = (CARD16) X86_ES;
- pInt->bp = (CARD32) X86_EBP;
- pInt->flags = (CARD32) X86_FLAGS;
+ pInt->ax = (uint32_t) X86_EAX;
+ pInt->bx = (uint32_t) X86_EBX;
+ pInt->cx = (uint32_t) X86_ECX;
+ pInt->dx = (uint32_t) X86_EDX;
+ pInt->si = (uint32_t) X86_ESI;
+ pInt->di = (uint32_t) X86_EDI;
+ pInt->es = (uint16_t) X86_ES;
+ pInt->bp = (uint32_t) X86_EBP;
+ pInt->flags = (uint32_t) X86_FLAGS;
#if defined (_PC)
if (pInt->Flags & RESTORE_BIOS_SCRATCH)
SetResetBIOSVars(pInt, FALSE);
@@ -102,23 +102,23 @@ finish_int(xf86Int10InfoPtr pInt, int sig)
}
/* general software interrupt handler */
-CARD32
+uint32_t
getIntVect(xf86Int10InfoPtr pInt, int num)
{
return MEM_RW(pInt, num << 2) + (MEM_RW(pInt, (num << 2) + 2) << 4);
}
void
-pushw(xf86Int10InfoPtr pInt, CARD16 val)
+pushw(xf86Int10InfoPtr pInt, uint16_t val)
{
X86_ESP -= 2;
- MEM_WW(pInt, ((CARD32) X86_SS << 4) + X86_SP, val);
+ MEM_WW(pInt, ((uint32_t) X86_SS << 4) + X86_SP, val);
}
int
run_bios_int(int num, xf86Int10InfoPtr pInt)
{
- CARD32 eflags;
+ uint32_t eflags;
#ifndef _PC
/* check if bios vector is initialized */
@@ -167,10 +167,10 @@ void
dump_code(xf86Int10InfoPtr pInt)
{
int i;
- CARD32 lina = SEG_ADR((CARD32), X86_CS, IP);
+ uint32_t lina = SEG_ADR((uint32_t), X86_CS, IP);
xf86DrvMsgVerb(pInt->pScrn->scrnIndex, X_INFO, 3, "code at 0x%8.8" PRIx32 ":\n",
- lina);
+ (unsigned) lina);
for (i = 0; i < 0x10; i++)
xf86ErrorFVerb(3, " %2.2x", MEM_RB(pInt, lina + i));
xf86ErrorFVerb(3, "\n");
@@ -203,8 +203,8 @@ void
stack_trace(xf86Int10InfoPtr pInt)
{
int i = 0;
- unsigned long stack = SEG_ADR((CARD32), X86_SS, SP);
- unsigned long tail = (CARD32) ((X86_SS << 4) + 0x1000);
+ unsigned long stack = SEG_ADR((uint32_t), X86_SS, SP);
+ unsigned long tail = (uint32_t) ((X86_SS << 4) + 0x1000);
if (stack >= tail)
return;
@@ -222,14 +222,14 @@ stack_trace(xf86Int10InfoPtr pInt)
int
port_rep_inb(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -1 : 1;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_insb(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
MEM_WB(pInt, dst, x_inb(port));
dst += inc;
@@ -239,14 +239,14 @@ port_rep_inb(xf86Int10InfoPtr pInt,
int
port_rep_inw(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -2 : 2;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_insw(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
MEM_WW(pInt, dst, x_inw(port));
dst += inc;
@@ -256,14 +256,14 @@ port_rep_inw(xf86Int10InfoPtr pInt,
int
port_rep_inl(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -4 : 4;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_insl(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
MEM_WL(pInt, dst, x_inl(port));
dst += inc;
@@ -273,14 +273,14 @@ port_rep_inl(xf86Int10InfoPtr pInt,
int
port_rep_outb(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -1 : 1;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_outb(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
x_outb(port, MEM_RB(pInt, dst));
dst += inc;
@@ -290,14 +290,14 @@ port_rep_outb(xf86Int10InfoPtr pInt,
int
port_rep_outw(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -2 : 2;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_outw(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
x_outw(port, MEM_RW(pInt, dst));
dst += inc;
@@ -307,14 +307,14 @@ port_rep_outw(xf86Int10InfoPtr pInt,
int
port_rep_outl(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count)
+ uint16_t port, uint32_t base, int d_f, uint32_t count)
{
register int inc = d_f ? -4 : 4;
- CARD32 dst = base;
+ uint32_t dst = base;
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" rep_outl(%#x) %" PRIu32 " bytes at %8.8" PRIx32 " %s\n",
- port, count, base, d_f ? "up" : "down");
+ port, (unsigned) count, (unsigned) base, d_f ? "up" : "down");
while (count--) {
x_outl(port, MEM_RL(pInt, dst));
dst += inc;
@@ -322,14 +322,14 @@ port_rep_outl(xf86Int10InfoPtr pInt,
return dst - base;
}
-CARD8
-x_inb(CARD16 port)
+uint8_t
+x_inb(uint16_t port)
{
- CARD8 val;
+ uint8_t val;
if (port == 0x40) {
Int10Current->inb40time++;
- val = (CARD8) (Int10Current->inb40time >>
+ val = (uint8_t) (Int10Current->inb40time >>
((Int10Current->inb40time & 1) << 3));
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" inb(%#x) = %2.2x\n", port, val);
@@ -353,10 +353,10 @@ x_inb(CARD16 port)
return val;
}
-CARD16
-x_inw(CARD16 port)
+uint16_t
+x_inw(uint16_t port)
{
- CARD16 val;
+ uint16_t val;
if (port == 0x5c) {
struct timeval tv;
@@ -366,7 +366,7 @@ x_inw(CARD16 port)
* Approximate this by dividing by 3.
*/
X_GETTIMEOFDAY(&tv);
- val = (CARD16) (tv.tv_usec / 3);
+ val = (uint16_t) (tv.tv_usec / 3);
}
else if (!pciCfg1inw(port, &val)) {
val = pci_io_read16(Int10Current->io, port);
@@ -377,7 +377,7 @@ x_inw(CARD16 port)
}
void
-x_outb(CARD16 port, CARD8 val)
+x_outb(uint16_t port, uint8_t val)
{
if ((port == 0x43) && (val == 0)) {
struct timeval tv;
@@ -389,7 +389,7 @@ x_outb(CARD16 port, CARD8 val)
* the bottom bit as a byte select. See inb(0x40) above.
*/
X_GETTIMEOFDAY(&tv);
- Int10Current->inb40time = (CARD16) (tv.tv_usec | 1);
+ Int10Current->inb40time = (uint16_t) (tv.tv_usec | 1);
if (PRINT_PORT && DEBUG_IO_TRACE())
ErrorF(" outb(%#x, %2.2x)\n", port, val);
#ifdef __NOT_YET__
@@ -411,7 +411,7 @@ x_outb(CARD16 port, CARD8 val)
}
void
-x_outw(CARD16 port, CARD16 val)
+x_outw(uint16_t port, uint16_t val)
{
if (!pciCfg1outw(port, val)) {
@@ -421,66 +421,66 @@ x_outw(CARD16 port, CARD16 val)
}
}
-CARD32
-x_inl(CARD16 port)
+uint32_t
+x_inl(uint16_t port)
{
- CARD32 val;
+ uint32_t val;
if (!pciCfg1in(port, &val)) {
val = pci_io_read32(Int10Current->io, port);
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" inl(%#x) = %8.8" PRIx32 "\n", port, val);
+ ErrorF(" inl(%#x) = %8.8" PRIx32 "\n", port, (unsigned) val);
}
return val;
}
void
-x_outl(CARD16 port, CARD32 val)
+x_outl(uint16_t port, uint32_t val)
{
if (!pciCfg1out(port, val)) {
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" outl(%#x, %8.8" PRIx32 ")\n", port, val);
+ ErrorF(" outl(%#x, %8.8" PRIx32 ")\n", port, (unsigned) val);
pci_io_write32(Int10Current->io, port, val);
}
}
-CARD8
-Mem_rb(CARD32 addr)
+uint8_t
+Mem_rb(uint32_t addr)
{
return (*Int10Current->mem->rb) (Int10Current, addr);
}
-CARD16
-Mem_rw(CARD32 addr)
+uint16_t
+Mem_rw(uint32_t addr)
{
return (*Int10Current->mem->rw) (Int10Current, addr);
}
-CARD32
-Mem_rl(CARD32 addr)
+uint32_t
+Mem_rl(uint32_t addr)
{
return (*Int10Current->mem->rl) (Int10Current, addr);
}
void
-Mem_wb(CARD32 addr, CARD8 val)
+Mem_wb(uint32_t addr, uint8_t val)
{
(*Int10Current->mem->wb) (Int10Current, addr, val);
}
void
-Mem_ww(CARD32 addr, CARD16 val)
+Mem_ww(uint32_t addr, uint16_t val)
{
(*Int10Current->mem->ww) (Int10Current, addr, val);
}
void
-Mem_wl(CARD32 addr, CARD32 val)
+Mem_wl(uint32_t addr, uint32_t val)
{
(*Int10Current->mem->wl) (Int10Current, addr, val);
}
-static CARD32 PciCfg1Addr = 0;
+static uint32_t PciCfg1Addr = 0;
#define PCI_DOM_FROM_TAG(tag) (((tag) >> 24) & (PCI_DOM_MASK))
#define PCI_BUS_FROM_TAG(tag) (((tag) >> 16) & (PCI_DOMBUS_MASK))
@@ -491,10 +491,10 @@ static CARD32 PciCfg1Addr = 0;
#define PCI_TAG(x) ((x) & 0x7fffff00)
static struct pci_device *
-pci_device_for_cfg_address(CARD32 addr)
+pci_device_for_cfg_address(uint32_t addr)
{
struct pci_device *dev = NULL;
- CARD32 tag = PCI_TAG(addr);
+ uint32_t tag = PCI_TAG(addr);
struct pci_slot_match slot_match = {
.domain = PCI_DOM_FROM_TAG(tag),
@@ -516,7 +516,7 @@ pci_device_for_cfg_address(CARD32 addr)
}
static int
-pciCfg1in(CARD16 addr, CARD32 *val)
+pciCfg1in(uint16_t addr, uint32_t *val)
{
if (addr == 0xCF8) {
*val = PciCfg1Addr;
@@ -526,15 +526,15 @@ pciCfg1in(CARD16 addr, CARD32 *val)
pci_device_cfg_read_u32(pci_device_for_cfg_address(PciCfg1Addr),
(uint32_t *) val, PCI_OFFSET(PciCfg1Addr));
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_inl(%#" PRIx32 ") = %8.8" PRIx32 "\n", PciCfg1Addr,
- *val);
+ ErrorF(" cfg_inl(%#" PRIx32 ") = %8.8" PRIx32 "\n", (unsigned) PciCfg1Addr,
+ (unsigned) *val);
return 1;
}
return 0;
}
static int
-pciCfg1out(CARD16 addr, CARD32 val)
+pciCfg1out(uint16_t addr, uint32_t val)
{
if (addr == 0xCF8) {
PciCfg1Addr = val;
@@ -542,8 +542,8 @@ pciCfg1out(CARD16 addr, CARD32 val)
}
if (addr == 0xCFC) {
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_outl(%#" PRIx32 ", %8.8" PRIx32 ")\n", PciCfg1Addr,
- val);
+ ErrorF(" cfg_outl(%#" PRIx32 ", %8.8" PRIx32 ")\n", (unsigned) PciCfg1Addr,
+ (unsigned) val);
pci_device_cfg_write_u32(pci_device_for_cfg_address(PciCfg1Addr), val,
PCI_OFFSET(PciCfg1Addr));
return 1;
@@ -552,7 +552,7 @@ pciCfg1out(CARD16 addr, CARD32 val)
}
static int
-pciCfg1inw(CARD16 addr, CARD16 *val)
+pciCfg1inw(uint16_t addr, uint16_t *val)
{
int shift;
@@ -567,30 +567,30 @@ pciCfg1inw(CARD16 addr, CARD16 *val)
pci_device_cfg_read_u16(pci_device_for_cfg_address(PciCfg1Addr),
val, PCI_OFFSET(PciCfg1Addr) + offset);
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_inw(%#" PRIx32 ") = %4.4x\n", PciCfg1Addr + offset,
- *val);
+ ErrorF(" cfg_inw(%#" PRIx32 ") = %4.4x\n", (unsigned) (PciCfg1Addr + offset),
+ (unsigned) *val);
return 1;
}
return 0;
}
static int
-pciCfg1outw(CARD16 addr, CARD16 val)
+pciCfg1outw(uint16_t addr, uint16_t val)
{
int shift;
if ((addr >= 0xCF8) && (addr <= 0xCFB)) {
shift = (addr - 0xCF8) * 8;
PciCfg1Addr &= ~(0xffff << shift);
- PciCfg1Addr |= ((CARD32) val) << shift;
+ PciCfg1Addr |= ((uint32_t) val) << shift;
return 1;
}
if ((addr >= 0xCFC) && (addr <= 0xCFF)) {
const unsigned offset = addr - 0xCFC;
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_outw(%#" PRIx32 ", %4.4x)\n", PciCfg1Addr + offset,
- val);
+ ErrorF(" cfg_outw(%#" PRIx32 ", %4.4x)\n", (unsigned) (PciCfg1Addr + offset),
+ (unsigned) val);
pci_device_cfg_write_u16(pci_device_for_cfg_address(PciCfg1Addr), val,
PCI_OFFSET(PciCfg1Addr) + offset);
return 1;
@@ -599,7 +599,7 @@ pciCfg1outw(CARD16 addr, CARD16 val)
}
static int
-pciCfg1inb(CARD16 addr, CARD8 *val)
+pciCfg1inb(uint16_t addr, uint8_t *val)
{
int shift;
@@ -614,30 +614,30 @@ pciCfg1inb(CARD16 addr, CARD8 *val)
pci_device_cfg_read_u8(pci_device_for_cfg_address(PciCfg1Addr),
val, PCI_OFFSET(PciCfg1Addr) + offset);
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_inb(%#" PRIx32 ") = %2.2x\n", PciCfg1Addr + offset,
- *val);
+ ErrorF(" cfg_inb(%#" PRIx32 ") = %2.2x\n", (unsigned) (PciCfg1Addr + offset),
+ (unsigned) *val);
return 1;
}
return 0;
}
static int
-pciCfg1outb(CARD16 addr, CARD8 val)
+pciCfg1outb(uint16_t addr, uint8_t val)
{
int shift;
if ((addr >= 0xCF8) && (addr <= 0xCFB)) {
shift = (addr - 0xCF8) * 8;
PciCfg1Addr &= ~(0xff << shift);
- PciCfg1Addr |= ((CARD32) val) << shift;
+ PciCfg1Addr |= ((uint32_t) val) << shift;
return 1;
}
if ((addr >= 0xCFC) && (addr <= 0xCFF)) {
const unsigned offset = addr - 0xCFC;
if (PRINT_PORT && DEBUG_IO_TRACE())
- ErrorF(" cfg_outb(%#" PRIx32 ", %2.2x)\n", PciCfg1Addr + offset,
- val);
+ ErrorF(" cfg_outb(%#" PRIx32 ", %2.2x)\n", (unsigned) (PciCfg1Addr + offset),
+ (unsigned) val);
pci_device_cfg_write_u8(pci_device_for_cfg_address(PciCfg1Addr), val,
PCI_OFFSET(PciCfg1Addr) + offset);
return 1;
@@ -645,10 +645,10 @@ pciCfg1outb(CARD16 addr, CARD8 val)
return 0;
}
-CARD8
-bios_checksum(const CARD8 *start, int size)
+uint8_t
+bios_checksum(const uint8_t *start, int size)
{
- CARD8 sum = 0;
+ uint8_t sum = 0;
while (size-- > 0)
sum += *start++;
@@ -682,12 +682,12 @@ LockLegacyVGA(xf86Int10InfoPtr pInt, legacyVGAPtr vga)
vga->save_46e8 = pci_io_read8(pInt->io, 0x46E8);
#endif
vga->save_pos102 = pci_io_read8(pInt->io, 0x0102);
- pci_io_write8(pInt->io, 0x03C2, ~(CARD8) 0x03 & vga->save_msr);
- pci_io_write8(pInt->io, 0x03C3, ~(CARD8) 0x01 & vga->save_vse);
+ pci_io_write8(pInt->io, 0x03C2, ~(uint8_t) 0x03 & vga->save_msr);
+ pci_io_write8(pInt->io, 0x03C3, ~(uint8_t) 0x01 & vga->save_vse);
#ifndef __ia64__
- pci_io_write8(pInt->io, 0x46E8, ~(CARD8) 0x08 & vga->save_46e8);
+ pci_io_write8(pInt->io, 0x46E8, ~(uint8_t) 0x08 & vga->save_46e8);
#endif
- pci_io_write8(pInt->io, 0x0102, ~(CARD8) 0x01 & vga->save_pos102);
+ pci_io_write8(pInt->io, 0x0102, ~(uint8_t) 0x01 & vga->save_pos102);
}
void
diff --git a/xorg-server/hw/xfree86/int10/helper_mem.c b/xorg-server/hw/xfree86/int10/helper_mem.c
index 160c5aedf..1b5960e0c 100644
--- a/xorg-server/hw/xfree86/int10/helper_mem.c
+++ b/xorg-server/hw/xfree86/int10/helper_mem.c
@@ -199,7 +199,7 @@ xf86HandleInt10Options(ScrnInfoPtr pScrn, int entityIndex)
OptionInfoPtr options = NULL;
if (pEnt->device) {
- pointer configOptions = NULL;
+ void *configOptions = NULL;
/* Check if xf86CollectOptions() has already been called */
if (((pEnt->index < 0) ||
diff --git a/xorg-server/hw/xfree86/int10/stub.c b/xorg-server/hw/xfree86/int10/stub.c
index 8fd079069..40e0ba719 100644
--- a/xorg-server/hw/xfree86/int10/stub.c
+++ b/xorg-server/hw/xfree86/int10/stub.c
@@ -62,7 +62,7 @@ xf86ExecX86int10(xf86Int10InfoPtr pInt)
return;
}
-pointer
+void *
xf86int10Addr(xf86Int10InfoPtr pInt, CARD32 addr)
{
return 0;
diff --git a/xorg-server/hw/xfree86/int10/xf86int10.h b/xorg-server/hw/xfree86/int10/xf86int10.h
index 6d564fc1a..83bab7e61 100644
--- a/xorg-server/hw/xfree86/int10/xf86int10.h
+++ b/xorg-server/hw/xfree86/int10/xf86int10.h
@@ -21,13 +21,13 @@
/* int10 info structure */
typedef struct {
int entityIndex;
- CARD16 BIOSseg;
- CARD16 inb40time;
+ uint16_t BIOSseg;
+ uint16_t inb40time;
ScrnInfoPtr pScrn;
- pointer cpuRegs;
+ void *cpuRegs;
char *BIOSScratch;
int Flags;
- pointer private;
+ void *private;
struct _int10Mem *mem;
int num;
int ax;
@@ -45,19 +45,19 @@ typedef struct {
} xf86Int10InfoRec, *xf86Int10InfoPtr;
typedef struct _int10Mem {
- CARD8 (*rb) (xf86Int10InfoPtr, int);
- CARD16 (*rw) (xf86Int10InfoPtr, int);
- CARD32 (*rl) (xf86Int10InfoPtr, int);
- void (*wb) (xf86Int10InfoPtr, int, CARD8);
- void (*ww) (xf86Int10InfoPtr, int, CARD16);
- void (*wl) (xf86Int10InfoPtr, int, CARD32);
+ uint8_t (*rb) (xf86Int10InfoPtr, int);
+ uint16_t (*rw) (xf86Int10InfoPtr, int);
+ uint32_t (*rl) (xf86Int10InfoPtr, int);
+ void (*wb) (xf86Int10InfoPtr, int, uint8_t);
+ void (*ww) (xf86Int10InfoPtr, int, uint16_t);
+ void (*wl) (xf86Int10InfoPtr, int, uint32_t);
} int10MemRec, *int10MemPtr;
typedef struct {
- CARD8 save_msr;
- CARD8 save_pos102;
- CARD8 save_vse;
- CARD8 save_46e8;
+ uint8_t save_msr;
+ uint8_t save_pos102;
+ uint8_t save_vse;
+ uint8_t save_46e8;
} legacyVGARec, *legacyVGAPtr;
/* OS dependent functions */
@@ -69,7 +69,7 @@ extern _X_EXPORT void *xf86Int10AllocPages(xf86Int10InfoPtr pInt, int num,
int *off);
extern _X_EXPORT void xf86Int10FreePages(xf86Int10InfoPtr pInt, void *pbase,
int num);
-extern _X_EXPORT pointer xf86int10Addr(xf86Int10InfoPtr pInt, CARD32 addr);
+extern _X_EXPORT void *xf86int10Addr(xf86Int10InfoPtr pInt, uint32_t addr);
/* x86 executor related functions */
extern _X_EXPORT void xf86ExecX86int10(xf86Int10InfoPtr pInt);
@@ -127,13 +127,13 @@ int int_handler(xf86Int10InfoPtr pInt);
/* helper_exec.c */
int setup_int(xf86Int10InfoPtr pInt);
void finish_int(xf86Int10InfoPtr, int sig);
-CARD32 getIntVect(xf86Int10InfoPtr pInt, int num);
-void pushw(xf86Int10InfoPtr pInt, CARD16 val);
+uint32_t getIntVect(xf86Int10InfoPtr pInt, int num);
+void pushw(xf86Int10InfoPtr pInt, uint16_t val);
int run_bios_int(int num, xf86Int10InfoPtr pInt);
void dump_code(xf86Int10InfoPtr pInt);
void dump_registers(xf86Int10InfoPtr pInt);
void stack_trace(xf86Int10InfoPtr pInt);
-CARD8 bios_checksum(const CARD8 *start, int size);
+uint8_t bios_checksum(const uint8_t *start, int size);
void LockLegacyVGA(xf86Int10InfoPtr pInt, legacyVGAPtr vga);
void UnlockLegacyVGA(xf86Int10InfoPtr pInt, legacyVGAPtr vga);
@@ -142,31 +142,31 @@ extern _X_EXPORT void xf86Int10SaveRestoreBIOSVars(xf86Int10InfoPtr pInt,
Bool save);
#endif
int port_rep_inb(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
int port_rep_inw(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
int port_rep_inl(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
int port_rep_outb(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
int port_rep_outw(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
int port_rep_outl(xf86Int10InfoPtr pInt,
- CARD16 port, CARD32 base, int d_f, CARD32 count);
-
-CARD8 x_inb(CARD16 port);
-CARD16 x_inw(CARD16 port);
-void x_outb(CARD16 port, CARD8 val);
-void x_outw(CARD16 port, CARD16 val);
-CARD32 x_inl(CARD16 port);
-void x_outl(CARD16 port, CARD32 val);
-
-CARD8 Mem_rb(CARD32 addr);
-CARD16 Mem_rw(CARD32 addr);
-CARD32 Mem_rl(CARD32 addr);
-void Mem_wb(CARD32 addr, CARD8 val);
-void Mem_ww(CARD32 addr, CARD16 val);
-void Mem_wl(CARD32 addr, CARD32 val);
+ uint16_t port, uint32_t base, int d_f, uint32_t count);
+
+uint8_t x_inb(uint16_t port);
+uint16_t x_inw(uint16_t port);
+void x_outb(uint16_t port, uint8_t val);
+void x_outw(uint16_t port, uint16_t val);
+uint32_t x_inl(uint16_t port);
+void x_outl(uint16_t port, uint32_t val);
+
+uint8_t Mem_rb(uint32_t addr);
+uint16_t Mem_rw(uint32_t addr);
+uint32_t Mem_rl(uint32_t addr);
+void Mem_wb(uint32_t addr, uint8_t val);
+void Mem_ww(uint32_t addr, uint16_t val);
+void Mem_wl(uint32_t addr, uint32_t val);
/* helper_mem.c */
void setup_int_vect(xf86Int10InfoPtr pInt);
diff --git a/xorg-server/hw/xfree86/int10/xf86x86emu.c b/xorg-server/hw/xfree86/int10/xf86x86emu.c
index 0f8737b49..b9a4d3603 100644
--- a/xorg-server/hw/xfree86/int10/xf86x86emu.c
+++ b/xorg-server/hw/xfree86/int10/xf86x86emu.c
@@ -50,12 +50,12 @@ xf86Int10ExecSetup(xf86Int10InfoPtr pInt)
X86EMU_intrFuncs intFuncs[256];
X86EMU_pioFuncs pioFuncs = {
- (&x_inb),
- (&x_inw),
- (&x_inl),
- (&x_outb),
- (&x_outw),
- (&x_outl)
+ .inb = x_inb,
+ .inw = x_inw,
+ .inl = x_inl,
+ .outb = x_outb,
+ .outw = x_outw,
+ .outl = x_outl
};
X86EMU_memFuncs memFuncs = {
diff --git a/xorg-server/hw/xfree86/loader/loaderProcs.h b/xorg-server/hw/xfree86/loader/loaderProcs.h
index 8b4b53f28..cfc4d8069 100644
--- a/xorg-server/hw/xfree86/loader/loaderProcs.h
+++ b/xorg-server/hw/xfree86/loader/loaderProcs.h
@@ -72,10 +72,10 @@ typedef struct module_desc {
void LoaderInit(void);
-ModuleDescPtr LoadDriver(const char *, const char *, int, pointer, int *,
+ModuleDescPtr LoadDriver(const char *, const char *, int, void *, int *,
int *);
ModuleDescPtr LoadModule(const char *, const char *, const char **,
- const char **, pointer, const XF86ModReqInfo *,
+ const char **, void *, const XF86ModReqInfo *,
int *, int *);
ModuleDescPtr DuplicateModule(ModuleDescPtr mod, ModuleDescPtr parent);
void UnloadDriver(ModuleDescPtr);
diff --git a/xorg-server/hw/xfree86/loader/loadmod.c b/xorg-server/hw/xfree86/loader/loadmod.c
index 2347b8e5b..092bf5735 100644
--- a/xorg-server/hw/xfree86/loader/loadmod.c
+++ b/xorg-server/hw/xfree86/loader/loadmod.c
@@ -81,7 +81,7 @@ static void UnloadModuleOrDriver(ModuleDescPtr mod);
static char *LoaderGetCanonicalName(const char *, PatternPtr);
static void RemoveChild(ModuleDescPtr);
static ModuleDescPtr doLoadModule(const char *, const char *, const char **,
- const char **, pointer,
+ const char **, void *,
const XF86ModReqInfo *, int *, int *);
const ModuleVersions LoaderVersionInfo = {
@@ -482,7 +482,7 @@ FindModule(const char *module, const char *dirname, const char **subdirlist,
return name;
}
-char **
+const char **
LoaderListDirs(const char **subdirlist, const char **patternlist)
{
char buf[PATH_MAX + 1];
@@ -490,7 +490,7 @@ LoaderListDirs(const char **subdirlist, const char **patternlist)
char **elem;
const char **subdirs;
const char **s;
- PatternPtr patterns;
+ PatternPtr patterns = NULL;
PatternPtr p;
DIR *d;
struct dirent *dp;
@@ -571,7 +571,7 @@ LoaderListDirs(const char **subdirlist, const char **patternlist)
FreePatterns(patterns);
FreeSubdirs(subdirs);
FreePathList(pathlist);
- return ret;
+ return (const char **) ret;
}
void
@@ -761,10 +761,10 @@ AddSibling(ModuleDescPtr head, ModuleDescPtr new)
return new;
}
-pointer
-LoadSubModule(pointer _parent, const char *module,
+void *
+LoadSubModule(void *_parent, const char *module,
const char **subdirlist, const char **patternlist,
- pointer options, const XF86ModReqInfo * modreq,
+ void *options, const XF86ModReqInfo * modreq,
int *errmaj, int *errmin)
{
ModuleDescPtr submod;
@@ -843,7 +843,7 @@ static const char *compiled_in_modules[] = {
static ModuleDescPtr
doLoadModule(const char *module, const char *path, const char **subdirlist,
- const char **patternlist, pointer options,
+ const char **patternlist, void *options,
const XF86ModReqInfo * modreq, int *errmaj, int *errmin)
{
XF86ModuleData *initdata = NULL;
@@ -1071,7 +1071,7 @@ doLoadModule(const char *module, const char *path, const char **subdirlist,
*/
ModuleDescPtr
LoadModule(const char *module, const char *path, const char **subdirlist,
- const char **patternlist, pointer options,
+ const char **patternlist, void *options,
const XF86ModReqInfo * modreq, int *errmaj, int *errmin)
{
return doLoadModule(module, path, subdirlist, patternlist, options,
@@ -1079,7 +1079,7 @@ LoadModule(const char *module, const char *path, const char **subdirlist,
}
void
-UnloadModule(pointer mod)
+UnloadModule(void *mod)
{
UnloadModuleOrDriver((ModuleDescPtr) mod);
}
@@ -1115,7 +1115,7 @@ UnloadModuleOrDriver(ModuleDescPtr mod)
}
void
-UnloadSubModule(pointer _mod)
+UnloadSubModule(void *_mod)
{
ModuleDescPtr mod = (ModuleDescPtr) _mod;
diff --git a/xorg-server/hw/xfree86/modes/xf86Crtc.c b/xorg-server/hw/xfree86/modes/xf86Crtc.c
index a441fd16a..b2eb72e8e 100644
--- a/xorg-server/hw/xfree86/modes/xf86Crtc.c
+++ b/xorg-server/hw/xfree86/modes/xf86Crtc.c
@@ -379,7 +379,7 @@ xf86CrtcSetModeTransform(xf86CrtcPtr crtc, DisplayModePtr mode,
crtc->transformPresent = saved_transform_present;
}
- free(adjusted_mode->name);
+ free((void *) adjusted_mode->name);
free(adjusted_mode);
if (didLock)
@@ -564,8 +564,8 @@ static const char *direction[4] = {
static Rotation
xf86OutputInitialRotation(xf86OutputPtr output)
{
- char *rotate_name = xf86GetOptValString(output->options,
- OPTION_ROTATE);
+ const char *rotate_name = xf86GetOptValString(output->options,
+ OPTION_ROTATE);
int i;
if (!rotate_name) {
@@ -926,7 +926,6 @@ xf86PickCrtcs(ScrnInfoPtr scrn,
xf86OutputPtr output;
xf86CrtcPtr crtc;
xf86CrtcPtr *crtcs;
- xf86CrtcPtr best_crtc;
int best_score;
int score;
int my_score;
@@ -939,7 +938,6 @@ xf86PickCrtcs(ScrnInfoPtr scrn,
* Compute score with this output disabled
*/
best_crtcs[n] = NULL;
- best_crtc = NULL;
best_score = xf86PickCrtcs(scrn, best_crtcs, modes, n + 1, width, height);
if (modes[n] == NULL)
return best_score;
@@ -993,7 +991,6 @@ xf86PickCrtcs(ScrnInfoPtr scrn,
score =
my_score + xf86PickCrtcs(scrn, crtcs, modes, n + 1, width, height);
if (score > best_score) {
- best_crtc = crtc;
best_score = score;
memcpy(best_crtcs, crtcs, config->num_output * sizeof(xf86CrtcPtr));
}
@@ -1087,8 +1084,8 @@ xf86UserConfiguredOutputs(ScrnInfoPtr scrn, DisplayModePtr * modes)
for (o = 0; o < config->num_output; o++) {
xf86OutputPtr output = config->output[o];
- char *position;
- char *relative_name;
+ const char *position;
+ const char *relative_name;
OutputOpts relation;
int r;
@@ -1145,8 +1142,8 @@ xf86InitialOutputPositions(ScrnInfoPtr scrn, DisplayModePtr * modes)
};
xf86OutputPtr output = config->output[o];
xf86OutputPtr relative;
- char *relative_name;
- char *position;
+ const char *relative_name;
+ const char *position;
OutputOpts relation;
int r;
@@ -1306,7 +1303,7 @@ xf86InitialPanning(ScrnInfoPtr scrn)
for (o = 0; o < config->num_output; o++) {
xf86OutputPtr output = config->output[o];
- char *panning = xf86GetOptValString(output->options, OPTION_PANNING);
+ const char *panning = xf86GetOptValString(output->options, OPTION_PANNING);
int width, height, left, top;
int track_width, track_height, track_left, track_top;
int brdr[4];
@@ -1389,7 +1386,7 @@ xf86SortModes(DisplayModePtr input)
for (o = output; o && (n = o->next); o = n) {
if (!strcmp(o->name, n->name) && xf86ModesEqual(o, n)) {
o->next = n->next;
- free(n->name);
+ free((void *) n->name);
free(n);
n = o;
}
@@ -1403,10 +1400,10 @@ xf86SortModes(DisplayModePtr input)
return output;
}
-static char *
+static const char *
preferredMode(ScrnInfoPtr pScrn, xf86OutputPtr output)
{
- char *preferred_mode = NULL;
+ const char *preferred_mode = NULL;
/* Check for a configured preference for a particular mode */
preferred_mode = xf86GetOptValString(output->options,
@@ -1610,7 +1607,7 @@ xf86ProbeOutputModes(ScrnInfoPtr scrn, int maxX, int maxY)
xf86OutputPtr output = config->output[o];
DisplayModePtr mode;
DisplayModePtr config_modes = NULL, output_modes, default_modes = NULL;
- char *preferred_mode;
+ const char *preferred_mode;
xf86MonPtr edid_monitor;
XF86ConfMonitorPtr conf_monitor;
MonRec mon_rec;
@@ -1833,10 +1830,6 @@ xf86ProbeOutputModes(ScrnInfoPtr scrn, int maxX, int maxY)
* Copy one of the output mode lists to the ScrnInfo record
*/
-/* XXX where does this function belong? Here? */
-void
- xf86RandR12GetOriginalVirtualSize(ScrnInfoPtr scrn, int *x, int *y);
-
static DisplayModePtr
biggestMode(DisplayModePtr a, DisplayModePtr b)
{
diff --git a/xorg-server/hw/xfree86/modes/xf86Modes.c b/xorg-server/hw/xfree86/modes/xf86Modes.c
index c4a3eb0a3..43b223307 100644
--- a/xorg-server/hw/xfree86/modes/xf86Modes.c
+++ b/xorg-server/hw/xfree86/modes/xf86Modes.c
@@ -129,11 +129,13 @@ void
xf86SetModeDefaultName(DisplayModePtr mode)
{
Bool interlaced = ! !(mode->Flags & V_INTERLACE);
+ char *tmp;
- free(mode->name);
+ free((void *) mode->name);
- XNFasprintf(&mode->name, "%dx%d%s", mode->HDisplay, mode->VDisplay,
+ XNFasprintf(&tmp, "%dx%d%s", mode->HDisplay, mode->VDisplay,
interlaced ? "i" : "");
+ mode->name = tmp;
}
/*
diff --git a/xorg-server/hw/xfree86/modes/xf86RandR12.c b/xorg-server/hw/xfree86/modes/xf86RandR12.c
index 76614de78..f7a7d44d9 100644
--- a/xorg-server/hw/xfree86/modes/xf86RandR12.c
+++ b/xorg-server/hw/xfree86/modes/xf86RandR12.c
@@ -454,7 +454,6 @@ xf86RandR12GetInfo(ScreenPtr pScreen, Rotation * rotations)
ScrnInfoPtr scrp = xf86ScreenToScrn(pScreen);
XF86RandRInfoPtr randrp = XF86RANDRINFO(pScreen);
DisplayModePtr mode;
- int refresh0 = 60;
int maxX = 0, maxY = 0;
*rotations = randrp->supported_rotations;
@@ -479,8 +478,6 @@ xf86RandR12GetInfo(ScreenPtr pScreen, Rotation * rotations)
if (maxY < mode->VDisplay)
maxY = mode->VDisplay;
}
- if (mode == scrp->modes)
- refresh0 = refresh;
pSize = RRRegisterSize(pScreen,
mode->HDisplay, mode->VDisplay,
randrp->mmWidth, randrp->mmHeight);
@@ -684,7 +681,6 @@ xf86RandR12ScreenSetSize(ScreenPtr pScreen,
WindowPtr pRoot = pScreen->root;
PixmapPtr pScrnPix;
Bool ret = FALSE;
- Bool panning = FALSE;
int c;
if (xf86RandR12Key) {
@@ -716,7 +712,6 @@ xf86RandR12ScreenSetSize(ScreenPtr pScreen,
crtc->panningTrackingArea.y2 += height - pScreen->height;
xf86RandR13VerifyPanningArea(crtc, width, height);
xf86RandR13Pan(crtc, randrp->pointerX, randrp->pointerY);
- panning = TRUE;
}
}
@@ -946,8 +941,6 @@ xf86RandR12SetRotations(ScreenPtr pScreen, Rotation rotations)
void
xf86RandR12SetTransformSupport(ScreenPtr pScreen, Bool transforms)
{
- XF86RandRInfoPtr randrp;
-
#if RANDR_13_INTERFACE
ScrnInfoPtr pScrn = xf86ScreenToScrn(pScreen);
int c;
@@ -957,7 +950,6 @@ xf86RandR12SetTransformSupport(ScreenPtr pScreen, Bool transforms)
if (xf86RandR12Key == NULL)
return;
- randrp = XF86RANDRINFO(pScreen);
#if RANDR_13_INTERFACE
for (c = 0; c < config->num_crtc; c++) {
xf86CrtcPtr crtc = config->crtc[c];
@@ -1455,7 +1447,6 @@ xf86RandR12SetInfo12(ScreenPtr pScreen)
RRCrtcPtr *crtcs;
int ncrtc;
int o, c, l;
- RRCrtcPtr randr_crtc;
int nclone;
clones = malloc(config->num_output * sizeof(RROutputPtr));
@@ -1468,11 +1459,6 @@ xf86RandR12SetInfo12(ScreenPtr pScreen)
if (output->possible_crtcs & (1 << c))
crtcs[ncrtc++] = config->crtc[c]->randr_crtc;
- if (output->crtc)
- randr_crtc = output->crtc->randr_crtc;
- else
- randr_crtc = NULL;
-
if (!RROutputSetCrtcs(output->randr_output, crtcs, ncrtc)) {
free(crtcs);
free(clones);
diff --git a/xorg-server/hw/xfree86/modes/xf86Rotate.c b/xorg-server/hw/xfree86/modes/xf86Rotate.c
index 495af9ba7..0ddd8408e 100644
--- a/xorg-server/hw/xfree86/modes/xf86Rotate.c
+++ b/xorg-server/hw/xfree86/modes/xf86Rotate.c
@@ -229,13 +229,12 @@ xf86RotateRedisplay(ScreenPtr pScreen)
static void
xf86RotateBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadmask)
+ void *pTimeout, void *pReadmask)
{
ScrnInfoPtr pScrn = xf86ScreenToScrn(pScreen);
xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
- Bool rotation_active;
- rotation_active = xf86RotateRedisplay(pScreen);
+ xf86RotateRedisplay(pScreen);
pScreen->BlockHandler = xf86_config->BlockHandler;
(*pScreen->BlockHandler) (pScreen, pTimeout, pReadmask);
/* cannot avoid re-wrapping until all wrapping is audited */
@@ -247,7 +246,6 @@ void
xf86RotateDestroy(xf86CrtcPtr crtc)
{
ScrnInfoPtr pScrn = crtc->scrn;
- ScreenPtr pScreen = xf86ScrnToScreen(pScrn);
xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
int c;
@@ -267,9 +265,6 @@ xf86RotateDestroy(xf86CrtcPtr crtc)
* Clean up damage structures when no crtcs are rotated
*/
if (xf86_config->rotation_damage) {
- DrawablePtr screenDrawable = NULL;
- if (pScreen && pScreen->root)
- screenDrawable = &pScreen->root->drawable;
/* Free damage structure */
if (xf86_config->rotation_damage_registered) {
xf86_config->rotation_damage_registered = FALSE;
diff --git a/xorg-server/hw/xfree86/modes/xf86cvt.c b/xorg-server/hw/xfree86/modes/xf86cvt.c
index de0784493..8b7bb8b03 100644
--- a/xorg-server/hw/xfree86/modes/xf86cvt.c
+++ b/xorg-server/hw/xfree86/modes/xf86cvt.c
@@ -89,6 +89,7 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
int HDisplayRnd, HMargin;
int VDisplayRnd, VMargin, VSync;
float Interlace; /* Please rename this */
+ char *tmp;
/* CVT default is 60.0Hz */
if (!VRefresh)
@@ -177,6 +178,7 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
/* 10. Find number of lines in back porch */
VBackPorch = VSyncAndBackPorch - VSync;
+ (void) VBackPorch;
/* 11. Find total number of lines in vertical field */
Mode->VTotal = VDisplayRnd + 2 * VMargin + VSyncAndBackPorch + Interlace
@@ -282,7 +284,8 @@ xf86CVTMode(int HDisplay, int VDisplay, float VRefresh, Bool Reduced,
if (Interlaced)
Mode->VTotal *= 2;
- XNFasprintf(&Mode->name, "%dx%d", HDisplay, VDisplay);
+ XNFasprintf(&tmp, "%dx%d", HDisplay, VDisplay);
+ Mode->name = tmp;
if (Reduced)
Mode->Flags |= V_PHSYNC | V_NVSYNC;
diff --git a/xorg-server/hw/xfree86/modes/xf86gtf.c b/xorg-server/hw/xfree86/modes/xf86gtf.c
index 23707b481..0a8078415 100644
--- a/xorg-server/hw/xfree86/modes/xf86gtf.c
+++ b/xorg-server/hw/xfree86/modes/xf86gtf.c
@@ -215,6 +215,7 @@ xf86GTFMode(int h_pixels, int v_lines, float freq, int interlaced, int margins)
*/
v_back_porch = vsync_plus_bp - V_SYNC_RQD;
+ (void) v_back_porch;
/* 10. Find the total number of lines in Vertical field period:
*
@@ -253,6 +254,7 @@ xf86GTFMode(int h_pixels, int v_lines, float freq, int interlaced, int margins)
*/
v_frame_rate = interlaced ? v_field_rate / 2.0 : v_field_rate;
+ (void) v_frame_rate;
/* 15. Find number of pixels in left margin:
*
diff --git a/xorg-server/hw/xfree86/os-support/bsd/alpha_video.c b/xorg-server/hw/xfree86/os-support/bsd/alpha_video.c
index 91f9fc826..95bd0591a 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/alpha_video.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/alpha_video.c
@@ -189,10 +189,10 @@ static int devMemFd = -1;
#define DEV_APERTURE "/dev/xf86"
#endif
-static pointer mapVidMem(int, unsigned long, unsigned long, int);
-static void unmapVidMem(int, pointer, unsigned long);
-static pointer mapVidMemSparse(int, unsigned long, unsigned long, int);
-static void unmapVidMemSparse(int, pointer, unsigned long);
+static void *mapVidMem(int, unsigned long, unsigned long, int);
+static void unmapVidMem(int, void *, unsigned long);
+static void *mapVidMemSparse(int, unsigned long, unsigned long, int);
+static void unmapVidMemSparse(int, void *, unsigned long);
/*
* Check if /dev/mem can be mmap'd. If it can't print a warning when
@@ -203,7 +203,7 @@ checkDevMem(Bool warn)
{
static Bool devMemChecked = FALSE;
int fd;
- pointer base;
+ void *base;
if (devMemChecked)
return;
@@ -295,10 +295,10 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
pVidMem->initialised = TRUE;
}
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
- pointer base;
+ void *base;
checkDevMem(FALSE);
Base = Base & ((1L << 32) - 1);
@@ -336,7 +336,7 @@ mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
}
static void
-unmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
munmap((caddr_t) Base, Size);
}
@@ -424,40 +424,40 @@ xf86DisableIO()
#define vuip volatile unsigned int *
-static pointer memSBase = 0;
-static pointer memBase = 0;
+static void *memSBase = 0;
+static void *memBase = 0;
-extern int readDense8(pointer Base, register unsigned long Offset);
-extern int readDense16(pointer Base, register unsigned long Offset);
-extern int readDense32(pointer Base, register unsigned long Offset);
+extern int readDense8(void *Base, register unsigned long Offset);
+extern int readDense16(void *Base, register unsigned long Offset);
+extern int readDense32(void *Base, register unsigned long Offset);
extern void
- writeDenseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB8(int Value, void *Base, register unsigned long Offset);
extern void
- writeDenseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB16(int Value, void *Base, register unsigned long Offset);
extern void
- writeDenseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB32(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense8(int Value, pointer Base, register unsigned long Offset);
+ writeDense8(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense16(int Value, pointer Base, register unsigned long Offset);
+ writeDense16(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense32(int Value, pointer Base, register unsigned long Offset);
+ writeDense32(int Value, void *Base, register unsigned long Offset);
-static int readSparse8(pointer Base, register unsigned long Offset);
-static int readSparse16(pointer Base, register unsigned long Offset);
-static int readSparse32(pointer Base, register unsigned long Offset);
+static int readSparse8(void *Base, register unsigned long Offset);
+static int readSparse16(void *Base, register unsigned long Offset);
+static int readSparse32(void *Base, register unsigned long Offset);
static void
- writeSparseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB8(int Value, void *Base, register unsigned long Offset);
static void
- writeSparseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB16(int Value, void *Base, register unsigned long Offset);
static void
- writeSparseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB32(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse8(int Value, pointer Base, register unsigned long Offset);
+ writeSparse8(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse16(int Value, pointer Base, register unsigned long Offset);
+ writeSparse16(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse32(int Value, pointer Base, register unsigned long Offset);
+ writeSparse32(int Value, void *Base, register unsigned long Offset);
#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
extern int sysarch(int, void *);
@@ -481,7 +481,7 @@ sethae(u_int64_t hae)
}
#endif
-static pointer
+static void *
mapVidMemSparse(int ScreenNum, unsigned long Base, unsigned long Size,
int flags)
{
@@ -514,16 +514,16 @@ mapVidMemSparse(int ScreenNum, unsigned long Base, unsigned long Size,
strerror(errno));
}
}
- return (pointer) ((unsigned long) memBase + Base);
+ return (void *) ((unsigned long) memBase + Base);
}
static void
-unmapVidMemSparse(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMemSparse(int ScreenNum, void *Base, unsigned long Size)
{
}
static int
-readSparse8(pointer Base, register unsigned long Offset)
+readSparse8(void *Base, register unsigned long Offset)
{
register unsigned long result, shift;
register unsigned long msb;
@@ -544,7 +544,7 @@ readSparse8(pointer Base, register unsigned long Offset)
}
static int
-readSparse16(pointer Base, register unsigned long Offset)
+readSparse16(void *Base, register unsigned long Offset)
{
register unsigned long result, shift;
register unsigned long msb;
@@ -566,14 +566,14 @@ readSparse16(pointer Base, register unsigned long Offset)
}
static int
-readSparse32(pointer Base, register unsigned long Offset)
+readSparse32(void *Base, register unsigned long Offset)
{
mem_barrier();
return *(vuip) ((unsigned long) Base + (Offset));
}
static void
-writeSparse8(int Value, pointer Base, register unsigned long Offset)
+writeSparse8(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int b = Value & 0xffU;
@@ -591,7 +591,7 @@ writeSparse8(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparse16(int Value, pointer Base, register unsigned long Offset)
+writeSparse16(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int w = Value & 0xffffU;
@@ -611,7 +611,7 @@ writeSparse16(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparse32(int Value, pointer Base, register unsigned long Offset)
+writeSparse32(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
*(vuip) ((unsigned long) Base + (Offset)) = Value;
@@ -619,7 +619,7 @@ writeSparse32(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB8(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB8(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int b = Value & 0xffU;
@@ -636,7 +636,7 @@ writeSparseNB8(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB16(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB16(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int w = Value & 0xffffU;
@@ -654,27 +654,27 @@ writeSparseNB16(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB32(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB32(int Value, void *Base, register unsigned long Offset)
{
*(vuip) ((unsigned long) Base + (Offset)) = Value;
return;
}
-void (*xf86WriteMmio8) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio8) (int Value, void *Base, unsigned long Offset)
= writeDense8;
-void (*xf86WriteMmio16) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio16) (int Value, void *Base, unsigned long Offset)
= writeDense16;
-void (*xf86WriteMmio32) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio32) (int Value, void *Base, unsigned long Offset)
= writeDense32;
-void (*xf86WriteMmioNB8) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB8) (int Value, void *Base, unsigned long Offset)
= writeDenseNB8;
-void (*xf86WriteMmioNB16) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB16) (int Value, void *Base, unsigned long Offset)
= writeDenseNB16;
-void (*xf86WriteMmioNB32) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB32) (int Value, void *Base, unsigned long Offset)
= writeDenseNB32;
-int (*xf86ReadMmio8) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio8) (void *Base, unsigned long Offset)
= readDense8;
-int (*xf86ReadMmio16) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio16) (void *Base, unsigned long Offset)
= readDense16;
-int (*xf86ReadMmio32) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio32) (void *Base, unsigned long Offset)
= readDense32;
diff --git a/xorg-server/hw/xfree86/os-support/bsd/arm_video.c b/xorg-server/hw/xfree86/os-support/bsd/arm_video.c
index 71064af03..6a977c2db 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/arm_video.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/arm_video.c
@@ -71,12 +71,12 @@
struct memAccess {
int ioctl;
struct map_info memInfo;
- pointer regionVirtBase;
+ void *regionVirtBase;
Bool Checked;
Bool OK;
};
-static pointer xf86MapInfoMap();
+static void *xf86MapInfoMap();
static void xf86MapInfoUnmap();
static struct memAccess *checkMapInfo();
extern int vgaPhysLinearBase;
@@ -111,8 +111,8 @@ struct memAccess ioMemInfo = { CONSOLE_GET_IO_INFO, NULL, NULL,
static Bool useDevMem = FALSE;
static int devMemFd = -1;
-static pointer mapVidMem(int, unsigned long, unsigned long, int);
-static void unmapVidMem(int, pointer, unsigned long);
+static void *mapVidMem(int, unsigned long, unsigned long, int);
+static void unmapVidMem(int, void *, unsigned long);
/*
* Check if /dev/mem can be mmap'd. If it can't print a warning when
@@ -123,7 +123,7 @@ checkDevMem(Bool warn)
{
static Bool devMemChecked = FALSE;
int fd;
- pointer base;
+ void *base;
if (devMemChecked)
return;
@@ -170,10 +170,10 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
pVidMem->initialised = TRUE;
}
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
- pointer base;
+ void *base;
checkDevMem(FALSE);
@@ -210,7 +210,7 @@ mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
}
static void
-unmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
munmap((caddr_t) Base, Size);
}
@@ -310,8 +310,8 @@ checkMapInfo(Bool warn, int Region)
}
}
-static pointer
-xf86MapInfoMap(struct memAccess *memInfoP, pointer Base, unsigned long Size)
+static void *
+xf86MapInfoMap(struct memAccess *memInfoP, void *Base, unsigned long Size)
{
struct map_info *mapInfoP = &(memInfoP->memInfo);
@@ -335,7 +335,7 @@ xf86MapInfoMap(struct memAccess *memInfoP, pointer Base, unsigned long Size)
MAP_SHARED,
xf86Info.consoleFd,
(unsigned long) mapInfoP->u.map_info_mmap.map_offset))
- == (pointer) -1) {
+ == (void *) -1) {
FatalError
("xf86MapInfoMap: Failed to map memory at 0x%x\n\t%s\n",
mapInfoP->u.map_info_mmap.map_offset, strerror(errno));
@@ -351,7 +351,7 @@ xf86MapInfoMap(struct memAccess *memInfoP, pointer Base, unsigned long Size)
break;
}
- return (pointer) ((int) memInfoP->regionVirtBase + (int) Base);
+ return (void *) ((int) memInfoP->regionVirtBase + (int) Base);
}
static void
@@ -374,7 +374,7 @@ xf86MapInfoUnmap(struct memAccess *memInfoP, unsigned long Size)
}
}
-static pointer
+static void *
armMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
struct memAccess *memInfoP;
@@ -404,7 +404,7 @@ armMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
}
static void
-armUnmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+armUnmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
struct memAccess *memInfoP;
@@ -450,17 +450,17 @@ Bool
xf86EnableIO()
{
int fd;
- pointer base;
+ void *base;
if (ExtendedEnabled)
return TRUE;
if ((fd = open("/dev/ttyC0", O_RDWR)) >= 0) {
/* Try to map a page at the pccons I/O space */
- base = (pointer) mmap((caddr_t) 0, 65536, PROT_READ | PROT_WRITE,
- MAP_FLAGS, fd, (off_t) 0x0000);
+ base = (void *) mmap((caddr_t) 0, 65536, PROT_READ | PROT_WRITE,
+ MAP_FLAGS, fd, (off_t) 0x0000);
- if (base != (pointer) -1) {
+ if (base != (void *) -1) {
IOPortBase = base;
}
else {
@@ -509,7 +509,7 @@ int ScreenNum;
{
int i;
int fd;
- pointer base;
+ void *base;
#ifdef __arm32__
struct memAccess *memInfoP;
@@ -524,10 +524,10 @@ int ScreenNum;
#ifdef USE_ARC_MMAP
if ((fd = open("/dev/ttyC0", O_RDWR)) >= 0) {
/* Try to map a page at the pccons I/O space */
- base = (pointer) mmap((caddr_t) 0, 65536, PROT_READ | PROT_WRITE,
- MAP_FLAGS, fd, (off_t) 0x0000);
+ base = (void *) mmap((caddr_t) 0, 65536, PROT_READ | PROT_WRITE,
+ MAP_FLAGS, fd, (off_t) 0x0000);
- if (base != (pointer) -1) {
+ if (base != (void *) -1) {
IOPortBase = base;
}
else {
@@ -563,10 +563,10 @@ int ScreenNum;
checkDevMem(TRUE);
if (devMemFd >= 0 && useDevMem) {
- base = (pointer) mmap((caddr_t) 0, 0x400, PROT_READ | PROT_WRITE,
+ base = (void *) mmap((caddr_t) 0, 0x400, PROT_READ | PROT_WRITE,
MAP_FLAGS, devMemFd, (off_t) DEV_MEM_IOBASE);
- if (base != (pointer) -1)
+ if (base != (void *) -1)
IOPortBase = (unsigned int) base;
}
diff --git a/xorg-server/hw/xfree86/os-support/bsd/bsd_apm.c b/xorg-server/hw/xfree86/os-support/bsd/bsd_apm.c
index b1938cf0d..1b929625e 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/bsd_apm.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/bsd_apm.c
@@ -14,7 +14,7 @@
#define APM_DEVICE "/dev/apm"
-static pointer APMihPtr = NULL;
+static void *APMihPtr = NULL;
static void bsdCloseAPM(void);
static struct {
diff --git a/xorg-server/hw/xfree86/os-support/bsd/bsd_ev56.c b/xorg-server/hw/xfree86/os-support/bsd/bsd_ev56.c
index 645377ed6..320bb23b6 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/bsd_ev56.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/bsd_ev56.c
@@ -22,77 +22,77 @@
*/
__asm(".arch ev56");
-int readDense8(pointer Base, register unsigned long Offset);
-int readDense16(pointer Base, register unsigned long Offset);
-int readDense32(pointer Base, register unsigned long Offset);
+int readDense8(void *Base, register unsigned long Offset);
+int readDense16(void *Base, register unsigned long Offset);
+int readDense32(void *Base, register unsigned long Offset);
void
- writeDenseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB8(int Value, void *Base, register unsigned long Offset);
void
- writeDenseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB16(int Value, void *Base, register unsigned long Offset);
void
- writeDenseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB32(int Value, void *Base, register unsigned long Offset);
void
- writeDense8(int Value, pointer Base, register unsigned long Offset);
+ writeDense8(int Value, void *Base, register unsigned long Offset);
void
- writeDense16(int Value, pointer Base, register unsigned long Offset);
+ writeDense16(int Value, void *Base, register unsigned long Offset);
void
- writeDense32(int Value, pointer Base, register unsigned long Offset);
+ writeDense32(int Value, void *Base, register unsigned long Offset);
int
-readDense8(pointer Base, register unsigned long Offset)
+readDense8(void *Base, register unsigned long Offset)
{
mem_barrier();
- return (alpha_ldbu((pointer) ((unsigned long) Base + (Offset))));
+ return (alpha_ldbu((void *) ((unsigned long) Base + (Offset))));
}
int
-readDense16(pointer Base, register unsigned long Offset)
+readDense16(void *Base, register unsigned long Offset)
{
mem_barrier();
- return (alpha_ldwu((pointer) ((unsigned long) Base + (Offset))));
+ return (alpha_ldwu((void *) ((unsigned long) Base + (Offset))));
}
int
-readDense32(pointer Base, register unsigned long Offset)
+readDense32(void *Base, register unsigned long Offset)
{
mem_barrier();
return *(volatile CARD32 *) ((unsigned long) Base + (Offset));
}
void
-writeDenseNB8(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB8(int Value, void *Base, register unsigned long Offset)
{
- alpha_stb((pointer) ((unsigned long) Base + (Offset)), Value);
+ alpha_stb((void *) ((unsigned long) Base + (Offset)), Value);
}
void
-writeDenseNB16(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB16(int Value, void *Base, register unsigned long Offset)
{
- alpha_stw((pointer) ((unsigned long) Base + (Offset)), Value);
+ alpha_stw((void *) ((unsigned long) Base + (Offset)), Value);
}
void
-writeDenseNB32(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB32(int Value, void *Base, register unsigned long Offset)
{
*(volatile CARD32 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDense8(int Value, pointer Base, register unsigned long Offset)
+writeDense8(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
- alpha_stb((pointer) ((unsigned long) Base + (Offset)), Value);
+ alpha_stb((void *) ((unsigned long) Base + (Offset)), Value);
}
void
-writeDense16(int Value, pointer Base, register unsigned long Offset)
+writeDense16(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
- alpha_stw((pointer) ((unsigned long) Base + (Offset)), Value);
+ alpha_stw((void *) ((unsigned long) Base + (Offset)), Value);
}
void
-writeDense32(int Value, pointer Base, register unsigned long Offset)
+writeDense32(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
*(volatile CARD32 *) ((unsigned long) Base + (Offset)) = Value;
diff --git a/xorg-server/hw/xfree86/os-support/bsd/bsd_kqueue_apm.c b/xorg-server/hw/xfree86/os-support/bsd/bsd_kqueue_apm.c
index 22943855b..32ea4892e 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/bsd_kqueue_apm.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/bsd_kqueue_apm.c
@@ -45,7 +45,7 @@
#define _PATH_APM_DEV "/dev/apm"
#define _PATH_APM_CTLDEV "/dev/apmctl"
-static pointer APMihPtr = NULL;
+static void *APMihPtr = NULL;
static int devFd = -1;
static int ctlFd = -1;
static void bsdCloseAPM(void);
diff --git a/xorg-server/hw/xfree86/os-support/bsd/i386_video.c b/xorg-server/hw/xfree86/os-support/bsd/i386_video.c
index 569a4ec51..745319054 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/i386_video.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/i386_video.c
@@ -85,18 +85,18 @@ static int devMemFd = -1;
#define DEV_APERTURE "/dev/xf86"
#endif
-static pointer mapVidMem(int, unsigned long, unsigned long, int);
-static void unmapVidMem(int, pointer, unsigned long);
+static void *mapVidMem(int, unsigned long, unsigned long, int);
+static void unmapVidMem(int, void *, unsigned long);
#ifdef HAS_MTRR_SUPPORT
-static pointer setWC(int, unsigned long, unsigned long, Bool, MessageType);
-static void undoWC(int, pointer);
+static void *setWC(int, unsigned long, unsigned long, Bool, MessageType);
+static void undoWC(int, void *);
static Bool cleanMTRR(void);
#endif
#if defined(HAS_MTRR_BUILTIN) && defined(__NetBSD__)
-static pointer NetBSDsetWC(int, unsigned long, unsigned long, Bool,
+static void *NetBSDsetWC(int, unsigned long, unsigned long, Bool,
MessageType);
-static void NetBSDundoWC(int, pointer);
+static void NetBSDundoWC(int, void *);
#endif
/*
@@ -108,7 +108,7 @@ checkDevMem(Bool warn)
{
static Bool devMemChecked = FALSE;
int fd;
- pointer base;
+ void *base;
if (devMemChecked)
return;
@@ -210,10 +210,10 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
pVidMem->initialised = TRUE;
}
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
- pointer base;
+ void *base;
checkDevMem(FALSE);
@@ -250,7 +250,7 @@ mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
}
static void
-unmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
munmap((caddr_t) Base, Size);
}
@@ -690,7 +690,7 @@ fullCoverage(unsigned long base, unsigned long size, RangePtr overlap)
return FALSE;
}
-static pointer
+static void *
addWC(int screenNum, unsigned long base, unsigned long size, MessageType from)
{
RangePtr uc = NULL, wc = NULL, retlist = NULL;
@@ -731,7 +731,7 @@ addWC(int screenNum, unsigned long base, unsigned long size, MessageType from)
}
}
-static pointer
+static void *
delWC(int screenNum, unsigned long base, unsigned long size, MessageType from)
{
RangePtr uc = NULL, wc = NULL, retlist = NULL;
@@ -776,7 +776,7 @@ delWC(int screenNum, unsigned long base, unsigned long size, MessageType from)
}
}
-static pointer
+static void *
setWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
MessageType from)
{
@@ -787,7 +787,7 @@ setWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
}
static void
-undoWC(int screenNum, pointer list)
+undoWC(int screenNum, void *list)
{
RangePtr rp;
struct mem_range_op mro;
@@ -835,7 +835,7 @@ undoWC(int screenNum, pointer list)
#endif /* HAS_MTRR_SUPPORT */
#if defined(HAS_MTRR_BUILTIN) && defined(__NetBSD__)
-static pointer
+static void *
NetBSDsetWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
MessageType from)
{
@@ -871,7 +871,7 @@ NetBSDsetWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
}
static void
-NetBSDundoWC(int screenNum, pointer list)
+NetBSDundoWC(int screenNum, void *list)
{
struct mtrr *mtrrp = (struct mtrr *) list;
int n;
diff --git a/xorg-server/hw/xfree86/os-support/bsd/ppc_video.c b/xorg-server/hw/xfree86/os-support/bsd/ppc_video.c
index 417adbf4b..947a68678 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/ppc_video.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/ppc_video.c
@@ -44,8 +44,8 @@
#define DEV_MEM "/dev/xf86"
#endif
-static pointer ppcMapVidMem(int, unsigned long, unsigned long, int flags);
-static void ppcUnmapVidMem(int, pointer, unsigned long);
+static void *ppcMapVidMem(int, unsigned long, unsigned long, int flags);
+static void ppcUnmapVidMem(int, void *, unsigned long);
Bool xf86EnableIO(void);
void xf86DisableIO(void);
@@ -62,11 +62,11 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
volatile unsigned char *ioBase = MAP_FAILED;
-static pointer
+static void *
ppcMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
int fd = xf86Info.consoleFd;
- pointer base;
+ void *base;
#ifdef DEBUG
xf86MsgVerb(X_INFO, 3, "mapVidMem %lx, %lx, fd = %d", Base, Size, fd);
@@ -83,7 +83,7 @@ ppcMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
}
static void
-ppcUnmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+ppcUnmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
munmap(Base, Size);
}
diff --git a/xorg-server/hw/xfree86/os-support/bsd/sparc64_video.c b/xorg-server/hw/xfree86/os-support/bsd/sparc64_video.c
index 21c166105..02951d602 100644
--- a/xorg-server/hw/xfree86/os-support/bsd/sparc64_video.c
+++ b/xorg-server/hw/xfree86/os-support/bsd/sparc64_video.c
@@ -38,8 +38,8 @@
/* Video Memory Mapping section */
/***************************************************************************/
-static pointer sparc64MapVidMem(int, unsigned long, unsigned long, int);
-static void sparc64UnmapVidMem(int, pointer, unsigned long);
+static void *sparc64MapVidMem(int, unsigned long, unsigned long, int);
+static void sparc64UnmapVidMem(int, void *, unsigned long);
void
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
@@ -50,12 +50,12 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
pVidMem->initialised = TRUE;
}
-static pointer
+static void *
sparc64MapVidMem(int ScreenNum, unsigned long Base, unsigned long Size,
int flags)
{
int fd = xf86Info.consoleFd;
- pointer base;
+ void *base;
#ifdef DEBUG
xf86MsgVerb(X_INFO, 3, "mapVidMem %lx, %lx, fd = %d", Base, Size, fd);
@@ -71,7 +71,7 @@ sparc64MapVidMem(int ScreenNum, unsigned long Base, unsigned long Size,
}
static void
-sparc64UnmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+sparc64UnmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
munmap(Base, Size);
}
diff --git a/xorg-server/hw/xfree86/os-support/bus/Sbus.c b/xorg-server/hw/xfree86/os-support/bus/Sbus.c
index 14e6d4bfd..16ce5b58a 100644
--- a/xorg-server/hw/xfree86/os-support/bus/Sbus.c
+++ b/xorg-server/hw/xfree86/os-support/bus/Sbus.c
@@ -641,10 +641,10 @@ sparcPromPathname2Node(const char *pathName)
return i;
}
-pointer
+void *
xf86MapSbusMem(sbusDevicePtr psdp, unsigned long offset, unsigned long size)
{
- pointer ret;
+ void *ret;
unsigned long pagemask = getpagesize() - 1;
unsigned long off = offset & ~pagemask;
unsigned long len = ((offset + size + pagemask) & ~pagemask) - off;
@@ -657,26 +657,26 @@ xf86MapSbusMem(sbusDevicePtr psdp, unsigned long offset, unsigned long size)
else if (psdp->fd < 0)
return NULL;
- ret = (pointer) mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_PRIVATE,
+ ret = (void *) mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_PRIVATE,
psdp->fd, off);
- if (ret == (pointer) -1) {
- ret = (pointer) mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_SHARED,
+ if (ret == (void *) -1) {
+ ret = (void *) mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_SHARED,
psdp->fd, off);
}
- if (ret == (pointer) -1)
+ if (ret == (void *) -1)
return NULL;
return (char *) ret + (offset - off);
}
void
-xf86UnmapSbusMem(sbusDevicePtr psdp, pointer addr, unsigned long size)
+xf86UnmapSbusMem(sbusDevicePtr psdp, void *addr, unsigned long size)
{
unsigned long mask = getpagesize() - 1;
unsigned long base = (unsigned long) addr & ~mask;
unsigned long len = (((unsigned long) addr + size + mask) & ~mask) - base;
- munmap((pointer) base, len);
+ munmap((void *) base, len);
}
/* Tell OS that we are driving the HW cursor ourselves. */
diff --git a/xorg-server/hw/xfree86/os-support/bus/nobus.c b/xorg-server/hw/xfree86/os-support/bus/nobus.c
index dc36ecd0a..4872c5be8 100644
--- a/xorg-server/hw/xfree86/os-support/bus/nobus.c
+++ b/xorg-server/hw/xfree86/os-support/bus/nobus.c
@@ -1,4 +1,7 @@
-static void
+void
+__noop_to_appease_ar__(void);
+
+void
__noop_to_appease_ar__(void)
{
return;
diff --git a/xorg-server/hw/xfree86/os-support/hurd/hurd_video.c b/xorg-server/hw/xfree86/os-support/hurd/hurd_video.c
index b3b94c9f2..dc1a8e670 100644
--- a/xorg-server/hw/xfree86/os-support/hurd/hurd_video.c
+++ b/xorg-server/hw/xfree86/os-support/hurd/hurd_video.c
@@ -42,7 +42,7 @@
/**************************************************************************
* Video Memory Mapping section
***************************************************************************/
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int Flags)
{
mach_port_t device, mem_dev;
@@ -89,11 +89,11 @@ mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int Flags)
("xf86MapVidMem() can't mach_port_deallocate.(mem_dev) (%s)\n",
strerror(errno));
}
- return (pointer) addr;
+ return (void *) addr;
}
static void
-unmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
kern_return_t err = vm_deallocate(mach_task_self(), (int) Base, Size);
diff --git a/xorg-server/hw/xfree86/os-support/linux/int10/linux.c b/xorg-server/hw/xfree86/os-support/linux/int10/linux.c
index 8bca37524..6181eb9c5 100644
--- a/xorg-server/hw/xfree86/os-support/linux/int10/linux.c
+++ b/xorg-server/hw/xfree86/os-support/linux/int10/linux.c
@@ -18,7 +18,7 @@
#define DEV_MEM "/dev/mem"
#endif
#define ALLOC_ENTRIES(x) ((V_RAM / x) - 1)
-#define SHMERRORPTR (pointer)(-1)
+#define SHMERRORPTR (void *)(-1)
#include <fcntl.h>
#include <errno.h>
@@ -153,9 +153,9 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
goto error0;
pInt->mem = &linuxMem;
pagesize = getpagesize();
- pInt->private = (pointer) xnfcalloc(1, sizeof(linuxInt10Priv));
+ pInt->private = (void *) xnfcalloc(1, sizeof(linuxInt10Priv));
((linuxInt10Priv *) pInt->private)->alloc =
- (pointer) xnfcalloc(1, ALLOC_ENTRIES(pagesize));
+ (void *) xnfcalloc(1, ALLOC_ENTRIES(pagesize));
if (!xf86IsEntityPrimary(entityIndex)) {
DebugF("Mapping high memory area\n");
@@ -233,10 +233,10 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
* 64K bytes at a time.
*/
if (!videoBiosMapped) {
- memset((pointer) V_BIOS, 0, SYS_BIOS - V_BIOS);
+ memset((void *) V_BIOS, 0, SYS_BIOS - V_BIOS);
DebugF("Reading BIOS\n");
for (cs = V_BIOS; cs < SYS_BIOS; cs += V_BIOS_SIZE)
- if (xf86ReadBIOS(cs, 0, (pointer) cs, V_BIOS_SIZE) < V_BIOS_SIZE)
+ if (xf86ReadBIOS(cs, 0, (void *) cs, V_BIOS_SIZE) < V_BIOS_SIZE)
xf86DrvMsg(screen, X_WARNING,
"Unable to retrieve all of segment 0x%06lX.\n",
(long) cs);
@@ -319,7 +319,7 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
Bool
MapCurrentInt10(xf86Int10InfoPtr pInt)
{
- pointer addr;
+ void *addr;
int fd = -1;
if (Int10Current) {
@@ -327,7 +327,7 @@ MapCurrentInt10(xf86Int10InfoPtr pInt)
if (((linuxInt10Priv *) Int10Current->private)->highMem >= 0)
shmdt((char *) HIGH_MEM);
else
- munmap((pointer) V_BIOS, (SYS_BIOS - V_BIOS));
+ munmap((void *) V_BIOS, (SYS_BIOS - V_BIOS));
}
addr =
shmat(((linuxInt10Priv *) pInt->private)->lowMem, (char *) 1, SHM_RND);
@@ -392,7 +392,7 @@ xf86FreeInt10(xf86Int10InfoPtr pInt)
if (((linuxInt10Priv *) pInt->private)->highMem >= 0)
shmdt((char *) HIGH_MEM);
else
- munmap((pointer) V_BIOS, (SYS_BIOS - V_BIOS));
+ munmap((void *) V_BIOS, (SYS_BIOS - V_BIOS));
Int10Current = NULL;
}
@@ -486,22 +486,22 @@ write_l(xf86Int10InfoPtr pInt, int addr, CARD32 val)
*((CARD32 *) (memType) addr) = val;
}
-pointer
+void *
xf86int10Addr(xf86Int10InfoPtr pInt, CARD32 addr)
{
if (addr < V_RAM)
return ((linuxInt10Priv *) pInt->private)->base + addr;
else if (addr < V_BIOS)
- return (pointer) (memType) addr;
+ return (void *) (memType) addr;
else if (addr < SYS_BIOS) {
if (((linuxInt10Priv *) pInt->private)->base_high)
- return (pointer) (((linuxInt10Priv *) pInt->private)->base_high
+ return (void *) (((linuxInt10Priv *) pInt->private)->base_high
- V_BIOS + addr);
else
- return (pointer) (memType) addr;
+ return (void *) (memType) addr;
}
else
- return (pointer) (memType) addr;
+ return (void *) (memType) addr;
}
#if defined DoSubModules
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_acpi.c b/xorg-server/hw/xfree86/os-support/linux/lnx_acpi.c
index dcaa19ee1..dbd5afe90 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_acpi.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_acpi.c
@@ -33,14 +33,14 @@
#define ACPI_VIDEO_HEAD_END (~0u)
static void lnxCloseACPI(void);
-static pointer ACPIihPtr = NULL;
+static void *ACPIihPtr = NULL;
PMClose lnxACPIOpen(void);
/* in milliseconds */
#define ACPI_REOPEN_DELAY 1000
static CARD32
-lnxACPIReopen(OsTimerPtr timer, CARD32 time, pointer arg)
+lnxACPIReopen(OsTimerPtr timer, CARD32 time, void *arg)
{
if (lnxACPIOpen()) {
TimerFree(timer);
@@ -74,13 +74,12 @@ lnxACPIGetEventFromOs(int fd, pmEvent * events, int num)
/* Check that we have a video event */
if (!strncmp(ev, "video", 5)) {
- char *video = NULL;
char *GFX = NULL;
char *notify = NULL;
char *data = NULL; /* doesn't appear to be used in the kernel */
- unsigned long int notify_l, data_l;
+ unsigned long int notify_l;
- video = strtok(ev, " ");
+ strtok(ev, " ");
if (!(GFX = strtok(NULL, " ")))
return 0;
@@ -97,8 +96,8 @@ lnxACPIGetEventFromOs(int fd, pmEvent * events, int num)
if (!(data = strtok(NULL, " ")))
return 0;
- data_l = strtoul(data, NULL, 16);
#if 0
+ data_l = strtoul(data, NULL, 16);
ErrorF("data: 0x%lx\n", data_l);
#endif
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_apm.c b/xorg-server/hw/xfree86/os-support/linux/lnx_apm.c
index 387934099..621691997 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_apm.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_apm.c
@@ -36,7 +36,7 @@ extern PMClose lnxACPIOpen(void);
static PMClose lnxAPMOpen(void);
static void lnxCloseAPM(void);
-static pointer APMihPtr = NULL;
+static void *APMihPtr = NULL;
static struct {
apm_event_t apmLinux;
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_ev56.c b/xorg-server/hw/xfree86/os-support/linux/lnx_ev56.c
index 49950705a..b6950009c 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_ev56.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_ev56.c
@@ -6,77 +6,77 @@
#include "xf86.h"
#include "compiler.h"
-int readDense8(pointer Base, register unsigned long Offset);
-int readDense16(pointer Base, register unsigned long Offset);
-int readDense32(pointer Base, register unsigned long Offset);
+int readDense8(void *Base, register unsigned long Offset);
+int readDense16(void *Base, register unsigned long Offset);
+int readDense32(void *Base, register unsigned long Offset);
void
- writeDenseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB8(int Value, void *Base, register unsigned long Offset);
void
- writeDenseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB16(int Value, void *Base, register unsigned long Offset);
void
- writeDenseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB32(int Value, void *Base, register unsigned long Offset);
void
- writeDense8(int Value, pointer Base, register unsigned long Offset);
+ writeDense8(int Value, void *Base, register unsigned long Offset);
void
- writeDense16(int Value, pointer Base, register unsigned long Offset);
+ writeDense16(int Value, void *Base, register unsigned long Offset);
void
- writeDense32(int Value, pointer Base, register unsigned long Offset);
+ writeDense32(int Value, void *Base, register unsigned long Offset);
int
-readDense8(pointer Base, register unsigned long Offset)
+readDense8(void *Base, register unsigned long Offset)
{
mem_barrier();
return *(volatile CARD8 *) ((unsigned long) Base + (Offset));
}
int
-readDense16(pointer Base, register unsigned long Offset)
+readDense16(void *Base, register unsigned long Offset)
{
mem_barrier();
return *(volatile CARD16 *) ((unsigned long) Base + (Offset));
}
int
-readDense32(pointer Base, register unsigned long Offset)
+readDense32(void *Base, register unsigned long Offset)
{
mem_barrier();
return *(volatile CARD32 *) ((unsigned long) Base + (Offset));
}
void
-writeDenseNB8(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB8(int Value, void *Base, register unsigned long Offset)
{
*(volatile CARD8 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDenseNB16(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB16(int Value, void *Base, register unsigned long Offset)
{
*(volatile CARD16 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDenseNB32(int Value, pointer Base, register unsigned long Offset)
+writeDenseNB32(int Value, void *Base, register unsigned long Offset)
{
*(volatile CARD32 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDense8(int Value, pointer Base, register unsigned long Offset)
+writeDense8(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
*(volatile CARD8 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDense16(int Value, pointer Base, register unsigned long Offset)
+writeDense16(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
*(volatile CARD16 *) ((unsigned long) Base + (Offset)) = Value;
}
void
-writeDense32(int Value, pointer Base, register unsigned long Offset)
+writeDense32(int Value, void *Base, register unsigned long Offset)
{
write_mem_barrier();
*(volatile CARD32 *) ((unsigned long) Base + (Offset)) = Value;
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_init.c b/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
index bcb039f3f..e2e8d0826 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
@@ -83,8 +83,8 @@ xf86OpenConsole(void)
struct vt_mode VT;
struct vt_stat vts;
MessageType from = X_PROBED;
- char *tty0[] = { "/dev/tty0", "/dev/vc/0", NULL };
- char *vcs[] = { "/dev/vc/%d", "/dev/tty%d", NULL };
+ const char *tty0[] = { "/dev/tty0", "/dev/vc/0", NULL };
+ const char *vcs[] = { "/dev/vc/%d", "/dev/tty%d", NULL };
if (serverGeneration == 1) {
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_kmod.c b/xorg-server/hw/xfree86/os-support/linux/lnx_kmod.c
index 0a17c2a81..f5917eefb 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_kmod.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_kmod.c
@@ -37,7 +37,7 @@ int
xf86LoadKernelModule(const char *modName)
{
char mpPath[MAX_PATH] = "";
- int fd = -1, status, n;
+ int fd = -1, status;
pid_t pid;
/* get the path to the modprobe program */
@@ -76,7 +76,7 @@ xf86LoadKernelModule(const char *modName)
"Setting of real/effective user Id to 0/0 failed");
}
setenv("PATH", "/sbin", 1);
- n = execl(mpPath, "modprobe", modName, NULL);
+ execl(mpPath, "modprobe", modName, NULL);
xf86Msg(X_WARNING, "LoadKernelModule %s\n", strerror(errno));
exit(EXIT_FAILURE); /* if we get here the child's exec failed */
break;
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_video.c b/xorg-server/hw/xfree86/os-support/linux/lnx_video.c
index 43d0a364a..824003d26 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_video.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_video.c
@@ -80,17 +80,17 @@ extern int iopl(int __level);
/* Video Memory Mapping section */
/***************************************************************************/
-static pointer mapVidMem(int, unsigned long, unsigned long, int);
-static void unmapVidMem(int, pointer, unsigned long);
+static void *mapVidMem(int, unsigned long, unsigned long, int);
+static void unmapVidMem(int, void *, unsigned long);
#if defined (__alpha__)
extern void sethae(unsigned long hae);
extern unsigned long _bus_base __P((void)) __attribute__ ((const));
extern unsigned long _bus_base_sparse __P((void)) __attribute__ ((const));
-static pointer mapVidMemSparse(int, unsigned long, unsigned long, int);
+static void *mapVidMemSparse(int, unsigned long, unsigned long, int);
extern axpDevice lnxGetAXP(void);
-static void unmapVidMemSparse(int, pointer, unsigned long);
+static void unmapVidMemSparse(int, void *, unsigned long);
static axpDevice axpSystem = -1;
static Bool needSparse;
static unsigned long hae_thresh;
@@ -102,8 +102,8 @@ static unsigned long bus_base;
#define SPLIT_WC_REGIONS 1
-static pointer setWC(int, unsigned long, unsigned long, Bool, MessageType);
-static void undoWC(int, pointer);
+static void *setWC(int, unsigned long, unsigned long, Bool, MessageType);
+static void undoWC(int, void *);
/* The file desc for /proc/mtrr. Once opened, left opened, and the mtrr
driver will clean up when we exit. */
@@ -339,7 +339,7 @@ mtrr_undo_wc_region(int screenNum, struct mtrr_wc_region *wcr)
}
}
-static pointer
+static void *
setWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
MessageType from)
{
@@ -350,7 +350,7 @@ setWC(int screenNum, unsigned long base, unsigned long size, Bool enable,
}
static void
-undoWC(int screenNum, pointer regioninfo)
+undoWC(int screenNum, void *regioninfo)
{
mtrr_undo_wc_region(screenNum, regioninfo);
}
@@ -396,16 +396,16 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
/* Basically, you simply cannot do this on Sparc. You have to do something portable
* like use /dev/fb* or mmap() on /proc/bus/pci/X/Y nodes. -DaveM
*/
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
return NULL;
}
#else
-static pointer
+static void *
mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
{
- pointer base;
+ void *base;
int fd;
int mapflags = MAP_SHARED;
int prot;
@@ -460,7 +460,7 @@ mapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int flags)
#endif /* !(__sparc__) */
static void
-unmapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
uintptr_t alignOff = (uintptr_t) Base
- ((uintptr_t) Base & ~(getpagesize() - 1));
@@ -565,44 +565,44 @@ xf86DisableIO(void)
#define vuip volatile unsigned int *
-extern int readDense8(pointer Base, register unsigned long Offset);
-extern int readDense16(pointer Base, register unsigned long Offset);
-extern int readDense32(pointer Base, register unsigned long Offset);
+extern int readDense8(void *Base, register unsigned long Offset);
+extern int readDense16(void *Base, register unsigned long Offset);
+extern int readDense32(void *Base, register unsigned long Offset);
extern void
- writeDenseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB8(int Value, void *Base, register unsigned long Offset);
extern void
- writeDenseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB16(int Value, void *Base, register unsigned long Offset);
extern void
- writeDenseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeDenseNB32(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense8(int Value, pointer Base, register unsigned long Offset);
+ writeDense8(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense16(int Value, pointer Base, register unsigned long Offset);
+ writeDense16(int Value, void *Base, register unsigned long Offset);
extern void
- writeDense32(int Value, pointer Base, register unsigned long Offset);
+ writeDense32(int Value, void *Base, register unsigned long Offset);
-static int readSparse8(pointer Base, register unsigned long Offset);
-static int readSparse16(pointer Base, register unsigned long Offset);
-static int readSparse32(pointer Base, register unsigned long Offset);
+static int readSparse8(void *Base, register unsigned long Offset);
+static int readSparse16(void *Base, register unsigned long Offset);
+static int readSparse32(void *Base, register unsigned long Offset);
static void
- writeSparseNB8(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB8(int Value, void *Base, register unsigned long Offset);
static void
- writeSparseNB16(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB16(int Value, void *Base, register unsigned long Offset);
static void
- writeSparseNB32(int Value, pointer Base, register unsigned long Offset);
+ writeSparseNB32(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse8(int Value, pointer Base, register unsigned long Offset);
+ writeSparse8(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse16(int Value, pointer Base, register unsigned long Offset);
+ writeSparse16(int Value, void *Base, register unsigned long Offset);
static void
- writeSparse32(int Value, pointer Base, register unsigned long Offset);
+ writeSparse32(int Value, void *Base, register unsigned long Offset);
#define DENSE_BASE 0x2ff00000000UL
#define SPARSE_BASE 0x30000000000UL
static unsigned long msb_set = 0;
-static pointer
+static void *
mapVidMemSparse(int ScreenNum, unsigned long Base, unsigned long Size,
int flags)
{
@@ -689,11 +689,11 @@ mapVidMemSparse(int ScreenNum, unsigned long Base, unsigned long Size,
" to DENSE only at 0x%lx\n", Base, Size, ret);
#endif
- return (pointer) ret;
+ return (void *) ret;
}
static void
-unmapVidMemSparse(int ScreenNum, pointer Base, unsigned long Size)
+unmapVidMemSparse(int ScreenNum, void *Base, unsigned long Size)
{
unsigned long Offset = (unsigned long) Base - DENSE_BASE;
@@ -709,7 +709,7 @@ unmapVidMemSparse(int ScreenNum, pointer Base, unsigned long Size)
}
static int
-readSparse8(pointer Base, register unsigned long Offset)
+readSparse8(void *Base, register unsigned long Offset)
{
register unsigned long result, shift;
register unsigned long msb;
@@ -733,7 +733,7 @@ readSparse8(pointer Base, register unsigned long Offset)
}
static int
-readSparse16(pointer Base, register unsigned long Offset)
+readSparse16(void *Base, register unsigned long Offset)
{
register unsigned long result, shift;
register unsigned long msb;
@@ -757,7 +757,7 @@ readSparse16(pointer Base, register unsigned long Offset)
}
static int
-readSparse32(pointer Base, register unsigned long Offset)
+readSparse32(void *Base, register unsigned long Offset)
{
/* NOTE: this is really using DENSE. */
mem_barrier();
@@ -765,7 +765,7 @@ readSparse32(pointer Base, register unsigned long Offset)
}
static void
-writeSparse8(int Value, pointer Base, register unsigned long Offset)
+writeSparse8(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int b = Value & 0xffU;
@@ -786,7 +786,7 @@ writeSparse8(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparse16(int Value, pointer Base, register unsigned long Offset)
+writeSparse16(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int w = Value & 0xffffU;
@@ -807,7 +807,7 @@ writeSparse16(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparse32(int Value, pointer Base, register unsigned long Offset)
+writeSparse32(int Value, void *Base, register unsigned long Offset)
{
/* NOTE: this is really using DENSE. */
write_mem_barrier();
@@ -816,7 +816,7 @@ writeSparse32(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB8(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB8(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int b = Value & 0xffU;
@@ -834,7 +834,7 @@ writeSparseNB8(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB16(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB16(int Value, void *Base, register unsigned long Offset)
{
register unsigned long msb;
register unsigned int w = Value & 0xffffU;
@@ -852,30 +852,30 @@ writeSparseNB16(int Value, pointer Base, register unsigned long Offset)
}
static void
-writeSparseNB32(int Value, pointer Base, register unsigned long Offset)
+writeSparseNB32(int Value, void *Base, register unsigned long Offset)
{
/* NOTE: this is really using DENSE. */
*(vuip) ((unsigned long) Base + (Offset)) = Value;
return;
}
-void (*xf86WriteMmio8) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio8) (int Value, void *Base, unsigned long Offset)
= writeDense8;
-void (*xf86WriteMmio16) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio16) (int Value, void *Base, unsigned long Offset)
= writeDense16;
-void (*xf86WriteMmio32) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmio32) (int Value, void *Base, unsigned long Offset)
= writeDense32;
-void (*xf86WriteMmioNB8) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB8) (int Value, void *Base, unsigned long Offset)
= writeDenseNB8;
-void (*xf86WriteMmioNB16) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB16) (int Value, void *Base, unsigned long Offset)
= writeDenseNB16;
-void (*xf86WriteMmioNB32) (int Value, pointer Base, unsigned long Offset)
+void (*xf86WriteMmioNB32) (int Value, void *Base, unsigned long Offset)
= writeDenseNB32;
-int (*xf86ReadMmio8) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio8) (void *Base, unsigned long Offset)
= readDense8;
-int (*xf86ReadMmio16) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio16) (void *Base, unsigned long Offset)
= readDense16;
-int (*xf86ReadMmio32) (pointer Base, unsigned long Offset)
+int (*xf86ReadMmio32) (void *Base, unsigned long Offset)
= readDense32;
#endif /* __alpha__ */
diff --git a/xorg-server/hw/xfree86/os-support/shared/vidmem.c b/xorg-server/hw/xfree86/os-support/shared/vidmem.c
index 68ed30e41..f473293c7 100644
--- a/xorg-server/hw/xfree86/os-support/shared/vidmem.c
+++ b/xorg-server/hw/xfree86/os-support/shared/vidmem.c
@@ -51,8 +51,8 @@
typedef struct {
unsigned long size;
- pointer virtBase;
- pointer mtrrInfo;
+ void *virtBase;
+ void *mtrrInfo;
} MappingRec, *MappingPtr;
typedef struct {
@@ -104,7 +104,7 @@ newMapping(VidMapPtr vp)
}
static MappingPtr
-findMapping(VidMapPtr vp, pointer vbase, unsigned long size)
+findMapping(VidMapPtr vp, void *vbase, unsigned long size)
{
int i;
@@ -165,10 +165,10 @@ xf86InitVidMem(void)
}
}
-pointer
+void *
xf86MapVidMem(int ScreenNum, int Flags, unsigned long Base, unsigned long Size)
{
- pointer vbase = NULL;
+ void *vbase = NULL;
VidMapPtr vp;
MappingPtr mp;
@@ -182,7 +182,7 @@ xf86MapVidMem(int ScreenNum, int Flags, unsigned long Base, unsigned long Size)
vbase = vidMemInfo.mapMem(ScreenNum, Base, Size, Flags);
- if (!vbase || vbase == (pointer) -1)
+ if (!vbase || vbase == (void *) -1)
return NULL;
vp = getVidMapRec(ScreenNum);
@@ -208,7 +208,7 @@ xf86MapVidMem(int ScreenNum, int Flags, unsigned long Base, unsigned long Size)
}
void
-xf86UnMapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+xf86UnMapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
VidMapPtr vp;
MappingPtr mp;
diff --git a/xorg-server/hw/xfree86/os-support/solaris/sun_apm.c b/xorg-server/hw/xfree86/os-support/solaris/sun_apm.c
index b6a1432f6..38fa5ecf2 100644
--- a/xorg-server/hw/xfree86/os-support/solaris/sun_apm.c
+++ b/xorg-server/hw/xfree86/os-support/solaris/sun_apm.c
@@ -90,7 +90,7 @@ typedef struct apm_event_info {
#define APM_DEVICE "/dev/srn"
#define APM_DEVICE1 "/dev/apm"
-static pointer APMihPtr = NULL;
+static void *APMihPtr = NULL;
static void sunCloseAPM(void);
static struct {
diff --git a/xorg-server/hw/xfree86/os-support/solaris/sun_init.c b/xorg-server/hw/xfree86/os-support/solaris/sun_init.c
index 68527a577..16fc1b739 100644
--- a/xorg-server/hw/xfree86/os-support/solaris/sun_init.c
+++ b/xorg-server/hw/xfree86/os-support/solaris/sun_init.c
@@ -316,7 +316,7 @@ xf86CloseConsole(void)
" attributes (%s)\n", strerror(errno));
}
else {
- pointer fbdata;
+ void *fbdata;
fbdata = mmap(NULL, fbattr.fbtype.fb_size,
PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0);
diff --git a/xorg-server/hw/xfree86/os-support/solaris/sun_vid.c b/xorg-server/hw/xfree86/os-support/solaris/sun_vid.c
index 67ef17689..fc464871d 100644
--- a/xorg-server/hw/xfree86/os-support/solaris/sun_vid.c
+++ b/xorg-server/hw/xfree86/os-support/solaris/sun_vid.c
@@ -107,10 +107,10 @@ solOpenAperture(void)
return TRUE;
}
-static pointer
+static void *
solMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int Flags)
{
- pointer base;
+ void *base;
int fd;
int prot;
@@ -144,7 +144,7 @@ solMapVidMem(int ScreenNum, unsigned long Base, unsigned long Size, int Flags)
/* ARGSUSED */
static void
-solUnMapVidMem(int ScreenNum, pointer Base, unsigned long Size)
+solUnMapVidMem(int ScreenNum, void *Base, unsigned long Size)
{
if (munmap(Base, Size) != 0) {
xf86DrvMsgVerb(ScreenNum, X_WARNING, 0,
diff --git a/xorg-server/hw/xfree86/os-support/xf86OSpriv.h b/xorg-server/hw/xfree86/os-support/xf86OSpriv.h
index bd734f554..7f003e8ce 100644
--- a/xorg-server/hw/xfree86/os-support/xf86OSpriv.h
+++ b/xorg-server/hw/xfree86/os-support/xf86OSpriv.h
@@ -32,12 +32,12 @@
#ifndef _XF86OSPRIV_H
#define _XF86OSPRIV_H
-typedef pointer (*MapMemProcPtr) (int, unsigned long, unsigned long, int);
-typedef void (*UnmapMemProcPtr) (int, pointer, unsigned long);
-typedef pointer (*SetWCProcPtr) (int, unsigned long, unsigned long, Bool,
+typedef void *(*MapMemProcPtr) (int, unsigned long, unsigned long, int);
+typedef void (*UnmapMemProcPtr) (int, void *, unsigned long);
+typedef void *(*SetWCProcPtr) (int, unsigned long, unsigned long, Bool,
MessageType);
-typedef void (*ProtectMemProcPtr) (int, pointer, unsigned long, Bool);
-typedef void (*UndoWCProcPtr) (int, pointer);
+typedef void (*ProtectMemProcPtr) (int, void *, unsigned long, Bool);
+typedef void (*UndoWCProcPtr) (int, void *);
typedef struct {
Bool initialised;
diff --git a/xorg-server/hw/xfree86/os-support/xf86_OSproc.h b/xorg-server/hw/xfree86/os-support/xf86_OSproc.h
index 106168aba..8d27e8b7b 100644
--- a/xorg-server/hw/xfree86/os-support/xf86_OSproc.h
+++ b/xorg-server/hw/xfree86/os-support/xf86_OSproc.h
@@ -132,9 +132,9 @@ _XFUNCPROTOBEGIN
/* public functions */
extern _X_EXPORT Bool xf86LinearVidMem(void);
extern _X_EXPORT _X_DEPRECATED Bool xf86CheckMTRR(int);
-extern _X_EXPORT _X_DEPRECATED pointer xf86MapVidMem(int, int, unsigned long,
+extern _X_EXPORT _X_DEPRECATED void *xf86MapVidMem(int, int, unsigned long,
unsigned long);
-extern _X_EXPORT _X_DEPRECATED void xf86UnMapVidMem(int, pointer,
+extern _X_EXPORT _X_DEPRECATED void xf86UnMapVidMem(int, void *,
unsigned long);
extern _X_EXPORT int xf86ReadBIOS(unsigned long, unsigned long, unsigned char *,
int);
diff --git a/xorg-server/hw/xfree86/parser/Configint.h b/xorg-server/hw/xfree86/parser/Configint.h
index 81cc1fc59..62e514201 100644
--- a/xorg-server/hw/xfree86/parser/Configint.h
+++ b/xorg-server/hw/xfree86/parser/Configint.h
@@ -90,7 +90,7 @@ typedef struct {
#include "configProcs.h"
#include <stdlib.h>
-#define TestFree(a) if (a) { free (a); a = NULL; }
+#define TestFree(a) if (a) { free ((void *) a); a = NULL; }
#define parsePrologue(typeptr,typerec) typeptr ptr; \
if( (ptr=calloc(1,sizeof(typerec))) == NULL ) { return NULL; }
diff --git a/xorg-server/hw/xfree86/parser/Files.c b/xorg-server/hw/xfree86/parser/Files.c
index 0d3e47ac5..a6e18dd2c 100644
--- a/xorg-server/hw/xfree86/parser/Files.c
+++ b/xorg-server/hw/xfree86/parser/Files.c
@@ -97,8 +97,7 @@ xf86parseFilesSection(void)
j = FALSE;
str = val.str;
if (ptr->file_fontpath == NULL) {
- ptr->file_fontpath = malloc(1);
- ptr->file_fontpath[0] = '\0';
+ ptr->file_fontpath = calloc(1, 1);
i = strlen(str) + 1;
}
else {
diff --git a/xorg-server/hw/xfree86/parser/Flags.c b/xorg-server/hw/xfree86/parser/Flags.c
index 2461476d1..326c6b77d 100644
--- a/xorg-server/hw/xfree86/parser/Flags.c
+++ b/xorg-server/hw/xfree86/parser/Flags.c
@@ -189,7 +189,7 @@ xf86printServerFlagsSection(FILE * f, XF86ConfFlagsPtr flags)
}
static XF86OptionPtr
-addNewOption2(XF86OptionPtr head, char *name, char *val, int used)
+addNewOption2(XF86OptionPtr head, char *name, char *_val, int used)
{
XF86OptionPtr new, old = NULL;
@@ -202,7 +202,7 @@ addNewOption2(XF86OptionPtr head, char *name, char *val, int used)
else
new = calloc(1, sizeof(*new));
new->opt_name = name;
- new->opt_val = val;
+ new->opt_val = _val;
new->opt_used = used;
if (old)
@@ -211,9 +211,9 @@ addNewOption2(XF86OptionPtr head, char *name, char *val, int used)
}
XF86OptionPtr
-xf86addNewOption(XF86OptionPtr head, char *name, char *val)
+xf86addNewOption(XF86OptionPtr head, char *name, char *_val)
{
- return addNewOption2(head, name, val, 0);
+ return addNewOption2(head, name, _val, 0);
}
void
@@ -230,11 +230,11 @@ XF86OptionPtr
xf86optionListDup(XF86OptionPtr opt)
{
XF86OptionPtr newopt = NULL;
- char *val;
+ char *_val;
while (opt) {
- val = opt->opt_val ? strdup(opt->opt_val) : NULL;
- newopt = xf86addNewOption(newopt, strdup(opt->opt_name), val);
+ _val = opt->opt_val ? strdup(opt->opt_val) : NULL;
+ newopt = xf86addNewOption(newopt, strdup(opt->opt_name), _val);
newopt->opt_used = opt->opt_used;
if (opt->opt_comment)
newopt->opt_comment = strdup(opt->opt_comment);
diff --git a/xorg-server/hw/xfree86/parser/InputClass.c b/xorg-server/hw/xfree86/parser/InputClass.c
index de6a816ea..a7f573e70 100644
--- a/xorg-server/hw/xfree86/parser/InputClass.c
+++ b/xorg-server/hw/xfree86/parser/InputClass.c
@@ -64,7 +64,7 @@ xf86ConfigSymTabRec InputClassTab[] = {
#define TOKEN_SEP "|"
static void
-add_group_entry(struct xorg_list *head, char **values)
+add_group_entry(struct xorg_list *head, const char **values)
{
xf86MatchGroup *group;
@@ -257,7 +257,7 @@ void
xf86printInputClassSection(FILE * cf, XF86ConfInputClassPtr ptr)
{
const xf86MatchGroup *group;
- char *const *cur;
+ const char *const *cur;
while (ptr) {
fprintf(cf, "Section \"InputClass\"\n");
@@ -363,7 +363,7 @@ xf86freeInputClassList(XF86ConfInputClassPtr ptr)
while (ptr) {
xf86MatchGroup *group, *next;
- char **list;
+ const char **list;
TestFree(ptr->identifier);
TestFree(ptr->driver);
@@ -371,55 +371,55 @@ xf86freeInputClassList(XF86ConfInputClassPtr ptr)
xorg_list_for_each_entry_safe(group, next, &ptr->match_product, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_vendor, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_device, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_os, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_pnpid, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_usbid, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_driver, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_tag, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
xorg_list_for_each_entry_safe(group, next, &ptr->match_layout, entry) {
xorg_list_del(&group->entry);
for (list = group->values; *list; list++)
- free(*list);
+ free((void *) *list);
free(group);
}
diff --git a/xorg-server/hw/xfree86/parser/Module.c b/xorg-server/hw/xfree86/parser/Module.c
index 87ddfc635..243ba9195 100644
--- a/xorg-server/hw/xfree86/parser/Module.c
+++ b/xorg-server/hw/xfree86/parser/Module.c
@@ -218,7 +218,7 @@ xf86printModuleSection(FILE * cf, XF86ConfModulePtr ptr)
}
XF86LoadPtr
-xf86addNewLoadDirective(XF86LoadPtr head, char *name, int type,
+xf86addNewLoadDirective(XF86LoadPtr head, const char *name, int type,
XF86OptionPtr opts)
{
XF86LoadPtr new;
diff --git a/xorg-server/hw/xfree86/parser/configProcs.h b/xorg-server/hw/xfree86/parser/configProcs.h
index 1250f3922..60509dcd8 100644
--- a/xorg-server/hw/xfree86/parser/configProcs.h
+++ b/xorg-server/hw/xfree86/parser/configProcs.h
@@ -67,7 +67,7 @@ int xf86validateLayout(XF86ConfigPtr p);
XF86ConfModulePtr xf86parseModuleSection(void);
void xf86printModuleSection(FILE * cf, XF86ConfModulePtr ptr);
extern _X_EXPORT XF86LoadPtr xf86addNewLoadDirective(XF86LoadPtr head,
- char *name, int type,
+ const char *name, int type,
XF86OptionPtr opts);
void xf86freeModules(XF86ConfModulePtr ptr);
@@ -141,7 +141,7 @@ xf86freeExtensions(XF86ConfExtensionsPtr ptr);
#include <xorg-config.h>
#endif
-#ifndef IN_XSERVER
+#ifndef HAVE_XORG_CONFIG_H
/* Externally provided functions */
void
ErrorF(const char *f, ...);
diff --git a/xorg-server/hw/xfree86/parser/scan.c b/xorg-server/hw/xfree86/parser/scan.c
index f852b83ec..55a84426d 100644
--- a/xorg-server/hw/xfree86/parser/scan.c
+++ b/xorg-server/hw/xfree86/parser/scan.c
@@ -820,7 +820,7 @@ static char *
OpenConfigDir(const char *path, const char *cmdline, const char *projroot,
const char *confname)
{
- char *dirpath, *pathcopy;
+ char *dirpath = NULL, *pathcopy;
const char *template;
Bool found = FALSE;
int cmdlineUsed = 0;
@@ -1078,9 +1078,10 @@ xf86nameCompare(const char *s1, const char *s2)
}
char *
-xf86addComment(char *cur, char *add)
+xf86addComment(char *cur, const char *add)
{
char *str;
+ const char *cstr;
int len, curlen, iscomment, hasnewline = 0, insnewline, endnewline;
if (add == NULL || add[0] == '\0')
@@ -1095,14 +1096,14 @@ xf86addComment(char *cur, char *add)
else
curlen = 0;
- str = add;
+ cstr = add;
iscomment = 0;
- while (*str) {
- if (*str != ' ' && *str != '\t')
+ while (*cstr) {
+ if (*cstr != ' ' && *cstr != '\t')
break;
- ++str;
+ ++cstr;
}
- iscomment = (*str == '#');
+ iscomment = (*cstr == '#');
len = strlen(add);
endnewline = add[len - 1] == '\n';
diff --git a/xorg-server/hw/xfree86/parser/xf86Parser.h b/xorg-server/hw/xfree86/parser/xf86Parser.h
index e7210e811..83607f26c 100644
--- a/xorg-server/hw/xfree86/parser/xf86Parser.h
+++ b/xorg-server/hw/xfree86/parser/xf86Parser.h
@@ -85,7 +85,7 @@ typedef struct {
typedef struct {
GenericListRec list;
int load_type;
- char *load_name;
+ const char *load_name;
XF86OptionPtr load_opt;
char *load_comment;
int ignore;
@@ -116,7 +116,7 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *ml_identifier;
+ const char *ml_identifier;
int ml_clock;
int ml_hdisplay;
int ml_hsyncstart;
@@ -134,21 +134,21 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *vp_identifier;
+ const char *vp_identifier;
XF86OptionPtr vp_option_lst;
char *vp_comment;
} XF86ConfVideoPortRec, *XF86ConfVideoPortPtr;
typedef struct {
GenericListRec list;
- char *va_identifier;
- char *va_vendor;
- char *va_board;
- char *va_busid;
- char *va_driver;
+ const char *va_identifier;
+ const char *va_vendor;
+ const char *va_board;
+ const char *va_busid;
+ const char *va_driver;
XF86OptionPtr va_option_lst;
XF86ConfVideoPortPtr va_port_lst;
- char *va_fwdref;
+ const char *va_fwdref;
char *va_comment;
} XF86ConfVideoAdaptorRec, *XF86ConfVideoAdaptorPtr;
@@ -165,21 +165,21 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *modes_identifier;
+ const char *modes_identifier;
XF86ConfModeLinePtr mon_modeline_lst;
char *modes_comment;
} XF86ConfModesRec, *XF86ConfModesPtr;
typedef struct {
GenericListRec list;
- char *ml_modes_str;
+ const char *ml_modes_str;
XF86ConfModesPtr ml_modes;
} XF86ConfModesLinkRec, *XF86ConfModesLinkPtr;
typedef struct {
GenericListRec list;
- char *mon_identifier;
- char *mon_vendor;
+ const char *mon_identifier;
+ const char *mon_vendor;
char *mon_modelname;
int mon_width; /* in mm */
int mon_height; /* in mm */
@@ -201,21 +201,21 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *dev_identifier;
- char *dev_vendor;
- char *dev_board;
- char *dev_chipset;
- char *dev_busid;
- char *dev_card;
- char *dev_driver;
- char *dev_ramdac;
+ const char *dev_identifier;
+ const char *dev_vendor;
+ const char *dev_board;
+ const char *dev_chipset;
+ const char *dev_busid;
+ const char *dev_card;
+ const char *dev_driver;
+ const char *dev_ramdac;
int dev_dacSpeeds[CONF_MAXDACSPEEDS];
int dev_videoram;
int dev_textclockfreq;
unsigned long dev_bios_base;
unsigned long dev_mem_base;
unsigned long dev_io_base;
- char *dev_clockchip;
+ const char *dev_clockchip;
int dev_clocks;
int dev_clock[CONF_MAXCLOCKS];
int dev_chipid;
@@ -228,7 +228,7 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *mode_name;
+ const char *mode_name;
} XF86ModeRec, *XF86ModePtr;
typedef struct {
@@ -239,7 +239,7 @@ typedef struct {
int disp_virtualY;
int disp_depth;
int disp_bpp;
- char *disp_visual;
+ const char *disp_visual;
parser_rgb disp_weight;
parser_rgb disp_black;
parser_rgb disp_white;
@@ -255,20 +255,20 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *al_adaptor_str;
+ const char *al_adaptor_str;
XF86ConfVideoAdaptorPtr al_adaptor;
} XF86ConfAdaptorLinkRec, *XF86ConfAdaptorLinkPtr;
typedef struct {
GenericListRec list;
- char *scrn_identifier;
- char *scrn_obso_driver;
+ const char *scrn_identifier;
+ const char *scrn_obso_driver;
int scrn_defaultdepth;
int scrn_defaultbpp;
int scrn_defaultfbbpp;
- char *scrn_monitor_str;
+ const char *scrn_monitor_str;
XF86ConfMonitorPtr scrn_monitor;
- char *scrn_device_str;
+ const char *scrn_device_str;
XF86ConfDevicePtr scrn_device;
XF86ConfAdaptorLinkPtr scrn_adaptor_lst;
XF86ConfDisplayPtr scrn_display_lst;
@@ -279,8 +279,8 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *inp_identifier;
- char *inp_driver;
+ const char *inp_identifier;
+ const char *inp_driver;
XF86OptionPtr inp_option_lst;
char *inp_comment;
} XF86ConfInputRec, *XF86ConfInputPtr;
@@ -288,7 +288,7 @@ typedef struct {
typedef struct {
GenericListRec list;
XF86ConfInputPtr iref_inputdev;
- char *iref_inputdev_str;
+ const char *iref_inputdev_str;
XF86OptionPtr iref_option_lst;
} XF86ConfInputrefRec, *XF86ConfInputrefPtr;
@@ -299,13 +299,13 @@ typedef struct {
typedef struct {
struct xorg_list entry;
- char **values;
+ const char **values;
} xf86MatchGroup;
typedef struct {
GenericListRec list;
char *identifier;
- char *driver;
+ const char *driver;
struct xorg_list match_product;
struct xorg_list match_vendor;
struct xorg_list match_device;
@@ -338,30 +338,30 @@ typedef struct {
GenericListRec list;
int adj_scrnum;
XF86ConfScreenPtr adj_screen;
- char *adj_screen_str;
+ const char *adj_screen_str;
XF86ConfScreenPtr adj_top;
- char *adj_top_str;
+ const char *adj_top_str;
XF86ConfScreenPtr adj_bottom;
- char *adj_bottom_str;
+ const char *adj_bottom_str;
XF86ConfScreenPtr adj_left;
- char *adj_left_str;
+ const char *adj_left_str;
XF86ConfScreenPtr adj_right;
- char *adj_right_str;
+ const char *adj_right_str;
int adj_where;
int adj_x;
int adj_y;
- char *adj_refscreen;
+ const char *adj_refscreen;
} XF86ConfAdjacencyRec, *XF86ConfAdjacencyPtr;
typedef struct {
GenericListRec list;
- char *inactive_device_str;
+ const char *inactive_device_str;
XF86ConfDevicePtr inactive_device;
} XF86ConfInactiveRec, *XF86ConfInactivePtr;
typedef struct {
GenericListRec list;
- char *lay_identifier;
+ const char *lay_identifier;
XF86ConfAdjacencyPtr lay_adjacency_lst;
XF86ConfInactivePtr lay_inactive_lst;
XF86ConfInputrefPtr lay_input_lst;
@@ -371,22 +371,22 @@ typedef struct {
typedef struct {
GenericListRec list;
- char *vs_name;
- char *vs_identifier;
+ const char *vs_name;
+ const char *vs_identifier;
XF86OptionPtr vs_option_lst;
char *vs_comment;
} XF86ConfVendSubRec, *XF86ConfVendSubPtr;
typedef struct {
GenericListRec list;
- char *vnd_identifier;
+ const char *vnd_identifier;
XF86OptionPtr vnd_option_lst;
XF86ConfVendSubPtr vnd_sub_lst;
char *vnd_comment;
} XF86ConfVendorRec, *XF86ConfVendorPtr;
typedef struct {
- char *dri_group_name;
+ const char *dri_group_name;
int dri_group;
int dri_mode;
char *dri_comment;
@@ -462,7 +462,7 @@ extern _X_EXPORT int xf86itemNotSublist(GenericListPtr list_1,
extern _X_EXPORT int xf86pathIsAbsolute(const char *path);
extern _X_EXPORT int xf86pathIsSafe(const char *path);
-extern _X_EXPORT char *xf86addComment(char *cur, char *add);
+extern _X_EXPORT char *xf86addComment(char *cur, const char *add);
extern _X_EXPORT Bool xf86getBoolValue(Bool *val, const char *str);
#endif /* _xf86Parser_h_ */
diff --git a/xorg-server/hw/xfree86/ramdac/xf86CursorPriv.h b/xorg-server/hw/xfree86/ramdac/xf86CursorPriv.h
index 04be14135..a5d2aabc3 100644
--- a/xorg-server/hw/xfree86/ramdac/xf86CursorPriv.h
+++ b/xorg-server/hw/xfree86/ramdac/xf86CursorPriv.h
@@ -34,7 +34,7 @@ typedef struct {
int ForceHWCursorCount;
Bool HWCursorForced;
- pointer transparentData;
+ void *transparentData;
} xf86CursorScreenRec, *xf86CursorScreenPtr;
void xf86SetCursor(ScreenPtr pScreen, CursorPtr pCurs, int x, int y);
diff --git a/xorg-server/hw/xfree86/ramdac/xf86HWCurs.c b/xorg-server/hw/xfree86/ramdac/xf86HWCurs.c
index 197abff8f..3b69698db 100644
--- a/xorg-server/hw/xfree86/ramdac/xf86HWCurs.c
+++ b/xorg-server/hw/xfree86/ramdac/xf86HWCurs.c
@@ -462,9 +462,9 @@ RealizeCursorInterleave16(xf86CursorInfoPtr infoPtr, CursorPtr pCurs)
}
/* 16 bit interleave */
- DstS = (pointer) mem2;
+ DstS = (void *) mem2;
DstM = DstS + (size >> 2);
- pntr = (pointer) mem;
+ pntr = (void *) mem;
count = (size >> 1);
while (count) {
*pntr++ = *DstS++;
@@ -497,9 +497,9 @@ RealizeCursorInterleave32(xf86CursorInfoPtr infoPtr, CursorPtr pCurs)
}
/* 32 bit interleave */
- DstS = (pointer) mem2;
+ DstS = (void *) mem2;
DstM = DstS + (size >> 3);
- pntr = (pointer) mem;
+ pntr = (void *) mem;
count = (size >> 2);
while (count) {
*pntr++ = *DstS++;
@@ -532,9 +532,9 @@ RealizeCursorInterleave64(xf86CursorInfoPtr infoPtr, CursorPtr pCurs)
}
/* 64 bit interleave */
- DstS = (pointer) mem2;
+ DstS = (void *) mem2;
DstM = DstS + (size >> 3);
- pntr = (pointer) mem;
+ pntr = (void *) mem;
count = (size >> 2);
while (count) {
*pntr++ = *DstS++;
diff --git a/xorg-server/hw/xfree86/sdksyms.sh b/xorg-server/hw/xfree86/sdksyms.sh
index d7f259d28..d9a44788c 100644
--- a/xorg-server/hw/xfree86/sdksyms.sh
+++ b/xorg-server/hw/xfree86/sdksyms.sh
@@ -261,6 +261,7 @@ cat > sdksyms.c << EOF
#include "dix.h"
#include "dixaccess.h"
#include "dixevents.h"
+#define _FONTPROTO_H
#include "dixfont.h"
#include "dixfontstr.h"
#include "dixfontstubs.h"
diff --git a/xorg-server/hw/xfree86/shadowfb/shadow.c b/xorg-server/hw/xfree86/shadowfb/shadow.c
index 614501770..43529398a 100644
--- a/xorg-server/hw/xfree86/shadowfb/shadow.c
+++ b/xorg-server/hw/xfree86/shadowfb/shadow.c
@@ -62,8 +62,8 @@ typedef struct {
} ShadowScreenRec, *ShadowScreenPtr;
typedef struct {
- GCOps *ops;
- GCFuncs *funcs;
+ const GCOps *ops;
+ const GCFuncs *funcs;
} ShadowGCRec, *ShadowGCPtr;
static DevPrivateKeyRec ShadowScreenKeyRec;
@@ -96,7 +96,7 @@ static DevPrivateKeyRec ShadowGCKeyRec;
#define SHADOW_GC_OP_PROLOGUE(pGC)\
ShadowScreenPtr pPriv = GET_SCREEN_PRIVATE(pGC->pScreen); \
ShadowGCPtr pGCPriv = GET_GC_PRIVATE(pGC);\
- GCFuncs *oldFuncs = pGC->funcs;\
+ const GCFuncs *oldFuncs = pGC->funcs;\
pGC->funcs = pGCPriv->funcs;\
pGC->ops = pGCPriv->ops
@@ -243,7 +243,7 @@ ShadowCloseScreen(ScreenPtr pScreen)
ps->Composite = pPriv->Composite;
}
- free((pointer) pPriv);
+ free((void *) pPriv);
return (*pScreen->CloseScreen) (pScreen);
}
@@ -342,7 +342,7 @@ static void ShadowValidateGC(GCPtr, unsigned long, DrawablePtr);
static void ShadowChangeGC(GCPtr, unsigned long);
static void ShadowCopyGC(GCPtr, unsigned long, GCPtr);
static void ShadowDestroyGC(GCPtr);
-static void ShadowChangeClip(GCPtr, int, pointer, int);
+static void ShadowChangeClip(GCPtr, int, void *, int);
static void ShadowDestroyClip(GCPtr);
static void ShadowCopyClip(GCPtr, GCPtr);
@@ -409,7 +409,7 @@ ShadowCopyGC(GCPtr pGCSrc, unsigned long mask, GCPtr pGCDst)
}
static void
-ShadowChangeClip(GCPtr pGC, int type, pointer pvalue, int nrects)
+ShadowChangeClip(GCPtr pGC, int type, void *pvalue, int nrects)
{
SHADOW_GC_FUNC_PROLOGUE(pGC);
(*pGC->funcs->ChangeClip) (pGC, type, pvalue, nrects);
@@ -1477,7 +1477,7 @@ ShadowImageGlyphBlt(DrawablePtr pDraw,
GCPtr pGC,
int x, int y,
unsigned int nglyphInit,
- CharInfoPtr * ppciInit, pointer pglyphBase)
+ CharInfoPtr * ppciInit, void *pglyphBase)
{
BoxRec box;
Bool boxNotEmpty = FALSE;
@@ -1538,7 +1538,7 @@ ShadowPolyGlyphBlt(DrawablePtr pDraw,
GCPtr pGC,
int x, int y,
unsigned int nglyphInit,
- CharInfoPtr * ppciInit, pointer pglyphBase)
+ CharInfoPtr * ppciInit, void *pglyphBase)
{
BoxRec box;
Bool boxNotEmpty = FALSE;
diff --git a/xorg-server/hw/xfree86/utils/cvt/cvt.c b/xorg-server/hw/xfree86/utils/cvt/cvt.c
index 5e2888e94..d5df17fd9 100644
--- a/xorg-server/hw/xfree86/utils/cvt/cvt.c
+++ b/xorg-server/hw/xfree86/utils/cvt/cvt.c
@@ -39,10 +39,10 @@ FatalError(const char *f, ...)
}
/* xnfalloc implementation used by the server code we built in */
-pointer
+void *
XNFalloc(unsigned long n)
{
- pointer r;
+ void *r;
r = malloc(n);
if (!r) {
@@ -53,10 +53,10 @@ XNFalloc(unsigned long n)
}
/* xnfcalloc implementation used by the server code we built in */
-pointer
+void *
XNFcalloc(unsigned long n)
{
- pointer r;
+ void *r;
r = calloc(1, n);
if (!r) {
diff --git a/xorg-server/hw/xfree86/vbe/vbe.c b/xorg-server/hw/xfree86/vbe/vbe.c
index 39f0cefb6..d41e61ba8 100644
--- a/xorg-server/hw/xfree86/vbe/vbe.c
+++ b/xorg-server/hw/xfree86/vbe/vbe.c
@@ -50,7 +50,7 @@ vbeInfoPtr
VBEExtendedInit(xf86Int10InfoPtr pInt, int entityIndex, int Flags)
{
int RealOff;
- pointer page = NULL;
+ void *page = NULL;
ScrnInfoPtr pScrn = xf86FindScreenForEntity(entityIndex);
vbeControllerInfoPtr vbe = NULL;
Bool init_int10 = FALSE;
@@ -259,7 +259,7 @@ static unsigned char *
vbeReadEDID(vbeInfoPtr pVbe)
{
int RealOff = pVbe->real_mode_base;
- pointer page = pVbe->memory;
+ void *page = pVbe->memory;
unsigned char *tmp = NULL;
Bool novbe = FALSE;
Bool noddc = FALSE;
@@ -319,7 +319,7 @@ vbeReadEDID(vbeInfoPtr pVbe)
}
xf86MonPtr
-vbeDoEDID(vbeInfoPtr pVbe, pointer unused)
+vbeDoEDID(vbeInfoPtr pVbe, void *unused)
{
unsigned char *DDC_data = NULL;
@@ -545,7 +545,7 @@ VBEFreeModeInfo(VbeModeInfoBlock * block)
Bool
VBESaveRestore(vbeInfoPtr pVbe, vbeSaveRestoreFunction function,
- pointer *memory, int *size, int *real_mode_pages)
+ void **memory, int *size, int *real_mode_pages)
{
/*
Input:
@@ -929,7 +929,7 @@ VBEVesaSaveRestore(vbeInfoPtr pVbe, vbeSaveRestorePtr vbe_sr,
memcpy(vbe_sr->state, vbe_sr->pstate, vbe_sr->stateSize);
ErrorF("VBESaveRestore\n");
if ((VBESaveRestore(pVbe, function,
- (pointer) &vbe_sr->state,
+ (void *) &vbe_sr->state,
&vbe_sr->stateSize, &vbe_sr->statePage))) {
if (function == MODE_SAVE) {
SaveSucc = TRUE;
@@ -1055,7 +1055,7 @@ struct vbePanelID *
VBEReadPanelID(vbeInfoPtr pVbe)
{
int RealOff = pVbe->real_mode_base;
- pointer page = pVbe->memory;
+ void *page = pVbe->memory;
void *tmp = NULL;
int screen = pVbe->pInt10->pScrn->scrnIndex;
diff --git a/xorg-server/hw/xfree86/vbe/vbe.h b/xorg-server/hw/xfree86/vbe/vbe.h
index 3907c53f3..bc3653334 100644
--- a/xorg-server/hw/xfree86/vbe/vbe.h
+++ b/xorg-server/hw/xfree86/vbe/vbe.h
@@ -25,7 +25,7 @@ typedef enum {
typedef struct {
xf86Int10InfoPtr pInt10;
int version;
- pointer memory;
+ void *memory;
int real_mode_base;
int num_pages;
Bool init_int10;
@@ -40,7 +40,7 @@ extern _X_EXPORT vbeInfoPtr VBEInit(xf86Int10InfoPtr pInt, int entityIndex);
extern _X_EXPORT vbeInfoPtr VBEExtendedInit(xf86Int10InfoPtr pInt,
int entityIndex, int Flags);
extern _X_EXPORT void vbeFree(vbeInfoPtr pVbe);
-extern _X_EXPORT xf86MonPtr vbeDoEDID(vbeInfoPtr pVbe, pointer pDDCModule);
+extern _X_EXPORT xf86MonPtr vbeDoEDID(vbeInfoPtr pVbe, void *pDDCModule);
#pragma pack(1)
@@ -227,7 +227,7 @@ typedef enum {
extern _X_EXPORT Bool
VBESaveRestore(vbeInfoPtr pVbe, vbeSaveRestoreFunction fuction,
- pointer *memory, int *size, int *real_mode_pages);
+ void **memory, int *size, int *real_mode_pages);
/*
* INT 5
diff --git a/xorg-server/hw/xfree86/vbe/vbeModes.c b/xorg-server/hw/xfree86/vbe/vbeModes.c
index 415167d0e..50ac50d2c 100644
--- a/xorg-server/hw/xfree86/vbe/vbeModes.c
+++ b/xorg-server/hw/xfree86/vbe/vbeModes.c
@@ -356,8 +356,10 @@ VBESetModeNames(DisplayModePtr pMode)
pMode->name = strdup("BADMODE");
}
else {
- XNFasprintf(&pMode->name, "%dx%d",
+ char *tmp;
+ XNFasprintf(&tmp, "%dx%d",
pMode->HDisplay, pMode->VDisplay);
+ pMode->name = tmp;
}
}
pMode = pMode->next;
@@ -433,7 +435,7 @@ VBESetModeParameters(ScrnInfoPtr pScrn, vbeInfoPtr pVbe)
*/
int
VBEValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
- char **modeNames, ClockRangePtr clockRanges,
+ const char **modeNames, ClockRangePtr clockRanges,
int *linePitches, int minPitch, int maxPitch, int pitchInc,
int minHeight, int maxHeight, int virtualX, int virtualY,
int apertureSize, LookupModeFlags strategy)
diff --git a/xorg-server/hw/xfree86/vbe/vbeModes.h b/xorg-server/hw/xfree86/vbe/vbeModes.h
index affd5b639..ee0257c15 100644
--- a/xorg-server/hw/xfree86/vbe/vbeModes.h
+++ b/xorg-server/hw/xfree86/vbe/vbeModes.h
@@ -82,7 +82,7 @@ extern _X_EXPORT void VBESetModeParameters(ScrnInfoPtr pScrn, vbeInfoPtr pVbe);
*/
extern _X_EXPORT int VBEValidateModes(ScrnInfoPtr scrp,
DisplayModePtr availModes,
- char **modeNames,
+ const char **modeNames,
ClockRangePtr clockRanges,
int *linePitches, int minPitch,
int maxPitch, int pitchInc, int minHeight,
diff --git a/xorg-server/hw/xfree86/vgahw/vgaCmap.c b/xorg-server/hw/xfree86/vgahw/vgaCmap.c
index e7a0d023e..6e028a7f5 100644
--- a/xorg-server/hw/xfree86/vgahw/vgaCmap.c
+++ b/xorg-server/hw/xfree86/vgahw/vgaCmap.c
@@ -252,7 +252,7 @@ ColormapPtr pmap;
if (pmap != GetInstalledmiColormap(pmap->pScreen))
return;
- dixLookupResourceByType((pointer *) &defColormap,
+ dixLookupResourceByType((void **) &defColormap,
pmap->pScreen->defColormap, RT_COLORMAP,
serverClient, DixInstallAccess);
diff --git a/xorg-server/hw/xfree86/vgahw/vgaHW.h b/xorg-server/hw/xfree86/vgahw/vgaHW.h
index 937a8a507..63a10f42b 100644
--- a/xorg-server/hw/xfree86/vgahw/vgaHW.h
+++ b/xorg-server/hw/xfree86/vgahw/vgaHW.h
@@ -107,18 +107,18 @@ typedef void (*vgaHWMiscProcPtr) (vgaHWPtr hwp);
* via the first 17 attribute registers and not the main 8-bit palette.
*/
typedef struct _vgaHWRec {
- pointer Base; /* Address of "VGA" memory */
+ void *Base; /* Address of "VGA" memory */
int MapSize; /* Size of "VGA" memory */
unsigned long MapPhys; /* phys location of VGA mem */
int IOBase; /* I/O Base address */
CARD8 *MMIOBase; /* Pointer to MMIO start */
int MMIOOffset; /* base + offset + vgareg
= mmioreg */
- pointer FontInfo1; /* save area for fonts in
+ void *FontInfo1; /* save area for fonts in
plane 2 */
- pointer FontInfo2; /* save area for fonts in
+ void *FontInfo2; /* save area for fonts in
plane 3 */
- pointer TextInfo; /* save area for text */
+ void *TextInfo; /* save area for text */
vgaRegRec SavedReg; /* saved registers */
vgaRegRec ModeReg; /* register settings for
current mode */
@@ -148,7 +148,7 @@ typedef struct _vgaHWRec {
vgaHWWriteProcPtr writeDacReadAddr;
vgaHWWriteProcPtr writeDacData;
vgaHWReadProcPtr readDacData;
- pointer ddc;
+ void *ddc;
struct pci_io_handle *io;
vgaHWReadProcPtr readEnable;
vgaHWWriteProcPtr writeEnable;
diff --git a/xorg-server/hw/xfree86/x86emu/ops.c b/xorg-server/hw/xfree86/x86emu/ops.c
index 76b83581f..8af1df47a 100644
--- a/xorg-server/hw/xfree86/x86emu/ops.c
+++ b/xorg-server/hw/xfree86/x86emu/ops.c
@@ -10189,8 +10189,8 @@ Handles opcode 0xe8
static void
x86emuOp_call_near_IMM(u8 X86EMU_UNUSED(op1))
{
- s16 ip16;
- s32 ip32;
+ s16 ip16 = 0;
+ s32 ip32 = 0;
START_OF_INSTR();
DECODE_PRINTF("CALL\t");
diff --git a/xorg-server/hw/xfree86/x86emu/x86emu/regs.h b/xorg-server/hw/xfree86/x86emu/x86emu/regs.h
index 2ecafa047..3a7456e4c 100644
--- a/xorg-server/hw/xfree86/x86emu/x86emu/regs.h
+++ b/xorg-server/hw/xfree86/x86emu/x86emu/regs.h
@@ -39,6 +39,8 @@
#ifndef __X86EMU_REGS_H
#define __X86EMU_REGS_H
+#include <X11/Xfuncproto.h>
+
/*---------------------- Macros and type definitions ----------------------*/
#ifdef PACK
@@ -337,7 +339,8 @@ extern "C" { /* Use "C" linkage when in C++ mode */
/* Function to log information at runtime */
- void printk(const char *fmt, ...);
+ void printk(const char *fmt, ...)
+ _X_ATTRIBUTE_PRINTF(1, 2);
#ifdef __cplusplus
} /* End of "C" linkage for C++ */
diff --git a/xorg-server/hw/xnest/Color.c b/xorg-server/hw/xnest/Color.c
index 7ef137d59..95c334308 100644
--- a/xorg-server/hw/xnest/Color.c
+++ b/xorg-server/hw/xnest/Color.c
@@ -137,7 +137,7 @@ xnestDestroyColormap(ColormapPtr pCmap)
(xnestWindow(pWin) != None && wColormap(pWin) == icws->cmapIDs[i])
static int
-xnestCountInstalledColormapWindows(WindowPtr pWin, pointer ptr)
+xnestCountInstalledColormapWindows(WindowPtr pWin, void *ptr)
{
xnestInstalledColormapWindows *icws = (xnestInstalledColormapWindows *) ptr;
int i;
@@ -152,7 +152,7 @@ xnestCountInstalledColormapWindows(WindowPtr pWin, pointer ptr)
}
static int
-xnestGetInstalledColormapWindows(WindowPtr pWin, pointer ptr)
+xnestGetInstalledColormapWindows(WindowPtr pWin, void *ptr)
{
xnestInstalledColormapWindows *icws = (xnestInstalledColormapWindows *) ptr;
int i;
@@ -198,12 +198,12 @@ xnestSetInstalledColormapWindows(ScreenPtr pScreen)
sizeof(Colormap));
icws.numCmapIDs = xnestListInstalledColormaps(pScreen, icws.cmapIDs);
icws.numWindows = 0;
- WalkTree(pScreen, xnestCountInstalledColormapWindows, (pointer) &icws);
+ WalkTree(pScreen, xnestCountInstalledColormapWindows, (void *) &icws);
if (icws.numWindows) {
icws.windows =
(Window *) malloc((icws.numWindows + 1) * sizeof(Window));
icws.index = 0;
- WalkTree(pScreen, xnestGetInstalledColormapWindows, (pointer) &icws);
+ WalkTree(pScreen, xnestGetInstalledColormapWindows, (void *) &icws);
icws.windows[icws.numWindows] = xnestDefaultWindows[pScreen->myNum];
numWindows = icws.numWindows + 1;
}
@@ -252,11 +252,11 @@ xnestSetInstalledColormapWindows(ScreenPtr pScreen)
visual = xnestVisualFromID(pScreen, wVisual(pWin));
if (visual == xnestDefaultVisual(pScreen))
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWin),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWin),
RT_COLORMAP, serverClient,
DixUseAccess);
else
- dixLookupResourceByType((pointer *) &pCmap,
+ dixLookupResourceByType((void **) &pCmap,
pScreen->defColormap, RT_COLORMAP,
serverClient, DixUseAccess);
@@ -309,7 +309,7 @@ xnestDirectInstallColormaps(ScreenPtr pScreen)
for (i = 0; i < n; i++) {
ColormapPtr pCmap;
- dixLookupResourceByType((pointer *) &pCmap, pCmapIDs[i], RT_COLORMAP,
+ dixLookupResourceByType((void **) &pCmap, pCmapIDs[i], RT_COLORMAP,
serverClient, DixInstallAccess);
if (pCmap)
XInstallColormap(xnestDisplay, xnestColormap(pCmap));
@@ -330,7 +330,7 @@ xnestDirectUninstallColormaps(ScreenPtr pScreen)
for (i = 0; i < n; i++) {
ColormapPtr pCmap;
- dixLookupResourceByType((pointer *) &pCmap, pCmapIDs[i], RT_COLORMAP,
+ dixLookupResourceByType((void **) &pCmap, pCmapIDs[i], RT_COLORMAP,
serverClient, DixUninstallAccess);
if (pCmap)
XUninstallColormap(xnestDisplay, xnestColormap(pCmap));
@@ -347,10 +347,10 @@ xnestInstallColormap(ColormapPtr pCmap)
/* Uninstall pInstalledMap. Notify all interested parties. */
if (pOldCmap != (ColormapPtr) None)
- WalkTree(pCmap->pScreen, TellLostMap, (pointer) &pOldCmap->mid);
+ WalkTree(pCmap->pScreen, TellLostMap, (void *) &pOldCmap->mid);
SetInstalledColormap(pCmap->pScreen, pCmap);
- WalkTree(pCmap->pScreen, TellGainedMap, (pointer) &pCmap->mid);
+ WalkTree(pCmap->pScreen, TellGainedMap, (void *) &pCmap->mid);
xnestSetInstalledColormapWindows(pCmap->pScreen);
xnestDirectInstallColormaps(pCmap->pScreen);
@@ -364,7 +364,7 @@ xnestUninstallColormap(ColormapPtr pCmap)
if (pCmap == pCurCmap) {
if (pCmap->mid != pCmap->pScreen->defColormap) {
- dixLookupResourceByType((pointer *) &pCurCmap,
+ dixLookupResourceByType((void **) &pCurCmap,
pCmap->pScreen->defColormap,
RT_COLORMAP,
serverClient, DixInstallAccess);
diff --git a/xorg-server/hw/xnest/Font.c b/xorg-server/hw/xnest/Font.c
index 1e95588ef..ffdfd2497 100644
--- a/xorg-server/hw/xnest/Font.c
+++ b/xorg-server/hw/xnest/Font.c
@@ -35,7 +35,7 @@ int xnestFontPrivateIndex;
Bool
xnestRealizeFont(ScreenPtr pScreen, FontPtr pFont)
{
- pointer priv;
+ void *priv;
Atom name_atom, value_atom;
int nprops;
FontPropPtr props;
@@ -64,7 +64,7 @@ xnestRealizeFont(ScreenPtr pScreen, FontPtr pFont)
if (!name)
return False;
- priv = (pointer) malloc(sizeof(xnestPrivFont));
+ priv = (void *) malloc(sizeof(xnestPrivFont));
FontSetPrivate(pFont, xnestFontPrivateIndex, priv);
xnestFontPriv(pFont)->font_struct = XLoadQueryFont(xnestDisplay, name);
diff --git a/xorg-server/hw/xnest/GC.c b/xorg-server/hw/xnest/GC.c
index cfaf71475..0ec60fcdc 100644
--- a/xorg-server/hw/xnest/GC.c
+++ b/xorg-server/hw/xnest/GC.c
@@ -188,7 +188,7 @@ xnestDestroyGC(GCPtr pGC)
}
void
-xnestChangeClip(GCPtr pGC, int type, pointer pValue, int nRects)
+xnestChangeClip(GCPtr pGC, int type, void *pValue, int nRects)
{
int i, size;
BoxPtr pBox;
@@ -225,7 +225,7 @@ xnestChangeClip(GCPtr pGC, int type, pointer pValue, int nRects)
* current pixmap contents.
*/
pGC->clientClip =
- (pointer) (*pGC->pScreen->BitmapToRegion) ((PixmapPtr) pValue);
+ (void *) (*pGC->pScreen->BitmapToRegion) ((PixmapPtr) pValue);
(*pGC->pScreen->DestroyPixmap) ((PixmapPtr) pValue);
pValue = pGC->clientClip;
type = CT_REGION;
@@ -269,7 +269,7 @@ xnestChangeClip(GCPtr pGC, int type, pointer pValue, int nRects)
* other parts of server can only deal with CT_NONE,
* CT_PIXMAP and CT_REGION client clips.
*/
- pGC->clientClip = (pointer) RegionFromRects(nRects,
+ pGC->clientClip = (void *) RegionFromRects(nRects,
(xRectangle *) pValue,
type);
free(pValue);
diff --git a/xorg-server/hw/xnest/GCOps.c b/xorg-server/hw/xnest/GCOps.c
index d00511d71..fa602314b 100644
--- a/xorg-server/hw/xnest/GCOps.c
+++ b/xorg-server/hw/xnest/GCOps.c
@@ -308,7 +308,7 @@ xnestImageText16(DrawablePtr pDrawable, GCPtr pGC, int x, int y, int count,
void
xnestImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, int x, int y,
unsigned int nGlyphs, CharInfoPtr * pCharInfo,
- pointer pGlyphBase)
+ void *pGlyphBase)
{
ErrorF("xnest warning: function xnestImageGlyphBlt not implemented\n");
}
@@ -316,7 +316,7 @@ xnestImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, int x, int y,
void
xnestPolyGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, int x, int y,
unsigned int nGlyphs, CharInfoPtr * pCharInfo,
- pointer pGlyphBase)
+ void *pGlyphBase)
{
ErrorF("xnest warning: function xnestPolyGlyphBlt not implemented\n");
}
diff --git a/xorg-server/hw/xnest/GCOps.h b/xorg-server/hw/xnest/GCOps.h
index b1cad110c..fd1f6bfc2 100644
--- a/xorg-server/hw/xnest/GCOps.h
+++ b/xorg-server/hw/xnest/GCOps.h
@@ -58,10 +58,10 @@ void xnestImageText16(DrawablePtr pDrawable, GCPtr pGC, int x, int y, int count,
unsigned short *string);
void xnestImageGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, int x, int y,
unsigned int nGlyphs, CharInfoPtr * pCharInfo,
- pointer pGlyphBase);
+ void *pGlyphBase);
void xnestPolyGlyphBlt(DrawablePtr pDrawable, GCPtr pGC, int x, int y,
unsigned int nGlyphs, CharInfoPtr * pCharInfo,
- pointer pGlyphBase);
+ void *pGlyphBase);
void xnestPushPixels(GCPtr pGC, PixmapPtr pBitmap, DrawablePtr pDrawable,
int width, int height, int x, int y);
diff --git a/xorg-server/hw/xnest/Handlers.c b/xorg-server/hw/xnest/Handlers.c
index 4605b90bd..05d559d8f 100644
--- a/xorg-server/hw/xnest/Handlers.c
+++ b/xorg-server/hw/xnest/Handlers.c
@@ -32,14 +32,14 @@ is" without express or implied warranty.
#include "Handlers.h"
void
-xnestBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadMask)
+xnestBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadMask)
{
xnestCollectExposures();
XFlush(xnestDisplay);
}
void
-xnestWakeupHandler(pointer blockData, int result, pointer pReadMask)
+xnestWakeupHandler(void *blockData, int result, void *pReadMask)
{
xnestCollectEvents();
}
diff --git a/xorg-server/hw/xnest/Handlers.h b/xorg-server/hw/xnest/Handlers.h
index 7160bdd13..d4ad6d254 100644
--- a/xorg-server/hw/xnest/Handlers.h
+++ b/xorg-server/hw/xnest/Handlers.h
@@ -15,8 +15,8 @@ is" without express or implied warranty.
#ifndef XNESTHANDLERS_H
#define XNESTHANDLERS_H
-void xnestBlockHandler(pointer blockData, OSTimePtr pTimeout,
- pointer pReadMask);
-void xnestWakeupHandler(pointer blockData, int result, pointer pReadMask);
+void xnestBlockHandler(void *blockData, OSTimePtr pTimeout,
+ void *pReadMask);
+void xnestWakeupHandler(void *blockData, int result, void *pReadMask);
#endif /* XNESTHANDLERS_H */
diff --git a/xorg-server/hw/xnest/Keyboard.c b/xorg-server/hw/xnest/Keyboard.c
index d013dc91e..2cf16246b 100644
--- a/xorg-server/hw/xnest/Keyboard.c
+++ b/xorg-server/hw/xnest/Keyboard.c
@@ -59,7 +59,7 @@ extern Status XkbGetControls(Display * /* dpy */ ,
DeviceIntPtr xnestKeyboardDevice = NULL;
void
-xnestBell(int volume, DeviceIntPtr pDev, pointer ctrl, int cls)
+xnestBell(int volume, DeviceIntPtr pDev, void *ctrl, int cls)
{
XBell(xnestDisplay, volume);
}
diff --git a/xorg-server/hw/xnest/Keyboard.h b/xorg-server/hw/xnest/Keyboard.h
index 45d56bc08..dc5eaa2de 100644
--- a/xorg-server/hw/xnest/Keyboard.h
+++ b/xorg-server/hw/xnest/Keyboard.h
@@ -20,7 +20,7 @@ is" without express or implied warranty.
extern DeviceIntPtr xnestKeyboardDevice;
-void xnestBell(int volume, DeviceIntPtr pDev, pointer ctrl, int cls);
+void xnestBell(int volume, DeviceIntPtr pDev, void *ctrl, int cls);
void xnestChangeKeyboardControl(DeviceIntPtr pDev, KeybdCtrl * ctrl);
int xnestKeyboardProc(DeviceIntPtr pDev, int onoff);
void xnestUpdateModifierState(unsigned int state);
diff --git a/xorg-server/hw/xnest/Pixmap.c b/xorg-server/hw/xnest/Pixmap.c
index 2902acd56..6514f3b31 100644
--- a/xorg-server/hw/xnest/Pixmap.c
+++ b/xorg-server/hw/xnest/Pixmap.c
@@ -80,7 +80,7 @@ xnestDestroyPixmap(PixmapPtr pPixmap)
Bool
xnestModifyPixmapHeader(PixmapPtr pPixmap, int width, int height, int depth,
- int bitsPerPixel, int devKind, pointer pPixData)
+ int bitsPerPixel, int devKind, void *pPixData)
{
if(!xnestPixmapPriv(pPixmap)->pixmap && width > 0 && height > 0) {
xnestPixmapPriv(pPixmap)->pixmap =
diff --git a/xorg-server/hw/xnest/Window.c b/xorg-server/hw/xnest/Window.c
index e2b21b58e..c33cbaa2b 100644
--- a/xorg-server/hw/xnest/Window.c
+++ b/xorg-server/hw/xnest/Window.c
@@ -42,7 +42,7 @@ is" without express or implied warranty.
DevPrivateKeyRec xnestWindowPrivateKeyRec;
static int
-xnestFindWindowMatch(WindowPtr pWin, pointer ptr)
+xnestFindWindowMatch(WindowPtr pWin, void *ptr)
{
xnestWindowMatch *wm = (xnestWindowMatch *) ptr;
@@ -64,7 +64,7 @@ xnestWindowPtr(Window window)
wm.window = window;
for (i = 0; i < xnestNumScreens; i++) {
- WalkTree(screenInfo.screens[i], xnestFindWindowMatch, (pointer) &wm);
+ WalkTree(screenInfo.screens[i], xnestFindWindowMatch, (void *) &wm);
if (wm.pWin)
break;
}
@@ -96,7 +96,7 @@ xnestCreateWindow(WindowPtr pWin)
xnestVisualFromID(pWin->drawable.pScreen, wVisual(pWin));
mask |= CWColormap;
if (pWin->optional->colormap) {
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWin),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWin),
RT_COLORMAP, serverClient,
DixUseAccess);
attributes.colormap = xnestColormap(pCmap);
@@ -109,7 +109,7 @@ xnestCreateWindow(WindowPtr pWin)
}
else { /* root windows have their own colormaps at creation time */
visual = xnestVisualFromID(pWin->drawable.pScreen, wVisual(pWin));
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWin),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWin),
RT_COLORMAP, serverClient, DixUseAccess);
mask |= CWColormap;
attributes.colormap = xnestColormap(pCmap);
@@ -331,7 +331,7 @@ xnestChangeWindowAttributes(WindowPtr pWin, unsigned long mask)
if (mask & CWColormap) {
ColormapPtr pCmap;
- dixLookupResourceByType((pointer *) &pCmap, wColormap(pWin),
+ dixLookupResourceByType((void **) &pCmap, wColormap(pWin),
RT_COLORMAP, serverClient, DixUseAccess);
attributes.colormap = xnestColormap(pCmap);
diff --git a/xorg-server/hw/xnest/XNGC.h b/xorg-server/hw/xnest/XNGC.h
index c7c25e426..e2f10fb9c 100644
--- a/xorg-server/hw/xnest/XNGC.h
+++ b/xorg-server/hw/xnest/XNGC.h
@@ -35,7 +35,7 @@ void xnestValidateGC(GCPtr pGC, unsigned long changes, DrawablePtr pDrawable);
void xnestChangeGC(GCPtr pGC, unsigned long mask);
void xnestCopyGC(GCPtr pGCSrc, unsigned long mask, GCPtr pGCDst);
void xnestDestroyGC(GCPtr pGC);
-void xnestChangeClip(GCPtr pGC, int type, pointer pValue, int nRects);
+void xnestChangeClip(GCPtr pGC, int type, void *pValue, int nRects);
void xnestDestroyClip(GCPtr pGC);
void xnestDestroyClipHelper(GCPtr pGC);
void xnestCopyClip(GCPtr pGCDst, GCPtr pGCSrc);
diff --git a/xorg-server/hw/xnest/XNPixmap.h b/xorg-server/hw/xnest/XNPixmap.h
index 5b2e796fe..b7b10e907 100644
--- a/xorg-server/hw/xnest/XNPixmap.h
+++ b/xorg-server/hw/xnest/XNPixmap.h
@@ -34,7 +34,7 @@ PixmapPtr xnestCreatePixmap(ScreenPtr pScreen, int width, int height,
int depth, unsigned usage_hint);
Bool xnestDestroyPixmap(PixmapPtr pPixmap);
Bool xnestModifyPixmapHeader(PixmapPtr pPixmap, int width, int height, int depth,
- int bitsPerPixel, int devKind, pointer pPixData);
+ int bitsPerPixel, int devKind, void *pPixData);
RegionPtr xnestPixmapToRegion(PixmapPtr pPixmap);
#endif /* XNESTPIXMAP_H */
diff --git a/xorg-server/hw/xquartz/applewm.c b/xorg-server/hw/xquartz/applewm.c
index aea0a45f2..4409d4bf6 100644
--- a/xorg-server/hw/xquartz/applewm.c
+++ b/xorg-server/hw/xquartz/applewm.c
@@ -83,9 +83,9 @@ static XID eventResource;
static unsigned int eventMask = 0;
static int
-WMFreeClient(pointer data, XID id);
+WMFreeClient(void *data, XID id);
static int
-WMFreeEvents(pointer data, XID id);
+WMFreeEvents(void *data, XID id);
static void
SNotifyEvent(xAppleWMNotifyEvent *from, xAppleWMNotifyEvent *to);
@@ -175,7 +175,7 @@ updateEventMask(WMEventPtr *pHead)
/*ARGSUSED*/
static int
-WMFreeClient(pointer data, XID id)
+WMFreeClient(void *data, XID id)
{
WMEventPtr pEvent;
WMEventPtr *pHead, pCur, pPrev;
@@ -183,7 +183,7 @@ WMFreeClient(pointer data, XID id)
pEvent = (WMEventPtr)data;
i = dixLookupResourceByType(
- (pointer *)&pHead, eventResource, EventType, serverClient,
+ (void **)&pHead, eventResource, EventType, serverClient,
DixReadAccess |
DixWriteAccess | DixDestroyAccess);
if (i == Success && pHead) {
@@ -198,13 +198,13 @@ WMFreeClient(pointer data, XID id)
}
updateEventMask(pHead);
}
- free((pointer)pEvent);
+ free((void *)pEvent);
return 1;
}
/*ARGSUSED*/
static int
-WMFreeEvents(pointer data, XID id)
+WMFreeEvents(void *data, XID id)
{
WMEventPtr *pHead, pCur, pNext;
@@ -212,9 +212,9 @@ WMFreeEvents(pointer data, XID id)
for (pCur = *pHead; pCur; pCur = pNext) {
pNext = pCur->next;
FreeResource(pCur->clientResource, ClientType);
- free((pointer)pCur);
+ free((void *)pCur);
}
- free((pointer)pHead);
+ free((void *)pHead);
eventMask = 0;
return 1;
}
@@ -229,7 +229,7 @@ ProcAppleWMSelectInput(register ClientPtr client)
REQUEST_SIZE_MATCH(xAppleWMSelectInputReq);
i =
- dixLookupResourceByType((pointer *)&pHead, eventResource, EventType,
+ dixLookupResourceByType((void **)&pHead, eventResource, EventType,
client,
DixWriteAccess);
if (stuff->mask != 0) {
@@ -257,7 +257,7 @@ ProcAppleWMSelectInput(register ClientPtr client)
*/
clientResource = FakeClientID(client->index);
pNewEvent->clientResource = clientResource;
- if (!AddResource(clientResource, ClientType, (pointer)pNewEvent))
+ if (!AddResource(clientResource, ClientType, (void *)pNewEvent))
return BadAlloc;
/*
* create a resource to contain a pointer to the list
@@ -268,7 +268,7 @@ ProcAppleWMSelectInput(register ClientPtr client)
if (i != Success || !pHead) {
pHead = (WMEventPtr *)malloc(sizeof(WMEventPtr));
if (!pHead ||
- !AddResource(eventResource, EventType, (pointer)pHead)) {
+ !AddResource(eventResource, EventType, (void *)pHead)) {
FreeResource(clientResource, RT_NONE);
return BadAlloc;
}
@@ -317,7 +317,7 @@ AppleWMSendEvent(int type, unsigned int mask, int which, int arg)
int i;
i =
- dixLookupResourceByType((pointer *)&pHead, eventResource, EventType,
+ dixLookupResourceByType((void **)&pHead, eventResource, EventType,
serverClient,
DixReadAccess);
if (i != Success || !pHead)
diff --git a/xorg-server/hw/xquartz/quartzCommon.h b/xorg-server/hw/xquartz/quartzCommon.h
index 813bc7713..308a3f173 100644
--- a/xorg-server/hw/xquartz/quartzCommon.h
+++ b/xorg-server/hw/xquartz/quartzCommon.h
@@ -47,8 +47,8 @@ extern int aquaMenuBarHeight;
extern const char *quartzOpenGLBundle;
void
-QuartzBlockHandler(pointer blockData, OSTimePtr pTimeout, pointer pReadmask);
+QuartzBlockHandler(void *blockData, OSTimePtr pTimeout, void *pReadmask);
void
-QuartzWakeupHandler(pointer blockData, int result, pointer pReadmask);
+QuartzWakeupHandler(void *blockData, int result, void *pReadmask);
#endif /* _QUARTZCOMMON_H */
diff --git a/xorg-server/hw/xquartz/xpr/dri.c b/xorg-server/hw/xquartz/xpr/dri.c
index adba69cca..014709b04 100644
--- a/xorg-server/hw/xquartz/xpr/dri.c
+++ b/xorg-server/hw/xquartz/xpr/dri.c
@@ -455,7 +455,7 @@ DRICreateSurface(ScreenPtr pScreen, Drawable id,
pDRIDrawablePriv->sid), pDRIDrawablePriv);
/* track this in case this window is destroyed */
- AddResource(id, DRIDrawablePrivResType, (pointer)pDrawable);
+ AddResource(id, DRIDrawablePrivResType, (void *)pDrawable);
/* Initialize shape */
DRIUpdateSurface(pDRIDrawablePriv, pDrawable);
@@ -529,7 +529,7 @@ DRIDestroySurface(ScreenPtr pScreen, Drawable id, DrawablePtr pDrawable,
* drops to <= 0, or the window/pixmap is destroyed.
*/
Bool
-DRIDrawablePrivDelete(pointer pResource, XID id)
+DRIDrawablePrivDelete(void *pResource, XID id)
{
DrawablePtr pDrawable = (DrawablePtr)pResource;
DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pDrawable->pScreen);
@@ -829,7 +829,7 @@ DRICreatePixmap(ScreenPtr pScreen, Drawable id,
dixSetPrivate(&pPix->devPrivates, DRIPixmapBufferPrivKey, shared);
- AddResource(id, DRIDrawablePrivResType, (pointer)pDrawable);
+ AddResource(id, DRIDrawablePrivResType, (void *)pDrawable);
return TRUE;
}
@@ -884,7 +884,7 @@ DRIFreePixmapImp(DrawablePtr pDrawable)
shm_unlink(shared->shmPath);
free(shared);
- dixSetPrivate(&pPix->devPrivates, DRIPixmapBufferPrivKey, (pointer)NULL);
+ dixSetPrivate(&pPix->devPrivates, DRIPixmapBufferPrivKey, (void *)NULL);
return TRUE;
}
diff --git a/xorg-server/hw/xquartz/xpr/dri.h b/xorg-server/hw/xquartz/xpr/dri.h
index 8717a5186..70cb8b6d6 100644
--- a/xorg-server/hw/xquartz/xpr/dri.h
+++ b/xorg-server/hw/xquartz/xpr/dri.h
@@ -99,7 +99,7 @@ DRIDestroySurface(ScreenPtr pScreen, Drawable id, DrawablePtr pDrawable,
void *data), void *notify_data);
extern Bool
-DRIDrawablePrivDelete(pointer pResource, XID id);
+DRIDrawablePrivDelete(void *pResource, XID id);
extern DRIWrappedFuncsRec *
DRIGetWrappedFuncs(ScreenPtr pScreen);
diff --git a/xorg-server/hw/xquartz/xpr/driWrap.c b/xorg-server/hw/xquartz/xpr/driWrap.c
index 5f9f3abd3..42282d52b 100644
--- a/xorg-server/hw/xquartz/xpr/driWrap.c
+++ b/xorg-server/hw/xquartz/xpr/driWrap.c
@@ -447,7 +447,7 @@ DRIImageText16(DrawablePtr dst, GCPtr pGC,
static void
DRIImageGlyphBlt(DrawablePtr dst, GCPtr pGC,
int x, int y, unsigned int nglyphInit,
- CharInfoPtr *ppciInit, pointer unused)
+ CharInfoPtr *ppciInit, void *unused)
{
DRISavedDrawableState saved;
@@ -465,7 +465,7 @@ DRIImageGlyphBlt(DrawablePtr dst, GCPtr pGC,
static void
DRIPolyGlyphBlt(DrawablePtr dst, GCPtr pGC,
int x, int y, unsigned int nglyph,
- CharInfoPtr *ppci, pointer pglyphBase)
+ CharInfoPtr *ppci, void *pglyphBase)
{
DRISavedDrawableState saved;
diff --git a/xorg-server/hw/xwin/glx/indirect.c b/xorg-server/hw/xwin/glx/indirect.c
index 495e366ca..32d227b31 100644
--- a/xorg-server/hw/xwin/glx/indirect.c
+++ b/xorg-server/hw/xwin/glx/indirect.c
@@ -886,7 +886,7 @@ glxWinCopyWindow(WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
GLWIN_TRACE_MSG("glxWinCopyWindow pWindow %p", pWindow);
- dixLookupResourceByType((pointer) &pGlxDraw, pWindow->drawable.id,
+ dixLookupResourceByType((void *) &pGlxDraw, pWindow->drawable.id,
__glXDrawableRes, NullClient, DixUnknownAccess);
/*
diff --git a/xorg-server/hw/xwin/win.h b/xorg-server/hw/xwin/win.h
index 1d3448a44..63a92f5e3 100644
--- a/xorg-server/hw/xwin/win.h
+++ b/xorg-server/hw/xwin/win.h
@@ -574,7 +574,7 @@ typedef struct {
#endif
typedef struct {
- pointer value;
+ void *value;
XID id;
} WindowIDPairRec, *WindowIDPairPtr;
@@ -738,7 +738,7 @@ void winSetAuthorization(void);
void
winBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadMask);
+ void *pTimeout, void *pReadMask);
#ifdef XWIN_NATIVEGDI
/*
@@ -1003,7 +1003,7 @@ winModifyPixmapHeaderNativeGDI(PixmapPtr pPixmap,
int iWidth, int iHeight,
int iDepth,
int iBitsPerPixel,
- int devKind, pointer pPixData);
+ int devKind, void *pPixData);
#endif
#ifdef XWIN_NATIVEGDI
@@ -1074,7 +1074,7 @@ Bool
void
winWakeupHandler(ScreenPtr pScreen,
- unsigned long ulResult, pointer pReadmask);
+ unsigned long ulResult, void *pReadmask);
/*
* winwindow.c
diff --git a/xorg-server/hw/xwin/winblock.c b/xorg-server/hw/xwin/winblock.c
index c3ef4becd..07e907828 100644
--- a/xorg-server/hw/xwin/winblock.c
+++ b/xorg-server/hw/xwin/winblock.c
@@ -37,7 +37,7 @@
/* See Porting Layer Definition - p. 6 */
void
winBlockHandler(ScreenPtr pScreen,
- pointer pTimeout, pointer pReadMask)
+ void *pTimeout, void *pReadMask)
{
#if defined(XWIN_CLIPBOARD) || defined(XWIN_MULTIWINDOW)
winScreenPriv(pScreen);
diff --git a/xorg-server/hw/xwin/wincmap.c b/xorg-server/hw/xwin/wincmap.c
index 283372a9f..4275265be 100644
--- a/xorg-server/hw/xwin/wincmap.c
+++ b/xorg-server/hw/xwin/wincmap.c
@@ -170,7 +170,7 @@ winUninstallColormap(ColormapPtr pmap)
/* Install the default cmap in place of the cmap to be uninstalled */
if (pmap->mid != pmap->pScreen->defColormap) {
- dixLookupResourceByType((pointer) &curpmap, pmap->pScreen->defColormap,
+ dixLookupResourceByType((void *) &curpmap, pmap->pScreen->defColormap,
RT_COLORMAP, NullClient, DixUnknownAccess);
(*pmap->pScreen->InstallColormap) (curpmap);
}
diff --git a/xorg-server/hw/xwin/winconfig.c b/xorg-server/hw/xwin/winconfig.c
index 11717a506..95b95bc73 100644
--- a/xorg-server/hw/xwin/winconfig.c
+++ b/xorg-server/hw/xwin/winconfig.c
@@ -106,7 +106,7 @@ winInfoRec g_winInfo = {
#ifdef XWIN_XF86CONFIG
serverLayoutRec g_winConfigLayout;
-static Bool ParseOptionValue(int scrnIndex, pointer options, OptionInfoPtr p);
+static Bool ParseOptionValue(int scrnIndex, void *options, OptionInfoPtr p);
static Bool configLayout(serverLayoutPtr, XF86ConfLayoutPtr, char *);
static Bool configImpliedLayout(serverLayoutPtr, XF86ConfScreenPtr);
static Bool GetBoolValue(OptionInfoPtr p, const char *s);
@@ -187,7 +187,7 @@ winReadConfigfile()
/* Check if layout is given in the config file */
if (g_xf86configptr->conf_flags != NULL) {
char *dfltlayout = NULL;
- pointer optlist = g_xf86configptr->conf_flags->flg_option_lst;
+ void *optlist = g_xf86configptr->conf_flags->flg_option_lst;
if (optlist && winFindOption(optlist, "defaultserverlayout"))
dfltlayout =
@@ -591,7 +591,7 @@ winConfigScreens(void)
#ifdef XWIN_XF86CONFIG
char *
-winSetStrOption(pointer optlist, const char *name, char *deflt)
+winSetStrOption(void *optlist, const char *name, char *deflt)
{
OptionInfoRec o;
@@ -606,7 +606,7 @@ winSetStrOption(pointer optlist, const char *name, char *deflt)
}
int
-winSetBoolOption(pointer optlist, const char *name, int deflt)
+winSetBoolOption(void *optlist, const char *name, int deflt)
{
OptionInfoRec o;
@@ -618,7 +618,7 @@ winSetBoolOption(pointer optlist, const char *name, int deflt)
}
int
-winSetIntOption(pointer optlist, const char *name, int deflt)
+winSetIntOption(void *optlist, const char *name, int deflt)
{
OptionInfoRec o;
@@ -630,7 +630,7 @@ winSetIntOption(pointer optlist, const char *name, int deflt)
}
double
-winSetRealOption(pointer optlist, const char *name, double deflt)
+winSetRealOption(void *optlist, const char *name, double deflt)
{
OptionInfoRec o;
@@ -642,7 +642,7 @@ winSetRealOption(pointer optlist, const char *name, double deflt)
}
double
-winSetPercentOption(pointer optlist, const char *name, double deflt)
+winSetPercentOption(void *optlist, const char *name, double deflt)
{
OptionInfoRec o;
@@ -737,7 +737,7 @@ winFindOptionValue(XF86OptionPtr list, const char *name)
*/
static Bool
-ParseOptionValue(int scrnIndex, pointer options, OptionInfoPtr p)
+ParseOptionValue(int scrnIndex, void *options, OptionInfoPtr p)
{
char *s, *end;
diff --git a/xorg-server/hw/xwin/winconfig.h b/xorg-server/hw/xwin/winconfig.h
index 94571ff71..798c779a6 100644
--- a/xorg-server/hw/xwin/winconfig.h
+++ b/xorg-server/hw/xwin/winconfig.h
@@ -58,15 +58,15 @@ typedef struct {
Bool inUse;
int videoRam;
int textClockFreq;
- pointer options;
+ void *options;
int screen; /* For multi-CRTC cards */
} GDevRec, *GDevPtr;
typedef struct {
char *identifier;
char *driver;
- pointer commonOptions;
- pointer extraOptions;
+ void *commonOptions;
+ void *extraOptions;
} IDevRec, *IDevPtr;
typedef struct {
@@ -81,19 +81,19 @@ typedef struct {
rgb whiteColour;
int defaultVisual;
char **modes;
- pointer options;
+ void *options;
} DispRec, *DispPtr;
typedef struct _confxvportrec {
char *identifier;
- pointer options;
+ void *options;
} confXvPortRec, *confXvPortPtr;
typedef struct _confxvadaptrec {
char *identifier;
int numports;
confXvPortPtr ports;
- pointer options;
+ void *options;
} confXvAdaptorRec, *confXvAdaptorPtr;
typedef struct _confscreenrec {
@@ -107,7 +107,7 @@ typedef struct _confscreenrec {
DispPtr displays;
int numxvadaptors;
confXvAdaptorPtr xvadaptors;
- pointer options;
+ void *options;
} confScreenRec, *confScreenPtr;
typedef enum {
@@ -142,7 +142,7 @@ typedef struct _serverlayoutrec {
screenLayoutPtr screens;
GDevPtr inactives;
IDevPtr inputs;
- pointer options;
+ void *options;
} serverLayoutRec, *serverLayoutPtr;
/*
@@ -233,11 +233,11 @@ typedef struct {
* Function prototypes
*/
-char *winSetStrOption(pointer optlist, const char *name, char *deflt);
-int winSetBoolOption(pointer optlist, const char *name, int deflt);
-int winSetIntOption(pointer optlist, const char *name, int deflt);
-double winSetRealOption(pointer optlist, const char *name, double deflt);
-double winSetPercentOption(pointer optlist, const char *name, double deflt);
+char *winSetStrOption(void *optlist, const char *name, char *deflt);
+int winSetBoolOption(void *optlist, const char *name, int deflt);
+int winSetIntOption(void *optlist, const char *name, int deflt);
+double winSetRealOption(void *optlist, const char *name, double deflt);
+double winSetPercentOption(void *optlist, const char *name, double deflt);
#ifdef XWIN_XF86CONFIG
XF86OptionPtr winFindOption(XF86OptionPtr list, const char *name);
diff --git a/xorg-server/hw/xwin/wingc.c b/xorg-server/hw/xwin/wingc.c
index aba398d0a..aba398d0a 100644..100755
--- a/xorg-server/hw/xwin/wingc.c
+++ b/xorg-server/hw/xwin/wingc.c
diff --git a/xorg-server/hw/xwin/winkeybd.c b/xorg-server/hw/xwin/winkeybd.c
index 54e1847d7..e74672529 100644
--- a/xorg-server/hw/xwin/winkeybd.c
+++ b/xorg-server/hw/xwin/winkeybd.c
@@ -51,7 +51,7 @@ static Bool g_winKeyState[NUM_KEYCODES];
*/
static void
- winKeybdBell(int iPercent, DeviceIntPtr pDeviceInt, pointer pCtrl, int iClass);
+ winKeybdBell(int iPercent, DeviceIntPtr pDeviceInt, void *pCtrl, int iClass);
static void
winKeybdCtrl(DeviceIntPtr pDevice, KeybdCtrl * pCtrl);
@@ -120,7 +120,7 @@ winTranslateKey(WPARAM wParam, LPARAM lParam)
/* Ring the keyboard bell (system speaker on PCs) */
static void
-winKeybdBell(int iPercent, DeviceIntPtr pDeviceInt, pointer pCtrl, int iClass)
+winKeybdBell(int iPercent, DeviceIntPtr pDeviceInt, void *pCtrl, int iClass)
{
/*
* We can't use Beep () here because it uses the PC speaker
diff --git a/xorg-server/hw/xwin/winmultiwindowwindow.c b/xorg-server/hw/xwin/winmultiwindowwindow.c
index 94956863b..2439ddb67 100644
--- a/xorg-server/hw/xwin/winmultiwindowwindow.c
+++ b/xorg-server/hw/xwin/winmultiwindowwindow.c
@@ -53,7 +53,7 @@ static void
winUpdateWindowsWindow(WindowPtr pWin);
static void
- winFindWindow(pointer value, XID id, pointer cdata);
+ winFindWindow(void *value, XID id, void *cdata);
static
void
@@ -728,7 +728,7 @@ winGetWindowID(WindowPtr pWin)
*/
static void
-winFindWindow(pointer value, XID id, pointer cdata)
+winFindWindow(void *value, XID id, void *cdata)
{
WindowIDPairPtr wi = (WindowIDPairPtr) cdata;
@@ -811,7 +811,7 @@ winMinimizeWindow(Window id)
winDebug("winMinimizeWindow\n");
- dixLookupResourceByType((pointer) &pWin, id, RT_WINDOW, NullClient,
+ dixLookupResourceByType((void *) &pWin, id, RT_WINDOW, NullClient,
DixUnknownAccess);
if (!pWin) {
ErrorF("%s: NULL pWin. Leaving\n", __FUNCTION__);
diff --git a/xorg-server/hw/xwin/winpfbdd.c b/xorg-server/hw/xwin/winpfbdd.c
index 12f3b172f..976eba9ad 100644
--- a/xorg-server/hw/xwin/winpfbdd.c
+++ b/xorg-server/hw/xwin/winpfbdd.c
@@ -306,7 +306,7 @@ winCloseScreenPrimaryDD(ScreenPtr pScreen)
pScreenInfo->pScreen = NULL;
/* Free the screen privates for this screen */
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
return fReturn;
}
diff --git a/xorg-server/hw/xwin/winpixmap.c b/xorg-server/hw/xwin/winpixmap.c
index 43c0c3c14..763d60e8c 100644
--- a/xorg-server/hw/xwin/winpixmap.c
+++ b/xorg-server/hw/xwin/winpixmap.c
@@ -170,7 +170,7 @@ Bool
winModifyPixmapHeaderNativeGDI(PixmapPtr pPixmap,
int iWidth, int iHeight,
int iDepth,
- int iBitsPerPixel, int devKind, pointer pPixData)
+ int iBitsPerPixel, int devKind, void *pPixData)
{
FatalError("winModifyPixmapHeaderNativeGDI ()\n");
return TRUE;
diff --git a/xorg-server/hw/xwin/winshaddd.c b/xorg-server/hw/xwin/winshaddd.c
index 5a117aace..59415515f 100644
--- a/xorg-server/hw/xwin/winshaddd.c
+++ b/xorg-server/hw/xwin/winshaddd.c
@@ -655,7 +655,7 @@ winCloseScreenShadowDD(ScreenPtr pScreen)
pScreenInfo->pScreen = NULL;
/* Free the screen privates for this screen */
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
return fReturn;
}
diff --git a/xorg-server/hw/xwin/winshadddnl.c b/xorg-server/hw/xwin/winshadddnl.c
index af13aba52..1ac1af06b 100644
--- a/xorg-server/hw/xwin/winshadddnl.c
+++ b/xorg-server/hw/xwin/winshadddnl.c
@@ -746,7 +746,7 @@ winCloseScreenShadowDDNL(ScreenPtr pScreen)
pScreenInfo->pScreen = NULL;
/* Free the screen privates for this screen */
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
return fReturn;
}
diff --git a/xorg-server/hw/xwin/winshadgdi.c b/xorg-server/hw/xwin/winshadgdi.c
index 9e981cea7..d2a357f8e 100644
--- a/xorg-server/hw/xwin/winshadgdi.c
+++ b/xorg-server/hw/xwin/winshadgdi.c
@@ -613,7 +613,7 @@ winCloseScreenShadowGDI(ScreenPtr pScreen)
pScreenInfo->pScreen = NULL;
/* Free the screen privates for this screen */
- free((pointer) pScreenPriv);
+ free((void *) pScreenPriv);
return fReturn;
}
diff --git a/xorg-server/hw/xwin/winwakeup.c b/xorg-server/hw/xwin/winwakeup.c
index 795221a1a..ebcb0fad9 100644
--- a/xorg-server/hw/xwin/winwakeup.c
+++ b/xorg-server/hw/xwin/winwakeup.c
@@ -39,7 +39,7 @@
/* See Porting Layer Definition - p. 7 */
void
winWakeupHandler(ScreenPtr pScreen,
- unsigned long ulResult, pointer pReadmask)
+ unsigned long ulResult, void *pReadmask)
{
MSG msg;
diff --git a/xorg-server/hw/xwin/winwindow.c b/xorg-server/hw/xwin/winwindow.c
index e3bac41d9..c67a1a610 100644
--- a/xorg-server/hw/xwin/winwindow.c
+++ b/xorg-server/hw/xwin/winwindow.c
@@ -39,7 +39,7 @@
*/
static int
- winAddRgn(WindowPtr pWindow, pointer data);
+ winAddRgn(WindowPtr pWindow, void *data);
static
void
@@ -417,7 +417,7 @@ winSetShapeRootless(WindowPtr pWin, int kind)
static
int
-winAddRgn(WindowPtr pWin, pointer data)
+winAddRgn(WindowPtr pWin, void *data)
{
int iX, iY, iWidth, iHeight, iBorder;
HRGN hRgn = *(HRGN *) data;
diff --git a/xorg-server/hw/xwin/winwindowswm.c b/xorg-server/hw/xwin/winwindowswm.c
index 36f4ce0ae..c61f5b79e 100644..100755
--- a/xorg-server/hw/xwin/winwindowswm.c
+++ b/xorg-server/hw/xwin/winwindowswm.c
@@ -53,8 +53,8 @@ static XID eventResource;
/* Currently selected events */
static unsigned int eventMask = 0;
-static int WMFreeClient(pointer data, XID id);
-static int WMFreeEvents(pointer data, XID id);
+static int WMFreeClient(void *data, XID id);
+static int WMFreeEvents(void *data, XID id);
static void SNotifyEvent(xWindowsWMNotifyEvent * from,
xWindowsWMNotifyEvent * to);
@@ -99,13 +99,13 @@ updateEventMask(WMEventPtr * pHead)
}
/*ARGSUSED*/ static int
-WMFreeClient(pointer data, XID id)
+WMFreeClient(void *data, XID id)
{
WMEventPtr pEvent;
WMEventPtr *pHead, pCur, pPrev;
pEvent = (WMEventPtr) data;
- dixLookupResourceByType((pointer) &pHead, eventResource, eventResourceType,
+ dixLookupResourceByType((void *) &pHead, eventResource, eventResourceType,
NullClient, DixUnknownAccess);
if (pHead) {
pPrev = 0;
@@ -119,12 +119,12 @@ WMFreeClient(pointer data, XID id)
}
updateEventMask(pHead);
}
- free((pointer) pEvent);
+ free((void *) pEvent);
return 1;
}
/*ARGSUSED*/ static int
-WMFreeEvents(pointer data, XID id)
+WMFreeEvents(void *data, XID id)
{
WMEventPtr *pHead, pCur, pNext;
@@ -132,9 +132,9 @@ WMFreeEvents(pointer data, XID id)
for (pCur = *pHead; pCur; pCur = pNext) {
pNext = pCur->next;
FreeResource(pCur->clientResource, ClientType);
- free((pointer) pCur);
+ free((void *) pCur);
}
- free((pointer) pHead);
+ free((void *) pHead);
eventMask = 0;
return 1;
}
@@ -147,7 +147,7 @@ ProcWindowsWMSelectInput(ClientPtr client)
XID clientResource;
REQUEST_SIZE_MATCH(xWindowsWMSelectInputReq);
- dixLookupResourceByType((pointer) &pHead, eventResource, eventResourceType,
+ dixLookupResourceByType((void *) &pHead, eventResource, eventResourceType,
client, DixWriteAccess);
if (stuff->mask != 0) {
if (pHead) {
@@ -174,7 +174,7 @@ ProcWindowsWMSelectInput(ClientPtr client)
*/
clientResource = FakeClientID(client->index);
pNewEvent->clientResource = clientResource;
- if (!AddResource(clientResource, ClientType, (pointer) pNewEvent))
+ if (!AddResource(clientResource, ClientType, (void *) pNewEvent))
return BadAlloc;
/*
* create a resource to contain a pointer to the list
@@ -185,7 +185,7 @@ ProcWindowsWMSelectInput(ClientPtr client)
if (!pHead) {
pHead = (WMEventPtr *) malloc(sizeof(WMEventPtr));
if (!pHead ||
- !AddResource(eventResource, eventResourceType, (pointer) pHead))
+ !AddResource(eventResource, eventResourceType, (void *) pHead))
{
FreeResource(clientResource, RT_NONE);
return BadAlloc;
@@ -236,7 +236,7 @@ winWindowsWMSendEvent(int type, unsigned int mask, int which, int arg,
xWindowsWMNotifyEvent se;
winDebug ("winWindowsWMSendEvent %d %d %d %d, %d %d - %d %d\n",
type, mask, which, arg, x, y, w, h);
- dixLookupResourceByType((pointer) &pHead, eventResource, eventResourceType,
+ dixLookupResourceByType((void *) &pHead, eventResource, eventResourceType,
NullClient, DixUnknownAccess);
if (!pHead)
return;