Peter Hutterer [Tue, 23 Apr 2013 05:39:32 +0000 (15:39 +1000)]
dix: use a temporary variable for listeners[0]
no functional changes
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 18 Apr 2013 00:32:11 +0000 (10:32 +1000)]
dix: drop DeviceIntRec's activeGrab struct
Obsolete since
4bc2761ad5ec2d0668aec639780ffb136605fbc8. This struct
existed so copying a passive grab could be simply done by
activeGrab = *grab
and thus have a copy of the GrabPtr we'd get from various sources but still
be able to check device->grab for NULL.
Since 4bc2761 activeGrab is a pointer itself and points to the same memory
as grabinfo->grab, leaving us with the potential of dangling pointers if
either calls FreeGrab() and doesn't reset the other one.
There is no reader of activeGrab anyway, so simply removing it is
sufficient.
Note: field is merely renamed to keep the ABI. Should be removed in the
future.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 17 Apr 2013 10:14:56 +0000 (20:14 +1000)]
dix: use a tmp variable for the to-be-removed touch listener
No functional changes.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 17 Apr 2013 10:13:34 +0000 (20:13 +1000)]
dix: invert a loop condition
Change the single if condition in the loop body to a
if (!foo) continue;
and re-indent the rest.
No functional changes.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 01:02:40 +0000 (11:02 +1000)]
dix: XAllowEvents() on a touch event means accepting it
A sync grab is the owner once it gets events. If it doesn't replay the
event it will get all events from this touch, equivalent to accepting it.
If the touch has ended before XAllowEvents() is called, we also now need to
send the TouchEnd event and clean-up since we won't see anything more from
this touch.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 1 Mar 2013 02:52:35 +0000 (12:52 +1000)]
dix: move EmitTouchEnd to touch.c
No functional changes, this just enables it to be re-used easier.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Fri, 1 Mar 2013 00:41:01 +0000 (10:41 +1000)]
Xi: Don't emit a TouchEnd event to a frozen device
EmitTouchEnd calls DeliverTouchEvents directly instead of through
public.processInputProc. If a device is frozen, the TouchEnd is
processed while the device is waiting for a XAllowEvents and thus ends the
touch point (and the grab) before the client decided what to do with it. In
the case of ReplayPointer, this loses the event.
This is a hack, but making EmitTouchEnd use processInputProc breaks
approximately everything, especially the touch point is cleaned up during
ProcessTouchEvents. Working around that is a bigger hack than this.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 03:07:26 +0000 (13:07 +1000)]
Xi: use public.processInputProc to replay the touch history
If a device is frozen in results to a grab, we need to enqueue the events.
This makes things complicated, and hard to follow since touch events are now
replayed in the history, pushed into EnqueueEvent, then replayed later
during PlayReleasedEvents in response to an XAllowEvents.
While the device is frozen, no touch events are processed, so if there is a
touch client with ownership mask _below_ the grab this will delay the
delivery and potentially screw gesture recognition. However, this is the
behaviour we have already anyway if the top-most client is a sync pgrab or
there is a sync grab active on the device when the TouchBegin was generated.
(also note, such a client would only reliably work in case of ReplayPointer
anyway)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 27 Feb 2013 05:05:54 +0000 (15:05 +1000)]
Xi: when punting to a new owner, always create TouchEnd events
If a touch is pending_finish and we just punted it to the next owner, that
client must receive a TouchEnd event.
If we just punted to the last owner and that owner not a touch grab, we need
to end the touch since this is the last event to be sent, and the client
cannot accept/reject this.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 23:15:37 +0000 (09:15 +1000)]
Xi: save state for early acceptance
Delivering an event changes the state to LISTENER_IS_OWNER and we thus lose
the information of early acceptance.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 05:28:46 +0000 (15:28 +1000)]
Xi: if a passive async grab is activated from an emulated touch, accept
Async grabs cannot replay events, they cannot reject, so we can do an early
accept here.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 03:04:36 +0000 (13:04 +1000)]
Xi: fix lookup in ActivateEarlyAccept
ActivateEarlyAccept() can only be called from a grabbing client, so we can
ignore the rest. And it's easy enough to get the client from that since
9ad0fdb135a1c336771aee1f6eab75a6ad874aff.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 28 Feb 2013 03:08:27 +0000 (13:08 +1000)]
Xi: update the core listener state if we delivered the touch event
If a TouchBegin is sent to a core client, that client is now the owner.
By the time the TouchEnd is being processed, the client cannot replay
anymore, so we can assume that this is the final touch end and we can clean
up the touch record.
Note: DeliverTouchEmulatedEvent is called for all listeners and immediately
bails out if the client is not the owner and thus shouldn't yet get the
event. Thus, check the return code.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 25 Feb 2013 01:21:07 +0000 (11:21 +1000)]
Xi: if we delivered a TouchEnd to a passive grab, end it
ef64b5ee97099618cf2e2cbbd3e471095695ae24 (which introduced the
TOUCH_CLIENT_ID check) has a wrong assumption that generated touch events
(TOUCH_CLIENT_ID) should not terminate passive grabs.
This is untrue, a TouchEnd may be generated in response to a TouchReject
higher up. If we _deliver_ an event to a client, terminate the passive grab.
This requires us to count the actually delivered events too (first hunk).
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 13 Feb 2013 01:26:11 +0000 (11:26 +1000)]
dix: don't prepend an activated passive grab to the listeners
If the device is currently grabbed as the result of a passive grab
activating, do not prepend that grab to the listeners (unlike active grabs).
Otherwise, a client with a passive pointer grab will prevent touch grabs
from activating higher up in the window stack.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 13 Feb 2013 00:49:23 +0000 (10:49 +1000)]
Xi: not having an ownership mask does not mean automatic acceptance
If we only have a single touch-grabbing client, setting the client as owner
would clean up the touch once the TouchEnd was processed. If the client then
calls XIAllowTouches() it will receive a BadValue for the touch ID (since
the internal record is already cleaned up).
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 9 May 2013 04:30:50 +0000 (14:30 +1000)]
input: print warnings if drivers don't initialize properly
If drivers supply incorrect values don't just quietly return False, spew to
the log so we can detect what's going on. All these cases are driver bugs
and should be fixed immediately.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Peter Hutterer [Thu, 9 May 2013 04:30:49 +0000 (14:30 +1000)]
dix: don't overwrite proximity/focus classes
InitPointerClassDeviceStruct/InitKeyboardDeviceStruct allocate a
proximity/focus class, respectively. If a driver calls
InitFocusClassDeviceStruct or InitProximityClassDeviceStruct beforehand,
the previously allocated class is overwritten, leaking the memory.
Neither takes a parameter other than the device, so we can simply skip
initialising it if we already have one.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Peter Hutterer [Thu, 9 May 2013 23:44:29 +0000 (09:44 +1000)]
dix: reset the OsBuffers after killing all clients
==21860== 24 bytes in 1 blocks are still reachable in loss record 85 of 397
==21860== at 0x4C2B3F8: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==21860== by 0x61ED93: AllocateOutputBuffer (io.c:1037)
==21860== by 0x61E15A: WriteToClient (io.c:764)
==21860== by 0x457B30: ProcQueryExtension (extension.c:275)
==21860== by 0x43596B: Dispatch (dispatch.c:432)
==21860== by 0x425DAB: main (main.c:295)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Robert Morell [Thu, 9 May 2013 20:09:02 +0000 (13:09 -0700)]
os: Reset input buffer's 'ignoreBytes' field
If a client sends a request larger than maxBigRequestSize, the server is
supposed to ignore it.
Before commit
cf88363d, the server would simply disconnect the client. After
that commit, it attempts to gracefully ignore the request by remembering how
long the client specified the request to be, and ignoring that many bytes.
However, if a client sends a BigReq header with a large size and disconnects
before actually sending the rest of the specified request, the server will
reuse the ConnectionInput buffer without resetting the ignoreBytes field. This
makes the server ignore new X clients' requests.
This fixes that behavior by resetting the ignoreBytes field when putting the
ConnectionInput buffer back on the FreeInputs list.
Signed-off-by: Robert Morell <rmorell@nvidia.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 27 Feb 2012 08:36:39 +0000 (18:36 +1000)]
dix: delete all callbacks before reset
DeleteCallbackManager() introduced for better symmetry in the caller, they
do the same thing.
==20085== 24 bytes in 1 blocks are still reachable in loss record 11 of 103
==20085== at 0x4C2A4CD: malloc (vg_replace_malloc.c:236)
==20085== by 0x43A097: CreateCallbackList (dixutils.c:837)
==20085== by 0x43A1D3: AddCallback (dixutils.c:869)
==20085== by 0x4B1736: GEExtensionInit (geext.c:209)
==20085== by 0x41C8A8: InitExtensions (miinitext.c:389)
==20085== by 0x5AC918: main (main.c:208)
==2042== 8 bytes in 1 blocks are still reachable in loss record 2 of 97
==2042== at 0x4C2A4CD: malloc (vg_replace_malloc.c:236)
==2042== by 0x4C2A657: realloc (vg_replace_malloc.c:525)
==2042== by 0x4802F5: XNFrealloc (utils.c:1095)
==2042== by 0x43A17A: CreateCallbackList (dixutils.c:855)
==2042== by 0x43A1EF: AddCallback (dixutils.c:870)
==2042== by 0x4B1752: GEExtensionInit (geext.c:209)
==2042== by 0x41C8A8: InitExtensions (miinitext.c:389)
==2042== by 0x5AC9E4: main (main.c:208)
==2042==
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Wed, 24 Apr 2013 04:59:11 +0000 (14:59 +1000)]
Xi: free barrier code at reset time
==29423== 16 bytes in 1 blocks are definitely lost in loss record 73 of 328
==29423== at 0x4A06B6F: calloc (vg_replace_malloc.c:593)
==29423== by 0x5987C0: XIBarrierInit (xibarriers.c:908)
==29423== by 0x58F370: XInputExtensionInit (extinit.c:1300)
==29423== by 0x4F33C3: InitExtensions (miinitext.c:337)
==29423== by 0x4997DB: main (main.c:208)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Tue, 30 Apr 2013 05:44:37 +0000 (15:44 +1000)]
os: Use ErrorFSigSafe from FatalError and it's friends
Backtrace logging etc. is already sigsafe, but the actual FatalError message
in response is not yet, leading to amusing logs like this:
(EE) Segmentation fault at address 0x0
(EE) BUG: triggered 'if (inSignalContext)'
(EE) BUG: log.c:499 in LogVMessageVerb()
(EE) Warning: attempting to log data in a signal unsafe manner while in
signal context.
Please update to check inSignalContext and/or use LogMessageVerbSigSafe() or
ErrorFSigSafe().
The offending log format message is:
Fatal server error:
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 14 Feb 2013 06:24:53 +0000 (16:24 +1000)]
os: complain about unsupported pnprintf directives
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 14 Feb 2013 06:19:34 +0000 (16:19 +1000)]
os: support %c in pnprintf
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 14 Feb 2013 06:13:22 +0000 (16:13 +1000)]
os: support %% in pnprintf
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 14 Feb 2013 05:34:32 +0000 (15:34 +1000)]
os: support pnprintf length modifiers for integers
Mainly for %ld, smaller than int is propagated anyway, and %lld isn't really
used.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Mon, 27 Feb 2012 08:59:45 +0000 (18:59 +1000)]
dix: reset the registry before quitting
Heaps of these:
==2042== 15,360 bytes in 120 blocks are still reachable in loss record 94 of
97
==2042== at 0x4C2A4CD: malloc (vg_replace_malloc.c:236)
==2042== by 0x4C2A657: realloc (vg_replace_malloc.c:525)
==2042== by 0x45FB91: double_size (registry.c:65)
==2042== by 0x45FC97: RegisterRequestName (registry.c:85)
==2042== by 0x460095: RegisterExtensionNames (registry.c:179)
==2042== by 0x460729: dixResetRegistry (registry.c:334)
==2042== by 0x5AC992: main (main.c:201)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Mon, 27 Feb 2012 07:17:41 +0000 (17:17 +1000)]
xkb: free XkbRulesUsed and XkbRulesDflt on extension cleanup
==2547== 1 bytes in 1 blocks are still reachable in loss record 1 of 111
==2547== at 0x4C2A4CD: malloc (vg_replace_malloc.c:236)
==2547== by 0x64D1551: strdup (strdup.c:43)
==2547== by 0x4802FB: Xstrdup (utils.c:1113)
==2547== by 0x585B6C: XkbSetRulesUsed (xkbInit.c:219)
==2547== by 0x58700F: InitKeyboardDeviceStruct (xkbInit.c:595)
==2547== by 0x419FA3: vfbKeybdProc (InitInput.c:74)
==2547== by 0x425A3D: ActivateDevice (devices.c:540)
==2547== by 0x425F65: InitAndStartDevices (devices.c:713)
==2547== by 0x5ACA57: main (main.c:259)
and a few more of the above.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 31 Jan 2013 23:06:20 +0000 (09:06 +1000)]
If neither HAL nor udev backends are enabled, warn the user
If both are missing, input device hotplugging will not work out of the box.
While we still have a DBus-API or the user may want to set AAD off all the
time, the most likely source of this is misconfiguration (i.e. lack of the
udev/hal devel packages).
Message printed last to make it more obvious to the user.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Tue, 26 Feb 2013 02:34:21 +0000 (12:34 +1000)]
Xi: always return BadMatch for XTest devices ChangeDeviceControl requests
The only controls that still do something are DEVICE_RESOLUTION and
DEVICE_ENABLE.
XTest devices have no resolution to change, and they cannot be disabled. So
skip the lot, and prevent a crash in the DDX when it's trying to
de-reference pInfo->control_proc on device with no pInfo struct.
Likewise, don't allow setting device mode or the valuators.
XTest pointers are always relative, they don't have a mode.
Test cases:
xts5/XI/ChangeDeviceControl (1/10)
xts5/XI/SetDeviceValuators (1/6)
and a few others
Reported-by: Knut Petersen <Knut_Petersen@t-online.de>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Thu, 14 Mar 2013 01:07:57 +0000 (11:07 +1000)]
dix: send the current axis value in DeviceChangedEvents (#62321)
X.Org Bug 62321 <http://bugs.freedesktop.org/show_bug.cgi?id=62321>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Peter Hutterer [Fri, 15 Feb 2013 01:19:10 +0000 (11:19 +1000)]
Xi: fix comment - XI2 grabs aren't keysym grabs
Comment dates back to a pre-release version of XI2 that supported keysym
grabs. That never made it into a release, it was ditched before.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Keith Packard [Mon, 6 May 2013 17:52:40 +0000 (10:52 -0700)]
Merge remote-tracking branch 'alanc/master'
Keith Packard [Mon, 6 May 2013 17:20:21 +0000 (10:20 -0700)]
Merge remote-tracking branch 'jturney/unused-but-set-variable-warning-fix'
Aaron Plattner [Tue, 30 Apr 2013 21:30:18 +0000 (14:30 -0700)]
xfree86: don't enable anything in xf86InitialConfiguration for GPU screens
There's no point in turning on outputs connected to GPU screens during initial
configuration. Not only does this cause them to just display black, it also
confuses clients when these screens are attached to a master screen and RandR
reports that the outputs are already on.
Also, don't print the warning about no outputs being found on GPU screens,
since that's expected.
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Reviewed-by: Dave Airlie <airlied@gmail.com>
Jon TURNEY [Wed, 3 Apr 2013 17:43:26 +0000 (18:43 +0100)]
hw/xwin: Fix unused-but-set-variable warning in ProcWindowsWMFrameGetRect()
/jhbuild/checkout/xorg/xserver/hw/xwin/winwindowswm.c: In function ‘ProcWindowsWMFrameGetRect’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winwindowswm.c:322:12: error: variable ‘ir’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 17:34:38 +0000 (18:34 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winMWExtWMUpdateWindowDecoration()
/jhbuild/checkout/xorg/xserver/hw/xwin/winwin32rootlesswindow.c: In function ‘winMWExtWMUpdateWindowDecoration’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winwin32rootlesswindow.c:189:11: error: variable ‘dwStyle’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:40:35 +0000 (16:40 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winHotKeyAltTabPrimaryDD()
/jhbuild/checkout/xorg/xserver/hw/xwin/winpfbdd.c: In function ‘winHotKeyAltTabPrimaryDD’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winpfbdd.c:518:20: error: variable ‘rcSrc’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:33:39 +0000 (16:33 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winMinimizeWindow() when built !XWIN_MULTIWINDOWEXTWM
/jhbuild/checkout/xorg/xserver/hw/xwin/winmultiwindowwindow.c: In function ‘winMinimizeWindow’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winmultiwindowwindow.c:813:20: error: variable ‘pScreenInfo’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:27:45 +0000 (16:27 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winClipboardProc()
/jhbuild/checkout/xorg/xserver/hw/xwin/winclipboardthread.c: In function ‘winClipboardProc’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winclipboardthread.c:88:25: error: variable ‘atomClipboardManager’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:25:54 +0000 (16:25 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winWindowProc()
/jhbuild/checkout/xorg/xserver/hw/xwin/winwndproc.c: In function ‘winWindowProc’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winwndproc.c:65:22: error: variable ‘s_hInstance’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:24:08 +0000 (16:24 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winCopyWindowNativeGDI()
/jhbuild/checkout/xorg/xserver/hw/xwin/winwindow.c: In function ‘winCopyWindowNativeGDI’:
/jhbuild/checkout/xorg/xserver/hw/xwin/winwindow.c:131:15: error: variable ‘pwinRoot’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:50:38 +0000 (16:50 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winFinishScreenInitFB()
/jhbuild/checkout/xorg/xserver/hw/xwin/winscrinit.c:264:11: error: variable ‘pbits’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:18:27 +0000 (16:18 +0100)]
hw/xwin: Fix unused-but-set-variable warning in winIsFakeCtrl_L()
/jhbuild/checkout/xorg/xserver/hw/xwin/winkeybd.c:331:17: error: variable ‘lastMessage’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Jon TURNEY [Wed, 3 Apr 2013 15:16:06 +0000 (16:16 +0100)]
hw/xwin: Fix unused-but-set-variable warnings in windialog.c
/jhbuild/checkout/xorg/xserver/hw/xwin/windialogs.c: In function ‘winChangeDepthDlgProc’:
/jhbuild/checkout/xorg/xserver/hw/xwin/windialogs.c:432:22: error: variable ‘s_pScreen’ set but not used [-Werror=unused-but-set-variable]
/jhbuild/checkout/xorg/xserver/hw/xwin/windialogs.c: In function ‘winAboutDlgProc’:
/jhbuild/checkout/xorg/xserver/hw/xwin/windialogs.c:564:22: error: variable ‘s_pScreen’ set but not used [-Werror=unused-but-set-variable]
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Reviewed-by: Colin Harrison <colin.harrison@virgin.net>
Dave Airlie [Wed, 9 Jan 2013 02:52:13 +0000 (12:52 +1000)]
gpu: call CreateScreenResources for GPU screens
I didn't think we needed this before, but after doing some more
work with reverse optimus it seems like it should be called.
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 02:52:08 +0000 (12:52 +1000)]
dix: allow pixmap dirty helper to be used for non-shared pixmaps
this allows the pixmap dirty helper to be used for reverse optimus,
where the GPU wants to copy from the shared pixmap to its VRAM copy.
[airlied: slave_dst is wrong name now but pointless ABI churn at this point]
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 02:52:03 +0000 (12:52 +1000)]
xf86crtc: don't use scrn->display for gpu screens
scrn->display is a property of the main screen really, and we don't
want to have the GPU screens use it for anything when picking modes
or a front buffer size.
This fixes a bug where when you plugged a display link device, it
would try and allocate a screen the same size as the current running
one (3360x1050 in this case), which was too big for the device. Avoid
doing this and just pick sizes based on whats plugged into this device.
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 02:51:55 +0000 (12:51 +1000)]
dix/gpu: remove asserts for output/offload from same slave
We should have no problem allowing output/offload from the same slave,
I asserted here, but in order to implement reverse optimus this makes
perfect sense. (reverse optimus is intel outputting to nvidia).
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 04:26:35 +0000 (14:26 +1000)]
randr: report changes when we disconnect a GPU slave
When we disconnect an output/offload slave set the changed bits,
so a later TellChanged can do something.
Then when we remove a GPU slave device, sent change notification
to the protocol screen.
This allows hot unplugged USB devices to disappear in clients.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 04:25:43 +0000 (14:25 +1000)]
randr: only respected changed on the protocol screen
We don't want to know about changes on the non-protocol screen,
we will fix up setchanged to make sure non-protocol screens update
the protocol screens when they have a change.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 04:29:47 +0000 (14:29 +1000)]
randr: make SetChanged modify the main protocol screen not the gpu screen
When SetChanged is called we now modify the main protocol screen,
not the the gpu screen. Since changed stuff should work at the protocol level.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 9 Jan 2013 04:23:57 +0000 (14:23 +1000)]
randr: don't directly set changed bits in randr screen
Introduce a wrapper interface so we can fix things up for multi-gpu
situations later.
This just introduces the API for now.
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Chris Wilson [Thu, 10 Jan 2013 03:26:33 +0000 (03:26 +0000)]
hw/xfree86: Only report SetDesiredModes() failed if at least one modeset fails
commit
6703a7c7cf1a349c137e247a0c8eb462ff7b07be
Author: Keith Packard <keithp@keithp.com>
Date: Tue Jan 8 20:24:32 2013 -0800
hw/xfree86: Require only one working CRTC to start the server.
changed the logic to try to set the mode on all connected outputs rather
than abort upon the first failure. The return error code was then
tweaked such that it reported success if it set a mode on any crtc.
However, this confuses the headless case where we never enable any crtcs
and also, importantly, never fail to set a crtc.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=59190
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Also-written-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
Alan Coopersmith [Wed, 24 Apr 2013 22:24:31 +0000 (15:24 -0700)]
Only call xf86platformVTProbe() when it's defined
Fixes build on non-udev systems, since XSERVER_PLATFORM_BUS is only
defined in configure.ac if $CONFIG_UDEV_KMS is true.
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Keith Packard [Thu, 25 Apr 2013 16:02:31 +0000 (09:02 -0700)]
shadow: Define c2p_unsupported
Just make this call BUG_WARN(1) to indicate that something unexpected
happened
Signed-off-by: Keith Packard <keithp@keithp.com>
Alan Coopersmith [Sun, 10 Feb 2013 18:24:59 +0000 (10:24 -0800)]
sparcPromPathname2Node: free name when returning error, instead of leaking it
Reported with other leaks found by cppcheck in bugzilla #50281
https://bugs.freedesktop.org/show_bug.cgi?id=50281
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Alan Coopersmith [Sun, 10 Feb 2013 18:24:59 +0000 (10:24 -0800)]
xf86SbusCmapLoadPalette: Delay malloc until needed, avoiding leak on error
Reported with other leaks found by cppcheck in bugzilla #50281
https://bugs.freedesktop.org/show_bug.cgi?id=50281
V2: check for malloc failure
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Alan Coopersmith [Sun, 10 Feb 2013 18:18:02 +0000 (10:18 -0800)]
dmxVDLRead: if we opened a file, close it instead of leaking it
Reported with other leaks found by cppcheck in bugzilla #50281
https://bugs.freedesktop.org/show_bug.cgi?id=50281
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Alan Coopersmith [Sun, 10 Feb 2013 18:24:59 +0000 (10:24 -0800)]
__glXDRIscreenProbe: free screen when DRI2Connect fails, instead of leaking it
Reported with other leaks found by cppcheck in bugzilla #50281
https://bugs.freedesktop.org/show_bug.cgi?id=50281
V2: goto existing error handler, instead of replicating more of it here
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Alan Coopersmith [Sun, 10 Feb 2013 18:24:59 +0000 (10:24 -0800)]
__glXDRIscreenCreateContext: free context on failure, instead of leaking it
Reported with other leaks found by cppcheck in bugzilla #50281
https://bugs.freedesktop.org/show_bug.cgi?id=50281
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Keith Packard [Wed, 24 Apr 2013 21:14:45 +0000 (14:14 -0700)]
Merge remote-tracking branch 'geertu/master'
Keith Packard [Wed, 24 Apr 2013 17:27:19 +0000 (10:27 -0700)]
Merge remote-tracking branch 'whot/for-keith'
Keith Packard [Wed, 24 Apr 2013 17:23:51 +0000 (10:23 -0700)]
Merge remote-tracking branch 'airlied/for-keithp-gpu-vt-owner'
Jeremy White [Thu, 21 Mar 2013 15:58:42 +0000 (10:58 -0500)]
Eliminate the use of xf86Rename.h
Signed-off-by: Jeremy White <jwhite@codeweavers.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
Keith Packard [Wed, 24 Apr 2013 17:11:03 +0000 (10:11 -0700)]
Bump to 1.14.99.1
Snapshot with fix for CVE-2013-1940.
Signed-off-by: Keith Packard <keithp@keithp.com>
Andreas Müller [Tue, 16 Apr 2013 12:30:43 +0000 (14:30 +0200)]
dixstruct.h: fix segfaults - char is unsigned for ARM and PowerPC architectures
see ARM related bug reports [1-3]
[1] https://github.com/archlinuxarm/PKGBUILDs/issues/446I
[2] http://www.raspberrypi.org/phpBB3/viewtopic.php?t=38568&p=321673
[3] http://lists.linuxtogo.org/pipermail/openembedded-core/2013-April/037805.html
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Wed, 17 Apr 2013 09:47:42 +0000 (19:47 +1000)]
dix: plug memory leak in freeing TouchClass
==15562== 1,800 bytes in 1 blocks are definitely lost in loss record 298 of 330
==15562== at 0x4A06B6F: calloc (vg_replace_malloc.c:593)
==15562== by 0x4312C7: InitTouchClassDeviceStruct (devices.c:1644)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 20:04:19 +0000 (21:04 +0100)]
Xfbdev: Wire up Amiga afb4 and afb8 support
Add support for Amiga-style bitplanes, with 4 or 8 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 16:17:26 +0000 (17:17 +0100)]
Xfbdev: Wire up Atari iplan2p4 and iplan2p8 support
Add support for Atari-style interleaved bitplanes, with 2 bytes interleave
and 4 or 8 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 16:17:26 +0000 (17:17 +0100)]
Xfbdev: Force shadowfb for frame buffers with non-packed pixels
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 16:17:26 +0000 (17:17 +0100)]
Xfbdev: Reject unsupported frame buffer types
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 20:03:44 +0000 (21:03 +0100)]
Shadow: Add support for Amiga afb8
Add support for Amiga-style bitplanes, with 8 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Wed, 27 Mar 2013 08:37:02 +0000 (09:37 +0100)]
Shadow: Add support for Amiga afb4
Add support for Amiga-style bitplanes, with 4 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 16:16:17 +0000 (17:16 +0100)]
Shadow: Add support for Atari iplan2p8
Add support for Atari-style interleaved bitplanes, with 2 bytes interleave
and 8 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 20:01:02 +0000 (21:01 +0100)]
Shadow: Add support for Atari iplan2p4
Add support for Atari-style interleaved bitplanes, with 2 bytes interleave
and 4 bits per pixel.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sun, 10 Mar 2013 16:15:05 +0000 (17:15 +0100)]
Shadow: Add c2p core
Add Chunky-to-Planar core functionality, to be used by the Atari and Amiga
(interleaved) bitplanes code.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Acked-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Tue, 12 Mar 2013 17:10:40 +0000 (18:10 +0100)]
Xfbdev: Treat 1 bpp pseudocolor as monochrome
miCreateDefColormap() only preallocates black and white pixels if
depth > 1.
Hence override the visual, so fbdevCreateColormap() takes care of it.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Tue, 12 Mar 2013 13:16:10 +0000 (14:16 +0100)]
Xfbdev: Add support for monochrome visuals
Monochrome supports StaticGray, with hardcoded black and white pixels.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Tue, 12 Mar 2013 13:19:25 +0000 (14:19 +0100)]
Xfbdev: Handle unset fix.line_length
Older frame buffer devices may not fill in fix.line_length, in which
case it must be calculated by the application.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Geert Uytterhoeven [Fri, 22 Feb 2013 12:21:28 +0000 (13:21 +0100)]
Xfbdev: Make char *fbdevDevicePath const
This fixes:
hw/kdrive/fbdev/fbdev.c: In function 'fbdevInitialize':
hw/kdrive/fbdev/fbdev.c:41:25: warning: assignment discards 'const' qualifier from pointer target type [enabled by default]
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Tue, 12 Mar 2013 14:20:00 +0000 (15:20 +0100)]
KDrive: Bail out if screen initialization failed
Else we may get a segmentation fault later.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Geert Uytterhoeven [Sat, 23 Feb 2013 19:09:22 +0000 (20:09 +0100)]
test/input: Fix double-aligned test in dix_valuator_alloc() on m68k
On m68k, doubles are not 64-bit aligned, just like on i386 and sh.
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Geert Uytterhoeven [Fri, 22 Feb 2013 20:10:07 +0000 (21:10 +0100)]
miext/shadow/shpacked.c: Remove unused PickBit() define
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Dave Airlie [Wed, 10 Apr 2013 06:09:01 +0000 (16:09 +1000)]
xf86: fix flush input to work with Linux evdev devices.
So when we VT switch back and attempt to flush the input devices,
we don't succeed because evdev won't return part of an event,
since we were only asking for 4 bytes, we'd only get -EINVAL back.
This could later cause events to be flushed that we shouldn't have
gotten.
This is a fix for CVE-2013-1940.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Mon, 27 Feb 2012 08:50:46 +0000 (18:50 +1000)]
Stop the shouting
Meanwhile, here in the future lowercase letters have been invented.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
Peter Hutterer [Mon, 27 Feb 2012 07:22:16 +0000 (17:22 +1000)]
dix: only allocate unused classes for master devices
Slave devices don't need these and the matching code in CloseDevice() has a
IsMaster() condition on freeing these, causing a leak.
==16111== 384 bytes in 4 blocks are definitely lost in loss record 72 of 105
==16111== at 0x4C28BB4: calloc (vg_replace_malloc.c:467)
==16111== by 0x42AEE2: AllocDevicePair (devices.c:2707)
==16111== by 0x4BAA27: AllocXTestDevice (xtest.c:617)
==16111== by 0x4BA89A: InitXTestDevices (xtest.c:570)
==16111== by 0x425F5E: InitCoreDevices (devices.c:690)
==16111== by 0x5ACB2D: main (main.c:257)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Chase Douglas <chase.douglas@canonical.com>
Maarten Lankhorst [Mon, 15 Apr 2013 14:53:48 +0000 (16:53 +0200)]
dix: copy event in TouchConvertToPointerEvent correctly
Fixes reading random memory read beyond the end of original event.
sizeof device_event: 424
sizeof internal_event: 2800
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Knut Petersen [Tue, 26 Feb 2013 06:52:59 +0000 (07:52 +0100)]
Never try to execute BellProcPtr NULL.
This prevents xts XI/XDeviceBell-2 test
from segfaulting the server.
Signed-off-by: Knut Petersen <Knut_Petersen@t-online.de>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Rui Matos [Sat, 13 Apr 2013 02:22:54 +0000 (04:22 +0200)]
Xi: fix swapped grab mode args for keyboard devices in XIGrabDevice
The protocol says that the grab_mode argument applies to the device
being grabbed and paired_device_mode to the paired master
device. GrabDevice() however takes in a pointer mode and a keyboard
mode and so we have to swap the values according the type of device
being grabbed.
Signed-off-by: Rui Matos <tiagomatos@gmail.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Bryce Harrington [Thu, 11 Apr 2013 06:05:40 +0000 (23:05 -0700)]
xfree86: Revert workaround for drm race condition.
Revert
70739e817b2d64bc020ea491f23a3574bdb6155e and mostly revert
c31eac647a9ecf0fb20dc98266cadf0ba923ba14.
Further investigation shows the encountered race condition is between
lightdm and plymouth-splash, as implemented in the Ubuntu distribution
within the limitations of upstart's job coordination logic, and can (and
should) be fixed within those limiations. Not in xserver itself.
This leaves some of the diagnostic improvements from the recent patch
series, in case others run into a similar situation.
Signed-off-by: Bryce Harrington <bryce@canonical.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Thu, 11 Apr 2013 23:14:53 +0000 (09:14 +1000)]
xfree86: change a log message
This path is technically executed through config/udev, but having two
messages in the form "config/udev: Adding drm device" makes it appear as if
the udev filters are wrong and it's trying to add the same device twice. In
fact, it's only one device, only added once, but a duplicate log message.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 10 Apr 2013 06:32:15 +0000 (16:32 +1000)]
xf86: don't hotplug output devices while VT switched.
We don't want to hotplug output devices while we are VT switched,
as we get races between multiple X servers on the device open, and
drm device master status. This just queues device opens until we return
from VT switch.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Wed, 10 Apr 2013 06:32:11 +0000 (16:32 +1000)]
xf86: use new xf86VTOwner interface in a few places
This replaces some previous uses of direct xf86Screens[0] accesses.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Dave Airlie <airlied@gmail.com>
Dave Airlie [Wed, 10 Apr 2013 06:32:02 +0000 (16:32 +1000)]
xfree86: add VT owner interface
This is just a simple interface to avoid accessing x86Screens[0]
directly.
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Dave Airlie <airlied@gmail.com>
Maarten Lankhorst [Tue, 9 Apr 2013 09:19:07 +0000 (11:19 +0200)]
Xi: Do not handle ET_TouchOwnership in ProcessTouchEvent
The event struct is different, causing memory corruption on 1.13 and 1.14,
as can be witnessed in https://bugs.freedesktop.org/show_bug.cgi?id=56578
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Keith Packard [Tue, 9 Apr 2013 23:23:19 +0000 (16:23 -0700)]
Xi: Use correct destination when swapping barrier events
Write the swapped values to the destination rather than the source.
Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Jasper St. Pierre <jstpierre@mecheye.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Peter Hutterer [Sun, 3 Mar 2013 21:58:41 +0000 (07:58 +1000)]
dix: don't set non-exisiting flags on touch events
Unlike pointer/keyboard events, the flags field for ET_Touch* is a set of
server-internal defines that we need to convert to XI protocol defines.
Currently only two of those defines actually translate to the protocol, so
make sure we don't send internal garbage down the wire.
No effect to current clients since they shouldn't look at undefined bits
anyway.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Jeremy White [Thu, 21 Mar 2013 15:58:57 +0000 (10:58 -0500)]
Define prototypes for hw/xfree86/modes/xf86Modes.c only in xf86Modes.h.
This removes a large number of redundant declaration warnings.
Signed-off-by: Jeremy White <jwhite@codeweavers.com>
Reviewed-by: Robert Morell <rmorell@nvidia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>