Re: [PATCH 1/3][master][1.12] Don't attempt to add non-master core touch pointer emulation listeners

2012-04-18 Thread Peter Hutterer
On Mon, Apr 16, 2012 at 11:22:48AM -0700, Chase Douglas wrote: On 04/12/2012 10:38 PM, Peter Hutterer wrote: On Wed, Apr 04, 2012 at 01:48:09PM -0700, Chase Douglas wrote: Core events aren't generated for slave devices, so this is just wrong. On top of that, the mask being checked in the

Re: [PATCH 06/10] Create a new dix touch record for an emulated touch with no listeners

2012-04-18 Thread Peter Hutterer
On Tue, Apr 17, 2012 at 04:33:25PM -0700, Chase Douglas wrote: As a special case, if a pointer emulated touch has no listeners and the device is explicitly grabbed for pointer events, create a new dix touch record for the grab only. this should include and the touch is still physically down.

Re: [PATCH 09/10] Save physical button state for emulated touches too

2012-04-18 Thread Peter Hutterer
On Tue, Apr 17, 2012 at 04:33:28PM -0700, Chase Douglas wrote: The physical button state is reported by XIQueryPointer for clients this should read logical button state and I believe TouchClassRec::state already has exactly this information, right? Cheers, Peter supporting XI 2.1 and

Re: [PATCH 00/10] Miscellaneous input fixes

2012-04-18 Thread Peter Hutterer
On Tue, Apr 17, 2012 at 04:33:19PM -0700, Chase Douglas wrote: These are more input fixes for various issues, mostly involving touchscreen pointer emulation. I have started maintaining a branch of all my fixes so I can keep better track of them. The branch can be found here:

Re: [PULL v2] XResource extension v1.2

2012-04-18 Thread Erkki Seppala
On 17.04.2012 18:20, Alan Coopersmith wrote: They seem to apply fine, and there haven't been updated, so yes. However, I'm wondering on which tree the server side is integrated into, not on fdo/xorg/xserver master surely? Or then my git-fu is too poor :). Oh, erm, I could have sworn they were.

Re: [PATCH 03/11] glx: Extend __GLXscreen::createContext to take attributes

2012-04-18 Thread Christopher James Halse Rogers
On Tue, 2012-04-17 at 08:36 -0700, Ian Romanick wrote: On 04/17/2012 03:05 AM, Christopher James Halse Rogers wrote: On Fri, 2012-04-13 at 18:11 -0700, Ian Romanick wrote: From: Ian Romanickian.d.roman...@intel.com The attributes will be used for glXCreateContextAttribsARB additions in

[PATCH 2/4] os/xprintf: add Xvscnprintf and Xscnprintf

2012-04-18 Thread Daniel Kurtz
Normal snprintf() usually returns the number of bytes that would have been written into a buffer had the buffer been long enough. The scnprintf() variants return the actual number of bytes written, excluding the trailing '\0'. Signed-off-by: Daniel Kurtz djku...@chromium.org ---

[PATCH 0/4] os/log: fixes for timestamps and malicious devices

2012-04-18 Thread Daniel Kurtz
Input drivers like to prepend the device name to logging messages using LogVHdrMessageVerb(). The current implementation of this function used the output of a snprintf() as the format string of another snprintf(). This is a big no-no, as a device name containing format strings could cause Bad

[PATCH 3/4] os/log: only write timestamp if a message is actually written to logfile

2012-04-18 Thread Daniel Kurtz
The current code will write a timestamps into the logFile whenever the last message ended with a '\n' - even if the verb for that timestamp is at too high a level. This timestamp will sit there with no matching message until the next call to LogVWrite with a valid verb. In other words, in some

[PATCH 1/4] os/log: trivial cleanups

2012-04-18 Thread Daniel Kurtz
* space-tab * remove comment that doesn't make any sense Signed-off-by: Daniel Kurtz djku...@chromium.org --- os/log.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/os/log.c b/os/log.c index 061b3dd..92cb7aa 100644 --- a/os/log.c +++ b/os/log.c @@ -168,7 +168,7 @@

[PATCH 4/4] os/log: refactor logging

2012-04-18 Thread Daniel Kurtz
It is not safe to ever use an arbitrary (possibly user supplied) string as part of the format for a *sprintf() call. For example: 1. Name a Bluetooth keyboard %n%n%n%n%n%n%n%n 2. Pair it with a computer running X and try to use it 3. X is not happy when trying to do the following in

Re: [PATCH 0/4] os/log: fixes for timestamps and malicious devices

2012-04-18 Thread Daniel Stone
Hi, On 18 April 2012 10:51, Daniel Kurtz djku...@chromium.org wrote: Input drivers like to prepend the device name to logging messages using LogVHdrMessageVerb().  The current implementation of this function used the output of a snprintf() as the format string of another snprintf().  This is a

Re: [PATCH 0/4] os/log: fixes for timestamps and malicious devices

2012-04-18 Thread Daniel Kurtz
On Wed, Apr 18, 2012 at 7:42 PM, Daniel Stone dan...@fooishbar.org wrote: Hi, On 18 April 2012 10:51, Daniel Kurtz djku...@chromium.org wrote: Input drivers like to prepend the device name to logging messages using LogVHdrMessageVerb(). The current implementation of this function used

[PULL v3] XResource extension v1.2

2012-04-18 Thread Erkki Seppala
Only the patches against the xserver needed some updating. Those updates were: - the renaming of struct list to struct xorg_list - swapl/swaps now use only one argument - some code layout fixes - and two misuses (..I think..) of swaps were detected by new compiler diagnostics of the revised

Re: [PATCH 0/4] os/log: fixes for timestamps and malicious devices

2012-04-18 Thread Daniel Stone
Hi, On 18 April 2012 13:14, Daniel Kurtz djku...@chromium.org wrote: On Wed, Apr 18, 2012 at 7:42 PM, Daniel Stone dan...@fooishbar.org wrote: On 18 April 2012 10:51, Daniel Kurtz djku...@chromium.org wrote: Input drivers like to prepend the device name to logging messages using

Re: [PATCH 09/10] Save physical button state for emulated touches too

2012-04-18 Thread Chase Douglas
On 04/17/2012 11:41 PM, Peter Hutterer wrote: On Tue, Apr 17, 2012 at 04:33:28PM -0700, Chase Douglas wrote: The physical button state is reported by XIQueryPointer for clients this should read logical button state and I believe TouchClassRec::state already has exactly this information,

Re: [PATCH] man: move ClickPad documentation into a single area

2012-04-18 Thread Chase Douglas
On 04/17/2012 10:30 PM, Peter Hutterer wrote: Having to read only one section is a tad easier than collecting the separate options. Signed-off-by: Peter Hutterer peter.hutte...@who-t.net --- man/synaptics.man | 50 -- 1 file changed, 32

[PATCH] miext/shadow: Remove ancient backwards-compatibility hack

2012-04-18 Thread Adam Jackson
Here's a trip down memory lane. Back when we merged kdrive we adopted kdrive's version of shadow, which used damage directly instead of hand-rolling it. However a couple of Xorg drivers referred to the accumulated damage region in the shadow private directly, so I added a hack to copy the damage

[PATCH xorg-gtest 1/3] Add Environment::Kill() to forcefully terminate the dummy Xorg server

2012-04-18 Thread Chase Douglas
Signed-off-by: Chase Douglas chase.doug...@canonical.com --- include/xorg/gtest/environment.h |5 + src/environment.cpp |6 ++ 2 files changed, 11 insertions(+), 0 deletions(-) diff --git a/include/xorg/gtest/environment.h b/include/xorg/gtest/environment.h index

[PATCH xorg-gtest 2/3] Kill dummy Xorg server when a terminating signal arrives

2012-04-18 Thread Chase Douglas
This only takes effect if the program links in the provided main() function. If you provide your own main() you must handle signals yourself. Signed-off-by: Chase Douglas chase.doug...@canonical.com --- src/xorg-gtest_main.cpp | 56 ++- 1 files

[PATCH xorg-gtest 3/3] Provide a full server layout in dummy.conf

2012-04-18 Thread Chase Douglas
The X.org server uses the first server layout, and provides one if none are found. If a layout is specified in /usr/share/X11/xorg.conf.d, the dummy video device configuration may not be used. This change ensures that the dummy video device is used by providing a full server layout in the main

Re: [PATCH 4/5] Use current time for event timestamps

2012-04-18 Thread Chase Douglas
On 04/17/2012 10:56 PM, Peter Hutterer wrote: On Mon, Apr 16, 2012 at 11:20:18AM -0700, Chase Douglas wrote: On 04/12/2012 10:27 PM, Peter Hutterer wrote: On Wed, Apr 11, 2012 at 11:22:13AM -0700, Chase Douglas wrote: During testing I was able to cause a pointer grab replay to fail by sending

Re: [PATCH 1/3][master][1.12] Don't attempt to add non-master core touch pointer emulation listeners

2012-04-18 Thread Chase Douglas
On 04/17/2012 11:03 PM, Peter Hutterer wrote: On Mon, Apr 16, 2012 at 11:22:48AM -0700, Chase Douglas wrote: On 04/12/2012 10:38 PM, Peter Hutterer wrote: On Wed, Apr 04, 2012 at 01:48:09PM -0700, Chase Douglas wrote: Core events aren't generated for slave devices, so this is just wrong. On

Re: [PATCH 1/3][master][1.12] Don't attempt to add non-master core touch pointer emulation listeners

2012-04-18 Thread Chase Douglas
On 04/18/2012 11:45 AM, Chase Douglas wrote: On 04/17/2012 11:03 PM, Peter Hutterer wrote: On Mon, Apr 16, 2012 at 11:22:48AM -0700, Chase Douglas wrote: On 04/12/2012 10:38 PM, Peter Hutterer wrote: On Wed, Apr 04, 2012 at 01:48:09PM -0700, Chase Douglas wrote: Core events aren't generated

[PATCH] Check other clients' core masks properly when adding touch listener

2012-04-18 Thread Chase Douglas
The current code checks the core event mask as though it were an XI mask. This change fixes the checks so the proper client and event masks are used. Signed-off-by: Chase Douglas chase.doug...@canonical.com --- dix/touch.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff

[PATCH] Update currentTime in dispatch loop

2012-04-18 Thread Chase Douglas
A request, like input device grabs, may check a request timestamp against currentTime. It is possible for currentTime to lag a previously sent event timestamp. If the client makes a request based on such an event timestamp, the request may fail the validity check against currentTime unless we

Re: [PATCH v3] os: Add -displayfd option

2012-04-18 Thread Chase Douglas
On 04/04/2012 03:29 PM, Chase Douglas wrote: This option specifies a file descriptor in the launching process. X will scan for an available display number and write that number back to the launching process, at the same time as SIGUSR1 generation. This means display managers don't need to

Re: [PATCH] Check other clients' core masks properly when adding touch listener

2012-04-18 Thread Peter Hutterer
On Wed, Apr 18, 2012 at 12:17:15PM -0700, Chase Douglas wrote: The current code checks the core event mask as though it were an XI mask. This change fixes the checks so the proper client and event masks are used. Signed-off-by: Chase Douglas chase.doug...@canonical.com --- dix/touch.c |

Re: [PATCH 09/10] Save physical button state for emulated touches too

2012-04-18 Thread Peter Hutterer
On Wed, Apr 18, 2012 at 07:16:57AM -0700, Chase Douglas wrote: On 04/17/2012 11:41 PM, Peter Hutterer wrote: On Tue, Apr 17, 2012 at 04:33:28PM -0700, Chase Douglas wrote: The physical button state is reported by XIQueryPointer for clients this should read logical button state and I

[PATCH] Replay original touch begin event instead of generated begin event

2012-04-18 Thread Chase Douglas
The generated event does not have axes other than X and Y and has a newer timestamp. In particular, the newer timestamp may be newer than the real touch end event, which may be stuck in the syncEvents queue. If a client uses the timestamps for grabbing bad things may happen. Signed-off-by: Chase

Re: [PATCH 08/10] Update device state including when touch record does not exist

2012-04-18 Thread Peter Hutterer
On Tue, Apr 17, 2012 at 04:33:27PM -0700, Chase Douglas wrote: If a touch is physically active, the pointer core state should reflect that the first button is pressed. Currently, this only occurs when there are active listeners of the touch sequence. By moving the device state updating to the

[PATCH v2] Update currentTime in dispatch loop

2012-04-18 Thread Chase Douglas
A request, like input device grabs, may check a request timestamp against currentTime. It is possible for currentTime to lag a previously sent event timestamp. If the client makes a request based on such an event timestamp, the request may fail the validity check against currentTime unless we

Re: [PATCH v2] Update currentTime in dispatch loop

2012-04-18 Thread Peter Hutterer
On Wed, Apr 18, 2012 at 06:36:12PM -0700, Chase Douglas wrote: A request, like input device grabs, may check a request timestamp against currentTime. It is possible for currentTime to lag a previously sent event timestamp. If the client makes a request based on such an event timestamp, the

Re: [PATCH] Replay original touch begin event instead of generated begin event

2012-04-18 Thread Peter Hutterer
On Wed, Apr 18, 2012 at 06:24:52PM -0700, Chase Douglas wrote: The generated event does not have axes other than X and Y and has a newer timestamp. In particular, the newer timestamp may be newer than the real touch end event, which may be stuck in the syncEvents queue. If a client uses the

[PATCH:libpciaccess] Solaris: Implement map_legacy legacy_io functions

2012-04-18 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith alan.coopersm...@oracle.com --- src/solx_devfs.c | 137 +- 1 file changed, 135 insertions(+), 2 deletions(-) diff --git a/src/solx_devfs.c b/src/solx_devfs.c index 2079df0..4069dc2 100644 --- a/src/solx_devfs.c

Can x input driver read from fifo?

2012-04-18 Thread c-aries
Hi all. I write a x input driver. When the driver read from normal device it works nice. After I change it to read from fifo, the driver works nice also before I turn off the Window Manager. After Xorg process exit, devices are all disabled, the screen won't change to tty, keyboard don't work

Re: synaptics bug 31636: non-uniform horizontal and vertical acceleration

2012-04-18 Thread Peter Hutterer
On Tue, Apr 03, 2012 at 09:29:37AM -0700, Chase Douglas wrote: On 04/02/2012 08:28 PM, Martin Spacek wrote: Hello, About a year ago, Chase Douglas suggested I post about this here. I've only recently become annoyed enough to finally do so. When I add a secondary monitor

Re: synaptics bug 31636: non-uniform horizontal and vertical acceleration

2012-04-18 Thread Peter Hutterer
On Thu, Apr 19, 2012 at 01:53:19PM +1000, Peter Hutterer wrote: On Tue, Apr 03, 2012 at 09:29:37AM -0700, Chase Douglas wrote: On 04/02/2012 08:28 PM, Martin Spacek wrote: Hello, About a year ago, Chase Douglas suggested I post about this here. I've only recently become

[PULL][master][1.12] Miscellaneous touch fixes

2012-04-18 Thread Chase Douglas
The following changes since commit 80fefc42f5e67e6b4a4b440d8991bee7e5f38359: Merge remote-tracking branch 'whot/for-keith' (2012-04-15 21:05:30 -0700) are available in the git repository at: git://people.freedesktop.org/~cndougla/xserver input-fixes for you to fetch changes up to

[PATCH:libpciaccess] Solaris: refactor pci_device_solx_devfs_map_range to reduce code duplication

2012-04-18 Thread Alan Coopersmith
The sparc x86 cases were doing essentially the same things with different paths, so make the path setup be inside the platform specific #ifdefs, make the open, mmap, error handling common code. Signed-off-by: Alan Coopersmith alan.coopersm...@oracle.com --- src/solx_devfs.c | 41

[PATCH:xorg-docs] Comment out mention of X-Resource 1.2 in release notes

2012-04-18 Thread Alan Coopersmith
Since only the protocol headers actually made it in time, skip describing it now, hold off until the server client bits are there so people can use it. Signed-off-by: Alan Coopersmith alan.coopersm...@oracle.com --- general/ReleaseNotes.xml |3 +++ 1 file changed, 3 insertions(+) diff