Commit Graph

7578 Commits

Author SHA1 Message Date
Aaron Plattner
a8cf63fd18 Export CompositeRegisterAlternateVisuals.
Drivers need this if they add visuals that require implicit redirection.  Add a
new SDK header, compositeext.h, to contain the prototype for this function.
2009-04-27 13:29:40 -07:00
Ian Romanick
ff6c7764c2 DRI2: Implement protocol for DRI2GetBuffersWithFormat
This change implements the protocol for DRI2GetBuffersWithFormat, but
the bulk of the differences are the changes to the extension / driver
interface to make this function work.  The old CreateBuffers and
DeleteBuffers routines are replaced with CreateBuffer and DeleteBuffer
(both singular).

This allows drivers to allocate buffers for a drawable one at a time.
As a result, 3D drivers can now allocate the (fake) front-buffer for a
window only when it is needed.  Since 3D drivers only ask for the
front-buffer on demand, the real front-buffer is always created.  This
allows CopyRegion impelemenations of SwapBuffers to continue working.
As with previous version of this code, if the client asks for the
front-buffer for a window, we instead give it the fake front-buffer.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@redhat.com>
2009-04-24 12:49:19 -07:00
Ian Romanick
28ddfc88d8 DRI2: Add interface for drivers to query DRI2 extension version
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2009-04-24 12:24:07 -07:00
Joel Bosveld
a1c98f7fa9 Correct fcntl(F_SETOWN) error check in non-Solaris sigio code
commit 64b7f96dca accidentally inverted the comparison, could
result in crashes on some systems later on.

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-24 10:12:26 -07:00
Alan Coopersmith
64b7f96dca Add SIGIO/SIGPOLL support for Solaris
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-24 00:23:52 -07:00
Alan Coopersmith
0c467b1f99 Add casts to generated entries in sdksyms.c to silence type mismatch warnings
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-24 00:23:51 -07:00
Alan Coopersmith
7d0f7518c2 Fix byte swapping of XF86VidMode{Get,Set}GammaRamp
Fixes OpenSolaris Bug 8315:
Xorg segfaults when screensaver fades in cross-endian xdmcp session
<http://defect.opensolaris.org/bz/show_bug.cgi?id=8315>

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-24 00:23:50 -07:00
Peter Hutterer
932d6bcbb6 mi: remove superfluous check.
mieqProcessInputEvents doesn't process events from MDs anymore, so we don't
need to check for pDev->isMaster.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-24 15:29:24 +10:00
Benjamin Close
fab563bf8f input: propagate XTst events through virtual slave devices.
A XTest virtual slave device pair (kbd/ptr) exists for every master
device pair. This is so XTest events are correctly propogated via slave
devices up to Master devices and the classes are correctly changed along
the way. We add the XTest slave device pair to the Virtual Core pointer
and provide a simple way of creating the devices.

A XTest Slave Device is identified by the XTstDevicePrivateKey property
being set in the devices devProperties

XI events are still propagated through the matching device, in the hope the
client knows what it is doing.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-24 15:28:33 +10:00
Jeremy Huddleston
ccd28ca2ad XQuartz: Localization update
(cherry picked from commit 9435fc5e20)
2009-04-22 19:30:33 -07:00
Jeremy Huddleston
a362d0f4fb XQuartz: Make sure the bgMouseLocationUpdated state is consistent
(cherry picked from commit 8fa8a8e1db)
2009-04-22 19:30:18 -07:00
Dave Airlie
8dc8812c22 exa: add missing exa.h header include 2009-04-23 12:13:35 +10:00
Dave Airlie
3ec6a121e1 exa: missed exa.h change 2009-04-23 12:13:05 +10:00
Dave Airlie
02ae85c4c9 exa: add CreatePixmap2 hook for driver pixmaps.
This adds a revised pixmap hook for driver pixmaps, which is
required to support tiling on various chips.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-04-23 12:04:17 +10:00
Dave Airlie
9d684ba0bc exa: avoid offscreen pixmap swapped out flag for driver pixmaps 2009-04-23 11:42:53 +10:00
Julien Cristau
0dfb97f15f Bug#21324: Add quirk for Iiyama Vision Master 450
Reported-by: Jeremy Henty <onepoint@starurchin.org>
Signed-off-by: Julien Cristau <jcristau@debian.org>
2009-04-22 20:02:38 +02:00
Ian Romanick
44227ef1b7 DRI2: Send the version the code actually supports
This prevents building an older server with a new dri2proto.h from
resulting in a DRI2 extension module that lies about the version it
supports.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2009-04-20 20:58:56 -07:00
Ian Romanick
d1e916d29b DRI2: Add missing front-buffer flush callback.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2009-04-20 20:58:56 -07:00
Benjamin Close
826a5bff01 dix: Change AllocMaster into AllocDevicePair, allow creation of SDs too.
Allocating a slave device is essentially the same as allocating a master device.
Hence we rename AllocMaster to AllocDevicePair and provided the ability to
indicate if a master or slave device pair is required.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-21 13:11:51 +10:00
Peter Hutterer
e2e5932bda dix: don't allow more than MAX_VALUATORS on one device.
Some keyboards (?) advertise more than MAX_VALUATORS axes. Parts of the
internal event delivery relies on not having more than MAX_VALUATOR axes, so
let's cap it down.
If there's real devices that require more than the current 36, I'm sure we can
bump this up.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-21 13:11:51 +10:00
Julien Cristau
063833f3a6 Add XI 1.5 event and requests to protocol.txt 2009-04-20 12:50:34 +02:00
Julien Cristau
4f86ee61a4 Add RandR 1.3 requests to protocol.txt 2009-04-20 12:50:29 +02:00
Colin Harrison
6559f02ef8 xkb: set bell_func in InitKeyboardDeviceStruct.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-20 16:40:34 +10:00
Werner LEMBERG
335c63fcd6 Add newline to some LogMessage strings.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-20 12:38:08 +10:00
Peter Hutterer
0e0642ee94 os: don't malloc memory in LogVMessageVerb.
LogVWrite is limited to a buffer size of 1024, so we don't loose anything here
by truncating. This way we can use LogVMessageVerb (and xf86Msg and friends)
during signal handlers with the normal message types.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-04-19 22:20:18 +10:00
Peter Hutterer
62d2fb6863 xkb: Add XkbFreeRMLVOSet helper function.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Dan Nicholson <dbn.lists@gmail.com>
2009-04-19 22:20:18 +10:00
Adam Jackson
ad76656f88 randr: Accept gamma set requests from XF86VidMode clients too 2009-04-17 17:47:54 -04:00
David Jander
d9bf52b4ab [kdrive] Fix rotation of pointer
Rotation matrix for pointer coordinates was incomplete and pointers with
absolute coordinates did not work correctly in xserver (kdrive) when the
sceen was rotated other than by 0 degrees.

Signed-off-by: David Jander <david.jander@protonic.nl>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2009-04-17 01:34:18 -04:00
Eamon Walsh
4559d2ace6 security: Grant untrusted windows remove access on all windows.
This allows untrusted clients to destroy their own windows when they
have been reparented by a trusted window manager.
2009-04-16 23:46:01 -04:00
Eamon Walsh
3481b32ab9 security: Fix a crash caused by wrong ordering of format arguments. 2009-04-16 23:46:01 -04:00
Eamon Walsh
6045506be0 security: Revert behavior of extension access for compatibility.
Previously, three extensions were defined as "trusted" by the extension:
BIG-REQUESTS, XC-MISC, and XPrint.  No other extensions were permitted
to be used by untrusted clients.

In commit 8b5d21cc1d this was changed for
some reason.  Return to the old, compatible behavior.
2009-04-16 23:46:00 -04:00
Peter Hutterer
56a5955c8c xkb: strdup the values returned by XkbGetRulesDflts
XkbGetRulesDftls may get a copy of what will later be freed when passed into
XkbSetRulesDftls.

On the second run of XkbGet/SetRulesDflts:
XkbGetRulesDflts(rmlvo)
        rmlvo->rules = current-rules

XkbSetRulesDflts(rmlvo)
        free(current-rules)
        current-rules = strdup(rmlvo->rules)

Leaving us with garbage in current-rules.

This patch requires callers of XkbGetRulesDflts to free the associated memory.

See also
http://lists.freedesktop.org/archives/xorg-devel/2009-February/000305.html

Reported-by: Benjamin Close <Benjamin.Close@clearchain.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Benjamin Close <Benjamin.Close@clearchain.com>
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2009-04-17 10:04:28 +10:00
Peter Hutterer
b406886bbf input: allow NULL as XkbRMVLOSet in InitKeyboardDeviceStruct.
Virtually all callers use
    XkbGetRulesDefault(&rmlvo);
    InitKeyboardDeviceStruct(..., rmlvo);

Let's save them the trouble and accept NULL as a hint to take the
default RMLVO.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Benjamin Close <Benjamin.Close@clearchain.com>
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2009-04-17 10:03:40 +10:00
Peter Hutterer
4e4e263bc0 dix: remove un-used parameter "core" from AllowSome
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-17 10:03:30 +10:00
Peter Hutterer
dd6e8a14ec Xi: fix a typo in a #ifdef
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-17 10:03:27 +10:00
Ian Romanick
de1e43181b DRI2: Don't leave empty entries in private->buffers
This should fix bug #21130.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2009-04-15 11:14:58 -07:00
Robert Noland
b3e3154cce One = is more than adequate here. Make is sh safe. 2009-04-15 12:06:19 -05:00
Samuel Thibault
74d27c8b5b Fix build on hurd-i386
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=523970
2009-04-15 15:49:25 +02:00
Dave Airlie
faf7dfa099 randr12: looking up these bits if randr isn't initialised is bad.
When xinerama is enabled we don't get randr protocol, but the
driver might still want randr internals
2009-04-15 18:39:55 +10:00
Ander Conselvan de Oliveira
efa31092d6 xfree86: Remove device from inputInfo.devices if ActivateDevice failed.
After the call to xf86ActivateDevice, the new device will be added to
inputInfo.devices. However, if the subsequent call to ActivateDevice
fails, the correponding InputInfoRec for the device is deleted but an
entry still remains in inputInfo.devices. This might lead to a server
crash later on (on InitAndStartDevices for instance) when the device
control proc would be called for an invalid device.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-15 12:17:57 +10:00
Peter Hutterer
d79bad0aa7 xfree86: don't synthesise a mouse section if synaptics devices are found.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-15 12:17:57 +10:00
Kristian Høgsberg
4a27618565 composite: Fix resource lookups 2009-04-14 16:21:04 -04:00
Kristian Høgsberg
e7785e8af3 xfixes: Fix a couple of resource lookups 2009-04-14 14:24:40 -04:00
Adam Jackson
0eb19f9437 xdmcp: Don't crash on X -query with more than 255 IP addresses. (#20675)
You could be more clever than this, but the wire protocol says this
really is an array of not more than 255 ARRAY8, so it's not just a
matter of changing the types.
2009-04-14 10:57:19 -04:00
Eric Anholt
f0543ae4ec Fix unused var warning from pci cleanups. 2009-04-14 10:35:44 -04:00
Eric Anholt
181cc08c89 Add shave so that we can see the steaming piles of warnings generated.
The old style output can be reenabled for build system debugging using
"make V=1", or --disable-shave at configure time.
2009-04-14 10:35:44 -04:00
Eric Anholt
4474c200a1 Move VENDOR_* defines from AC_SUBST to a header to avoid angering shave.
This is more sane anyway, as it ensures a rebuild when changing them.
2009-04-14 10:35:44 -04:00
Eric Anholt
e72c85547b Move contributed m4 to a subdir so we can more easily update contributions. 2009-04-14 10:35:44 -04:00
Peter Hutterer
bef1cfb239 xnest: remove unused variable 'names'.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-04-14 17:13:34 +10:00
Kristian Høgsberg
7b6400a1b8 glx: Fix drawable private leak on destroy
When a drawable goes away, we don't destroy the GLX drawable in full,
since it may be current for a context.  This means that when the drawable
is destroyed in full later, the backend doesn't get a chance to
destroy resources associated with the drawable (the DRI2Drawable).

With this patch, we destroy the GLX drawable in full when it goes away
and then track down all contexts that reference it and NULL their
pointers.
2009-04-13 13:17:53 -04:00