Commit graph

7105 commits

Author SHA1 Message Date
Eamon Walsh
2dbcb06a5d xselinux: Use a more informative message when disabled by boolean.
Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:32:09 -07:00
Eamon Walsh
2e0319df67 xselinux: Allow SetWindowCreateContext to be used for pixmaps as well.
Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:32:09 -07:00
Eamon Walsh
bec7c23e42 xselinux: Note something in the log if disabled by boolean.
Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:32:09 -07:00
Eamon Walsh
e84432f926 xselinux: switch from x_device to separate x_pointer and x_keyboard classes.
This will allow separate controls over pointer and keyboard without having
to relabel the devices to separate types.

[Backport to 1.6]

Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:31:47 -07:00
Eamon Walsh
250ce150b2 xace: Relax permissions on XkbGetState from Read to Getattr.
This request is used to get the current keyboard group and is called from
GTK.  It does not return an actual keymap (aside from modifiers) so it
should be safe to relax the permission on it.  However it does return
button state information which should be controlled through a separate
pointer Read check.

Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
(cherry picked from commit c4ffce4dc8)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:30:16 -07:00
Eamon Walsh
f9e6ee70f3 xselinux: Stop special-casing QueryPointer access checks.
XACE has been changed to not return BadAccess on device read failures.
Thus, no need for this workaround code.

[Backport to 1.6]

Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:30:06 -07:00
Eamon Walsh
c1c7feec90 xace: Fake return values on denials in input polling requests.
Instead of returning BadAccess when "read" permission is denied
on a device, falsify the device state (buttons down, keys pressed).
This is nicer to applications, but may still have undesired side
effects.  The long-term solution is not to use these requests in
event-driven code!

Requests affected: QueryPointer, QueryKeymap, XiQueryDevice.

[Backport to 1.6]

Signed-off-by: Eamon Walsh <ewalsh@tycho.nsa.gov>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-27 14:27:47 -07:00
Keith Packard
439c588493 Bump version to 1.6.5
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-11 22:03:32 -07:00
Peter Hutterer
7f2f71da51 ephyr: if -parent is given, check for a trailing -screen. (#24144)
If -parent is given, don't open up a new window if -screen is given as well.
The commandline option -screen allows to set the depth of the embedded
Xephry instance, even though width and height are autoscaled on -parent.

This patch checks for a -screen parameter after -parent and - if one is
found - delays initializing the screen. The parent window id is stored
temporarily but re-set after a -screen argument.
The following command is thus valid:

Xephyr -parent 1234 -screen 640x480@8 -screen 1024x768

It embeds the first 8-bit screen into window 1234 and opens up a new window
for the second screen. Multiple parent arguments are possible, the screens
are embedded in-order.

X.Org Bug 24144 <http://bugs.freedesktop.org/show_bug.cgi?id=24144>

Tested-by: Vic Lee
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 19be992d9d)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-11 21:21:42 -07:00
Keith Packard
c07b2368a7 Bump to version 1.6.4.901
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-10-01 15:24:58 -07:00
Keith Packard
fc31f76b6f Re-fix DGA removal.
Removing DGA ended up breaking any drivers calling into the old
xf86DiDGAInit function as it tried to see if DGA was already enabled
and ended up crashing if the VT wasn't completely initialized. Oops.

Also, if the driver initializes DGA itself, have the DiDGA
initialization overwrite that information as the DiDGA code will call
ReInit on mode detect.

Signed-off-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit db98b26ee1)
2009-09-30 22:21:05 -07:00
Keith Packard
8cf659f3a5 Bump to version 1.6.4
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-09-27 19:21:45 -07:00
Peter Hutterer
a26fd1a6d6 Don't send events through the master if the device has SendCoreEvents off.
In server 1.6, all devices are attached to the master device (VCP or VCK).
Sending an event through the master device means the device is sending core
events. If a device is configured as SendCoreEvents, just send through the
device, not through the master.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-09-27 19:08:14 -07:00
Keith Packard
507e57381f xfree86/modes: Remove all framebuffer support from DGA
This removes all rendering and mapping code from xf86DiDGA, leaving
just mode setting and raw input device access. The mapping code didn't
have the offset within /dev/mem for the frame buffer and the pixmap
support assumed that the framebuffer was never reallocated.
(cherry picked from 0b7c6c728c)

Signed-off-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-09-22 12:17:09 -07:00
Rémi Cardona
c3d182a479 dix: append "built-ins" to the font path in SetDefaultFontPath
49b93df8a3 made the hard dependency on
a "fixed" font go away but only Xorg could use the built-ins fonts by
default.

With this commit, all DDXs get "built-ins" appended to their FontPath, not
just Xorg.

Tested with Xorg, Xvfb and Xnest.
(cherry picked from commit f56cbe1ef2)

Signed-off-by: Rémi Cardona <remi@gentoo.org>
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Tested-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-09-22 12:14:56 -07:00
Daniel Stone
9bc4a69040 fbdevhw: Test for graphics:fb%d as well as graphics/fb%d
Apparently the kernel can't decide on an API to expose to userspace, so
let's just try both in the hope that one will work.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Acked-by: Michel Dänzer <michel@daenzer.net>
(cherry picked from commit f4350c66b4)
2009-09-22 12:10:41 -07:00
Keith Packard
d78669c92d render: return the supported version rather than just passing the proto's version
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-09-22 12:09:48 -07:00
Michel Dänzer
f5d1da499c dri2: Don't crash if pPriv is NULL.
(cherry picked from commit df597709d7)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-09-22 12:04:27 -07:00
Richard Hughes
468787bdd2 Don't reset the lastDeviceEventTime when doing DPMS actions
When we change the DPMS mode, don't play games with the last event time as
this breaks applications using IDLETIME to turn the backlight off after a
preset time.

This patch fixes gnome-power-manager and xfce-power-manager

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit c1d901d723)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-09-22 12:03:33 -07:00
Keith Packard
3044711412 Bump version to 1.6.3.901 (1.6.4 RC1)
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-08-25 22:37:16 -07:00
Keith Packard
d8e48deb21 Block signals while delivering XTest events (fixes bug 23100)
XTest uses the same event list as all input devices, and input devices
use it at SIGIO time. This causes mass confusion when a SIGIO event
occurs in the middle of XTest event processing.

The master branch has a much different fix, using a separate input
queue which reduces latency that may be caused by XTest event queuing;
it's a 'nicer' fix in some ways, but this simple fix should solve the
problem.

Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-08-25 22:29:25 -07:00
Keith Packard
76a1839b0a Ensure that rotation updates happen frequently
The smart scheduler is designed to minimize scheduler overhead by
increasing the interval between WaitForSomething calls when a single
client is running. However, the software rotation code depends on
its BlockHandler being invoked for screen updates; the long delays
caused by the smart scheduler optimizations means that screen updates
can be delayed a long time as well.

The change is simple -- prevent the smart scheduler from increasing
the scheduling interval while any screen is using software rotation.
(cherry picked from commit e7dd1efef4)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-08-25 20:12:17 -07:00
Keith Packard
31dc4fe0be Perform rotation redisplay before calling driver block handler (which may flush rendering)
The rotation block handler uses regular driver rendering functions to
repaint the screen, if those functions queue commands in the driver,
it's important that the driver block handler be invoked after the
rotated image is drawn.

Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 1740cda7a3)
2009-08-25 20:12:17 -07:00
Keith Packard
cebc0a7aa7 xf86_reload_cursors: fix cursor position to eliminate jumping after mode set
xf86_reload_cursors restores the cursor to the correct position, but
that must adjust for cursor hot spot and frame before calling down to
the hardware function, otherwise the cursor jumps to the wrong
position until it is repositioned by the user.

Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 4aab05e3b3)
2009-08-25 20:12:17 -07:00
Michel Dänzer
5848fca11f glx: Clean up more thoroughly if the drawable of a current context goes away.
Fixes crash when restarting compiz, due to cl->currentContexts[x] being stale.
(cherry picked from commit 3020b1d43e)
2009-08-25 20:12:17 -07:00
Michel Dänzer
fad2de1cca glx: If a destroyed window is bound to the current context, make it not current.
Avoids subsequent crashes due to stale pointers to the DrawableRec, see
https://bugs.freedesktop.org/show_bug.cgi?id=21132#c15 and previous comments.

Signed-off-by: Michel Dänzer <daenzer@vmware.com>
(cherry picked from commit 2075d4bf9e)
2009-08-25 20:12:17 -07:00
Richard Hughes
a32d717ac6 Do not reset lastDeviceEventTime when we do dixSaveScreens
When we turn off DPMS with DPMSModeOff and do dixSaveScreens, don't reset the
event time else session clients using IDLETIME will be reset.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 6b5978dcf1)
2009-08-25 20:12:16 -07:00
Peter Hutterer
32115e690f dix: update the sprite trace for all masters && floating slaves (#23257)
When the windows are restructured, CheckMotion needs to be called for all
masters and floating slaves to update the spriteTrace.

X.Org Bug 23257 <http://bugs.freedesktop.org/show_bug.cgi?id=23257>
(cherry picked from commit 6c292d1705)

Tested-by: Thomas Jaeger
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-08-25 20:12:02 -07:00
Dan Nicholson
af7e62a913 xfree86: Link libselinux with Xorg system libraries
Put the reference to -lselinux in XORG_SYS_LIBS so it isn't added as a
make dependency for libxorg.la. Otherwise, make goes looking for a file
-lselinux in the current directory, which it obviously won't find.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Tested-by: Justin P. Mattock <justinmattock@gmail.com>
(cherry picked from commit c73cd3b265)
2009-08-25 19:46:55 -07:00
Peter Hutterer
397f7c42cd config: don't shutdown the libhal ctx if it failed to initialize (#23213)
Regression introduced by b1c3dc6ae2.
Shutting down the libhal_ctx if the init failed may cause an abort.
This can happen if hald is not yet running at server startup.

X.Org Bug 23213 <http://bugs.freedesktop.org/show_bug.cgi?id=23213>

Tested-by: Stefan Dirsch
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 49046088f1)
2009-08-25 19:46:15 -07:00
Peter Hutterer
55c26d8e4d Xext: fix up wrong conditions for negative sync transitions.
If the counter had a value higher than the trigger value for a negative
transition, the trigger value did not get set.

The correct sequence of checks is:
if (positive transition)
   if (counter value < trigger value)
      set up trigger
if (negative transition)
   if (counter value > trigger value)
      set up trigger

Red Hat Bug 501601 <https://bugzilla.redhat.com/show_bug.cgi?id=501601>

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit db568f9eab)
2009-08-25 19:45:36 -07:00
Keith Packard
f274e595ed Bump release number to 1.6.3
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-31 23:37:53 -07:00
Alan Coopersmith
55dcfdbbd6 Remove hardcoded gcc -Wall option from configure.ac
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
(cherry picked from commit 442967c90d)
2009-07-29 15:51:08 -07:00
Adam Jackson
4d349b6c33 selinux: Only activate if policy says to be an object manager
(cherry picked from commit 283a081572)
2009-07-29 15:50:06 -07:00
Ben Skeggs
d0875154f4 quirk: use first detailed timing as preferred for PEA prod 9003 (rh#492359)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 048697ccfa)
2009-07-29 15:49:52 -07:00
Rémi Cardona
c941479ecc config: add HAL error checks
This patch simplifies error handling in the HAL code and fixes a
segfault if libhal_find_device_by_capability() failed.

Fixes http://bugs.gentoo.org/278760

Based on a patch by Martin von Gagern <Martin.vGagern@gmx.net>

Signed-off-by: Rémi Cardona <remi@gentoo.org>
Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit b1c3dc6ae2)
2009-07-29 15:49:36 -07:00
Alan Coopersmith
546f913ff5 Don't printf NULL pointers on HAL connection error
Fixes Solaris bug 6801386 Xorg core dumps on startup if hald not running
http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6801386

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
(cherry picked from commit 1e816065e5)
2009-07-29 15:49:23 -07:00
Keith Packard
155cb2f9a3 Bump to version 1.6.2.901 (1.6.3 RC1)
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 14:22:35 -07:00
Dave Airlie
87900645c2 xfree86: move didLock assignment down to where the function pointer is valid.
crtc->funcs->lock is NULL, so it's no use calling it here. Move it down so
it's actually defined before we use it.

Introduced with 6f59a81600.

Tested-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 0de58c88ab)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Benjamin Defnet
72c9bc64ff randr: fix operation order so that rotation+transform works
The matrix multiply to combine rotation and projective transforms was being
done in the wrong order.

Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit b2bf67b61c)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Benjamin Defnet
7f95d18397 hw/xf86/modes: Set crtc mode/rotation/transform before calling set_mode_major
This moves code out of each implementation of set_mode_major and back into
the X server. The real feature here is that the transform is now available
in the crtc for use by either xf86CrtcRotate or whatever the driver wants to
do. Without this change, the transform was lost for drivers providing the
set_mode_major interface.

Note that users of this API will want to stop smashing the transformPresent
field, and could also stop setting mode/x/y/rotation for new enough X servers,
but there's no reason to make that change as it will break things when
running against older X servers.

Signed-off-by: Keith Packard <keithp@keithp.com>
Acked-by: Daniel Stone <daniel@fooishbar.org>
(cherry picked from commit 6f59a81600)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Matthias Hopf
abc89e2c48 randr: Nuke broken set_origin shortcut
Shortcut is impossible to implement this way, because we don't know for sure
whether the crtc of an output has changed or not.
(cherry picked from commit cadf65a6e1)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Julien Cristau
b1eed8970f randr: fix server crash in RRGetScreenInfo
We don't return rates to randr < 1.1 clients, so don't allocate space
for them.  This fixes a FatalError due to not all allocated space being
used.

X.Org bug#21861 <http://bugs.freedesktop.org/show_bug.cgi?id=21861>

Reported-by: Guillaume Quintin <coincoin169g@gmail.com>
Signed-off-by: Julien Cristau <jcristau@debian.org>
(cherry picked from commit 12e725d08b)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Keith Packard
1addf6fe23 Replace dixLookupResource by dixLookupResourceBy{Type,Class}
dixLookupResource attempted to automatically detect whether the caller
wanted a lookup by-type or by-class, unfortunately, it guessed wrong for
RT_NONE. Instead of trying to make the guess better, this patch just reverts
the unification and creates separate functions for each operation.
(cherry picked from commit f8dd80d13b)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Robert Noland
c838a03e89 One = is more than adequate here. Make is sh safe.
(cherry picked from commit b3e3154cce)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:57 -07:00
Rémi Cardona
68cb38bed6 configure: libXinerama isn't needed anymore
since libXinerama commit 90d4d23bf2e94721149ddc0a80093b10a82e8845 and
xineramaproto commit 21477147613c28c968b5e1eb9d8aea7017dd399d, the
server no longer needs libXinerama.

Signed-off-by: Rémi Cardona <remi@gentoo.org>
(cherry picked from commit 2c69deb92e)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:56 -07:00
Michel Dänzer
ec60f4ca65 EXA: Only pass CT_YXBANDED to RECTS_TO_REGION() if that is really true.
Fixes http://bugs.freedesktop.org/show_bug.cgi?id=22642 .
(cherry picked from commit 3575854481)

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-26 13:56:56 -07:00
Kim Woelders
b10c4fe343 Fix key repeat problem.
Signed-off-by: Kim Woelders <kim@woelders.dk>
2009-07-26 13:56:56 -07:00
Adam Jackson
606f6dba16 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.

(cherry picked from commit 0eb19f9437)
2009-07-09 12:05:31 -04:00
Alan Coopersmith
396d3a7762 Fix build of drivers with 1.6.2 when not using --install-libxf86config
c859b736d1 removed duplicate entries for
these from the Makefile, but removed a different set than was done in
master branch, causing xf86Parser.h to not be installed, which in turn
breaks the build of drivers like -ati, -intel & -nv that use xf86Modes.h,
which includes xf86Parser.h

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-08 13:36:23 -07:00