[PATCH 2/5] systemd_logind_find_info_ptr_by_devnum: Move to higher inside the file

2014-03-12 Thread Hans de Goede
This is a preparation patch for adding support for server managed fds for InputDevices where multiple input devices share the same device node (and thus also their major and minor). Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/os-support/linux/systemd-logind.c | 28

[PATCH 3/5] systemd-logind: Add a systemd_logind_set_input_fd_for_all_devs helper

2014-03-12 Thread Hans de Goede
And use it where appropriate. Setting the fd for all matching InputDevices is necessary when we've multiple InputDevices sharing a single device-node, such as happens with Wacom tablets. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/os-support/linux/systemd-logind.c | 33

[PATCH 4/5] systemd-logind: Correctly deal with InputDevs sharing a device-node

2014-03-12 Thread Hans de Goede
. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/os-support/linux/systemd-logind.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/hw/xfree86/os-support/linux/systemd-logind.c b/hw/xfree86/os-support/linux/systemd-logind.c index a2ef7af..62858b0

[PATCH 5/5] xf86Xinput: release server managed fd before removing the device from the list

2014-03-12 Thread Hans de Goede
So that the fd in use test in systemd_logind_release_fd works properly. Note we cannot change the test inside systemd_logind_release_fd as it must work for devices which were never added to the xf86InputDevs too. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common

[PATCH 1/5] systemd_logind_find_info_ptr_by_devnum: Add a start argument

2014-03-12 Thread Hans de Goede
Modify systemd_logind_find_info_ptr_by_devnum to take a start argument, so that it can be used to find all occurences of a devnum in an InputInfo list, rather then just the first. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/os-support/linux/systemd-logind.c | 8 +--- 1

[PATCH xf86-input-wacom 3/3] Add server managed fd handling

2014-03-12 Thread Hans de Goede
This mostly consists of skipping common fd handling when server managed fds are in used, the rest is handled by xf86OpenSerial and our wcmClose xf86CloseSerial wrapper. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/wcmConfig.c | 5 - src/xf86Wacom.c | 9 + 2 files changed

[PATCH xf86-input-wacom 2/3] Add a wcmClose helper function

2014-03-12 Thread Hans de Goede
This is a preparation patch for adding server managed fds support. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/wcmConfig.c | 13 ++--- src/xf86Wacom.c | 32 ++-- src/xf86Wacom.h | 3 +++ 3 files changed, 27 insertions(+), 21 deletions(-) diff

[PATCH xf86-input-wacom 1/3] wcmUSB: Don't directly dereference common-fd

2014-03-12 Thread Hans de Goede
it. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/wcmUSB.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/wcmUSB.c b/src/wcmUSB.c index e22cd5e..002c986 100644 --- a/src/wcmUSB.c +++ b/src/wcmUSB.c @@ -1531,11 +1531,11 @@ static int toolTypeToDeviceType

Re: [PATCH 1/2] config: only free odev-attrib_name for string types

2014-03-11 Thread Hans de Goede
Hi, On 03/11/2014 05:30 AM, Peter Hutterer wrote: Signed-off-by: Peter Hutterer peter.hutte...@who-t.net Good catch: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans --- config/config.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/config/config.c b

Re: [PATCH 2/2] xfree86: handle xorg.conf devices with logind

2014-03-11 Thread Hans de Goede
devices don't have that set, make sure we try to stat it first where needed. Signed-off-by: Peter Hutterer peter.hutte...@who-t.net Looks good: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans --- Fixes a crash when running with hotplug disabled and fixed devices

Re: [PATCH synaptics 0/4] Drop mtdev from synaptics

2014-03-11 Thread Hans de Goede
is: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH v2] Xorg: Add a suid root wrapper

2014-03-11 Thread Hans de Goede
Hi, On 03/11/2014 07:16 AM, Peter Hutterer wrote: On Mon, Mar 10, 2014 at 10:21:39PM +0100, Hans de Goede wrote: With the recent systemd-logind changes it is possible to install the Xorg binary without suid root rights and still have everything working as it should *if* the user only has

[PATCH xf86-video-ati] Add support for server managed fds

2014-03-11 Thread Hans de Goede
Signed-off-by: Hans de Goede hdego...@redhat.com --- src/radeon_kms.c | 60 +- src/radeon_probe.c | 5 + src/radeon_probe.h | 2 ++ 3 files changed, 57 insertions(+), 10 deletions(-) diff --git a/src/radeon_kms.c b/src/radeon_kms.c

[PATCH xf86-video-ati 0/1] Add support for server managed fds

2014-03-11 Thread Hans de Goede
Hi All, Here is a patch to add server managed fds support to the ati driver. Note that is exactly the same patch as the RFC I send earlier, this is no longer RFC as the necessary xserver changes have now landed upstream. Regards, Hans ___

[PATCH 2/2] Remove config_odev_add_*attribute checks in various places

2014-03-11 Thread Hans de Goede
Note that there are more callers but those were already not doing any error checking. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/udev.c | 32 ++ hw/xfree86/os-support/linux/lnx_platform.c | 5 + 2 files changed, 7

[PATCH 1/2] config_odev*: Use XNF alloc functions

2014-03-11 Thread Hans de Goede
also fixup an unchecked strdup case. Note the function prototypes are kept unchanged, as they are part of the server ABI. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c | 18 +++--- hw/xfree86/common/xf86platformBus.h | 5 +++-- include

Re: [PATCH synaptics] Add property support for secondary (top) software buttons

2014-03-10 Thread Hans de Goede
Hutterer peter.hutte...@who-t.net Looks good: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans --- include/synaptics-properties.h | 3 +++ man/synaptics.man | 3 ++- src/properties.c | 48 +- src/synaptics.c

Re: [PATCH RFC] Xorg: Add a suid root wrapper

2014-03-10 Thread Hans de Goede
Hi, On 03/09/2014 11:39 PM, Mark Kettenis wrote: Date: Thu, 06 Mar 2014 13:57:32 +0100 From: Hans de Goede hdego...@redhat.com +for (i = 0; i 16; i++) { +snprintf(buf, PATH_MAX, /dev/dri/card%d, i); Hardcoding paths like this is a bad idea. We use /dev/drm%d on OpenBSD

Re: [PATCH] Xorg: Add a suid root wrapper

2014-03-10 Thread Hans de Goede
Hi, On 03/10/2014 07:03 AM, Peter Hutterer wrote: On Fri, Mar 07, 2014 at 11:38:52AM +0100, Hans de Goede wrote: With the recent systemd-logind changes it is possible to install the Xorg binary without suid root rights and still have everything working as it should *if* the user only has

[PATCH v2 0/1] Xorg: Add a suid root wrapper

2014-03-10 Thread Hans de Goede
Hi All, Here is v2 of my suid root wrapper, changes: v2: -Use xf86drm.h DRM_DEV_NAME -Added a SUID_WRAPPER_DIR autoconfig variable, set it to libexecdir be default and use it as installation path for the wrapper as well as path to find the real Xserver when using the wrapper -Use SYSCONFDIR

[PATCH v2] Xorg: Add a suid root wrapper

2014-03-10 Thread Hans de Goede
. Hopefully this will allow Debian to replace their own wrapper with this upstream one. Signed-off-by: Hans de Goede hdego...@redhat.com --- configure.ac | 14 ++- hw/xfree86/Makefile.am | 15 ++- hw/xfree86/Xorg.sh.in | 12 ++ hw/xfree86/man

Re: [PATCH v2 synaptics] synaptics: Add support for server managed fds

2014-03-10 Thread Hans de Goede
Hi, On 03/10/2014 05:17 AM, Hans de Goede wrote: Signed-off-by: Hans de Goede hdego...@redhat.com Signed-off-by: Peter Hutterer peter.hutte...@who-t.net --- Give this one a test please, seems to work on first glance. Changes to v1: - use helper function for closing the fd, avoids forgetting

[PATCH v2 synaptics] synaptics: Add support for server managed fds

2014-03-09 Thread Hans de Goede
Signed-off-by: Hans de Goede hdego...@redhat.com Signed-off-by: Peter Hutterer peter.hutte...@who-t.net --- Give this one a test please, seems to work on first glance. Changes to v1: - use helper function for closing the fd, avoids forgetting the flag check - Optimise DeviceOn to have a single

[PATCH xf86-input-evdev] evdev: Add support for server managed fds

2014-03-08 Thread Hans de Goede
Signed-off-by: Hans de Goede hdego...@redhat.com --- src/evdev.c | 49 - 1 file changed, 28 insertions(+), 21 deletions(-) diff --git a/src/evdev.c b/src/evdev.c index d1ed9ee..ed84f0f 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -97,6 +97,10

[PATCH xf86-input-synaptics] synaptics: Add support for server managed fds

2014-03-08 Thread Hans de Goede
Signed-off-by: Hans de Goede hdego...@redhat.com --- src/eventcomm.c | 10 -- src/synaptics.c | 30 +- src/synproto.h | 4 3 files changed, 33 insertions(+), 11 deletions(-) diff --git a/src/eventcomm.c b/src/eventcomm.c index a0a2af0..49a8a3f 100644

Re: [PATCH] xserver: fix build since system-logind.h

2014-03-08 Thread Hans de Goede
Hi, On 03/08/2014 11:39 AM, Dave Airlie wrote: on tinderbox and irc Signed-off-by: Dave Airlie airl...@redhat.com Oops, sorry about that. Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans --- include/systemd-logind.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions

Re: [PATCH libxtrans] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-08 Thread Hans de Goede
Hi all, On 03/03/2014 03:14 PM, Daniel Stone wrote: Hi, On 3 March 2014 07:56, Hans de Goede hdego...@redhat.com wrote: The latest glibc considers _BSD_SOURCE deprecated, leading to the following warning being issued for pretty much every C-file in the xserver: In file included from /usr

Re: [PATCH libxtrans] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-08 Thread Hans de Goede
Hi, On 03/08/2014 05:31 PM, Mark Kettenis wrote: Date: Sat, 08 Mar 2014 17:11:42 +0100 From: Hans de Goede hdego...@redhat.com Hi, On 03/08/2014 05:07 PM, Gaetan Nadon wrote: On 14-03-08 09:03 AM, Hans de Goede wrote: So I've just been looking into using AC_USE_SYSTEM_EXTENSIONS

[PATCH 0/2] misc. fixes

2014-03-07 Thread Hans de Goede
Hi All, Here are 2 misc. systemd-logind related bug fixes. Note the 1st patch is v2 of a patch I've send before. New in v2 is the addition if a helper function while fixing this issue to avoid code duplication. Regards, Hans ___

[PATCH 2/2] systemd-logind: Fix vt-enter not working when using a legacy video driver

2014-03-07 Thread Hans de Goede
for input device resumes are a nop 2) This assumes that there will always be at least one server event fd supporting input device. Since all non legacy input-drivers will be patched to supported server fds this seems a safe assumption. Signed-off-by: Hans de Goede hans@localhost.localdomain --- hw

[PATCH 1/2] config_odev_add*_attribute: Don't add the attribute to the list twice

2014-03-07 Thread Hans de Goede
Don't do the xorg_list_append a 2nd time when updating existing attributes, while at it add a helper function for this to avoid code duplication. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c | 31 +-- 1 file changed, 21 insertions(+), 10

Re: [PATCH 2/2] systemd-logind: Fix vt-enter not working when using a legacy video driver

2014-03-07 Thread Hans de Goede
Hi On 03/07/2014 11:22 AM, Hans de Goede wrote: If there is only a single non kms video device (tested with the vesa driver), then we will never get a resume signal for a drm node, so also call vtenter when we get a resume for an input device. Notes: 1) vtenter checks if it is ok to do

[PATCH v2 0/2] Require video drivers to report that they support server fds

2014-03-07 Thread Hans de Goede
Hi All, Here is v2 of my patch-set which requires video drivers to report that they support server fds. New in v2: -Fix drivers without a driverFunc getting seen as supporting server fds Regards, Hans ___ xorg-devel@lists.x.org: X.Org development

[PATCH v2 2/2] Require video drivers to report that they support server managed fds

2014-03-07 Thread Hans de Goede
This makes how we handle video drivers identical to what we do for input drivers, and this should make live easier for old non kms drivers. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86platformBus.c | 14 +- hw/xfree86/common/xf86str.h | 3

[PATCH v2 1/2] xf86platformBus: Make doPlatformProbe accept a NULL gdev argument

2014-03-07 Thread Hans de Goede
And use it from xf86platformAddDevice too, instead of directly calling drvp-platformProbe. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86platformBus.c | 14 +- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/hw/xfree86/common

[PATCH 0/1] Xorg: Add a suid root wrapper

2014-03-07 Thread Hans de Goede
Hi all, Here is the first non RFC version of my suid root wrapper patch, taking all comments made to the RFC into account. Please review. Thanks Regards, Hans ___ xorg-devel@lists.x.org: X.Org development Archives:

[PATCH] Xorg: Add a suid root wrapper

2014-03-07 Thread Hans de Goede
. Hopefully this will allow Debian to replace their own wrapper with this upstream one. Signed-off-by: Hans de Goede hdego...@redhat.com --- configure.ac | 7 ++ hw/xfree86/Makefile.am| 14 ++- hw/xfree86/Xorg.sh.in | 12 +++ hw/xfree86/xorg-wrapper.c | 211

[RFC xf86-video-ati 0/1] Add support for server managed fds

2014-03-07 Thread Hans de Goede
Hi All, Here is a patch to add support for server managed fds to xf86-video-ati this is RFC only atm since not all related server patches have landed yet. With the server patches + this patch it is possible to run Xorg without root-rights on systemd-logind using systems. Regards, Hans

[RFC xf86-video-ati] Add support for server managed fds

2014-03-07 Thread Hans de Goede
Signed-off-by: Hans de Goede hdego...@redhat.com --- src/radeon_kms.c | 60 +- src/radeon_probe.c | 5 + src/radeon_probe.h | 2 ++ 3 files changed, 57 insertions(+), 10 deletions(-) diff --git a/src/radeon_kms.c b/src/radeon_kms.c

Re: [RFC xf86-video-ati 0/1] Add support for server managed fds

2014-03-07 Thread Hans de Goede
Hi, On 03/07/2014 02:38 PM, Mark Kettenis wrote: From: Hans de Goede hdego...@redhat.com Date: Fri, 7 Mar 2014 14:12:57 +0100 Hi All, Here is a patch to add support for server managed fds to xf86-video-ati this is RFC only atm since not all related server patches have landed yet

Re: [PATCH RFC] Xorg: Add a suid root wrapper

2014-03-06 Thread Hans de Goede
Hi, On 03/06/2014 06:40 AM, Alan Coopersmith wrote: On 03/ 5/14 07:51 AM, Hans de Goede wrote: This commit adds a little suid root wrapper, which is a bit weird, first we strip the suid-root bit of the Xorg binary, and then we add a wrapper ? Have you looked at Debian's Xwrapper

Re: [PATCH RFC 0/1] Xorg: Add a suid root wrapper

2014-03-06 Thread Hans de Goede
Hi Mark, On 03/06/2014 01:23 PM, Mark Kettenis wrote: snip Oh dear, the wrapper script is back! Before you go further down this road, may I point out the privilege seperation support that we've had in xenocara (Xorg for OpenBSD) for years now? As Ilja van Sprundel says, Xorg guys should

Re: [PATCH RFC] Xorg: Add a suid root wrapper

2014-03-06 Thread Hans de Goede
Hi, Thanks for the review! On 03/06/2014 01:46 PM, Mark Kettenis wrote: From: Hans de Goede hdego...@redhat.com Date: Wed, 5 Mar 2014 16:51:52 +0100 If you end up going with this wrapper approach anyway despite my previous message, here are some comments. Oh, and it's good

[PATCH RFC] Xorg: Add a suid root wrapper

2014-03-05 Thread Hans de Goede
on the wrapper pkg, and since our default install contains some legacy drivers it will be part of the default install, but users can later yum remove it (which will also automatically remove the legacy driver packages as those won't work without it anyways). Signed-off-by: Hans de Goede hdego

[PATCH RFC 0/1] Xorg: Add a suid root wrapper

2014-03-05 Thread Hans de Goede
Hi All, Let me repeat the commit msg here as that explains it all: With the recent systemd-logind changes it is possible to install the Xorg binary without suid root rights and still have everything working as it should *if* the user only has cards which are supported by kms. This commit adds a

Re: [PATCH libxtrans] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-04 Thread Hans de Goede
Hi Daniel, On 03/03/2014 03:14 PM, Daniel Stone wrote: Hi, On 3 March 2014 07:56, Hans de Goede hdego...@redhat.com wrote: The latest glibc considers _BSD_SOURCE deprecated, leading to the following warning being issued for pretty much every C-file in the xserver: In file included from /usr

Re: [PATCH libxtrans] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-04 Thread Hans de Goede
Hi, On 03/05/2014 01:13 AM, Alan Coopersmith wrote: On 03/ 4/14 08:54 AM, Hans de Goede wrote: Hi Daniel, On 03/03/2014 03:14 PM, Daniel Stone wrote: Hi, On 3 March 2014 07:56, Hans de Goede hdego...@redhat.com wrote: The latest glibc considers _BSD_SOURCE deprecated, leading

Re: [PATCH 1/2] xf86Config: Fix warning: declaration of 'Pointer' shadows a global

2014-03-04 Thread Hans de Goede
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi, On 03/05/2014 02:15 AM, Eric Anholt wrote: Hans de Goede hdego...@redhat.com writes: This fixes the following compiler warning: xf86Config.c: In function 'checkCoreInputDevices': xf86Config.c:1136:18: warning: declaration of 'Pointer

[PATCH 2/2] hashtabletest: Fix warning: format ‘%ld’ expects argument of type ...

2014-03-03 Thread Hans de Goede
This fixes the following compiler warning: hashtabletest.c: In function ‘print_xid’: hashtabletest.c:15:5: warning: format ‘%ld’ expects argument of type ‘long int’, but argument 2 has type ‘XID’ [-Wformat=] printf(%ld, *x); ^ Signed-off-by: Hans de Goede hdego...@redhat.com --- test

[PATCH 1/2] xf86Config: Fix warning: declaration of 'Pointer' shadows a global

2014-03-03 Thread Hans de Goede
, from xf86Config.c:66: /opt/xorg/include/X11/extensions/XIproto.h:88:24: warning: shadowed declaration is here [-Wshadow] typedef unsigned char *Pointer; Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86Config.c | 20 ++-- 1 file changed, 10

Re: [PATCH 1/2] xf86Config: Fix warning: declaration of 'Pointer' shadows a global

2014-03-03 Thread Hans de Goede
Hi, On 03/03/2014 11:23 AM, Mark Kettenis wrote: From: Hans de Goede hdego...@redhat.com Date: Mon, 3 Mar 2014 09:53:12 +0100 This fixes the following compiler warning: xf86Config.c: In function 'checkCoreInputDevices': xf86Config.c:1136:18: warning: declaration of 'Pointer' shadows

[PULL] systemd-logind integration series

2014-03-03 Thread Hans de Goede
to bf3543739db18c6cd52908f7c693cb64f43e3f23: xf86OpenSerial: Add support server managed fds (2014-03-03 08:13:56 +0100) Hans de Goede (13): linux: xf86OpenConsole remove root-rights check for keeptty option linux: xf86OpenConsole: Don't detach from

[PATCH 1/3] config_odev_add*_attribute: Don't add the attribute to the list twice

2014-03-03 Thread Hans de Goede
Don't do the xorg_list_append a 2nd time when updating existing attributes. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/config/config.c b/config/config.c index 7971b87..28dac86 100644

[PATCH 2/3] xf86platformBus: Make doPlatformProbe accept a NULL gdev argument

2014-03-03 Thread Hans de Goede
And use it from xf86platformAddDevice too, instead of directly calling drvp-platformProbe. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86platformBus.c | 14 +- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/hw/xfree86/common

[PATCH 3/3] Require video drivers to report that they support server managed fds

2014-03-03 Thread Hans de Goede
This makes how we handle video drivers identical to what we do for input drivers, and this should make live easier for old non kms drivers. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86platformBus.c | 14 +- hw/xfree86/common/xf86str.h | 3

[PATCH libxtrans 0/1] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-02 Thread Hans de Goede
Hi All, Here is a small xtrans patch fixing the latest glibc issueing a warning for every .c file in the xserver. Since we've done so much effort to kill (allmost) all warnings in the xserver, this new warning is rather unfortunate. So I plan to do a new xtrans release soon, assuming this patch

[PATCH libxtrans] configure: under glibc define _GNU_SOURCE rather then _BSD_SOURCE

2014-03-02 Thread Hans de Goede
by switching to _GNU_SOURCE, which also includes all the necessary functions from BSD. Signed-off-by: Hans de Goede hdego...@redhat.com --- configure.ac | 14 ++ xtrans.pc.in | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 6898c6d

Re: [PATCH xf86-input-synaptics 5/8] Don't report motion inside soft-button areas

2014-03-01 Thread Hans de Goede
Hi Carl, On 02/28/2014 06:41 PM, Carl Worth wrote: Carl Worth cwo...@cworth.org writes: xinput set-prop 'SynPS/2 Synaptics TouchPad' 'Synaptics Soft Button Areas' 3951 0 0 1700 2950 3950 0 1700 ... The above values are working well enough for me now that they could even be a

Re: [PATCH xf86-input-synaptics 0/8] Various clickpad improvements

2014-03-01 Thread Hans de Goede
Hi, On 02/26/2014 06:10 AM, Peter Hutterer wrote: On Fri, Feb 21, 2014 at 10:31:36AM +0100, Hans de Goede wrote: Hi Peter, Benjamin et al, The following patchset is the result of me playing with the clickpad on the T440s and trying to make using it a more pleasant experience Patch 1: Add

[PATCH xf86-input-synaptics 7/8] On button down update cumulative to current x and y, instead of previous

2014-02-21 Thread Hans de Goede
to determine the click location Signed-off-by: Hans de Goede hdego...@redhat.com --- src/eventcomm.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/eventcomm.c b/src/eventcomm.c index 7fc408f..fe57aa8 100644 --- a/src/eventcomm.c +++ b/src/eventcomm.c @@ -671,6 +671,7 @@ EventReadHwState

[PATCH xf86-input-synaptics 6/8] Ignore motion the first X ms after a clickpad click

2014-02-21 Thread Hans de Goede
This fixes my #1 anoyance with clickpads, where 2 out of 3 clicks turn into a click + drag unless I hold my finger really really still. Signed-off-by: Hans de Goede hdego...@redhat.com --- include/synaptics-properties.h | 2 ++ man/synaptics.man | 10 ++ src/properties.c

[PATCH xf86-input-synaptics 4/8] Get rid of old_hw_state

2014-02-21 Thread Hans de Goede
We only use it to store button state which we already have in priv-lastButtons. While at it also properly indent the code block checking the various soft button areas. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/synaptics.c| 58

[PATCH xf86-input-synaptics 5/8] Don't report motion inside soft-button areas

2014-02-21 Thread Hans de Goede
the reporting of unintended motion just before a click in a soft button area which sometimes causes mis-clicks. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/synaptics.c| 68 -- src/synapticsstr.h | 1 + 2 files changed, 67 insertions(+), 2

[PATCH xf86-input-synaptics 0/8] Various clickpad improvements

2014-02-21 Thread Hans de Goede
Hi Peter, Benjamin et al, The following patchset is the result of me playing with the clickpad on the T440s and trying to make using it a more pleasant experience Patch 1: Add another third state to TouchpadOff for disabling all but button clicks Is from bugzilla, I've added this as one of my

[PATCH xf86-input-synaptics 1/8] Add another third state to TouchpadOff for disabling all but button clicks

2014-02-21 Thread Hans de Goede
with an optstring starting with : which allows us to manually parse the options. Original version of this patch by John Pham jhn...@gmail.com Signed-off-by: Peter Hutterer peter.hutte...@who-t.net Reviewed-by: Hans de Goede hdego...@redhat.com Signed-off-by: Hans de Goede hdego...@redhat.com --- man

[PATCH xf86-input-synaptics 8/8] Wait for *new* coordinates on a clickpad click before reporting the click

2014-02-21 Thread Hans de Goede
; and 4) If when we're called again we still don't have a finger down, just treat the click as a BTN_LEFT But this is not worth the trouble IMHO, the proper thing to do in this scenario is to fix the mis-identification of the touchpad as a clickpad. Signed-off-by: Hans de Goede hdego...@redhat.com

[PATCH xf86-input-synaptics 3/8] Add an enum for the different soft_button_areas

2014-02-21 Thread Hans de Goede
While at it also move the enum for the soft button edges out of is_inside_button_area() so that it can be used elsewhere too. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/synaptics.c | 35 ++- 1 file changed, 22 insertions(+), 13 deletions(-) diff

[PATCH xf86-input-synaptics 2/8] Add secondary (top) software buttons area

2014-02-21 Thread Hans de Goede
detecting the devices that need it based on udev tags and MatchTag configuration items, this area doesn't need to be exposed through properties. So static configuration is fine. Signed-off-by: Benjamin Tissoires benjamin.tissoi...@redhat.com Reviewed-by: Hans de Goede hdego...@redhat.com Signed-off

Re: [PATCH v2 00/14] Use systemd-logind to manage /dev/... nodes for us

2014-02-21 Thread Hans de Goede
Hi, On 02/18/2014 11:37 PM, Dave Airlie wrote: Thanks for the review! I'm not systemd-logind aware enough to know about the rest yet, Well we already have a number of flags from video drivers probing, like the needs hw one etc, do you need to have a separate capabilities field in the

[PATCH xf86-input-synaptics 1/2] Allow using the entire touchpad for motions started inside the active area

2014-02-19 Thread Hans de Goede
. This commit allows such motions to continue normally. I would like to thank Juerd Waalboer for the basic idea, some coding and lots of testing for this fix. Cc: Juerd Waalboer ju...@tnx.nl Reported-by: Juerd Waalboer ju...@tnx.nl Tested-by: Juerd Waalboer ju...@tnx.nl Signed-off-by: Hans de Goede hdego

[PATCH xf86-input-synaptics 0/2] Improve clickpad soft button behavior

2014-02-19 Thread Hans de Goede
Hi Peter, Benjamin et al, Here are 2 somewhat unrelated patches, the first makes live better for people who are using active-area settings. The second patch, which is somewhat inspired by the first, stops synaptics from reporting movement on clicks inside soft-button areas, while still allowing

[PATCH xf86-input-synaptics 2/2] Don't report motion inside soft-button areas

2014-02-19 Thread Hans de Goede
Unless the motion has started outside the soft-button area. This fixes my #1 anoyance with clickpads, where 2 out of 3 clicks turn into a click + drag unless I hold my finger really really still. Signed-off-by: Hans de Goede hdego...@redhat.com --- src/synaptics.c| 33

Re: Fixing the kernels backlight API

2014-02-14 Thread Hans de Goede
Hi, On 02/13/2014 09:12 PM, Matthew Garrett wrote: On Thu, Feb 13, 2014 at 08:43:10PM +0100, Hans de Goede wrote: I can understand where Dave is coming from, from a kernel pov, so this might really be easier to just solve in userspace. I don't know if you've seen my very rough sketch of how

Re: [Intel-gfx] What to do with xf86-video-intel backlight control when running Xorg as non root

2014-02-14 Thread Hans de Goede
Hi, On 02/13/2014 09:24 PM, Mark Kettenis wrote: Date: Thu, 13 Feb 2014 20:37:47 +0100 From: Hans de Goede hdego...@redhat.com snip Right, that is what I was thinking too, so the question then becomes how hard you will scream at me if I add something like this to xf86-video-intel linux

Re: Fixing the kernels backlight API

2014-02-13 Thread Hans de Goede
Hi, On 02/12/2014 09:14 PM, Dave Airlie wrote: The biggest remaining stumbling block is the backlight API, because opening the sysfs files requires root rights. I'll very likely write a little helper for this for now, but in the long run it would be good to have a better solution. While

Re: Fixing the kernels backlight API

2014-02-13 Thread Hans de Goede
Hi, On 02/12/2014 11:26 PM, David Herrmann wrote: Hi On Wed, Feb 12, 2014 at 9:43 PM, Ville Syrjälä ville.syrj...@linux.intel.com wrote: On Thu, Feb 13, 2014 at 06:14:04AM +1000, Dave Airlie wrote: The biggest remaining stumbling block is the backlight API, because opening the sysfs

Re: Fixing the kernels backlight API

2014-02-13 Thread Hans de Goede
Hi, On 02/13/2014 07:37 AM, Alexander E. Patrakov wrote: 13.02.2014 04:26, David Herrmann wrote: The attach stuff actually sounds doable, but who decides which one to attach? You still need some user-space script during device-plug for that. But to be honest, the simplest way would be a

What to do with xf86-video-intel backlight control when running Xorg as non root

2014-02-13 Thread Hans de Goede
Hi All, Currently xf86-video-intel is unique in that it is the only video driver which does backlight control inside the driver rather then letting something else (ie the desktop environment) deal with it. This is a problem when running the xserver without root rights because writing

Re: [Intel-gfx] What to do with xf86-video-intel backlight control when running Xorg as non root

2014-02-13 Thread Hans de Goede
Hi, On 02/13/2014 05:40 PM, Chris Wilson wrote: On Thu, Feb 13, 2014 at 04:52:59PM +0100, Hans de Goede wrote: Hi All, Currently xf86-video-intel is unique in that it is the only video driver which does backlight control inside the driver rather then letting something else (ie the desktop

Re: Fixing the kernels backlight API

2014-02-13 Thread Hans de Goede
Hi, On 02/13/2014 06:19 PM, Matthew Garrett wrote: On Thu, Feb 13, 2014 at 02:41:53PM +0100, Hans de Goede wrote: I still believe we need to do better, but maybe that better needs to be done in userspace rather then in the kernel. One option is to put it on the connector but provide some

Fixing the kernels backlight API

2014-02-12 Thread Hans de Goede
Hi All, Quick self intro: I've been a FOSS developer for 15+ years now and I've been working for Red Hat for 5 years. Recently I've moved to the graphics team. One of my first tasks in the graphics team is to make the xserver run without root rights. I'm making good progress with this, having

Re: [PATCH 2/2] xfree86: Support autoloading of non-PCI drivers

2014-02-12 Thread Hans de Goede
Hi, On 02/12/2014 05:11 PM, Thierry Reding wrote: Drivers for non-PCI devices cannot be autoloaded because there is no mechanism in place to correlate the device to the driver name. This patch adds a simple table that maps the name of the Linux kernel driver name to a list of DDX module

Re: [PATCH v2 10/14] systemd-logind: Add systemd-logind core

2014-02-11 Thread Hans de Goede
to the fake-sessions spawning multiple heads we were talking about before? Regards, Hans On Mon, Feb 10, 2014 at 4:54 PM, Hans de Goede hdego...@redhat.com wrote: Hi, On 02/10/2014 10:49 PM, David Herrmann wrote: Hi On Mon, Feb 10, 2014 at 10:48 PM, Hans de Goede hdego...@redhat.com

Re: [PATCH v2 00/14] Use systemd-logind to manage /dev/... nodes for us

2014-02-11 Thread Hans de Goede
Hi, On 02/11/2014 04:04 AM, Dave Airlie wrote: On Tue, Feb 4, 2014 at 9:49 PM, Hans de Goede hdego...@redhat.com wrote: Hi All, Here is v2 of my systemd-logind / run the xserver without root rights series, this version drops some already merged patches, and addresses all the review comments

Re: [PATCH v2 03/14] linux: xf86OpenConsole: Don't detach from controlling tty when it is our vt

2014-02-11 Thread Hans de Goede
Hi Peter, On 02/11/2014 06:55 AM, Peter Hutterer wrote: On Tue, Feb 04, 2014 at 12:49:09PM +0100, Hans de Goede wrote: Detaching from our controllling tty makes little sense when it is the same typo: controlling. otherwise, Reviewed-by: Peter Hutterer peter.hutte...@who-t.net Thanks

Re: [PATCH v2 08/14] OdevAttribute: Remove unowned flag from OdevAttributes head

2014-02-11 Thread Hans de Goede
Hi, On 02/11/2014 06:55 AM, Peter Hutterer wrote: On Tue, Feb 04, 2014 at 12:49:14PM +0100, Hans de Goede wrote: The OdevAttributes struct should just be a head of the attributes list, and not contain various unrelated flags. Instead add a flags field to struct xf86_platform_device and use

Re: [PATCH v2 09/14] hotplug: Extend OdevAttributes for server-managed fd support

2014-02-11 Thread Hans de Goede
Hi, On 02/11/2014 06:56 AM, Peter Hutterer wrote: On Tue, Feb 04, 2014 at 12:49:15PM +0100, Hans de Goede wrote: With systemd-logind support, the xserver, rather than the drivers will be responsible for opening/closing the fd for drm nodes. This commit adds a fd member to OdevAttributes

Re: [PATCH v2 03/14] linux: xf86OpenConsole: Don't detach from controlling tty when it is our vt

2014-02-11 Thread Hans de Goede
Hi, On 02/12/2014 05:01 AM, Peter Hutterer wrote: On Tue, Feb 11, 2014 at 09:47:10AM +0100, Hans de Goede wrote: Hi Peter, On 02/11/2014 06:55 AM, Peter Hutterer wrote: On Tue, Feb 04, 2014 at 12:49:09PM +0100, Hans de Goede wrote: Detaching from our controllling tty makes little sense when

Re: [PATCH v2 10/14] systemd-logind: Add systemd-logind core

2014-02-10 Thread Hans de Goede
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi, On 02/10/2014 10:49 PM, David Herrmann wrote: Hi On Mon, Feb 10, 2014 at 10:48 PM, Hans de Goede hdego...@redhat.com wrote: Hi, On 02/10/2014 09:58 PM, Jasper St. Pierre wrote: Something I noticed here is that you use GetSessionByPID

Re: [PATCH] configure.ac: add missing test

2014-02-07 Thread Hans de Goede
Hi, Thanks, this is my bad. Note I already posted a fix for this myself too. Either way, this is: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans On 02/07/2014 02:06 AM, David Heidelberger wrote: --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [PATCH v2 04/14] xf86Xinput: Modify API for server-managed fd support

2014-02-05 Thread Hans de Goede
Hi, On 02/05/2014 12:50 PM, Mark Kettenis wrote: Date: Tue, 04 Feb 2014 16:44:07 +0100 From: Hans de Goede hdego...@redhat.com Hi, On 02/04/2014 02:12 PM, Mark Kettenis wrote: Date: Tue, 04 Feb 2014 13:16:21 +0100 From: Hans de Goede hdego...@redhat.com The systemd-logind API uses separate

Re: [PATCH] xfree86: use xnfstrdup in the Xorg -configure code

2014-02-05 Thread Hans de Goede
-by: Hans de Goede hdego...@redhat.com diff --git a/hw/xfree86/common/xf86Configure.c b/hw/xfree86/common/xf86Configure.c index 6aaf634..967bfbc 100644 --- a/hw/xfree86/common/xf86Configure.c +++ b/hw/xfree86/common/xf86Configure.c @@ -159,8 +159,8 @@ configureInputSection(void

Re: [PATCH v2 3/7] input: un-constify InputAttributes

2014-02-04 Thread Hans de Goede
-reviewed it, and yep this is still: Reviewed-by: Hans de Goede hdego...@redhat.com Regards, Hans config/udev.c| 14 +++--- dix/inpututils.c | 16 include/input.h | 12 ++-- test/input.c | 56

[PATCH v2 02/14] linux: xf86OpenConsole remove root-rights check for keeptty option

2014-02-04 Thread Hans de Goede
There is no reason why keeptty cannot be used without root-rights. Signed-off-by: Hans de Goede hdego...@redhat.com Reviewed-by: Peter Hutterer peter.hutte...@who-t.net --- hw/xfree86/os-support/linux/lnx_init.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/hw/xfree86/os-support/linux

[PATCH v2 04/14] xf86Xinput: Modify API for server-managed fd support

2014-02-04 Thread Hans de Goede
, this commit bumps it. systemd-logind tracks devices by their chardev major + minor numbers, since we are breaking ABI anyways also add major and minor fields for easy storage / retreival of these. Signed-off-by: Hans de Goede hdego...@redhat.com --- hw/xfree86/common/xf86Module.h | 2 +- hw/xfree86/common

[PATCH v2 05/14] OdevAttribute: Add config_odev_get_attribute helper

2014-02-04 Thread Hans de Goede
Add a config_odev_get_attribute helper, and replace the diy looing over all the attributes done in various places with calls to this helper. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c| 23 +++ hw/xfree86/common

[PATCH v2 00/14] Use systemd-logind to manage /dev/... nodes for us

2014-02-04 Thread Hans de Goede
Hi All, Here is v2 of my systemd-logind / run the xserver without root rights series, this version drops some already merged patches, and addresses all the review comments on the first RFC posting of these series. One open question is if we want to add a capabilities field to video drivers like

[PATCH v2 01/14] configure: Fix missing test in systemd-daemon check

2014-02-04 Thread Hans de Goede
The commit adding the systemd-daemon configure check has a small error in it where one if statement is missing the test call, this fixes this. Signed-off-by: Hans de Goede hdego...@redhat.com --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b

[PATCH v2 06/14] OdevAttribute: config_odev_add_attribute: replace existing values

2014-02-04 Thread Hans de Goede
If an attribute already exists replace its value rather then adding a duplicate attribute with the new value to the list. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/config/config.c b/config/config.c

[PATCH v2 07/14] OdevAttribute: Add support for integer attributes

2014-02-04 Thread Hans de Goede
Add a couple of new functions for dealing with storing integer values into OdevAttributes. Signed-off-by: Hans de Goede hdego...@redhat.com --- config/config.c | 40 + hw/xfree86/common/xf86platformBus.c | 18 + hw/xfree86

<    2   3   4   5   6   7   8   9   >