From 1a88aed5c82c7c131e3d473ef7b8766a418fdf1b Mon Sep 17 00:00:00 2001 From: David Nusinow Date: Mon, 21 Jan 2008 21:16:13 -0500 Subject: [PATCH 01/12] Add tags/TAGS to .gitignore for ctags usage --- .gitignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitignore b/.gitignore index b52664bda..406b74c4e 100644 --- a/.gitignore +++ b/.gitignore @@ -27,6 +27,8 @@ install-sh libtool ltmain.sh missing +TAGS +tags ylwrap xorg-server.pc stamp-h? From 4fc2d3cef8d7868b025aa14af7ed4b730e8f2c49 Mon Sep 17 00:00:00 2001 From: Jeremy Huddleston Date: Mon, 28 Jan 2008 12:18:43 -0800 Subject: [PATCH 02/12] Rootless: RootlessEnsureFrame: Added check for !IsRoot This was causing an issue with Apple-DRI and was reported here: http://trac.macosforge.org/projects/xquartz/ticket/51 (cherry picked from commit 116800279d2ec783c63f43d3902627edde6a4cff) --- miext/rootless/rootlessWindow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/miext/rootless/rootlessWindow.c b/miext/rootless/rootlessWindow.c index b95339888..7285f959d 100644 --- a/miext/rootless/rootlessWindow.c +++ b/miext/rootless/rootlessWindow.c @@ -471,7 +471,7 @@ RootlessEnsureFrame(WindowPtr pWin) if (WINREC(pWin) != NULL) return WINREC(pWin); - if (!IsTopLevel(pWin)) + if (!IsTopLevel(pWin) && !IsRoot(pWin)) return NULL; if (pWin->drawable.class != InputOutput) From 2cb0ebec2b85d96289c23c17cfdcdf97ef6877d2 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Fri, 25 Jan 2008 11:48:13 +1030 Subject: [PATCH 03/12] config: add a debug message, fix a whitespace error. (cherry picked from commit 7732898aaa70e076000f6e6aa9420482896ed996) --- config/hal.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/config/hal.c b/config/hal.c index 4ab296159..52a011333 100644 --- a/config/hal.c +++ b/config/hal.c @@ -105,7 +105,7 @@ get_prop_string(LibHalContext *hal_ctx, const char *udi, const char *name) char *prop, *ret; prop = libhal_device_get_property_string(hal_ctx, udi, name, NULL); - DebugF(" [config/hal] getting %s on %s returned %s\n", name, udi, prop); + DebugF("[config/hal] getting %s on %s returned %s\n", name, udi, prop); if (prop) { ret = xstrdup(prop); libhal_free_string(prop); @@ -234,8 +234,9 @@ device_added(LibHalContext *hal_ctx, const char *udi) if (xkb_options) add_option(&options, "xkb_options", xkb_options); + DebugF("[config/hal] Adding device %s\n", name); if (NewInputDeviceRequest(options, &dev) != Success) { - DebugF("[config/hal] NewInputDeviceRequest failed\n"); + ErrorF("[config/hal] NewInputDeviceRequest failed\n"); dev = NULL; goto unwind; } From f0ba7707161b8866e6fde32d6f25be6afcdecb48 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Fri, 25 Jan 2008 13:45:22 +1030 Subject: [PATCH 04/12] config: only shutdown libhal if the connection is valid. Thanks to libdbus' extensive use of assert we won't just get an error, it'll bring the whole server down for us. (cherry picked from commit fb07fab2c07e7b0834724541dc47bfba02ba8574) --- config/hal.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/config/hal.c b/config/hal.c index 52a011333..1575422c3 100644 --- a/config/hal.c +++ b/config/hal.c @@ -283,12 +283,14 @@ disconnect_hook(void *data) struct config_hal_info *info = data; if (info->hal_ctx) { - dbus_error_init(&error); - if (!libhal_ctx_shutdown(info->hal_ctx, &error)) - DebugF("[config/hal] couldn't shut down context: %s (%s)\n", - error.name, error.message); + if (dbus_connection_get_is_connected(info->system_bus)) { + dbus_error_init(&error); + if (!libhal_ctx_shutdown(info->hal_ctx, &error)) + DebugF("[config/hal] couldn't shut down context: %s (%s)\n", + error.name, error.message); + dbus_error_free(&error); + } libhal_ctx_free(info->hal_ctx); - dbus_error_free(&error); } info->hal_ctx = NULL; From 7dde5a694a06efed0a9186f05d33f5be6f5dba71 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Fri, 25 Jan 2008 13:54:47 +1030 Subject: [PATCH 05/12] config: check connection != NULL before getting dbus' dispatch status. (cherry picked from commit d23266522390a4ef7203ae7c062b2b920e45f9d7) --- config/dbus-core.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/config/dbus-core.c b/config/dbus-core.c index 9cf153076..b349c6e3c 100644 --- a/config/dbus-core.c +++ b/config/dbus-core.c @@ -56,8 +56,9 @@ wakeup_handler(pointer data, int err, pointer read_mask) if (info->connection && FD_ISSET(info->fd, (fd_set *) read_mask)) { do { dbus_connection_read_write_dispatch(info->connection, 0); - } while (dbus_connection_get_dispatch_status(info->connection) == - DBUS_DISPATCH_DATA_REMAINS); + } while (info->connection && + dbus_connection_get_is_connected(info->connection) && + dbus_connection_get_dispatch_status(info->connection) == DBUS_DISPATCH_DATA_REMAINS); } } From 975ab11799c819a81da1dfe83505194410dbcb95 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Sat, 26 Jan 2008 09:39:54 +1030 Subject: [PATCH 06/12] config: don't reset connection info on disconnect. If dbus is restarted, we try to connect again and this is difficult if the busname and/or busobject is not set. (cherry picked from commit 210eeef495770c1883c842ff003c28ce25f279d4) --- config/dbus.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/config/dbus.c b/config/dbus.c index f6ac4c11c..0be42afb6 100644 --- a/config/dbus.c +++ b/config/dbus.c @@ -396,9 +396,6 @@ err_start: static void disconnect_hook(void *data) { - struct connection_info *info = data; - - reset_info(info); } #if 0 @@ -440,4 +437,6 @@ void config_dbus_fini(void) { config_dbus_core_remove_hook(&core_hook); + connection_data.busname[0] = '\0'; + connection_data.busobject[0] = '\0'; } From 5b8641a5fdc112c19e78ca2954878712e328d403 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Tue, 29 Jan 2008 10:01:37 +1030 Subject: [PATCH 07/12] xfree86: fix AlwaysCore handling. (Bug #14256) Assume AlwaysCore being set by default, just like the other options. X.Org Bug 14256 --- hw/xfree86/common/xf86Xinput.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/xfree86/common/xf86Xinput.c b/hw/xfree86/common/xf86Xinput.c index cd0c30ac1..9a94c0487 100644 --- a/hw/xfree86/common/xf86Xinput.c +++ b/hw/xfree86/common/xf86Xinput.c @@ -115,7 +115,7 @@ _X_EXPORT void xf86ProcessCommonOptions(LocalDevicePtr local, pointer list) { - if (xf86SetBoolOption(list, "AlwaysCore", 0) || + if (!xf86SetBoolOption(list, "AlwaysCore", 1) || !xf86SetBoolOption(list, "SendCoreEvents", 1) || !xf86SetBoolOption(list, "CorePointer", 1) || !xf86SetBoolOption(list, "CoreKeyboard", 1)) { From 442838fcb3bf07ac57553ae5600d9e6c59a559bb Mon Sep 17 00:00:00 2001 From: Julien Goodwin Date: Sun, 27 Jan 2008 12:27:26 +1100 Subject: [PATCH 08/12] xorg.conf.man: Fix monitor/output confusion in monitor positioning On the Intel driver at least, LeftOf/RightOf/Above/Below in xorg.conf refers to output names, not monitor names. Fix nomenclature in xorg.conf.man. --- hw/xfree86/doc/man/xorg.conf.man.pre | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/hw/xfree86/doc/man/xorg.conf.man.pre b/hw/xfree86/doc/man/xorg.conf.man.pre index 1369a16c9..608ba37ed 100644 --- a/hw/xfree86/doc/man/xorg.conf.man.pre +++ b/hw/xfree86/doc/man/xorg.conf.man.pre @@ -1432,24 +1432,24 @@ This optional entry specifies the position of the monitor within the X screen. (RandR 1.2-supporting drivers only) .TP 7 -.BI "Option " "\*qLeftOf\*q " \*qmonitor\*q +.BI "Option " "\*qLeftOf\*q " \*qoutput\*q This optional entry specifies that the monitor should be positioned to the -left of the monitor of the given name. +left of the output (not monitor) of the given name. (RandR 1.2-supporting drivers only) .TP 7 -.BI "Option " "\*qRightOf\*q " \*qmonitor\*q +.BI "Option " "\*qRightOf\*q " \*qoutput\*q This optional entry specifies that the monitor should be positioned to the -right of the monitor of the given name. +right of the output (not monitor) of the given name. (RandR 1.2-supporting drivers only) .TP 7 -.BI "Option " "\*qAbove\*q " \*qmonitor\*q +.BI "Option " "\*qAbove\*q " \*qoutput\*q This optional entry specifies that the monitor should be positioned above the -monitor of the given name. +output (not monitor) of the given name. (RandR 1.2-supporting drivers only) .TP 7 -.BI "Option " "\*qBelow\*q " \*qmonitor\*q +.BI "Option " "\*qBelow\*q " \*qoutput\*q This optional entry specifies that the monitor should be positioned below the -monitor of the given name. +output (not monitor) of the given name. (RandR 1.2-supporting drivers only) .TP 7 .BI "Option " "\*qEnable\*q " \*qbool\*q From 94f412cb7e954fe872fed979057cbdfbef953c6f Mon Sep 17 00:00:00 2001 From: Julien Goodwin Date: Sun, 27 Jan 2008 12:30:16 +1100 Subject: [PATCH 09/12] Loader: Fix verbosity confusion 'Loading foo' is verbosity 3, whereas 'already built-in' is verbosity 0. This means that gdm's log would just be full of bare 'module already built-in' messages. --- hw/xfree86/loader/loadmod.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/xfree86/loader/loadmod.c b/hw/xfree86/loader/loadmod.c index 584cabfd1..45e9cb374 100644 --- a/hw/xfree86/loader/loadmod.c +++ b/hw/xfree86/loader/loadmod.c @@ -864,7 +864,7 @@ doLoadModule(const char *module, const char *path, const char **subdirlist, for (cim = compiled_in_modules; *cim; cim++) if (!strcmp (module, *cim)) { - xf86MsgVerb(X_INFO, 0, "Module \"%s\" already built-in\n", module); + xf86MsgVerb(X_INFO, 3, "Module \"%s\" already built-in\n", module); return (ModuleDescPtr) 1; } From df325be394e1f75c396b2768f81373f2989aef7c Mon Sep 17 00:00:00 2001 From: Coleman Kane Date: Tue, 29 Jan 2008 09:47:00 -0800 Subject: [PATCH 10/12] Bug 13101: xorg-server has a typo in hw/xfree86/os-support/bsd/i386_video.c X.Org Bug #13101 Patch #12360 --- hw/xfree86/os-support/bsd/i386_video.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/xfree86/os-support/bsd/i386_video.c b/hw/xfree86/os-support/bsd/i386_video.c index 42b905483..0dcff6631 100644 --- a/hw/xfree86/os-support/bsd/i386_video.c +++ b/hw/xfree86/os-support/bsd/i386_video.c @@ -602,7 +602,7 @@ cleanMTRR() #ifdef DEBUG ErrorF("Clean for (0x%lx,0x%lx)\n", (unsigned long)mrd[i].mr_base, - (unsigned long)rd[i].mr_len); + (unsigned long)mrd[i].mr_len); #endif if (mrd[i].mr_flags & MDF_FIXACTIVE) { mro.mo_arg[0] = MEMRANGE_SET_UPDATE; From d954f9c80348de294602d931d387e5cd1ef4b9a5 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 30 Jan 2008 10:39:54 +1030 Subject: [PATCH 11/12] xkb: don't update LEDs if they don't exist. (Bug #13961) In some weird cases we call this function when there is no SrvLedInfo on the device. And it turns out null-pointer dereferences are bad. X.Org Bug 13961 --- xkb/xkbLEDs.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/xkb/xkbLEDs.c b/xkb/xkbLEDs.c index 2877af0c4..55ce12aad 100644 --- a/xkb/xkbLEDs.c +++ b/xkb/xkbLEDs.c @@ -63,6 +63,9 @@ XkbSrvLedInfoPtr sli; sli= XkbFindSrvLedInfo(dev,XkbDfltXIClass,XkbDfltXIId,0); + if (!sli) + return update; + if (state_changes&(XkbModifierStateMask|XkbGroupStateMask)) update|= sli->usesEffective; if (state_changes&(XkbModifierBaseMask|XkbGroupBaseMask)) From 1692dcf197470d074f69d5af1608cb2ff1d08872 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 30 Jan 2008 13:04:58 +1030 Subject: [PATCH 12/12] dix: print out event type if a bogus pointer event occurs. --- dix/events.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dix/events.c b/dix/events.c index 15aa16ed6..4a8e480c8 100644 --- a/dix/events.c +++ b/dix/events.c @@ -3312,7 +3312,7 @@ ProcessPointerEvent (xEvent *xE, DeviceIntPtr mouse, int count) deactivateGrab = TRUE; break; default: - FatalError("bogus pointer event from ddx"); + FatalError("bogus pointer event from ddx: %d", xE->u.u.type); } } else if (!CheckMotion(xE))