xorg-server: Changes to 'ubuntu'
Xi/exevents.c | 93 +++---
Xi/xichangehierarchy.c | 9
configure.ac | 6
debian/changelog | 9
debian/patches/237_dix_save_touchpoint_last_coords_before_transform.patch | 80 ------
debian/patches/drm_device_keep_trying.patch | 62 ++--
debian/patches/randr-cleanup-provider-properly.patch | 133 ----------
debian/patches/series | 4
dix/devices.c | 6
dix/events.c | 43 ++-
dix/getevents.c | 61 ++--
dix/grabs.c | 5
dix/touch.c | 40 +--
hw/dmx/config/xdmxconfig.c | 3
hw/xfree86/common/xf86DGA.c | 10
hw/xfree86/common/xf86Events.c | 11
hw/xfree86/modes/xf86Crtc.c | 12
hw/xfree86/modes/xf86RandR12.c | 22 +
hw/xquartz/GL/capabilities.c | 4
include/input.h | 4
include/inputstr.h | 24 -
include/protocol-versions.h | 2
m4/xorg-tls.m4 | 2
mi/mieq.c | 6
os/strndup.c | 4
randr/randrstr.h | 8
randr/rrcrtc.c | 5
randr/rrprovider.c | 2
render/animcur.c | 3
xfixes/xfixes.c | 2
xkb/xkbAccessX.c | 30 +-
xkb/xkbUtils.c | 10
32 files changed, 303 insertions(+), 412 deletions(-)
New commits:
commit ed3c57a620861e12e2f568c1613e0f4c6b55b20e
Author: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Date: Mon Mar 11 19:43:38 2013 +0100
New upstream release.
* New upstream release.
* Drop patches applied upstream.
- 237_dix_save_touchpoint_last_coords_before_transform.patch
- randr-cleanup-provider-properly.patch
diff --git a/debian/changelog b/debian/changelog
index dd5a23e..956c364 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+xorg-server (2:1.13.3-0ubuntu1) UNRELEASED; urgency=low
+
+ * New upstream release.
+ * Drop patches applied upstream.
+ - 237_dix_save_touchpoint_last_coords_before_transform.patch
+ - randr-cleanup-provider-properly.patch
+
+ -- Maarten Lankhorst <maarten.lankhorst@ubuntu.com> Mon, 11 Mar 2013 19:30:46 +0100
+
xorg-server (2:1.13.2-0ubuntu3) raring; urgency=low
* Add drm_device_keep_trying.patch: When kernel reports drm device is
diff --git a/debian/patches/237_dix_save_touchpoint_last_coords_before_transform.patch b/debian/patches/237_dix_save_touchpoint_last_coords_before_transform.patch
deleted file mode 100644
index 84897d4..0000000
--- a/debian/patches/237_dix_save_touchpoint_last_coords_before_transform.patch
+++ /dev/null
@@ -1,80 +0,0 @@
-commit 3b9f1c701787965246638c1a6fd99fb2b6078114
-Author: Yuly Novikov <ynovikov@chromium.org>
-Date: Mon Nov 19 21:04:57 2012 -0500
-
- dix: Save touchpoint last coordinates before transform. #49347
-
- DDXTouchPointInfoRec.valuators used to store axis values after transform.
- This resulted in Coordinate Transformation Matrix
- being applied multiple times to the last coordinates,
- in the case when only pressure changes in the last touch event.
-
- Changed DDXTouchPointInfoRec.valuators to store values before transform.
-
- Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=49347
-
- Signed-off-by: Yuly Novikov <ynovikov@chromium.org>
- Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
- Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
-
-# 2012-12-21 - Backport patch to 1.13.0.902
-# Bryce Harrington <bryce@canonical.com>
-
-diff --git a/dix/getevents.c b/dix/getevents.c
-index 8b4379d..58abdba 100644
---- a/dix/getevents.c
-+++ b/dix/getevents.c
-@@ -1951,32 +1951,27 @@ GetTouchEvents(InternalEvent *events, DeviceIntPtr dev, uint32_t ddx_touchid,
- default:
- return 0;
- }
-- if (t->mode == XIDirectTouch && !(flags & TOUCH_CLIENT_ID)) {
-- if (!valuator_mask_isset(&mask, 0))
-- valuator_mask_set_double(&mask, 0,
-- valuator_mask_get_double(touchpoint.ti->
-- valuators, 0));
-- if (!valuator_mask_isset(&mask, 1))
-- valuator_mask_set_double(&mask, 1,
-- valuator_mask_get_double(touchpoint.ti->
-- valuators, 1));
-- }
-
- /* Get our screen event co-ordinates (root_x/root_y/event_x/event_y):
- * these come from the touchpoint in Absolute mode, or the sprite in
- * Relative. */
- if (t->mode == XIDirectTouch) {
-- transformAbsolute(dev, &mask);
--
- if (!(flags & TOUCH_CLIENT_ID)) {
-- for (i = 0; i < valuator_mask_size(&mask); i++) {
-+ for (i = 0; i < max(valuator_mask_size(&mask), 2); i++) {
- double val;
-
- if (valuator_mask_fetch_double(&mask, i, &val))
- valuator_mask_set_double(touchpoint.ti->valuators, i, val);
-+ /* If the device doesn't post new X and Y axis values,
-+ * use the last values posted.
-+ */
-+ else if (i < 2 &&
-+ valuator_mask_fetch_double(touchpoint.ti->valuators, i, &val))
-+ valuator_mask_set_double(&mask, i, val);
- }
- }
-
-+ transformAbsolute(dev, &mask);
- clipAbsolute(dev, &mask);
- }
- else {
-diff --git a/include/inputstr.h b/include/inputstr.h
-index 5a38924..bb0a779 100644
---- a/include/inputstr.h
-+++ b/include/inputstr.h
-@@ -331,7 +331,7 @@ typedef struct _DDXTouchPointInfo {
- uint32_t ddx_id; /* touch ID given by the DDX */
- Bool emulate_pointer;
-
-- ValuatorMask *valuators; /* last recorded axis values */
-+ ValuatorMask *valuators; /* last axis values as posted, pre-transform */
- } DDXTouchPointInfoRec;
-
- typedef struct _TouchClassRec {
diff --git a/debian/patches/drm_device_keep_trying.patch b/debian/patches/drm_device_keep_trying.patch
index 13b5f5d..e1809e0 100644
--- a/debian/patches/drm_device_keep_trying.patch
+++ b/debian/patches/drm_device_keep_trying.patch
@@ -16,8 +16,6 @@ Signed-off-by: Bryce Harrington <bryce@canonical.com>
hw/xfree86/os-support/linux/lnx_platform.c | 29 +++++++++++++++++++++++++---
1 file changed, 26 insertions(+), 3 deletions(-)
-diff --git a/hw/xfree86/os-support/linux/lnx_platform.c b/hw/xfree86/os-support/linux/lnx_platform.c
-index 76f5583..e26ef25 100644
--- a/hw/xfree86/os-support/linux/lnx_platform.c
+++ b/hw/xfree86/os-support/linux/lnx_platform.c
@@ -7,6 +7,7 @@
@@ -28,7 +26,7 @@ index 76f5583..e26ef25 100644
/* Linux platform device support */
#include "xf86_OSproc.h"
-@@ -23,6 +24,12 @@ get_drm_info(struct OdevAttributes *attribs, char *path)
+@@ -23,17 +24,40 @@
drmSetVersion sv;
char *buf;
int fd;
@@ -41,35 +39,37 @@ index 76f5583..e26ef25 100644
fd = open(path, O_RDWR, O_CLOEXEC);
if (fd == -1)
-@@ -32,9 +39,25 @@ get_drm_info(struct OdevAttributes *attribs, char *path)
- sv.drm_di_minor = 4;
- sv.drm_dd_major = -1; /* Don't care */
- sv.drm_dd_minor = -1; /* Don't care */
+ return FALSE;
+
+- sv.drm_di_major = 1;
+- sv.drm_di_minor = 4;
+- sv.drm_dd_major = -1; /* Don't care */
+- sv.drm_dd_minor = -1; /* Don't care */
- if (drmSetInterfaceVersion(fd, &sv)) {
- ErrorF("setversion 1.4 failed\n");
-- return FALSE;
-+ err = drmSetInterfaceVersion(fd, &sv);
-+ while (err && drm_wait_counter--) {
-+ if (drm_wait_counter % drm_wait_msg_time == 0) {
-+ if (err == -EACCES) {
-+ ErrorF("drm device access denied\n");
-+ } else if (err == -EAGAIN) {
-+ LogMessage(X_INFO, "get_drm_info: waiting on drm device\n");
-+ } else {
-+ ErrorF("drm device not ready (%d)\n", err);
-+ }
-+ }
-+ usleep(drm_wait_usleep);
-+ err = drmSetInterfaceVersion(fd, &sv);
-+ if (!err)
-+ ErrorF("drm setversion 1.4 succeeded after wait\n");
-+ }
-+ if (err) {
-+ ErrorF("setversion 1.4 failed\n");
-+ return FALSE;
++ while (1) {
++ sv.drm_di_major = 1;
++ sv.drm_di_minor = 4;
++ sv.drm_dd_major = -1; /* Don't care */
++ sv.drm_dd_minor = -1; /* Don't care */
++
++ err = drmSetInterfaceVersion(fd, &sv);
++ if (!err)
++ break;
++
++ if (err != -EACCESS) {
++ ErrorF("drmSetInterfaceVersion failed with %i(%s)\n", err, strerror(-err));
++ goto err;
++ }
++
++ err = drmSetMaster(fd);
++ if (!err)
++ /* retry */
++ continue;
++
++ ErrorF("drmSetMaster failed with %i(%s)\n", err, strerror(-err));
++err:
++ close(fd);
+ return FALSE;
}
- xf86_add_platform_device(attribs);
---
-1.7.9.5
-
diff --git a/debian/patches/randr-cleanup-provider-properly.patch b/debian/patches/randr-cleanup-provider-properly.patch
deleted file mode 100644
index 271108b..0000000
--- a/debian/patches/randr-cleanup-provider-properly.patch
+++ /dev/null
@@ -1,133 +0,0 @@
-From 9d9444a0796707eaa6a5635e78e2db6a4c04226e Mon Sep 17 00:00:00 2001
-From: Dave Airlie <airlied@redhat.com>
-Date: Wed, 9 Jan 2013 12:58:28 +1000
-Subject: [PATCH] randr: cleanup provider properly
-
-So in the cold plug server shutdown case, we reap the resources
-before we call CloseScreen handlers, so the config->randr_provider
-is a dangling pointer when the xf86CrtcCloseScreen handler is called,
-
-however in the hot screen unplug case, we can't rely on automatically
-reaped resources, so we need to clean up the provider in the xf86CrtcCloseScreen
-case.
-
-This patch provides a cleanup callback from the randr provider removal
-into the DDX so it can cleanup properly, this then gets called by the automatic
-code for cold plug, or if hot unplug it gets called explicitly.
-
-Fixes a number of random server crashes on shutdown
-Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=58174
-Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=891140
-
-Signed-off-by: Dave Airlie <airlied@redhat.com>
-Signed-off-by: Fedora X Ninjas <x@fedoraproject.org>
----
- hw/xfree86/modes/xf86Crtc.c | 12 ++----------
- hw/xfree86/modes/xf86RandR12.c | 22 ++++++++++++++++++++++
- randr/randrstr.h | 6 ++++++
- randr/rrprovider.c | 2 ++
- 4 files changed, 32 insertions(+), 10 deletions(-)
-
-diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
-index e527abc..1263dd7 100644
---- a/hw/xfree86/modes/xf86Crtc.c
-+++ b/hw/xfree86/modes/xf86Crtc.c
-@@ -743,16 +743,8 @@ xf86CrtcCloseScreen(ScreenPtr screen)
- }
- /* detach any providers */
- if (config->randr_provider) {
-- if (config->randr_provider->offload_sink) {
-- DetachOffloadGPU(screen);
-- config->randr_provider->offload_sink = NULL;
-- }
-- else if (config->randr_provider->output_source) {
-- DetachOutputGPU(screen);
-- config->randr_provider->output_source = NULL;
-- }
-- else if (screen->current_master)
-- DetachUnboundGPU(screen);
-+ RRProviderDestroy(config->randr_provider);
-+ config->randr_provider = NULL;
- }
- return TRUE;
- }
-diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
-index 3530abf..01fc9c5 100644
---- a/hw/xfree86/modes/xf86RandR12.c
-+++ b/hw/xfree86/modes/xf86RandR12.c
-@@ -1885,6 +1885,27 @@ xf86RandR13ConstrainCursorHarder(DeviceIntPtr dev, ScreenPtr screen, int mode, i
- }
- }
-
-+static void
-+xf86RandR14ProviderDestroy(ScreenPtr screen, RRProviderPtr provider)
-+{
-+ ScrnInfoPtr scrn = xf86ScreenToScrn(screen);
-+ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
-+
-+ if (config->randr_provider == provider) {
-+ if (config->randr_provider->offload_sink) {
-+ DetachOffloadGPU(screen);
-+ config->randr_provider->offload_sink = NULL;
-+ }
-+ else if (config->randr_provider->output_source) {
-+ DetachOutputGPU(screen);
-+ config->randr_provider->output_source = NULL;
-+ }
-+ else if (screen->current_master)
-+ DetachUnboundGPU(screen);
-+ }
-+ config->randr_provider = NULL;
-+}
-+
- static Bool
- xf86RandR12Init12(ScreenPtr pScreen)
- {
-@@ -1914,6 +1935,7 @@ xf86RandR12Init12(ScreenPtr pScreen)
- rp->rrProviderSetProperty = xf86RandR14ProviderSetProperty;
- rp->rrProviderGetProperty = xf86RandR14ProviderGetProperty;
- rp->rrCrtcSetScanoutPixmap = xf86CrtcSetScanoutPixmap;
-+ rp->rrProviderDestroy = xf86RandR14ProviderDestroy;
-
- pScrn->PointerMoved = xf86RandR12PointerMoved;
- pScrn->ChangeGamma = xf86RandR12ChangeGamma;
-diff --git a/randr/randrstr.h b/randr/randrstr.h
-index 212b0a9..55faaed 100644
---- a/randr/randrstr.h
-+++ b/randr/randrstr.h
-@@ -232,6 +232,9 @@ typedef Bool (*RRProviderSetOffloadSinkProcPtr)(ScreenPtr pScreen,
- RRProviderPtr offload_sink);
-
-
-+typedef void (*RRProviderDestroyProcPtr)(ScreenPtr pScreen,
-+ RRProviderPtr provider);
-+
- /* These are for 1.0 compatibility */
-
- typedef struct _rrRefresh {
-@@ -330,6 +333,9 @@ typedef struct _rrScrPriv {
- Bool discontiguous;
-
- RRProviderPtr provider;
-+
-+ RRProviderDestroyProcPtr rrProviderDestroy;
-+
- } rrScrPrivRec, *rrScrPrivPtr;
-
- extern _X_EXPORT DevPrivateKeyRec rrPrivKeyRec;
-diff --git a/randr/rrprovider.c b/randr/rrprovider.c
-index c4ed515..b321e62 100644
---- a/randr/rrprovider.c
-+++ b/randr/rrprovider.c
-@@ -389,6 +389,8 @@ RRProviderDestroyResource (pointer value, XID pid)
- {
- rrScrPriv(pScreen);
-
-+ if (pScrPriv->rrProviderDestroy)
-+ (*pScrPriv->rrProviderDestroy)(pScreen, provider);
- pScrPriv->provider = NULL;
- }
- free(provider);
---
-1.8.1
-
diff --git a/debian/patches/series b/debian/patches/series
index 97273f7..eaea7d4 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -34,9 +34,6 @@ drm_device_keep_trying.patch
111_armel-drv-fallbacks.patch
500_pointer_barrier_thresholds.diff
-## from upstream, drop when rebasing to a new version
-237_dix_save_touchpoint_last_coords_before_transform.patch
-
# hybrid graphics fixes for xserver 1.13
228_autobind_gpu.patch
@@ -48,5 +45,4 @@ xf86crtc-don-t-use-display-for-vx-vy-for-gpu-screens.patch
dix-allow-pixmap-dirty-helper-to-be-used-for-non-sha.patch
xserver-call-CSR-for-gpus.patch
xf86-actually-set-the-compat-output-in-the-failure-c.patch
-randr-cleanup-provider-properly.patch
autoconfig-fixup-tell-changed-so-randr-clients-can-t.patch
commit eec5eb2f09682718e69f42491181ade0b093f52d
Author: Matt Dew <marcoz@osource.org>
Date: Thu Mar 7 23:08:09 2013 -0700
Bump version to 1.13.3
diff --git a/configure.ac b/configure.ac
index bc4f22e..b28d8e3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,9 +26,9 @@ dnl
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.60)
-AC_INIT([xorg-server], 1.13.2.902, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2013-02-28"
-RELEASE_NAME="1.13.3-rc2"
+AC_INIT([xorg-server], 1.13.3, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2013-03-07"
+RELEASE_NAME="Golden Needle"
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
commit f7ac91301912d0d7ba4beba5e309e6cc8b435945
Author: Dave Airlie <airlied@redhat.com>
Date: Wed Jan 9 12:58:28 2013 +1000
randr: cleanup provider properly
So in the cold plug server shutdown case, we reap the resources
before we call CloseScreen handlers, so the config->randr_provider
is a dangling pointer when the xf86CrtcCloseScreen handler is called,
however in the hot screen unplug case, we can't rely on automatically
reaped resources, so we need to clean up the provider in the xf86CrtcCloseScreen
case.
This patch provides a cleanup callback from the randr provider removal
into the DDX so it can cleanup properly, this then gets called by the automatic
code for cold plug, or if hot unplug it gets called explicitly.
Fixes a number of random server crashes on shutdown
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=58174
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=891140
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
diff --git a/hw/xfree86/modes/xf86Crtc.c b/hw/xfree86/modes/xf86Crtc.c
index 13251cf..33f5a14 100644
--- a/hw/xfree86/modes/xf86Crtc.c
+++ b/hw/xfree86/modes/xf86Crtc.c
@@ -743,16 +743,8 @@ xf86CrtcCloseScreen(ScreenPtr screen)
}
/* detach any providers */
if (config->randr_provider) {
- if (config->randr_provider->offload_sink) {
- DetachOffloadGPU(screen);
- config->randr_provider->offload_sink = NULL;
- }
- else if (config->randr_provider->output_source) {
- DetachOutputGPU(screen);
- config->randr_provider->output_source = NULL;
- }
- else if (screen->current_master)
- DetachUnboundGPU(screen);
+ RRProviderDestroy(config->randr_provider);
+ config->randr_provider = NULL;
}
return TRUE;
}
diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index 3530abf..01fc9c5 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
@@ -1885,6 +1885,27 @@ xf86RandR13ConstrainCursorHarder(DeviceIntPtr dev, ScreenPtr screen, int mode, i
}
}
+static void
+xf86RandR14ProviderDestroy(ScreenPtr screen, RRProviderPtr provider)
+{
+ ScrnInfoPtr scrn = xf86ScreenToScrn(screen);
+ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn);
+
+ if (config->randr_provider == provider) {
+ if (config->randr_provider->offload_sink) {
+ DetachOffloadGPU(screen);
+ config->randr_provider->offload_sink = NULL;
+ }
+ else if (config->randr_provider->output_source) {
+ DetachOutputGPU(screen);
+ config->randr_provider->output_source = NULL;
+ }
+ else if (screen->current_master)
+ DetachUnboundGPU(screen);
+ }
+ config->randr_provider = NULL;
+}
+
static Bool
xf86RandR12Init12(ScreenPtr pScreen)
{
@@ -1914,6 +1935,7 @@ xf86RandR12Init12(ScreenPtr pScreen)
rp->rrProviderSetProperty = xf86RandR14ProviderSetProperty;
rp->rrProviderGetProperty = xf86RandR14ProviderGetProperty;
rp->rrCrtcSetScanoutPixmap = xf86CrtcSetScanoutPixmap;
+ rp->rrProviderDestroy = xf86RandR14ProviderDestroy;
pScrn->PointerMoved = xf86RandR12PointerMoved;
pScrn->ChangeGamma = xf86RandR12ChangeGamma;
diff --git a/randr/randrstr.h b/randr/randrstr.h
index 27aa101..70aaa3d 100644
--- a/randr/randrstr.h
+++ b/randr/randrstr.h
@@ -232,6 +232,9 @@ typedef Bool (*RRProviderSetOffloadSinkProcPtr)(ScreenPtr pScreen,
RRProviderPtr offload_sink);
+typedef void (*RRProviderDestroyProcPtr)(ScreenPtr pScreen,
+ RRProviderPtr provider);
+
/* These are for 1.0 compatibility */
typedef struct _rrRefresh {
@@ -330,6 +333,9 @@ typedef struct _rrScrPriv {
Bool discontiguous;
RRProviderPtr provider;
+
+ RRProviderDestroyProcPtr rrProviderDestroy;
+
} rrScrPrivRec, *rrScrPrivPtr;
extern _X_EXPORT DevPrivateKeyRec rrPrivKeyRec;
diff --git a/randr/rrprovider.c b/randr/rrprovider.c
index c4ed515..b321e62 100644
--- a/randr/rrprovider.c
+++ b/randr/rrprovider.c
@@ -389,6 +389,8 @@ RRProviderDestroyResource (pointer value, XID pid)
{
rrScrPriv(pScreen);
+ if (pScrPriv->rrProviderDestroy)
+ (*pScrPriv->rrProviderDestroy)(pScreen, provider);
pScrPriv->provider = NULL;
}
free(provider);
commit 4d98c7da78db66a20397112899dc5aa455a2fdd0
Author: Matt Dew <marcoz@osource.org>
Date: Thu Feb 28 23:48:03 2013 -0700
bump rev from 1.13.3-rc1 to 1.13.3-rc2
diff --git a/configure.ac b/configure.ac
index 9415a54..bc4f22e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,9 +26,9 @@ dnl
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.60)
-AC_INIT([xorg-server], 1.13.2.901, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2013-02-15"
-RELEASE_NAME="1.13.3-rc1"
+AC_INIT([xorg-server], 1.13.2.902, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2013-02-28"
+RELEASE_NAME="1.13.3-rc2"
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
commit e604b19fc54fee839bbe2d66930b36108ff03950
Author: Aaron Plattner <aplattner@nvidia.com>
Date: Wed Jan 23 16:58:47 2013 -0800
randr: unref the provider shared pixmap the appropriate number of times
When an RandR shared pixmap is created in rrCreateSharedPixmap, it has a refcnt
of 1. Then, PixmapShareToSlave bumps the refcnt to 2. However, there's no
corresponding PixmapUnshareFromSlave where the refcnt can be decreased again,
and there's no convenient common place where the refcnt can be decremented when
the slave pixmap is destroyed.
Fix this by just unreffing the pixmap twice in RRCrtcDetachScanoutPixmap.
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
diff --git a/randr/rrcrtc.c b/randr/rrcrtc.c
index e82d050..6e2eca5 100644
--- a/randr/rrcrtc.c
+++ b/randr/rrcrtc.c
@@ -372,6 +372,11 @@ RRCrtcDetachScanoutPixmap(RRCrtcPtr crtc)
ret = pScrPriv->rrCrtcSetScanoutPixmap(crtc, NULL);
if (crtc->scanout_pixmap) {
master->StopPixmapTracking(mscreenpix, crtc->scanout_pixmap);
+ /*
+ * Unref the pixmap twice: once for the original reference, and once
+ * for the reference implicitly added by PixmapShareToSlave.
+ */
+ master->DestroyPixmap(crtc->scanout_pixmap->master_pixmap);
master->DestroyPixmap(crtc->scanout_pixmap->master_pixmap);
crtc->pScreen->DestroyPixmap(crtc->scanout_pixmap);
}
commit e7b4b83679604919035d5aab544092aef5ea6034
Author: Carlos Garnacho <carlosg@gnome.org>
Date: Wed Feb 6 14:07:22 2013 +0100
dix: Set focus field on XI2 crossing events
Set on DeviceEnterLeaveEvent() the xXIEnterEvent->focus field
similarly to how the CoreEnterLeaveEvent() function above does
for core events.
This fixes bug https://bugzilla.gnome.org/show_bug.cgi?id=677329
reported to GTK+, where focus handling on window managers with
sloppy focus or no window manager present was broken due to this
field being always set to FALSE.
Signed-off-by: Carlos Garnacho <carlosg@gnome.org>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 509b3c3dc82e7abce1900d5e1cddd90f23be5a87)
diff --git a/dix/events.c b/dix/events.c
index 904f0ba..a43c99a 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -4561,6 +4561,7 @@ DeviceEnterLeaveEvent(DeviceIntPtr mouse,
{
GrabPtr grab = mouse->deviceGrab.grab;
xXIEnterEvent *event;
+ WindowPtr focus;
int filter;
int btlen, len, i;
DeviceIntPtr kbd;
@@ -4602,6 +4603,11 @@ DeviceEnterLeaveEvent(DeviceIntPtr mouse,
event->group.locked_group = kbd->key->xkbInfo->state.locked_group;
}
+ focus = (kbd) ? kbd->focus->win : None;
+ if ((focus != NoneWin) &&
+ ((pWin == focus) || (focus == PointerRootWin) || IsParent(focus, pWin)))
+ event->focus = TRUE;
+
FixUpEventFromWindow(mouse->spriteInfo->sprite, (xEvent *) event, pWin,
None, FALSE);
commit 29a0c87f4d235898a526758b34c2abfdb656cdf4
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Fri Jan 25 11:47:32 2013 +1000
dix: when shutting down slave devices, shut down xtest devices last
XTest devices are the first ones in the list, being initialised together
with the master devices. If we disable the devices in-order and a device has
a button down when being disabled, the XTest device is checked for a
required button release (xkbAccessX.c's ProcessPointerEvent). This fails if
the device is already NULL.
Instead of putting the check there, disable the devices in the reverse order
they are initialised. Disable physical slaves first, then xtest devices,
then the master devices.
Testcase: shut down server with a button still held down on a physical
device
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 3e4be4033aed78b2bb3a18d51f0963989efd1af3)
diff --git a/dix/devices.c b/dix/devices.c
index fd4916a..7d7888e 100644
--- a/dix/devices.c
+++ b/dix/devices.c
@@ -514,6 +514,12 @@ DisableAllDevices(void)
{
DeviceIntPtr dev, tmp;
+ /* Disable slave devices first, excluding XTest devices */
+ nt_list_for_each_entry_safe(dev, tmp, inputInfo.devices, next) {
+ if (!IsXTestDevice(dev, NULL) && !IsMaster(dev))
+ DisableDevice(dev, FALSE);
+ }
+ /* Disable XTest devices */
nt_list_for_each_entry_safe(dev, tmp, inputInfo.devices, next) {
if (!IsMaster(dev))
DisableDevice(dev, FALSE);
commit d8a09a4b15a6830b3fd281540015015a5663952e
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Fri Jan 11 14:22:07 2013 +1000
dix: pre-scale relative events from abs devices to desktop ratio (#31636)
Absolute devices may send relative events depending on the mode (synaptics
by default, wacom per option). The relative events are added to the previous
position, converted into device coordinates and then scaled into desktop
coordinates for pointer movement.
Because the device range must be mapped into the desktop coordinate range,
this results in uneven scaling depending dimensions, e.g. on a setup with
width == 2 * height, a relative movement of 10/10 in device coordinates
results in a cursor movement of 20/10 (+ acceleration)
Other commonly user-visible results:
* the touchpad changing acceleration once an external monitor as added.
* drawing a circle on a wacom tablet in relative mode gives an ellipsis in
the same ratio as the desktop dimensions.
Solution: pre-scale the incoming relative x/y coordinates by width/height
ratio of the total desktop size. Then add them to the previous
coordinates and scale back with the previous mapping, which will undo the
pre-scaling and give us the right movement.
X.Org Bug 31636 <http://bugs.freedesktop.org/show_bug.cgi?id=31636>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 61a99aff9d33728a0b67920254d2d4d79f80cf39)
diff --git a/dix/getevents.c b/dix/getevents.c
index bf87ffa..7076783 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -787,11 +787,33 @@ add_to_scroll_valuator(DeviceIntPtr dev, ValuatorMask *mask, int valuator, doubl
* @param[in,out] mask Valuator data for this event, modified in-place.
*/
static void
-moveRelative(DeviceIntPtr dev, ValuatorMask *mask)
+moveRelative(DeviceIntPtr dev, int flags, ValuatorMask *mask)
{
int i;
Bool clip_xy = IsMaster(dev) || !IsFloating(dev);
+ /* for abs devices in relative mode, we've just scaled wrong, since we
+ mapped the device's shape into the screen shape. Undo this. */
+ if ((flags & POINTER_ABSOLUTE) == 0 && dev->valuator &&
+ dev->valuator->axes[0].min_value < dev->valuator->axes[0].max_value) {
+
+ double ratio = 1.0 * screenInfo.width/screenInfo.height;
+
+ if (ratio > 1.0) {
+ double y;
+ if (valuator_mask_fetch_double(mask, 1, &y)) {
+ y *= ratio;
+ valuator_mask_set_double(mask, 1, y);
+ }
+ } else {
+ double x;
+ if (valuator_mask_fetch_double(mask, 0, &x)) {
+ x *= ratio;
+ valuator_mask_set_double(mask, 0, x);
+ }
+ }
+ }
+
/* calc other axes, clip, drop back into valuators */
for (i = 0; i < valuator_mask_size(mask); i++) {
double val = dev->last.valuators[i];
@@ -1387,7 +1409,7 @@ fill_pointer_events(InternalEvent *events, DeviceIntPtr pDev, int type,
if ((flags & POINTER_NORAW) == 0)
set_raw_valuators(raw, &mask, raw->valuators.data);
- moveRelative(pDev, &mask);
+ moveRelative(pDev, flags, &mask);
}
/* valuators are in device coordinate system in absolute coordinates */
commit 79f5430ba62e0020cb19e4ce72599a220d0bb2f9
Author: Sybren van Elderen <sowmestno@msn.com>
Date: Tue Jan 29 15:43:57 2013 +1000
dix: when scaling from desktop coord, take the total desktop size (#51904)
Scaled is already in desktop coordinates, take the total width into account,
not just the current screen's width.
Fixes Xdmx pointer position calculation.
X.Org Bug 51904 <http://bugs.freedesktop.org/show_bug.cgi?id=51904>
Signed-off-by: Sybren van Elderen <sowmestno@msn.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit a191dbfe850ed9c6440346f59cb0078e0e844edc)
diff --git a/dix/getevents.c b/dix/getevents.c
index 241fcfd..bf87ffa 100644
--- a/dix/getevents.c
+++ b/dix/getevents.c
@@ -844,14 +844,14 @@ scale_from_screen(DeviceIntPtr dev, ValuatorMask *mask)
scaled = valuator_mask_get_double(mask, 0) + scr->x;
scaled = rescaleValuatorAxis(scaled,
NULL, dev->valuator->axes + 0,
- 0, scr->width);
+ screenInfo.x, screenInfo.width);
valuator_mask_set_double(mask, 0, scaled);
}
if (valuator_mask_isset(mask, 1)) {
scaled = valuator_mask_get_double(mask, 1) + scr->y;
scaled = rescaleValuatorAxis(scaled,
NULL, dev->valuator->axes + 1,
- 0, scr->height);
+ screenInfo.y, screenInfo.height);
valuator_mask_set_double(mask, 1, scaled);
}
}
commit fa6cbd099f65eea46e41ecffcc46135bae2face8
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Sat Jan 26 14:13:33 2013 +1000
dmx: don't include dmx-config.h from xdmxconfig (#37502)
dmx-config.h is a server header which includes dix-config.h. That again
defines a bunch of server-specifics, including setting the size of XID to
32 bit.
libX11 uses unsigned long (8 bits on x86_64). XGCValues thus ends up being
16 bytes smaller in xdmxconfig than in the library, causing garbage to be
sent to the server.
X.Org Bug 37502 <http://bugs.freedesktop.org/show_bug.cgi?id=37502>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 1058fcf57fdcb94d92e7b5f4483b347853d5f8e6)
diff --git a/hw/dmx/config/xdmxconfig.c b/hw/dmx/config/xdmxconfig.c
index f308412..2121dd7 100644
--- a/hw/dmx/config/xdmxconfig.c
+++ b/hw/dmx/config/xdmxconfig.c
@@ -31,9 +31,6 @@
*
*/
-#ifdef HAVE_DMX_CONFIG_H
-#include <dmx-config.h>
-#endif
#include <stdio.h>
#include <stdlib.h>
commit 63f928a9d702512db4c1e683c3b772a4d1f32010
Author: Daniel Martin <consume.noise@gmail.com>
Date: Fri Dec 7 19:38:55 2012 +0100
xfixes: Fix minor number in QueryVersion
Due to a typo the major version number was passed as minor version to
version_compare().
Regression-from: ffd4874798ba54f86acac75779a15b4babeaa5f3
Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 36740d02b9ca117f1404e077367fbbbe271a17d6)
diff --git a/xfixes/xfixes.c b/xfixes/xfixes.c
index 52c57df..48af9ea 100644
--- a/xfixes/xfixes.c
+++ b/xfixes/xfixes.c
@@ -74,7 +74,7 @@ ProcXFixesQueryVersion(ClientPtr client)
if (version_compare(stuff->majorVersion, stuff->minorVersion,
SERVER_XFIXES_MAJOR_VERSION,
- SERVER_XFIXES_MAJOR_VERSION) < 0) {
+ SERVER_XFIXES_MINOR_VERSION) < 0) {
rep.majorVersion = stuff->majorVersion;
rep.minorVersion = stuff->minorVersion;
}
commit bc4c3158ba3ef438426a2376f20f97d7f266828c
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Tue Dec 4 15:28:14 2012 +1000
xkb: only post a XTest release if the XTest device has the button down
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 5daa442fe15d9a87112a2def673c99a5f2506dcf)
diff --git a/xkb/xkbAccessX.c b/xkb/xkbAccessX.c
index 9631502..13051e0 100644
--- a/xkb/xkbAccessX.c
+++ b/xkb/xkbAccessX.c
@@ -732,8 +732,13 @@ ProcessPointerEvent(InternalEvent *ev, DeviceIntPtr mouse)
if (rc != Success)
ErrorF("[xkb] bad sourceid '%d' on button release event.\n",
event->sourceid);
- else if (!IsXTestDevice(source, GetMaster(dev, MASTER_POINTER)))
- XkbFakeDeviceButton(dev, FALSE, event->detail.key);
+ else if (!IsXTestDevice(source, GetMaster(dev, MASTER_POINTER))) {
+ DeviceIntPtr xtest_device;
+
+ xtest_device = GetXTestDevice(GetMaster(dev, MASTER_POINTER));
+ if (button_is_down(xtest_device, ev->device_event.detail.button, BUTTON_PROCESSED))
+ XkbFakeDeviceButton(dev, FALSE, event->detail.key);
+ }
}
if (xkbi)
commit b3b7be7d49ee9a253062661d6c72fa1f8ddff493
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date: Tue Dec 4 15:03:37 2012 +1000
xkb: always post XTest button up when the physical button released (#28808)
Regression introduced by commit 2decff6393a44b56d80d53570718f95354fde454
xkb: ProcesssPointerEvent must work on the VCP if it gets the VCP
XTest buttons must be released when a physical button is released. This was
fixed in 14327858391ebe929b806efb53ad79e789361883, but
2decff6393a44b56d80d53570718f95354fde454 changed a condition that this code
didn't get triggered anymore.
"dev" for pointer events is now always the VCP which doesn't have a xkbi
struct. So move this condition out and always trigger the XTest released for
button events.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Frank Roscher <Frank-Roscher@gmx.net>
(cherry picked from commit c4fee9d2ecd6fdd4c05b04c9f02b23f10f2938b8)
diff --git a/xkb/xkbAccessX.c b/xkb/xkbAccessX.c
index 21df85d..9631502 100644
--- a/xkb/xkbAccessX.c
+++ b/xkb/xkbAccessX.c
@@ -723,23 +723,22 @@ ProcessPointerEvent(InternalEvent *ev, DeviceIntPtr mouse)
changed |= XkbPointerButtonMask;
}
else if (event->type == ET_ButtonRelease) {
- if (xkbi) {
- xkbi->lockedPtrButtons &= ~(1 << (event->detail.key & 0x7));
-
- if (IsMaster(dev)) {
- DeviceIntPtr source;
- int rc;
-
- rc = dixLookupDevice(&source, event->sourceid, serverClient,
- DixWriteAccess);
- if (rc != Success)
- ErrorF("[xkb] bad sourceid '%d' on button release event.\n",
- event->sourceid);
- else if (!IsXTestDevice(source, GetMaster(dev, MASTER_POINTER)))
- XkbFakeDeviceButton(dev, FALSE, event->detail.key);
- }
+ if (IsMaster(dev)) {
+ DeviceIntPtr source;
+ int rc;
+
+ rc = dixLookupDevice(&source, event->sourceid, serverClient,
+ DixWriteAccess);
+ if (rc != Success)
+ ErrorF("[xkb] bad sourceid '%d' on button release event.\n",
+ event->sourceid);
+ else if (!IsXTestDevice(source, GetMaster(dev, MASTER_POINTER)))
+ XkbFakeDeviceButton(dev, FALSE, event->detail.key);
}
+ if (xkbi)
+ xkbi->lockedPtrButtons &= ~(1 << (event->detail.key & 0x7));
+
changed |= XkbPointerButtonMask;
}
commit c260ae1a0ca76dadc44e7031ffcb78e12ba4087e
Author: Matt Dew <marcoz@osource.org>
Date: Sat Feb 16 00:08:59 2013 -0700
Update release to 1.13.3-rc1
diff --git a/configure.ac b/configure.ac
index a21d38d..9415a54 100644
--- a/configure.ac
+++ b/configure.ac
@@ -26,9 +26,9 @@ dnl
dnl Process this file with autoconf to create configure.
AC_PREREQ(2.60)
-AC_INIT([xorg-server], 1.13.2, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
-RELEASE_DATE="2013-01-24"
-RELEASE_NAME="Silver Needle"
+AC_INIT([xorg-server], 1.13.2.901, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xorg-server)
+RELEASE_DATE="2013-02-15"
+RELEASE_NAME="1.13.3-rc1"
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([foreign dist-bzip2])
AM_MAINTAINER_MODE
commit b6c59f73d2dabca6348ca5ceae978488c3a4856f
Author: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Date: Sat Feb 9 20:53:02 2013 -0800
Reply to: