Commit graph

4860 commits

Author SHA1 Message Date
Jeremy Huddleston
ceaa2f438d XQuartz: RandR: Capture the display when switching modes with RandR
This will prevent native windows from resizing as we change resolutions.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 13578b852b)
2011-03-03 18:16:07 -08:00
Jeremy Huddleston
0e253a9c86 XQuartz: Localization Updates
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit b17fc99cb9)
2011-02-24 20:07:07 -08:00
Jeremy Huddleston
3412f4799c XQuartz: Add LSApplicationCategoryType key to Info.plist
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 59850630fe)
2011-02-24 20:06:57 -08:00
Jeremy Huddleston
79a367d6e3 XQuartz: Localization Updates
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 8c1f75a1d4)
2011-01-30 17:06:56 -08:00
Jeremy Huddleston
3396d237a5 XQuartz: Use the default signal handler
This allows better interaction with CrashTracer

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit effaf9459c)
2011-01-30 17:06:52 -08:00
Jeremy Huddleston
e7871a9512 XQuartz: Call RRScreenSizeNotify after handling externally-generated XP_EVENT_DISPLAY_CHANGED
We get an XP_EVENT_DISPLAY_CHANGED event when our display configuration is
changed.  If this change was caused by hotplugging a monitor or Mac Display
Preferences changes by the user, we need to call RRScreenSizeNotify in order
to ensure new connections get the correct screen size.

http://xquartz.macosforge.org/trac/ticket/460

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 418bb57a39)
2011-01-30 17:06:43 -08:00
Jeremy Huddleston
824ebda72a XQuartz: Bump version string to 2.6.1
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 6f52b10b9e)
2011-01-30 17:06:34 -08:00
Jeremy Huddleston
c11f9bfc08 XQuartz: Update copyright dates in bundle's plist
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-01-07 17:21:33 -08:00
Zhao Yakui
3d12e6d25a edid: Fix incorrect timings for VIC61
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Anssi Hannula <anssi.hannula@iki.fi>
Signed-off-by: Zhao Yakui <yakui.zhao@intel.com>
(cherry picked from commit 86ca434a1a)
2011-01-06 15:16:58 -05:00
Adam Jackson
9213c2525a x86emu: Fix more mis-decoding of the data prefix
cc2c73ddcb4370a7c3ad439cda4da825156c26c9's three-cent titanium tax
doesn't go too far enough.  Fix the rest of the call and jmp
instructions to handle the data prefix correctly.

Reference: Intel 64 and IA-32 Architectures Software Developer's Manual
Volume 2A: Instruction Set Reference, A-M

http://www.intel.com/Assets/PDF/manual/253666.pdf

Reviewed-by: Julien Cristau <jcristau@debian.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit bb18f27715)
2011-01-06 15:16:52 -05:00
Ville Syrjälä
aec278eb65 xfree86/modes: Take rotation into account when checking mode size
Assume that a mode can be used in either landscape or portrait
orientation. I suppose the correct thing to do would be to
collect all the supported rotations from the CRTCs that can be used
with a specific output, but that information doesn't seem to be
readily available when these checks are done. So just assume that
either orientation is fine.

Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit 2e781457d4)
2011-01-06 15:15:24 -05:00
Ville Syrjälä
005b465048 dri2: Don't page flip when the window size doesn't match the pixmap size
If the drawable size doesn't match the pixmap size page flipping should
not be allowed.

If the window is larger than the pixmap, page flipping might need to
reposition the CRTC somewhere in the middle of the pixmap. I didn't
spot any code that would handle that at least in the intel driver.

Also the root pixmap could then move to some negative screen
coordinates. Not sure if all bits of code could handle that. Perhaps
when composite is enabled screen_x/y would make it work, but without
composite there's no way that it would work AFAICS.

Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com>
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
(cherry picked from commit 0ce25fd790)
2011-01-06 15:15:17 -05:00
Jörn Horstmann
d819ff1cb5 Add EDID quirk for HP Compaq nc8430.
Like some other LPL panels, this one reports the vertical size in cm rather
than mm.
Patch taken from Launchpad bug #380009 <https://launchpad.net/bugs/380009>

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

Signed-off-by: Christopher James Halse Rogers <christopher.halse.rogers@canonical.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 4b88c7be8d)
2010-12-21 10:51:19 -08:00
Jeremy Huddleston
e1e37ef7eb XQuartz GL: Add $(GL_CFLAGS) to CFLAGS
This fixes a build failure I found on tinderbox.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit f641e4b34a)
2010-12-14 17:55:19 -08:00
Jeremy Huddleston
f7d60dae09 XQuartz: Just NSBeep() for XBell()
The CoreAudio path uses deprecated API and has reported crashes that
aren't worth fixing (4e8bf12b13 fixed
one and introduced another).  NSBeep() does the job just fine.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 883039e07b)
2010-12-13 12:10:02 -08:00
Jeremy Huddleston
47d474ee8f XQuartz: RandR: Fix mode changing for multi-monitor configurations.
This just fixes the regression whereby we couldn't switch between the legacy
fullscreen mode and rootless on multi-monitor configurations.  This was
happening because ref wasn't being set in these cases (since we don't ever
actually change CG modes), so we failed a CFEqual.  Setting the references
fixes this regression and places us one step closer to more mode RandR
mode switching in multi-monitor configurations.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 714b68d9e5)
2010-12-03 21:56:26 -08:00
Jeremy Huddleston
4c3aaef3ff XQuartz: Cleanup some compiler warnings
Mark __crashreporter_info__ as __attribute__((__used__))

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 14f00449eb)
2010-12-03 21:56:20 -08:00
Jeremy Huddleston
438dd53e4b XQuartz: Disable the Mac OS X screensaver when in full screen mode
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit ca431371a2)
2010-12-03 21:56:06 -08:00
Peter Hutterer
444e180ad1 xfree86: add missing linebreak in error message.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Magnus Kessler <Magnus.Kessler@gmx.net>
(cherry picked from commit b31df0439f)
2010-12-02 15:47:46 -08:00
Aaron Plattner
7eaf84d2d1 xfree86: Fix rotation of 2-color non-interleaved cursor images
When RandR 1.2's transformation code is enabled, it rotates the cursor
image so that it appears upright on a rotated screen.  This code
completely mangles 2-color cursors on hardware where the the mask and
source images are not interleaved due to two problems:

1. stride is calculated as (width / 4) rather than (width / 8), so the
   expression (y * stride) skips two lines instead of one for every
   time y is incremented.
2. cursor_bitpos ignores the 'mask' parameter if the hardware doesn't
   specify any of the HARDWARE_CURSOR_SOURCE_MASK_INTERLEAVE_* flags.

To fix this, refactor the code to pass the whole xf86CursorInfoPtr
through to cursor_bitpos and compute the correct stride there based on
the flags.  If none of the SOURCE_MASK_INTERLEAVE flags are set, use
the total cursor size to move the 'image' variable into the mask part
of the image before computing the desired byte pointer.

Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Reviewed-by: Robert Morell <rmorell@nvidia.com>
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Tested-by: Cyril Brulebois <kibi@debian.org>
(cherry picked from commit ffcbfa0063)
2010-12-02 14:55:29 -08:00
Cyril Brulebois
e720e0874e Fix screen number checks.
screenInfo.numScreens is not a valid screen number, they go from 0 to
numScreens - 1.

Signed-off-by: Cyril Brulebois <kibi@debian.org>
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 279ef1ffd7)
2010-12-02 12:17:01 -08:00
Julien Cristau
e2960ce14e DGA: fix screen number check
screenInfo.numScreens is not a valid screen number, they go from 0 to
numScreens - 1.

Signed-off-by: Julien Cristau <jcristau@debian.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 8684543021)
2010-12-02 12:17:00 -08:00
Bill Nottingham
3b7becd98a xfree86: store the screen's gamma information on init.
This fixes a gamma issue on vt switch observed with KDM. VT switching away
and back would result in a black screen. Avoid this by storing the current
gamma information on init.

https://bugzilla.redhat.com/show_bug.cgi?id=533217

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 566d09a5cd)
2010-12-02 12:17:00 -08:00
Adam Jackson
602ad98684 xfree86: apply gamma settings on EnterVT.
When entering the VT, re-apply the saved gamma settings for each screen.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit c050aa2f5f)
2010-12-02 12:17:00 -08:00
Jeremy Huddleston
65f2ab20b2 XQuartz: Localization Updates
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 97b9bb1e2c)
2010-11-26 12:17:21 -05:00
Jeremy Huddleston
3603a64564 XQuartz: Remove existing localization files on install to avoid conflicts
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit f9fbafa1a0)
2010-11-26 12:17:15 -05:00
Jeremy Huddleston
d49f0c1737 XQuartz dri: Don't check CoreGraphics version
The version check is hackish, and I highly doubt anyone using this code is on
a version of OS X that predates this support (10.2 has support for it).

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 6eed13ad59)
2010-11-26 12:17:00 -05:00
Adam Jackson
2da9b72835 edid: Fix the HDTV sync pulse adjustment
Simple typo, should have been adjusting the horizontal timings
consistently since we're not trying to mangle vertical at all.

Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Patrick E. Kane <pekane52@gmail.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit b2f9ce201c)
2010-11-23 13:32:15 -05:00
Luc Verhaegen
a4452133ff x86emu: fix jump_near_IMM to handle DATA: flag correctly.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=24348

Before (data flag ignored -> broken):
66                  DATA:
e944f1              JMP       1ff6

After (fixed):
66                  DATA:
e944f1ffff          JMP       00001ff8

This subtle difference in the length of decoded instruction meant
that the VBE call jumped to the routine setting AX=0x14F (VBE Failed)
instead of the routine that set AX=0x4F (VBE success).

The ability to run the same code in vm86 significantly aided the
debugging of this issue. Those X.org developers who would like to drop
vm86 better take special care towards _all_ vesa bugs, as those will
expose further issues.

Patch applies easily to even xserver 1.4.2.

Signed-off-by: Luc Verhaegen <libv@skynet.be>
Tested-by: Luc Verhaegen <libv@skynet.be>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit cc2c73ddcb)
2010-11-23 13:08:29 -05:00
Samuel Thibault
06ca34fe01 Do not trap access to timer and keyboard
Disable timer/keyboard trapping on GNU/Hurd for now

Trapping disabled for now, as some VBIOSes (mga-g450 notably) use these
ports, and the int10 wrapper is not emulating them.

It's effectively what happens in the Linux variant too, as iopl() is used there,
making the ioperm() meaningless.

Signed-off-by: Olaf Buddenhagen <antrik@users.sf.net>
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit a6c64d9645)
2010-11-23 13:08:21 -05:00
Pauli Nieminen
32004e8d6e DRI2: Avoid call to NULL pointer
DDX driver may implement schedule swap without GetMSC. In that case we
can't call GetMSC in DRI2SwapBuffers.

Signed-off-by: Pauli Nieminen <ext-pauli.nieminen@nokia.com>
Reviewed-by: Mario Kleiner <mario.kleiner@tuebingen.mpg.de>
CC: Keith Packard <keithp@keithp.com>
CC: Kristian Høgsberg <krh@bitplanet.net>
Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 383dfe23f1)
2010-11-23 13:08:13 -05:00
Olivier Fourdan
9770500983 modes: improve aspect ratio match for classic drivers
After we infer the aspect ratio for the screen, we pick the largest
mode matching that aspect ratio from the best mode pool available.
We then clamp virtual size to that mode, and run the resulting mode
list through the driver's ValidMode hook.  In doing so we might filter
away our initial guess.  If this happens we shrink the default mode
to the next largest mode from _any_ mode pool.  This is usually wrong,
and we should instead pick the next aspect-matched mode from the best
available mode pool (as always, user then driver then default).

Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit 7bb653bedc)
2010-11-23 13:06:36 -05:00
Jeremy Huddleston
201273a2b9 XQuartz: Don't use bashism in uninstall-hook
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-11-15 10:57:43 -08:00
Adam Jackson
814413faef ddc: Don't probe for DDC/CI or EEPROM
For whatever reason, some (broken) monitors will crash if you do this.
We're not actually using this information for anything, so let's just
not do it.

Originally reported as http://bugzilla.redhat.com/620333

Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
(cherry picked from commit d2064fbb68)
2010-11-14 02:15:29 -08:00
Jeremy Huddleston
42a3747f0f XQuartz: Fix make distcheck
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-11-13 16:04:32 -08:00
Eric Anholt
dfda3c696d Replace usage of DamageRegionAppend with DamageDamageRegion to fix reportAfter.
In all these cases, any rendering implied by this damage has already
occurred, and we want to get the damage out to the client.  Some of
the DamageRegionAppend calls were explicitly telling damage to flush
the reportAfter damage out, but not all.

Bug #30260. Fixes the compiz wallpaper plugin with client damage
changed to reportAfter.

Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit f36153e3ef)
2010-11-13 15:17:58 -08:00
Samuel Thibault
f51f1de995 hurd: Fix use of deprecated iopl device
Fix Xserver on GNU/Hurd into using the "mem" device instead of
the deprecated "iopl" device.

Reviewed-by: Olaf Buddenhagen <antrik@users.sf.net>
Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
(cherry picked from commit f72aadd38b)
2010-11-13 12:08:59 -08:00
Paulius Zaleckas
46314e1e7a KDrive: Fix error handlig in tslib driver
If ts_open() fails and return NULL, then next call to ts_fd()
segfaults because of NULL dereference. There is no need to
check output of ts_fd() as ts_open() did this internally.

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@gmail.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
(cherry picked from commit 8990b31214)
2010-11-10 11:18:09 +10:00
Peter Hutterer
b144c0f4c7 xfree86: set mask for valuators 0/1 when emulating core events (#30267)
EventToCore as of the commit below won't generate core motion events if the
valuator mask for x/y isn't set. For DGA, we work around this check by
forcibly setting the mask in the event we pass down.

commit de8be07cc0
Author: Peter Hutterer <peter.hutterer@who-t.net>
Date:   Tue Aug 17 12:08:52 2010 +1000

    dix: don't create core motion events for non-x/y valuators.

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

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Tested-by: Andrew Randrianasulu <randrik@mail.ru>
Tested-by: Andy Furniss
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
(cherry picked from commit 9872e0f011)
2010-11-10 11:14:46 +10:00
Adam Jackson
efeb2ebd7e vbe: Fix copying the mode info block
Just use memcpy, seriously.

Reviewed-by: Rémi Cardona <remi@gentoo.org>
Signed-off-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 853d7ebfa3)
2010-10-13 18:42:45 -07:00
Adam Jackson
560e425499 xfree86: Add 18bpp support
Signed-off-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 9df4fb0adf)
2010-09-29 14:08:39 -04:00
Macpaul Lin
5ae0c0cdb2 xfree86: nds32: add nds32 support for compiler related mmio codes
Add nds32 support for compiler related mmio codes.
It includes byte-swap or non-swap operations.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 58bd317e29)
2010-09-29 14:08:08 -04:00
Macpaul Lin
dfef37797c xfree86: nds32: add nds32 support for compiler specific codes
Add nds32 definitions and related assembly codes to compiler header files.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 28e6de66b4)
2010-09-29 14:08:04 -04:00
Macpaul Lin
7c016917b0 xfree86: nds32: add nds32 definition for vgaHW support.
Add __nds32__ definitions for vgaHW support.

Signed-off-by: Macpaul Lin <macpaul@andestech.com>
Acked-by: Tiago Vignatti <tiago.vignatti@nokia.com>
Signed-off-by: Keith Packard <keithp@keithp.com>
(cherry picked from commit 2b24b2bd85)
2010-09-29 14:07:57 -04:00
Peter Hutterer
8d6e2e9906 xfree86: fix compiler warning about implicied decl of DuplicateModule.
../../../../hw/xfree86/common/xf86Xinput.c: In function ‘xf86AllocateInput’:
../../../../hw/xfree86/common/xf86Xinput.c:722: warning: implicit
declaration of function ‘DuplicateModule’
../../../../hw/xfree86/common/xf86Xinput.c:722: warning: nested extern
declaration of ‘DuplicateModule’
../../../../hw/xfree86/common/xf86Xinput.c:722: warning: assignment makes
pointer from integer without a cast

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
(cherry picked from commit 3cc5e44224)
2010-09-29 14:07:04 -04:00
Jesse Adkins
223794505e xfree86: Fix leaks in OpenConfigFile and OpenConfigDir
[mattst88: fixed whitespace and a missing semicolon]

Signed-off-by: Jesse Adkins <jesserayadkins@gmail.com>
Signed-off-by: Matt Turner <mattst88@gmail.com>
(cherry picked from commit 18b62e0479)
2010-09-29 14:06:41 -04:00
Jeremy Huddleston
6a0b405197 XQuartz: RandR: Refactor legacy mode-switching to be better integrated with RandR
Adds three new functions
void QuartzRandRSetFakeRootless (void);
void QuartzRandRSetFakeFullscreen (void);
void QuartzRandRToggleFullscreen (void);

The first two are identical to requesting the fake modes from a RandR client
The third responds to cmd-alt-a to leave fullscreen or RandR.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit c45bea0c04)
2010-09-28 18:54:40 -07:00
Jeremy Huddleston
abfb3c7994 XQuartz: RandR: Don't change the rootless preference when changing RandR mode
Also renames a bunch of other variables for better consistency.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 229323a19b)
2010-09-28 18:54:34 -07:00
Jeremy Huddleston
92b3dc67ee XQuartz: RandR: Better handle switching betwen RandR modes that share CG modes
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 721edc69c3)
2010-09-28 18:54:28 -07:00
Jeremy Huddleston
0402a44096 XQuartz: RandR: Respond better to resolution changes made outside X
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 026a47e212)
2010-09-28 18:54:23 -07:00