summaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
Diffstat (limited to 'hw')
-rw-r--r--hw/dmx/dmx-config.h2
-rw-r--r--hw/dmx/glxProxy/glxext.h2
-rw-r--r--hw/kdrive/Makefile.am12
-rw-r--r--hw/kdrive/ati/Makefile.am3
-rw-r--r--hw/kdrive/chips/Makefile.am3
-rw-r--r--hw/kdrive/ephyr/Makefile.am3
-rw-r--r--hw/kdrive/epson/Makefile.am3
-rw-r--r--hw/kdrive/fake/Makefile.am3
-rw-r--r--hw/kdrive/fbdev/Makefile.am3
-rw-r--r--hw/kdrive/i810/Makefile.am3
-rw-r--r--hw/kdrive/mach64/Makefile.am3
-rw-r--r--hw/kdrive/mga/Makefile.am3
-rw-r--r--hw/kdrive/neomagic/Makefile.am3
-rw-r--r--hw/kdrive/nvidia/Makefile.am3
-rw-r--r--hw/kdrive/pm2/Makefile.am3
-rw-r--r--hw/kdrive/r128/Makefile.am3
-rw-r--r--hw/kdrive/sdl/Makefile.am3
-rw-r--r--hw/kdrive/sis300/Makefile.am3
-rw-r--r--hw/kdrive/smi/Makefile.am3
-rw-r--r--hw/kdrive/vesa/Makefile.am3
-rw-r--r--hw/kdrive/via/Makefile.am3
-rw-r--r--hw/xfree86/common/xf86Config.c140
-rw-r--r--hw/xfree86/common/xf86Config.h19
-rw-r--r--hw/xfree86/common/xf86Privstr.h2
-rw-r--r--hw/xfree86/common/xf86Xinput.c44
-rw-r--r--hw/xfree86/common/xf86Xinput.h3
-rw-r--r--hw/xfree86/ddc/edid_modes.c361
-rw-r--r--hw/xfree86/dixmods/Makefile.am3
-rw-r--r--hw/xfree86/dixmods/afbmodule.c1
-rw-r--r--hw/xfree86/dixmods/cfb32module.c3
-rw-r--r--hw/xfree86/dixmods/cfbmodule.c3
-rw-r--r--hw/xfree86/doc/man/xorg.conf.man.pre19
-rw-r--r--hw/xfree86/dri/dri.c16
-rw-r--r--hw/xfree86/dri/dri.h13
-rw-r--r--hw/xfree86/modes/xf86Crtc.c22
-rw-r--r--hw/xfree86/modes/xf86Crtc.h4
-rw-r--r--hw/xfree86/modes/xf86EdidModes.c5
-rw-r--r--hw/xfree86/modes/xf86RandR12.c5
-rw-r--r--hw/xfree86/modes/xf86RandR12.h3
-rw-r--r--hw/xfree86/modes/xf86Rename.h9
-rw-r--r--hw/xfree86/modes/xf86Rotate.c64
-rw-r--r--hw/xfree86/os-support/bus/Pci.c14
-rw-r--r--hw/xfree86/os-support/bus/Pci.h2
-rw-r--r--hw/xfree86/parser/Module.c17
-rw-r--r--hw/xfree86/parser/xf86Parser.h2
-rw-r--r--hw/xfree86/parser/xf86tokens.h1
-rw-r--r--hw/xfree86/xaa/xaaWideLine.c4
-rw-r--r--hw/xgl/xglcompose.c2
-rw-r--r--hw/xwin/winmouse.c5
-rw-r--r--hw/xwin/winmultiwindowwm.c5
-rw-r--r--hw/xwin/winmultiwindowwndproc.c9
-rwxr-xr-xhw/xwin/winwin32rootlesswndproc.c5
-rw-r--r--hw/xwin/winwndproc.c5
53 files changed, 407 insertions, 473 deletions
diff --git a/hw/dmx/dmx-config.h b/hw/dmx/dmx-config.h
index 9647448dc..18a05356b 100644
--- a/hw/dmx/dmx-config.h
+++ b/hw/dmx/dmx-config.h
@@ -66,7 +66,7 @@
((year-2000) * 10000) + \
((month) * 100) + \
((day) * 1)
-#define VENDOR_RELEASE DMX_VENDOR_RELEASE(1,2,2004,6,30)
+#define VENDOR_RELEASE DMX_VENDOR_RELEASE(1,2,2007,4,24)
#define VENDOR_STRING "DMX Project"
/* Enable the DMX extension */
diff --git a/hw/dmx/glxProxy/glxext.h b/hw/dmx/glxProxy/glxext.h
index 8572aa43a..011393732 100644
--- a/hw/dmx/glxProxy/glxext.h
+++ b/hw/dmx/glxProxy/glxext.h
@@ -67,7 +67,7 @@ extern void __glXFreeGLXPixmap( __GLXpixmap *pGlxPixmap );
extern void __glXNoSuchRenderOpcode(GLbyte*);
extern int __glXNoSuchSingleOpcode(__GLXclientState*, GLbyte*);
-extern void __glXErrorCallBack(__GLinterface *gc, GLenum code);
+extern void __glXErrorCallBack(GLenum code);
extern void __glXClearErrorOccured(void);
extern GLboolean __glXErrorOccured(void);
extern void __glXResetLargeCommandStatus(__GLXclientState*);
diff --git a/hw/kdrive/Makefile.am b/hw/kdrive/Makefile.am
index e07804948..267d772e2 100644
--- a/hw/kdrive/Makefile.am
+++ b/hw/kdrive/Makefile.am
@@ -23,14 +23,20 @@ if KDRIVELINUX
LINUX_SUBDIRS = linux
endif
-SUBDIRS = \
- src \
- $(LINUX_SUBDIRS) \
+SERVER_SUBDIRS = \
$(XSDL_SUBDIRS) \
$(FBDEV_SUBDIRS) \
$(VESA_SUBDIRS) \
$(XEPHYR_SUBDIRS) \
$(XFAKE_SUBDIRS)
+SUBDIRS = \
+ src \
+ $(LINUX_SUBDIRS) \
+ $(SERVER_SUBDIRS)
+
DIST_SUBDIRS = vesa ati chips epson i810 mach64 mga neomagic nvidia pm2 r128 \
smi via fbdev sdl ephyr src linux fake sis300
+
+relink:
+ @for i in $(SERVER_SUBDIRS) ; do make -C $$i relink ; done
diff --git a/hw/kdrive/ati/Makefile.am b/hw/kdrive/ati/Makefile.am
index 76635fb52..61c1c844b 100644
--- a/hw/kdrive/ati/Makefile.am
+++ b/hw/kdrive/ati/Makefile.am
@@ -62,3 +62,6 @@ Xati_LDADD = \
$(ATI_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/chips/Makefile.am b/hw/kdrive/chips/Makefile.am
index 2f8a88da0..a0a10d715 100644
--- a/hw/kdrive/chips/Makefile.am
+++ b/hw/kdrive/chips/Makefile.am
@@ -24,3 +24,6 @@ Xchips_LDADD = \
$(CHIPS_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/ephyr/Makefile.am b/hw/kdrive/ephyr/Makefile.am
index c201fe9d6..1e820c097 100644
--- a/hw/kdrive/ephyr/Makefile.am
+++ b/hw/kdrive/ephyr/Makefile.am
@@ -29,3 +29,6 @@ Xephyr_LDADD = \
../../../exa/libexa.la \
@KDRIVE_LIBS@ \
@XEPHYR_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/epson/Makefile.am b/hw/kdrive/epson/Makefile.am
index a5bc70b02..d36230abe 100644
--- a/hw/kdrive/epson/Makefile.am
+++ b/hw/kdrive/epson/Makefile.am
@@ -24,3 +24,6 @@ Xepson_LDADD = \
$(EPSON_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/fake/Makefile.am b/hw/kdrive/fake/Makefile.am
index d7ebfc243..69fdf59d5 100644
--- a/hw/kdrive/fake/Makefile.am
+++ b/hw/kdrive/fake/Makefile.am
@@ -20,3 +20,6 @@ Xfake_LDADD = \
libfake.a \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/fbdev/Makefile.am b/hw/kdrive/fbdev/Makefile.am
index cb7180184..b7a863bf6 100644
--- a/hw/kdrive/fbdev/Makefile.am
+++ b/hw/kdrive/fbdev/Makefile.am
@@ -18,4 +18,7 @@ Xfbdev_LDADD = \
libfbdev.a \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
endif
diff --git a/hw/kdrive/i810/Makefile.am b/hw/kdrive/i810/Makefile.am
index 503958571..79093da60 100644
--- a/hw/kdrive/i810/Makefile.am
+++ b/hw/kdrive/i810/Makefile.am
@@ -27,3 +27,6 @@ Xi810_LDADD = \
$(I810_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/mach64/Makefile.am b/hw/kdrive/mach64/Makefile.am
index 67712e262..b4d9a4eef 100644
--- a/hw/kdrive/mach64/Makefile.am
+++ b/hw/kdrive/mach64/Makefile.am
@@ -31,3 +31,6 @@ Xmach64_LDADD = \
$(MACH64_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/mga/Makefile.am b/hw/kdrive/mga/Makefile.am
index ee0798915..db1a9563d 100644
--- a/hw/kdrive/mga/Makefile.am
+++ b/hw/kdrive/mga/Makefile.am
@@ -26,3 +26,6 @@ Xmga_LDADD = \
$(MGA_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/neomagic/Makefile.am b/hw/kdrive/neomagic/Makefile.am
index 9a1af990c..33bc3a911 100644
--- a/hw/kdrive/neomagic/Makefile.am
+++ b/hw/kdrive/neomagic/Makefile.am
@@ -38,3 +38,6 @@ Xneomagic_LDADD = \
$(NEOMAGIC_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/nvidia/Makefile.am b/hw/kdrive/nvidia/Makefile.am
index 67eff6961..79d2738a0 100644
--- a/hw/kdrive/nvidia/Makefile.am
+++ b/hw/kdrive/nvidia/Makefile.am
@@ -27,3 +27,6 @@ Xnvidia_LDADD = \
$(NVIDIA_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/pm2/Makefile.am b/hw/kdrive/pm2/Makefile.am
index a7b0f0088..ec70276c5 100644
--- a/hw/kdrive/pm2/Makefile.am
+++ b/hw/kdrive/pm2/Makefile.am
@@ -25,3 +25,6 @@ Xpm2_LDADD = \
$(PM2_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/r128/Makefile.am b/hw/kdrive/r128/Makefile.am
index eab80cce0..1ca1a605b 100644
--- a/hw/kdrive/r128/Makefile.am
+++ b/hw/kdrive/r128/Makefile.am
@@ -24,3 +24,6 @@ Xr128_LDADD = \
$(R128_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/sdl/Makefile.am b/hw/kdrive/sdl/Makefile.am
index f5abb86e8..fa09640d2 100644
--- a/hw/kdrive/sdl/Makefile.am
+++ b/hw/kdrive/sdl/Makefile.am
@@ -11,3 +11,6 @@ Xsdl_LDADD = @KDRIVE_PURE_LIBS@ \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@ \
@XSDL_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/sis300/Makefile.am b/hw/kdrive/sis300/Makefile.am
index 98020745c..62f3266e1 100644
--- a/hw/kdrive/sis300/Makefile.am
+++ b/hw/kdrive/sis300/Makefile.am
@@ -38,3 +38,6 @@ Xsis_LDADD = \
$(SIS_LIBS) \
@KDRIVE_LIBS@ \
$(TSLIB_FLAG)
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/smi/Makefile.am b/hw/kdrive/smi/Makefile.am
index 0fd9729fc..a6ac474b0 100644
--- a/hw/kdrive/smi/Makefile.am
+++ b/hw/kdrive/smi/Makefile.am
@@ -29,3 +29,6 @@ Xsmi_LDADD = \
$(SMI_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/vesa/Makefile.am b/hw/kdrive/vesa/Makefile.am
index 54a6f47ee..e062fe777 100644
--- a/hw/kdrive/vesa/Makefile.am
+++ b/hw/kdrive/vesa/Makefile.am
@@ -23,3 +23,6 @@ Xvesa_LDADD = \
libvesa.a \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/kdrive/via/Makefile.am b/hw/kdrive/via/Makefile.am
index 0ea88816a..1c5796963 100644
--- a/hw/kdrive/via/Makefile.am
+++ b/hw/kdrive/via/Makefile.am
@@ -25,3 +25,6 @@ Xvia_LDADD = \
$(VIA_LIBS) \
@KDRIVE_LIBS@ \
@XSERVER_LIBS@
+
+relink:
+ rm -f $(bin_PROGRAMS) && make $(bin_PROGRAMS)
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
index 0421bf94b..67e8af468 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
@@ -254,6 +254,7 @@ xf86ModulelistFromConfig(pointer **optlist)
char *ignore[] = { "GLcore", "speedo", "bitmap", "drm", NULL };
pointer *optarray;
XF86LoadPtr modp;
+ Bool found;
/*
* make sure the config file has been parsed and that we have a
@@ -266,35 +267,76 @@ xf86ModulelistFromConfig(pointer **optlist)
}
if (xf86configptr->conf_modules) {
- /*
- * Walk the list of modules in the "Module" section to determine how
- * many we have.
- */
- modp = xf86configptr->conf_modules->mod_load_lst;
- while (modp) {
- for (i = 0; ignore[i]; i++) {
- if (strcmp(modp->load_name, ignore[i]) == 0)
- modp->ignore = 1;
+ /* Walk the disable list and let people know what we've parsed to
+ * not be loaded
+ */
+ modp = xf86configptr->conf_modules->mod_disable_lst;
+ while (modp) {
+ xf86Msg(X_WARNING, "\"%s\" will not be loaded unless you've specified it to be loaded elsewhere.\n", modp->load_name);
+ modp = (XF86LoadPtr) modp->list.next;
+ }
+ /*
+ * Walk the default settings table. For each module listed to be
+ * loaded, make sure it's in the mod_load_lst. If it's not, make
+ * sure it's not in the mod_no_load_lst. If it's not disabled,
+ * append it to mod_load_lst
+ */
+ for (i=0 ; ModuleDefaults[i].name != NULL ; i++) {
+ if (ModuleDefaults[i].toLoad == FALSE) {
+ xf86Msg(X_WARNING, "\"%s\" is not to be loaded by default. Skipping.\n", ModuleDefaults[i].name);
+ continue;
}
- if (!modp->ignore)
- count++;
- modp = (XF86LoadPtr) modp->list.next;
- }
+ found = FALSE;
+ modp = xf86configptr->conf_modules->mod_load_lst;
+ while (modp) {
+ if (strcmp(modp->load_name, ModuleDefaults[i].name) == 0) {
+ xf86Msg(X_INFO, "\"%s\" will be loaded. This was enabled by default and also specified in the config file.\n", ModuleDefaults[i].name);
+ found = TRUE;
+ break;
+ }
+ modp = (XF86LoadPtr) modp->list.next;
+ }
+ if (found == FALSE) {
+ modp = xf86configptr->conf_modules->mod_disable_lst;
+ while (modp) {
+ if (strcmp(modp->load_name, ModuleDefaults[i].name) == 0) {
+ xf86Msg(X_INFO, "\"%s\" will be loaded even though the default is to disable it.\n", ModuleDefaults[i].name);
+ found = TRUE;
+ break;
+ }
+ modp = (XF86LoadPtr) modp->list.next;
+ }
+ }
+ if (found == FALSE) {
+ XF86ConfModulePtr ptr = xf86configptr->conf_modules;
+ ptr = xf86addNewLoadDirective(ptr, ModuleDefaults[i].name, XF86_LOAD_MODULE, ModuleDefaults[i].load_opt);
+ xf86Msg(X_INFO, "\"%s\" will be loaded by default.\n", ModuleDefaults[i].name);
+ }
+ }
} else {
xf86configptr->conf_modules = xnfcalloc(1, sizeof(XF86ConfModuleRec));
+ for (i=0 ; ModuleDefaults[i].name != NULL ; i++) {
+ if (ModuleDefaults[i].toLoad == TRUE) {
+ XF86ConfModulePtr ptr = xf86configptr->conf_modules;
+ ptr = xf86addNewLoadDirective(ptr, ModuleDefaults[i].name, XF86_LOAD_MODULE, ModuleDefaults[i].load_opt);
+ }
+ }
}
- if (count == 0) {
- XF86ConfModulePtr ptr = xf86configptr->conf_modules;
- ptr = xf86addNewLoadDirective(ptr, "extmod", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "dbe", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "glx", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "freetype", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "type1", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "record", XF86_LOAD_MODULE, NULL);
- ptr = xf86addNewLoadDirective(ptr, "dri", XF86_LOAD_MODULE, NULL);
- count = 7;
- }
+ /*
+ * Walk the list of modules in the "Module" section to determine how
+ * many we have.
+ */
+ modp = xf86configptr->conf_modules->mod_load_lst;
+ while (modp) {
+ for (i = 0; ignore[i]; i++) {
+ if (strcmp(modp->load_name, ignore[i]) == 0)
+ modp->ignore = 1;
+ }
+ if (!modp->ignore)
+ count++;
+ modp = (XF86LoadPtr) modp->list.next;
+ }
/*
* allocate the memory and walk the list again to fill in the pointers
@@ -303,22 +345,22 @@ xf86ModulelistFromConfig(pointer **optlist)
optarray = xnfalloc((count + 1) * sizeof(pointer));
count = 0;
if (xf86configptr->conf_modules) {
- modp = xf86configptr->conf_modules->mod_load_lst;
- while (modp) {
+ modp = xf86configptr->conf_modules->mod_load_lst;
+ while (modp) {
if (!modp->ignore) {
- modulearray[count] = modp->load_name;
- optarray[count] = modp->load_opt;
- count++;
+ modulearray[count] = modp->load_name;
+ optarray[count] = modp->load_opt;
+ count++;
}
- modp = (XF86LoadPtr) modp->list.next;
- }
+ modp = (XF86LoadPtr) modp->list.next;
+ }
}
modulearray[count] = NULL;
optarray[count] = NULL;
if (optlist)
- *optlist = optarray;
+ *optlist = optarray;
else
- xfree(optarray);
+ xfree(optarray);
return modulearray;
}
@@ -565,16 +607,24 @@ configFiles(XF86ConfFilesPtr fileconf)
char *log_buf;
/* FontPath */
-
/* Try XF86Config FontPath first */
if (!xf86fpFlag) {
if (fileconf) {
if (fileconf->file_fontpath) {
char *f = xf86ValidateFontPath(fileconf->file_fontpath);
pathFrom = X_CONFIG;
- if (*f)
- defaultFontPath = f;
- else {
+ if (*f) {
+ if (xf86Info.useDefaultFontPath) {
+ xf86Msg(X_WARNING, "Including the default font path %s.\n", defaultFontPath);
+ char *g = xnfalloc(strlen(defaultFontPath) + strlen(f) + 3);
+ strcpy(g, f);
+ strcat(g, ",");
+ defaultFontPath = strcat(g, defaultFontPath);
+ xfree(f);
+ } else {
+ defaultFontPath = f;
+ }
+ } else {
xf86Msg(X_WARNING,
"FontPath is completely invalid. Using compiled-in default.\n");
fontPath = NULL;
@@ -742,6 +792,7 @@ typedef enum {
FLAG_AIGLX,
FLAG_IGNORE_ABI,
FLAG_ALLOW_EMPTY_INPUT,
+ FLAG_USE_DEFAULT_FONT_PATH
} FlagValues;
static OptionInfoRec FlagOptions[] = {
@@ -817,6 +868,8 @@ static OptionInfoRec FlagOptions[] = {
{0}, FALSE },
{ FLAG_IGNORE_ABI, "IgnoreABI", OPTV_BOOLEAN,
{0}, FALSE },
+ { FLAG_USE_DEFAULT_FONT_PATH, "UseDefaultFontPath", OPTV_BOOLEAN,
+ {0}, FALSE },
{ -1, NULL, OPTV_NONE,
{0}, FALSE },
};
@@ -1016,6 +1069,13 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
if (xf86GetOptValBool(FlagOptions, FLAG_ALLOW_EMPTY_INPUT, &value))
xf86Info.allowEmptyInput = TRUE;
+ xf86Info.useDefaultFontPath = TRUE;
+ xf86Info.useDefaultFontPathFrom = X_DEFAULT;
+ if (xf86GetOptValBool(FlagOptions, FLAG_USE_DEFAULT_FONT_PATH, &value)) {
+ xf86Info.useDefaultFontPath = value;
+ xf86Info.useDefaultFontPathFrom = X_CONFIG;
+ }
+
/* Make sure that timers don't overflow CARD32's after multiplying */
#define MAX_TIME_IN_MIN (0x7fffffff / MILLI_PER_MIN)
@@ -1749,7 +1809,7 @@ configImpliedLayout(serverLayoutPtr servlayoutp, XF86ConfScreenPtr conf_screen)
indp = xnfalloc(sizeof(IDevRec));
indp->identifier = NULL;
servlayoutp->inputs = indp;
- if (!xf86Info.allowEmptyInput && checkCoreInputDevices(servlayoutp, TRUE))
+ if (!xf86Info.allowEmptyInput && !checkCoreInputDevices(servlayoutp, TRUE))
return FALSE;
return TRUE;
@@ -2451,9 +2511,9 @@ xf86HandleConfigFile(Bool autoconfig)
/* Now process everything else */
- if (!configFiles(xf86configptr->conf_files) ||
- !configServerFlags(xf86configptr->conf_flags,
+ if (!configServerFlags(xf86configptr->conf_flags,
xf86ConfigLayout.options) ||
+ !configFiles(xf86configptr->conf_files) ||
!configExtensions(xf86configptr->conf_extensions)
#ifdef XF86DRI
|| !configDRI(xf86configptr->conf_dri)
diff --git a/hw/xfree86/common/xf86Config.h b/hw/xfree86/common/xf86Config.h
index 3787ba21e..7fc161d49 100644
--- a/hw/xfree86/common/xf86Config.h
+++ b/hw/xfree86/common/xf86Config.h
@@ -33,6 +33,8 @@
#ifndef _xf86_config_h
#define _xf86_config_h
+#include "xf86Optrec.h"
+
#ifdef HAVE_PARSER_DECLS
/*
* global structure that holds the result of parsing the config file
@@ -46,6 +48,23 @@ typedef enum _ConfigStatus {
CONFIG_NOFILE
} ConfigStatus;
+typedef struct _ModuleDefault {
+ char *name;
+ Bool toLoad;
+ XF86OptionPtr load_opt;
+} ModuleDefault;
+
+static ModuleDefault ModuleDefaults[] = {
+ {.name = "extmod", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "dbe", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "glx", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "freetype", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "type1", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "record", .toLoad = TRUE, .load_opt=NULL},
+ {.name = "dri", .toLoad = TRUE, .load_opt=NULL},
+ {.name = NULL, .toLoad = FALSE, .load_opt=NULL}
+};
+
/*
* prototypes
*/
diff --git a/hw/xfree86/common/xf86Privstr.h b/hw/xfree86/common/xf86Privstr.h
index 659e566e0..7ca0669a5 100644
--- a/hw/xfree86/common/xf86Privstr.h
+++ b/hw/xfree86/common/xf86Privstr.h
@@ -120,6 +120,8 @@ typedef struct {
MessageType randRFrom;
Bool aiglx;
MessageType aiglxFrom;
+ Bool useDefaultFontPath;
+ MessageType useDefaultFontPathFrom;
Bool ignoreABI;
struct {
Bool disabled; /* enable/disable deactivating
diff --git a/hw/xfree86/common/xf86Xinput.c b/hw/xfree86/common/xf86Xinput.c
index 6ebb087cf..2d0a37674 100644
--- a/hw/xfree86/common/xf86Xinput.c
+++ b/hw/xfree86/common/xf86Xinput.c
@@ -764,4 +764,48 @@ xf86InitValuatorDefaults(DeviceIntPtr dev, int axnum)
}
}
+
+/**
+ * Deactivate a device. Call this function from the driver if you receive a
+ * read error or something else that spoils your day.
+ * Device will be moved to the off_devices list, but it will still be there
+ * until you really clean up after it.
+ * Notifies the client about an inactive device.
+ *
+ * @param panic True if device is unrecoverable and needs to be removed.
+ */
+_X_EXPORT void
+xf86DisableDevice(DeviceIntPtr dev, Bool panic)
+{
+ devicePresenceNotify ev;
+ DeviceIntRec dummyDev;
+
+ if(!panic)
+ {
+ DisableDevice(dev);
+ } else
+ {
+ ev.type = DevicePresenceNotify;
+ ev.time = currentTime.milliseconds;
+ ev.devchange = DeviceUnrecoverable;
+ ev.deviceid = dev->id;
+ dummyDev.id = 0;
+ SendEventToAllWindows(&dummyDev, DevicePresenceNotifyMask,
+ (xEvent *) &ev, 1);
+
+ DeleteInputDeviceRequest(dev);
+ }
+}
+
+/**
+ * Reactivate a device. Call this function from the driver if you just found
+ * out that the read error wasn't quite that bad after all.
+ * Device will be re-activated, and an event sent to the client.
+ */
+_X_EXPORT void
+xf86EnableDevice(DeviceIntPtr dev)
+{
+ EnableDevice(dev);
+}
+
/* end of xf86Xinput.c */
diff --git a/hw/xfree86/common/xf86Xinput.h b/hw/xfree86/common/xf86Xinput.h
index b2bc8dec1..7ef28ed73 100644
--- a/hw/xfree86/common/xf86Xinput.h
+++ b/hw/xfree86/common/xf86Xinput.h
@@ -187,6 +187,8 @@ void xf86InitValuatorAxisStruct(DeviceIntPtr dev, int axnum, int minval,
void xf86InitValuatorDefaults(DeviceIntPtr dev, int axnum);
void xf86AddEnabledDevice(InputInfoPtr pInfo);
void xf86RemoveEnabledDevice(InputInfoPtr pInfo);
+void xf86DisableDevice(DeviceIntPtr dev, Bool panic);
+void xf86EnableDevice(DeviceIntPtr dev);
/* xf86Helper.c */
void xf86AddInputDriver(InputDriverPtr driver, pointer module, int flags);
@@ -204,6 +206,7 @@ int xf86GetMotionEvents(DeviceIntPtr dev, xTimecoord *buff,
void xf86CollectInputOptions(InputInfoPtr pInfo, const char **defaultOpts,
pointer extraOpts);
+
/* Legacy hatred */
#define SendCoreEvents 59
#define DontSendCoreEvents 60
diff --git a/hw/xfree86/ddc/edid_modes.c b/hw/xfree86/ddc/edid_modes.c
deleted file mode 100644
index 926bc8921..000000000
--- a/hw/xfree86/ddc/edid_modes.c
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * Copyright 2006 Luc Verhaegen.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sub license,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice (including the
- * next paragraph) shall be included in all copies or substantial portions
- * of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- */
-
-#ifdef HAVE_XORG_CONFIG_H
-#include <xorg-config.h>
-#endif
-
-#include "xf86.h"
-#include "xf86DDC.h"
-#include <X11/Xatom.h>
-#include "property.h"
-#include "propertyst.h"
-#include "xf86DDC.h"
-
-/*
- * TODO:
- * - for those with access to the VESA DMT standard; review please.
- */
-#define MODEPREFIX(name) NULL, NULL, name, 0,M_T_DRIVER
-#define MODESUFFIX 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,FALSE,FALSE,0,NULL,0,0.0,0.0
-
-DisplayModeRec DDCEstablishedModes[17] = {
- { MODEPREFIX("800x600"), 40000, 800, 840, 968, 1056, 0, 600, 601, 605, 628, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 800x600@60Hz */
- { MODEPREFIX("800x600"), 36000, 800, 824, 896, 1024, 0, 600, 601, 603, 625, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 800x600@56Hz */
- { MODEPREFIX("640x480"), 31500, 640, 656, 720, 840, 0, 480, 481, 484, 500, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 640x480@75Hz */
- { MODEPREFIX("640x480"), 31500, 640, 664, 704, 832, 0, 480, 489, 491, 520, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 640x480@72Hz */
- { MODEPREFIX("640x480"), 30240, 640, 704, 768, 864, 0, 480, 483, 486, 525, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 640x480@67Hz */
- { MODEPREFIX("640x480"), 25200, 640, 656, 752, 800, 0, 480, 490, 492, 525, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 640x480@60Hz */
- { MODEPREFIX("720x400"), 35500, 720, 738, 846, 900, 0, 400, 421, 423, 449, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 720x400@88Hz */
- { MODEPREFIX("720x400"), 28320, 720, 738, 846, 900, 0, 400, 412, 414, 449, 0, V_NHSYNC | V_PVSYNC, MODESUFFIX }, /* 720x400@70Hz */
- { MODEPREFIX("1280x1024"), 135000, 1280, 1296, 1440, 1688, 0, 1024, 1025, 1028, 1066, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 1280x1024@75Hz */
- { MODEPREFIX("1024x768"), 78800, 1024, 1040, 1136, 1312, 0, 768, 769, 772, 800, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 1024x768@75Hz */
- { MODEPREFIX("1024x768"), 75000, 1024, 1048, 1184, 1328, 0, 768, 771, 777, 806, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 1024x768@70Hz */
- { MODEPREFIX("1024x768"), 65000, 1024, 1048, 1184, 1344, 0, 768, 771, 777, 806, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 1024x768@60Hz */
- { MODEPREFIX("1024x768"), 44900, 1024, 1032, 1208, 1264, 0, 768, 768, 776, 817, 0, V_PHSYNC | V_PVSYNC | V_INTERLACE, MODESUFFIX }, /* 1024x768@43Hz */
- { MODEPREFIX("832x624"), 57284, 832, 864, 928, 1152, 0, 624, 625, 628, 667, 0, V_NHSYNC | V_NVSYNC, MODESUFFIX }, /* 832x624@75Hz */
- { MODEPREFIX("800x600"), 49500, 800, 816, 896, 1056, 0, 600, 601, 604, 625, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 800x600@75Hz */
- { MODEPREFIX("800x600"), 50000, 800, 856, 976, 1040, 0, 600, 637, 643, 666, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 800x600@72Hz */
- { MODEPREFIX("1152x864"), 108000, 1152, 1216, 1344, 1600, 0, 864, 865, 868, 900, 0, V_PHSYNC | V_PVSYNC, MODESUFFIX }, /* 1152x864@75Hz */
-};
-
-static DisplayModePtr
-DDCModesFromEstablished(int scrnIndex, struct established_timings *timing)
-{
- DisplayModePtr Modes = NULL, Mode = NULL;
- CARD32 bits = (timing->t1) | (timing->t2 << 8) |
- ((timing->t_manu & 0x80) << 9);
- int i;
-
- for (i = 0; i < 17; i++) {
- if (bits & (0x01 << i)) {
- Mode = xf86DuplicateMode(&DDCEstablishedModes[i]);
- Modes = xf86ModesAdd(Modes, Mode);
- }
- }
-
- return Modes;
-}
-
-/*
- *
- */
-static DisplayModePtr
-DDCModesFromStandardTiming(int scrnIndex, struct std_timings *timing)
-{
- DisplayModePtr Modes = NULL, Mode = NULL;
- int i;
-
- for (i = 0; i < STD_TIMINGS; i++) {
- if (timing[i].hsize && timing[i].vsize && timing[i].refresh) {
- Mode = xf86CVTMode(timing[i].hsize, timing[i].vsize,
- timing[i].refresh, FALSE, FALSE);
- Mode->type = M_T_DRIVER;
- Modes = xf86ModesAdd(Modes, Mode);
- }
- }
-
- return Modes;
-}
-
-/*
- *
- */
-static DisplayModePtr
-DDCModeFromDetailedTiming(int scrnIndex, struct detailed_timings *timing,
- int preferred)
-{
- DisplayModePtr Mode;
-
- /*
- * Refuse to create modes that are insufficiently large. 64 is a random
- * number, maybe the spec says something about what the minimum is. In
- * particular I see this frequently with _old_ EDID, 1.0 or so, so maybe
- * our parser is just being too aggresive there.
- */
- if (timing->h_active < 64 || timing->v_active < 64) {
- xf86DrvMsg(scrnIndex, X_INFO,
- "%s: Ignoring tiny %dx%d mode\n", __func__,
- timing->h_active, timing->v_active);
- return NULL;
- }
-
- /* We don't do stereo */
- if (timing->stereo) {
- xf86DrvMsg(scrnIndex, X_INFO,
- "%s: Ignoring: We don't handle stereo.\n", __func__);
- return NULL;
- }
-
- /* We only do seperate sync currently */
- if (timing->sync != 0x03) {
- xf86DrvMsg(scrnIndex, X_INFO,
- "%s: %dx%d Warning: We only handle seperate"
- " sync.\n", __func__, timing->h_active, timing->v_active);
- }
-
- Mode = xnfalloc(sizeof(DisplayModeRec));
- memset(Mode, 0, sizeof(DisplayModeRec));
-
- Mode->type = M_T_DRIVER;
- if (preferred)
- Mode->type |= M_T_PREFERRED;
-
- Mode->Clock = timing->clock / 1000.0;
-
- Mode->HDisplay = timing->h_active;
- Mode->HSyncStart = timing->h_active + timing->h_sync_off;
- Mode->HSyncEnd = Mode->HSyncStart + timing->h_sync_width;
- Mode->HTotal = timing->h_active + timing->h_blanking;
-
- Mode->VDisplay = timing->v_active;
- Mode->VSyncStart = timing->v_active + timing->v_sync_off;
- Mode->VSyncEnd = Mode->VSyncStart + timing->v_sync_width;
- Mode->VTotal = timing->v_active + timing->v_blanking;
-
- xf86SetModeDefaultName(Mode);
-
- /* We ignore h/v_size and h/v_border for now. */
-
- if (timing->interlaced)
- Mode->Flags |= V_INTERLACE;
-
- if (timing->misc & 0x02)
- Mode->Flags |= V_PHSYNC;
- else
- Mode->Flags |= V_NHSYNC;
-
- if (timing->misc & 0x01)
- Mode->Flags |= V_PVSYNC;
- else
- Mode->Flags |= V_NVSYNC;
-
- return Mode;
-}
-
-/*
- *
- */
-static void
-DDCGuessRangesFromModes(int scrnIndex, MonPtr Monitor, DisplayModePtr Modes)
-{
- DisplayModePtr Mode = Modes;
-
- if (!Monitor || !Modes)
- return;
-
- /* set up the ranges for scanning through the modes */
- Monitor->nHsync = 1;
- Monitor->hsync[0].lo = 1024.0;
- Monitor->hsync[0].hi = 0.0;
-
- Monitor->nVrefresh = 1;
- Monitor->vrefresh[0].lo = 1024.0;
- Monitor->vrefresh[0].hi = 0.0;
-
- while (Mode) {
- if (!Mode->HSync)
- Mode->HSync = ((float) Mode->Clock ) / ((float) Mode->HTotal);
-
- if (!Mode->VRefresh)
- Mode->VRefresh = (1000.0 * ((float) Mode->Clock)) /
- ((float) (Mode->HTotal * Mode->VTotal));
-
- if (Mode->HSync < Monitor->hsync[0].lo)
- Monitor->hsync[0].lo = Mode->HSync;
-
- if (Mode->HSync > Monitor->hsync[0].hi)
- Monitor->hsync[0].hi = Mode->HSync;
-
- if (Mode->VRefresh < Monitor->vrefresh[0].lo)
- Monitor->vrefresh[0].lo = Mode->VRefresh;
-
- if (Mode->VRefresh > Monitor->vrefresh[0].hi)
- Monitor->vrefresh[0].hi = Mode->VRefresh;
-
- Mode = Mode->next;
- }
-}
-
-DisplayModePtr
-xf86DDCGetModes(int scrnIndex, xf86MonPtr DDC)
-{
- int preferred, i;
- DisplayModePtr Modes = NULL, Mode;
-
- preferred = PREFERRED_TIMING_MODE(DDC->features.msc);
-
- /* Add established timings */
- Mode = DDCModesFromEstablished(scrnIndex, &DDC->timings1);
- Modes = xf86ModesAdd(Modes, Mode);
-
- /* Add standard timings */
- Mode = DDCModesFromStandardTiming(scrnIndex, DDC->timings2);
- Modes = xf86ModesAdd(Modes, Mode);
-
- for (i = 0; i < DET_TIMINGS; i++) {
- struct detailed_monitor_section *det_mon = &DDC->det_mon[i];
-
- switch (det_mon->type) {
- case DT:
- Mode = DDCModeFromDetailedTiming(scrnIndex,
- &det_mon->section.d_timings,
- preferred);
- preferred = 0;
- Modes = xf86ModesAdd(Modes, Mode);
- break;
- case DS_STD_TIMINGS:
- Mode = DDCModesFromStandardTiming(scrnIndex,
- det_mon->section.std_t);
- Modes = xf86ModesAdd(Modes, Mode);
- break;
- default:
- break;
- }
- }
-
- return Modes;
-}
-
-/*
- * Fill out MonPtr with xf86MonPtr information.
- */
-void
-xf86DDCMonitorSet(int scrnIndex, MonPtr Monitor, xf86MonPtr DDC)
-{
- DisplayModePtr Modes = NULL, Mode;
- int i, clock;
- Bool have_hsync = FALSE, have_vrefresh = FALSE;
-
- if (!Monitor || !DDC)
- return;
-
- Monitor->DDC = DDC;
-
- Monitor->widthmm = 10 * DDC->features.hsize;
- Monitor->heightmm = 10 * DDC->features.vsize;
-
- /* If this is a digital display, then we can use reduced blanking */
- if (DDC->features.input_type)
- Monitor->reducedblanking = TRUE;
- /* Allow the user to also enable this through config */
-
- Modes = xf86DDCGetModes(scrnIndex, DDC);
-
- /* Skip EDID ranges if they were specified in the config file */
- have_hsync = (Monitor->nHsync != 0);
- have_vrefresh = (Monitor->nVrefresh != 0);
-
- /* Go through the detailed monitor sections */
- for (i = 0; i < DET_TIMINGS; i++) {
- switch (DDC->det_mon[i].type) {
- case DS_RANGES:
- if (!have_hsync) {
- if (!Monitor->nHsync)
- xf86DrvMsg(scrnIndex, X_INFO,
- "Using EDID range info for horizontal sync\n");
- Monitor->hsync[Monitor->nHsync].lo =
- DDC->det_mon[i].section.ranges.min_h;
- Monitor->hsync[Monitor->nHsync].hi =
- DDC->det_mon[i].section.ranges.max_h;
- Monitor->nHsync++;
- } else {
- xf86DrvMsg(scrnIndex, X_INFO,
- "Using hsync ranges from config file\n");
- }
-
- if (!have_vrefresh) {
- if (!Monitor->nVrefresh)
- xf86DrvMsg(scrnIndex, X_INFO,
- "Using EDID range info for vertical refresh\n");
- Monitor->vrefresh[Monitor->nVrefresh].lo =
- DDC->det_mon[i].section.ranges.min_v;
- Monitor->vrefresh[Monitor->nVrefresh].hi =
- DDC->det_mon[i].section.ranges.max_v;
- Monitor->nVrefresh++;
- } else {
- xf86DrvMsg(scrnIndex, X_INFO,
- "Using vrefresh ranges from config file\n");
- }
-
- clock = DDC->det_mon[i].section.ranges.max_clock * 1000;
- if (clock > Monitor->maxPixClock)
- Monitor->maxPixClock = clock;
-
- break;
- default:
- break;
- }
- }
-
- if (Modes) {
- /* Print Modes */
- xf86DrvMsg(scrnIndex, X_INFO, "Printing DDC gathered Modelines:\n");
-
- Mode = Modes;
- while (Mode) {
- xf86PrintModeline(scrnIndex, Mode);
- Mode = Mode->next;
- }
-
- /* Do we still need ranges to be filled in? */
- if (!Monitor->nHsync || !Monitor->nVrefresh)
- DDCGuessRangesFromModes(scrnIndex, Monitor, Modes);
-
- /* look for last Mode */
- Mode = Modes;
-
- while (Mode->next)
- Mode = Mode->next;
-
- /* add to MonPtr */
- if (Monitor->Modes) {
- Monitor->Last->next = Modes;
- Modes->prev = Monitor->Last;
- Monitor->Last = Mode;
- } else {
- Monitor->Modes = Modes;
- Monitor->Last = Mode;
- }
- }
-}
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 1581019d1..06e6d4080 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -45,9 +45,6 @@ fontsmodule_LTLIBRARIES = libfreetype.la \
AM_CFLAGS = @XORG_CFLAGS@ @DIX_CFLAGS@
INCLUDES = @XORG_INCS@ \
- -I$(top_srcdir)/afb \
- -I$(top_srcdir)/cfb \
- -I$(top_srcdir)/mfb \
-I$(top_srcdir)/dbe \
-I$(top_srcdir)/hw/xfree86/loader \
-I$(top_srcdir)/miext/shadow \
diff --git a/hw/xfree86/dixmods/afbmodule.c b/hw/xfree86/dixmods/afbmodule.c
index ee8cf2037..b0aea6ddc 100644
--- a/hw/xfree86/dixmods/afbmodule.c
+++ b/hw/xfree86/dixmods/afbmodule.c
@@ -29,7 +29,6 @@
#endif
#include "xf86Module.h"
-#include "afb.h"
static MODULESETUPPROTO(afbSetup);
diff --git a/hw/xfree86/dixmods/cfb32module.c b/hw/xfree86/dixmods/cfb32module.c
index 1451594e5..23708e4c2 100644
--- a/hw/xfree86/dixmods/cfb32module.c
+++ b/hw/xfree86/dixmods/cfb32module.c
@@ -28,10 +28,7 @@
#include <xorg-config.h>
#endif
-#define PSZ 32
-
#include "xf86Module.h"
-#include "cfb.h"
static MODULESETUPPROTO(cfb32Setup);
diff --git a/hw/xfree86/dixmods/cfbmodule.c b/hw/xfree86/dixmods/cfbmodule.c
index 693fd6177..07074c158 100644
--- a/hw/xfree86/dixmods/cfbmodule.c
+++ b/hw/xfree86/dixmods/cfbmodule.c
@@ -28,10 +28,7 @@
#include <xorg-config.h>
#endif
-#define PSZ 8
-
#include "xf86Module.h"
-#include "cfb.h"
static MODULESETUPPROTO(cfbSetup);
diff --git a/hw/xfree86/doc/man/xorg.conf.man.pre b/hw/xfree86/doc/man/xorg.conf.man.pre
index 19315c024..f2cb5ef03 100644
--- a/hw/xfree86/doc/man/xorg.conf.man.pre
+++ b/hw/xfree86/doc/man/xorg.conf.man.pre
@@ -604,6 +604,11 @@ the builtin handler will be used.
.BI "Option \*qAIGLX\*q \*q" boolean \*q
enable or disable AIGLX. AIGLX is enabled by default.
.TP 7
+.BI "Option \*qUseDefaultFontPath\*q \*q" boolean \*q
+Include the default font path even if other paths are specified in
+xorg.conf. If enabled, other font paths are included as well. Enabled by
+default.
+.TP 7
.BI "Option \*qIgnoreABI\*q \*q" boolean \*q
Allow modules built for a different, potentially incompatible version of
the X server to load. Disabled by default.
@@ -639,6 +644,20 @@ Example: the Type 1 font rasteriser can be loaded with the following entry:
.B "Load \*qtype1\*q"
.RE
.RE
+.TP 7
+.BI "Disable \*q" modulename \*q
+This instructs the server to not load the module called
+.IR modulename .
+Some modules are loaded by default in the server, and this overrides that
+default. If a
+.B Load
+instruction is given for the same module, it overrides the
+.B Disable
+instruction and the module is loaded. The module name given should be the
+module's standard name, not the module file name. As with the
+.B Load
+instruction, the standard name is case-sensitive, and does not include the
+"lib" prefix, or the ".a", ".o", or ".so" suffixes.
.PP
The second form of entry is a
.BR SubSection,
diff --git a/hw/xfree86/dri/dri.c b/hw/xfree86/dri/dri.c
index 35da8a625..fae0b43fb 100644
--- a/hw/xfree86/dri/dri.c
+++ b/hw/xfree86/dri/dri.c
@@ -473,6 +473,9 @@ DRIScreenInit(ScreenPtr pScreen, DRIInfoPtr pDRIInfo, int *pDRMFD)
pDRIPriv->pLockRefCount = &pDRIEntPriv->lockRefCount;
pDRIPriv->pLockingContext = &pDRIEntPriv->lockingContext;
+ if (!pDRIEntPriv->keepFDOpen)
+ pDRIEntPriv->keepFDOpen = pDRIInfo->keepFDOpen;
+
pDRIEntPriv->refCount++;
return TRUE;
@@ -2207,6 +2210,19 @@ DRIGetContext(ScreenPtr pScreen)
return pDRIPriv->myContext;
}
+void
+DRIGetTexOffsetFuncs(ScreenPtr pScreen,
+ DRITexOffsetStartProcPtr *texOffsetStartFunc,
+ DRITexOffsetFinishProcPtr *texOffsetFinishFunc)
+{
+ DRIScreenPrivPtr pDRIPriv = DRI_SCREEN_PRIV(pScreen);
+
+ if (!pDRIPriv) return;
+
+ *texOffsetStartFunc = pDRIPriv->pDriverInfo->texOffsetStart;
+ *texOffsetFinishFunc = pDRIPriv->pDriverInfo->texOffsetFinish;
+}
+
/* This lets get at the unwrapped functions so that they can correctly
* call the lowerlevel functions, and choose whether they will be
* called at every level of recursion (eg in validatetree).
diff --git a/hw/xfree86/dri/dri.h b/hw/xfree86/dri/dri.h
index a21338a90..e49bb6fa0 100644
--- a/hw/xfree86/dri/dri.h
+++ b/hw/xfree86/dri/dri.h
@@ -107,9 +107,12 @@ typedef struct {
*/
#define DRIINFO_MAJOR_VERSION 5
-#define DRIINFO_MINOR_VERSION 2
+#define DRIINFO_MINOR_VERSION 3
#define DRIINFO_PATCH_VERSION 0
+typedef unsigned long long (*DRITexOffsetStartProcPtr)(PixmapPtr pPix);
+typedef void (*DRITexOffsetFinishProcPtr)(PixmapPtr pPix);
+
typedef struct {
/* driver call back functions
*
@@ -180,6 +183,10 @@ typedef struct {
/* New with DRI version 5.2.0 */
Bool allocSarea;
Bool keepFDOpen;
+
+ /* New with DRI version 5.3.0 */
+ DRITexOffsetStartProcPtr texOffsetStart;
+ DRITexOffsetFinishProcPtr texOffsetFinish;
} DRIInfoRec, *DRIInfoPtr;
@@ -358,7 +365,9 @@ extern void *DRIMasterSareaPointer(ScrnInfoPtr pScrn);
extern drm_handle_t DRIMasterSareaHandle(ScrnInfoPtr pScrn);
-
+extern void DRIGetTexOffsetFuncs(ScreenPtr pScreen,
+ DRITexOffsetStartProcPtr *texOffsetStartFunc,
+ DRITexOffsetFinishProcPtr *texOffsetFinishFunc);
#define _DRI_H_
diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index ad0f5ff4b..88c31af58 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -1723,8 +1723,26 @@ Bool
xf86SetDesiredModes (ScrnInfoPtr scrn)
{
xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
- int c;
+ int c, o;
+
+ /*
+ * Turn off everything so mode setting is done
+ * with hardware in a consistent state
+ */
+ for (o = 0; o < config->num_output; o++)
+ {
+ xf86OutputPtr output = config->output[o];
+ (*output->funcs->dpms)(output, DPMSModeOff);
+ }
+ for (c = 0; c < config->num_crtc; c++)
+ {
+ xf86CrtcPtr crtc = config->crtc[c];
+
+ crtc->funcs->dpms(crtc, DPMSModeOff);
+ memset(&crtc->mode, 0, sizeof(crtc->mode));
+ }
+
for (c = 0; c < config->num_crtc; c++)
{
xf86CrtcPtr crtc = config->crtc[c];
@@ -1903,7 +1921,9 @@ xf86SetSingleMode (ScrnInfoPtr pScrn, DisplayModePtr desired, Rotation rotation)
}
}
xf86DisableUnusedFunctions(pScrn);
+#if RANDR_12_INTERFACE
xf86RandR12TellChanged (pScrn->pScreen);
+#endif
return ok;
}
diff --git a/hw/xfree86/modes/xf86Crtc.h b/hw/xfree86/modes/xf86Crtc.h
index 0c019e0e6..2d6260030 100644
--- a/hw/xfree86/modes/xf86Crtc.h
+++ b/hw/xfree86/modes/xf86Crtc.h
@@ -562,6 +562,10 @@ typedef struct _xf86CrtcConfig {
OptionInfoPtr options;
Bool debug_modes;
+
+ /* wrap screen BlockHandler for rotation */
+ ScreenBlockHandlerProcPtr BlockHandler;
+
} xf86CrtcConfigRec, *xf86CrtcConfigPtr;
extern int xf86CrtcConfigPrivateIndex;
diff --git a/hw/xfree86/modes/xf86EdidModes.c b/hw/xfree86/modes/xf86EdidModes.c
index 18e42dd06..46cb6c41e 100644
--- a/hw/xfree86/modes/xf86EdidModes.c
+++ b/hw/xfree86/modes/xf86EdidModes.c
@@ -86,6 +86,11 @@ static Bool quirk_prefer_large_60 (int scrnIndex, xf86MonPtr DDC)
if (memcmp (DDC->vendor.name, "ACR", 4) == 0 &&
DDC->vendor.prod_id == 44358)
return TRUE;
+
+ /* Samsung SyncMaster 226BW */
+ if (memcmp (DDC->vendor.name, "SAM", 4) == 0 &&
+ DDC->vendor.prod_id == 638)
+ return TRUE;
return FALSE;
}
diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index 90de585f5..db912745f 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
@@ -337,6 +337,7 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
ScrnInfoPtr pScrn = XF86SCRNINFO(pScreen);
xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn);
WindowPtr pRoot = WindowTable[pScreen->myNum];
+ PixmapPtr pScrnPix = (*pScreen->GetScreenPixmap)(pScreen);
Bool ret = FALSE;
if (randrp->virtualX == -1 || randrp->virtualY == -1)
@@ -353,8 +354,8 @@ xf86RandR12ScreenSetSize (ScreenPtr pScreen,
ret = TRUE;
- pScreen->width = width;
- pScreen->height = height;
+ pScreen->width = pScrnPix->drawable.width = width;
+ pScreen->height = pScrnPix->drawable.height = height;
pScreen->mmWidth = mmWidth;
pScreen->mmHeight = mmHeight;
diff --git a/hw/xfree86/modes/xf86RandR12.h b/hw/xfree86/modes/xf86RandR12.h
index 0d3346a77..4fd855cf5 100644
--- a/hw/xfree86/modes/xf86RandR12.h
+++ b/hw/xfree86/modes/xf86RandR12.h
@@ -24,6 +24,9 @@
#define _XF86_RANDR_H_
#include <randrstr.h>
#include <X11/extensions/render.h>
+#if XF86_MODES_RENAME
+#include "xf86Rename.h"
+#endif
Bool xf86RandR12CreateScreenResources (ScreenPtr pScreen);
Bool xf86RandR12Init(ScreenPtr pScreen);
diff --git a/hw/xfree86/modes/xf86Rename.h b/hw/xfree86/modes/xf86Rename.h
index 9dcfef5da..b8c1d70ef 100644
--- a/hw/xfree86/modes/xf86Rename.h
+++ b/hw/xfree86/modes/xf86Rename.h
@@ -25,6 +25,12 @@
#include "local_xf86Rename.h"
+#define xf86_cursors_fini XF86NAME(xf86_cursors_fini)
+#define xf86_cursors_init XF86NAME(xf86_cursors_init)
+#define xf86_hide_cursors XF86NAME(xf86_hide_cursors)
+#define xf86_reload_cursors XF86NAME(xf86_reload_cursors)
+#define xf86_show_cursors XF86NAME(xf86_show_cursors)
+#define xf86ConnectorGetName XF86NAME(xf86ConnectorGetName)
#define xf86CrtcConfigInit XF86NAME(xf86CrtcConfigInit)
#define xf86CrtcConfigPrivateIndex XF86NAME(xf86CrtcConfigPrivateIndex)
#define xf86CrtcCreate XF86NAME(xf86CrtcCreate)
@@ -35,6 +41,7 @@
#define xf86CrtcSetMode XF86NAME(xf86CrtcSetMode)
#define xf86CrtcSetSizeRange XF86NAME(xf86CrtcSetSizeRange)
#define xf86CVTMode XF86NAME(xf86CVTMode)
+#define xf86DDCMonitorSet XF86NAME(xf86DDCMonitorSet)
#define xf86DisableUnusedFunctions XF86NAME(xf86DisableUnusedFunctions)
#define xf86DPMSSet XF86NAME(xf86DPMSSet)
#define xf86DuplicateMode XF86NAME(xf86DuplicateMode)
@@ -52,9 +59,11 @@
#define xf86OutputGetEDIDModes XF86NAME(xf86OutputGetEDIDModes)
#define xf86OutputRename XF86NAME(xf86OutputRename)
#define xf86OutputSetEDID XF86NAME(xf86OutputSetEDID)
+#define xf86OutputUseScreenMonitor XF86NAME(xf86OutputUseScreenMonitor)
#define xf86PrintModeline XF86NAME(xf86PrintModeline)
#define xf86ProbeOutputModes XF86NAME(xf86ProbeOutputModes)
#define xf86PruneInvalidModes XF86NAME(xf86PruneInvalidModes)
+#define xf86RotateCloseScreen XF86NAME(xf86RotateCloseScreen)
#define xf86SetModeCrtc XF86NAME(xf86SetModeCrtc)
#define xf86SetModeDefaultName XF86NAME(xf86SetModeDefaultName)
#define xf86SetScrnInfoModes XF86NAME(xf86SetScrnInfoModes)
diff --git a/hw/xfree86/modes/xf86Rotate.c b/hw/xfree86/modes/xf86Rotate.c
index e8fafd073..137993926 100644
--- a/hw/xfree86/modes/xf86Rotate.c
+++ b/hw/xfree86/modes/xf86Rotate.c
@@ -264,7 +264,7 @@ xf86RotatePrepare (ScreenPtr pScreen)
}
}
-static void
+static Bool
xf86RotateRedisplay(ScreenPtr pScreen)
{
ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
@@ -273,18 +273,28 @@ xf86RotateRedisplay(ScreenPtr pScreen)
RegionPtr region;
if (!damage)
- return;
+ return FALSE;
xf86RotatePrepare (pScreen);
region = DamageRegion(damage);
if (REGION_NOTEMPTY(pScreen, region))
{
- int c;
-
+ int c;
+ SourceValidateProcPtr SourceValidate;
+
+ /*
+ * SourceValidate is used by the software cursor code
+ * to pull the cursor off of the screen when reading
+ * bits from the frame buffer. Bypassing this function
+ * leaves the software cursor in place
+ */
+ SourceValidate = pScreen->SourceValidate;
+ pScreen->SourceValidate = NULL;
+
for (c = 0; c < xf86_config->num_crtc; c++)
{
xf86CrtcPtr crtc = xf86_config->crtc[c];
- if (crtc->rotation != RR_Rotate_0)
+ if (crtc->rotation != RR_Rotate_0 && crtc->enabled)
{
BoxRec box;
RegionRec crtc_damage;
@@ -304,21 +314,28 @@ xf86RotateRedisplay(ScreenPtr pScreen)
REGION_UNINIT (pScreen, &crtc_damage);
}
}
+ pScreen->SourceValidate = SourceValidate;
DamageEmpty(damage);
}
+ return TRUE;
}
static void
-xf86RotateBlockHandler(pointer data, OSTimePtr pTimeout, pointer pRead)
+xf86RotateBlockHandler(int screenNum, pointer blockData,
+ pointer pTimeout, pointer pReadmask)
{
- ScreenPtr pScreen = (ScreenPtr) data;
-
- xf86RotateRedisplay(pScreen);
-}
+ ScreenPtr pScreen = screenInfo.screens[screenNum];
+ ScrnInfoPtr pScrn = xf86Screens[screenNum];
+ xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(pScrn);
-static void
-xf86RotateWakeupHandler(pointer data, int i, pointer LastSelectMask)
-{
+ pScreen->BlockHandler = xf86_config->BlockHandler;
+ (*pScreen->BlockHandler) (screenNum, blockData, pTimeout, pReadmask);
+ if (xf86RotateRedisplay(pScreen))
+ {
+ /* Re-wrap if rotation is still happening */
+ xf86_config->BlockHandler = pScreen->BlockHandler;
+ pScreen->BlockHandler = xf86RotateBlockHandler;
+ }
}
static void
@@ -338,7 +355,8 @@ xf86RotateDestroy (xf86CrtcPtr crtc)
}
for (c = 0; c < xf86_config->num_crtc; c++)
- if (crtc->rotatedPixmap || crtc->rotatedData)
+ if (xf86_config->crtc[c]->rotatedPixmap ||
+ xf86_config->crtc[c]->rotatedData)
return;
/*
@@ -355,10 +373,6 @@ xf86RotateDestroy (xf86CrtcPtr crtc)
}
DamageDestroy (xf86_config->rotation_damage);
xf86_config->rotation_damage = NULL;
- /* Free block/wakeup handler */
- RemoveBlockAndWakeupHandlers (xf86RotateBlockHandler,
- xf86RotateWakeupHandler,
- (pointer) pScreen);
}
}
@@ -428,20 +442,12 @@ xf86CrtcRotate (xf86CrtcPtr crtc, DisplayModePtr mode, Rotation rotation)
if (!xf86_config->rotation_damage)
goto bail2;
- /* Assign block/wakeup handler */
- if (!RegisterBlockAndWakeupHandlers (xf86RotateBlockHandler,
- xf86RotateWakeupHandler,
- (pointer) pScreen))
- {
- goto bail3;
- }
+ /* Wrap block handler */
+ xf86_config->BlockHandler = pScreen->BlockHandler;
+ pScreen->BlockHandler = xf86RotateBlockHandler;
}
if (0)
{
-bail3:
- DamageDestroy (xf86_config->rotation_damage);
- xf86_config->rotation_damage = NULL;
-
bail2:
if (shadow || shadowData)
{
diff --git a/hw/xfree86/os-support/bus/Pci.c b/hw/xfree86/os-support/bus/Pci.c
index b80371d83..bc5e11fb8 100644
--- a/hw/xfree86/os-support/bus/Pci.c
+++ b/hw/xfree86/os-support/bus/Pci.c
@@ -232,14 +232,14 @@ _X_EXPORT int pciNumBuses = 0; /* Actual number of PCI buses */
int pciMaxBusNum = MAX_PCI_BUSES;
static Bool inProbe = FALSE;
-static pciConfigPtr pci_devp[MAX_PCI_DEVICES + 1] = {NULL, };
+static pciConfigPtr *pci_devp = NULL;
static int readPciBios( PCITAG Tag, CARD8* tmp, ADDRESS hostbase,
unsigned char * buf, int len, PciBiosType BiosType );
static int (*pciOSHandleBIOS)(PCITAG Tag, int basereg, unsigned char *buf, int len);
-int xf86MaxPciDevs = MAX_PCI_DEVICES;
+int xf86MaxPciDevs = 0;
/*
* Platform specific PCI function pointers.
@@ -272,6 +272,14 @@ pciInit()
if (pciNumBuses <= 0)
ARCH_PCI_OS_INIT();
#endif
+ if (xf86MaxPciDevs == 0) {
+ xf86Msg(X_WARNING,
+ "OS did not count PCI devices, guessing wildly\n");
+ xf86MaxPciDevs = MAX_PCI_DEVICES;
+ }
+ if (pci_devp)
+ xfree(pci_devp);
+ pci_devp = xnfcalloc(xf86MaxPciDevs + 1, sizeof(pciConfigPtr));
}
void pciSetOSBIOSPtr(int (*bios_fn)(PCITAG Tag, int basereg, unsigned char * buf, int len))
@@ -920,7 +928,7 @@ xf86scanpci(int flags)
* result in an endless recursion if platform/OS specific PCI
* bus probing code calls this function from with in it.
*/
- if (done || pci_devp[0])
+ if (done || pci_devp)
return pci_devp;
done = TRUE;
diff --git a/hw/xfree86/os-support/bus/Pci.h b/hw/xfree86/os-support/bus/Pci.h
index 7cc882d36..f0cb916da 100644
--- a/hw/xfree86/os-support/bus/Pci.h
+++ b/hw/xfree86/os-support/bus/Pci.h
@@ -327,7 +327,7 @@
# define INCLUDE_XF86_MAP_PCI_MEM
# define INCLUDE_XF86_NO_DOMAIN
# endif
-# if !defined(__FreeBSD__)
+# if !defined(__FreeBSD__) && !defined(linux)
# define ARCH_PCI_PCI_BRIDGE sparcPciPciBridge
# endif
#elif defined(__amd64__) || defined(__amd64)
diff --git a/hw/xfree86/parser/Module.c b/hw/xfree86/parser/Module.c
index 81eff18ae..2012ce6d2 100644
--- a/hw/xfree86/parser/Module.c
+++ b/hw/xfree86/parser/Module.c
@@ -76,6 +76,7 @@ static xf86ConfigSymTabRec ModuleTab[] =
{
{ENDSECTION, "endsection"},
{LOAD, "load"},
+ {DISABLE, "disable"},
{LOAD_DRIVER, "loaddriver"},
{SUBSECTION, "subsection"},
{-1, ""},
@@ -141,6 +142,13 @@ xf86parseModuleSection (void)
xf86addNewLoadDirective (ptr->mod_load_lst, val.str,
XF86_LOAD_MODULE, NULL);
break;
+ case DISABLE:
+ if (xf86getSubToken (&(ptr->mod_comment)) != STRING)
+ Error (QUOTE_MSG, "Disable");
+ ptr->mod_disable_lst =
+ xf86addNewLoadDirective (ptr->mod_disable_lst, val.str,
+ XF86_DISABLE_MODULE, NULL);
+ break;
case LOAD_DRIVER:
if (xf86getSubToken (&(ptr->mod_comment)) != STRING)
Error (QUOTE_MSG, "LoadDriver");
@@ -257,6 +265,15 @@ xf86freeModules (XF86ConfModulePtr ptr)
lptr = lptr->list.next;
xf86conffree (prev);
}
+ lptr = ptr->mod_disable_lst;
+ while (lptr)
+ {
+ TestFree (lptr->load_name);
+ TestFree (lptr->load_comment);
+ prev = lptr;
+ lptr = lptr->list.next;
+ xf86conffree (prev);
+ }
TestFree (ptr->mod_comment);
xf86conffree (ptr);
}
diff --git a/hw/xfree86/parser/xf86Parser.h b/hw/xfree86/parser/xf86Parser.h
index 89de97bbb..dc30823cc 100644
--- a/hw/xfree86/parser/xf86Parser.h
+++ b/hw/xfree86/parser/xf86Parser.h
@@ -82,6 +82,7 @@ XF86ConfFilesRec, *XF86ConfFilesPtr;
/* Values for load_type */
#define XF86_LOAD_MODULE 0
#define XF86_LOAD_DRIVER 1
+#define XF86_DISABLE_MODULE 2
typedef struct
{
@@ -97,6 +98,7 @@ XF86LoadRec, *XF86LoadPtr;
typedef struct
{
XF86LoadPtr mod_load_lst;
+ XF86LoadPtr mod_disable_lst;
char *mod_comment;
}
XF86ConfModuleRec, *XF86ConfModulePtr;
diff --git a/hw/xfree86/parser/xf86tokens.h b/hw/xfree86/parser/xf86tokens.h
index d5948dd5b..822bbb9b7 100644
--- a/hw/xfree86/parser/xf86tokens.h
+++ b/hw/xfree86/parser/xf86tokens.h
@@ -170,6 +170,7 @@ typedef enum {
/* Module tokens */
LOAD,
LOAD_DRIVER,
+ DISABLE,
/* Device tokens */
DRIVER,
diff --git a/hw/xfree86/xaa/xaaWideLine.c b/hw/xfree86/xaa/xaaWideLine.c
index 9479b0d7a..a684d6676 100644
--- a/hw/xfree86/xaa/xaaWideLine.c
+++ b/hw/xfree86/xaa/xaaWideLine.c
@@ -32,10 +32,6 @@ Original mi code written by Keith Packard.
#include "xaa.h"
#include "xaalocal.h"
-#ifdef ICEILTEMPDECL
-ICEILTEMPDECL
-#endif
-
#define DRAW_POINT(pScrn, x, y) \
if(hardClip) (*infoRec->SubsequentSolidFillRect)(pScrn, x, y, 1, 1); \
else XAAPointHelper(pScrn, x, y)
diff --git a/hw/xgl/xglcompose.c b/hw/xgl/xglcompose.c
index d2aead05b..34f7a0c43 100644
--- a/hw/xgl/xglcompose.c
+++ b/hw/xgl/xglcompose.c
@@ -177,7 +177,7 @@ xglCompositeGeneral (CARD8 op,
{
if (!pSrc->transform && pSrc->filter != PictFilterConvolution)
{
- if (pSrc->pDrawable && pSrc->repeat == RepeatNormal)
+ if (pSrc->pDrawable && pSrc->repeatType == RepeatNormal)
{
XGL_PIXMAP_PRIV ((PixmapPtr) pSrc->pDrawable);
diff --git a/hw/xwin/winmouse.c b/hw/xwin/winmouse.c
index f0092e9a8..1507dd34f 100644
--- a/hw/xwin/winmouse.c
+++ b/hw/xwin/winmouse.c
@@ -100,9 +100,10 @@ winMouseProc (DeviceIntPtr pDeviceInt, int iState)
InitPointerDeviceStruct (pDevice,
map,
lngMouseButtons + lngWheelEvents,
- miPointerGetMotionEvents,
+ GetMotionHistory,
winMouseCtrl,
- miPointerGetMotionBufferSize ());
+ GetMotionHistorySize(),
+ 2);
free(map);
#if defined(XFree86Server) && defined(XINPUT)
diff --git a/hw/xwin/winmultiwindowwm.c b/hw/xwin/winmultiwindowwm.c
index 1918e54d1..5401ecdee 100644
--- a/hw/xwin/winmultiwindowwm.c
+++ b/hw/xwin/winmultiwindowwm.c
@@ -445,10 +445,7 @@ GetWindowName (Display *pDisplay, Window iWin, char **ppName)
}
else
{
- XmbTextPropertyToTextList (pDisplay, &xtpName, &ppList, &nNum);
-
- /* */
- if (nNum && ppList && *ppList)
+ if (XmbTextPropertyToTextList (pDisplay, &xtpName, &ppList, &nNum) >= Success && nNum > 0 && *ppList)
{
*ppName = strdup (*ppList);
XFreeStringList (ppList);
diff --git a/hw/xwin/winmultiwindowwndproc.c b/hw/xwin/winmultiwindowwndproc.c
index 0df896dd3..0a7579b61 100644
--- a/hw/xwin/winmultiwindowwndproc.c
+++ b/hw/xwin/winmultiwindowwndproc.c
@@ -38,6 +38,7 @@
#include "winmultiwindowclass.h"
#include "winprefs.h"
#include "winmsg.h"
+#include "inputstr.h"
/*
* External global variables
@@ -444,7 +445,7 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
/* Avoid the BitBlt's if the PAINTSTRUCT is bogus */
if (ps.rcPaint.right==0 && ps.rcPaint.bottom==0 && ps.rcPaint.left==0 && ps.rcPaint.top==0)
{
- EndPaint (hwndScreen, &ps);
+ EndPaint (hwnd, &ps);
return 0;
}
@@ -474,7 +475,7 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
}
/* EndPaint frees the DC */
- EndPaint (hwndScreen, &ps);
+ EndPaint (hwnd, &ps);
return 0;
case WM_MOUSEMOVE:
@@ -494,8 +495,8 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
break;
/* Has the mouse pointer crossed screens? */
- if (s_pScreen != miPointerCurrentScreen ())
- miPointerSetNewScreen (s_pScreenInfo->dwScreen,
+ if (s_pScreen != miPointerGetScreen(inputInfo.pointer))
+ miPointerSetScreen (inputInfo.pointer, s_pScreenInfo->dwScreen,
ptMouse.x - s_pScreenInfo->dwXOffset,
ptMouse.y - s_pScreenInfo->dwYOffset);
diff --git a/hw/xwin/winwin32rootlesswndproc.c b/hw/xwin/winwin32rootlesswndproc.c
index ffa84938f..859aafd29 100755
--- a/hw/xwin/winwin32rootlesswndproc.c
+++ b/hw/xwin/winwin32rootlesswndproc.c
@@ -41,6 +41,7 @@
#include <X11/Xatom.h>
#include "winmultiwindowclass.h"
#include "winmsg.h"
+#include "inputstr.h"
/*
@@ -534,8 +535,8 @@ winMWExtWMWindowProc (HWND hwnd, UINT message,
break;
/* Has the mouse pointer crossed screens? */
- if (pScreen != miPointerCurrentScreen ())
- miPointerSetNewScreen (pScreenInfo->dwScreen,
+ if (pScreen != miPointerGetScreen(inputInfo.pointer))
+ miPointerSetScreen (inputInfo.pointer, pScreenInfo->dwScreen,
ptMouse.x - pScreenInfo->dwXOffset,
ptMouse.y - pScreenInfo->dwYOffset);
diff --git a/hw/xwin/winwndproc.c b/hw/xwin/winwndproc.c
index 2974c41ed..29ea81fc1 100644
--- a/hw/xwin/winwndproc.c
+++ b/hw/xwin/winwndproc.c
@@ -40,6 +40,7 @@
#include "winprefs.h"
#include "winconfig.h"
#include "winmsg.h"
+#include "inputstr.h"
#ifdef XKB
extern BOOL winCheckKeyPressed(WPARAM wParam, LPARAM lParam);
@@ -723,8 +724,8 @@ winWindowProc (HWND hwnd, UINT message,
break;
/* Has the mouse pointer crossed screens? */
- if (s_pScreen != miPointerCurrentScreen ())
- miPointerSetNewScreen (s_pScreenInfo->dwScreen,
+ if (s_pScreen != miPointerGetScreen(inputInfo.pointer))
+ miPointerSetScreen (inputInfo.pointer, s_pScreenInfo->dwScreen,
GET_X_LPARAM(lParam)-s_pScreenInfo->dwXOffset,
GET_Y_LPARAM(lParam)-s_pScreenInfo->dwYOffset);