Commit Graph

4961 Commits

Author SHA1 Message Date
Michel Dänzer
0fba91a532 EXA: Offscreen memory eviction improvements.
* Make sure available areas are considered to have no eviction cost. This seems
  to help for https://bugs.freedesktop.org/show_bug.cgi?id=15513 but I'm afraid
  that may just be coincidence.
* Only calculate eviction cost of each area once for each eviction pass.
  Safeguard against potential (though unlikely) division by zero.
* Cosmetic enhancements: Name eviction cost related variables 'cost' instead of
  'score' to emphasize that smaller values are better, update Doxygen file
  comment to the way eviction works now.
(cherry picked from commit 6c95fae1e9)
2008-06-09 13:44:26 -04:00
Dave Airlie
50e77eb838 int10: add pci_device_enable support on Linux
(cherry picked from commit ea4ec9e998)
2008-06-09 13:29:32 -04:00
Adam Jackson
9211a10b98 xserver 1.4.99.902 2008-05-21 17:52:23 -04:00
Aaron Plattner
b69c74d14b Short-circuit PanoramiXTranslateVisualID after verifying that the visual actually exists first.
This allows using PanoramiXTranslateVisualID to test whether a given visual made
it through PanoramiXVisualConsolidate.
(cherry picked from commit 8b3d26f5b6)
2008-05-20 14:11:37 -07:00
Adam Jackson
5efe36f7af Fix reduced-blanking mode filtering in RANDR 1.2.
If the monitor isn't reduced-blanking (either through EDID logic, or
config file setting), then remove RB modes from the default pool.  Any
RB modes from the driver and config file pools will stick around though;
you asked for them, you got them.
(cherry picked from commit 0178b6a4ab)
2008-05-19 11:27:58 -04:00
James Cloos
e644d2e73f Prevent the -wm command line option from causing a SEGV
The -wm (when mapped) option for the BackingStore support has been
causing the server to dereference a NULL pointer.

This has probably been the case since backing store has been
implemented on top of Composite.

It looks like (some of?) Composite didn’t expect its WIndowPtr
argument to be the root window.

In Composite’s compCheckRedirect() function we now avoid calling
compAllocPixmap() and compFreePixmap() when the pWin pointer’s
parent member is NULL, as is it the case with a server’s root window.

This addresses:

https://bugs.freedesktop.org/show_bug.cgi?id=15878

(cherry picked from commit 04211c3532)
2008-05-16 13:01:34 -04:00
Adam Jackson
0230f39fa3 RANDR 1.1 compat: remove senseless comparison against the virtual size.
(cherry picked from commit aad1c37b09)
2008-05-16 11:11:40 -04:00
Adam Jackson
95985256ef xf86SetDesiredModes(): Skip disabled CRTCs first thing.
(cherry picked from commit 14726b776d)
2008-05-16 11:11:40 -04:00
Adam Jackson
bedcf98558 Fix initial mode selection even harder.
The first guess used to be "is the preferred mode for one output the
preferred mode on all outputs".  Instead, do "find the largest mode that's
preferred for at least one output and available on all outputs".
(cherry picked from commit 459f34b089)
2008-05-16 11:11:40 -04:00
Adam Jackson
bd50c41f6f Redo RANDR compatibility output selection.
Old logic was just the first one that happened to have an associated
CRTC.  The new logic tries to find one that's definitely connected, has
probed modes, and has the largest candidate mode.
(cherry picked from commit 96111c1547)
2008-05-16 11:11:40 -04:00
Adam Jackson
0b031442fe Re-add sync range inference from legacy setup to RANDR 1.2.
(cherry picked from commit a4bbe1c8bc)
2008-05-16 11:11:39 -04:00
Adam Jackson
b053c9768b Default X-SELinux to off.
Applied only to 1.5 branch for purposes of release stability.  Reevaluate
this when we do 1.6.
2008-05-16 10:06:27 -04:00
Adam Jackson
cfff55a2bb Fix fbdevhw initialization for PCI drivers.
graphics/fb%d, not graphics:fb%d.  Thanks sysfs.  Thysfs.
(cherry picked from commit 86678e7cc2)
2008-05-16 10:03:24 -04:00
Adam Jackson
1bd229d4ac Fix hal shutdown crash.
Removing the device invalidates its ->next pointer.  Copy it aside before
destroying the device.
(cherry picked from commit f52f6c5c7e)
2008-05-16 09:50:38 -04:00
Hans de Goede
18a1d643bc Prefer glxvisuals with stencil buffer for default visuals
The first fbconfig which has a depthbuffer > 0  and doublebuf is choosen
when associating fbconfigs with the visuals, indepenent of stencil bits.
This happens to work ok on intel as there all fbconfigs with a
depthbuffer > 0 also have stencil bits.

This patch fixes this by first trying to get a fbconfig for default X visuals
with both stencilbuf, depthbuf and doublebuffering, and if that fails fallback
to trying to get one with only a depthbuf and doublebuffering.
(cherry picked from commit f6e22d69af)
2008-05-16 09:45:30 -04:00
Alan Coopersmith
ce1f6de2e8 When XKB fails to open rules file, log the file name, not the NULL file pointer
(cherry picked from 7cdc19b29d commit)
2008-05-13 16:40:46 -07:00
Aaron Plattner
8afd1d62f6 Bug #14692: Allow drivers to have a say in Xinerama visual consolidation.
Create a new exported global variable, XineramaVisualsEqualPtr.  Use this
pointer to decide whether two visuals are equal during visual consolidation.
This pointer can be wrapped, which allows drivers and extensions to control
which visuals are consolidated.  A wrapper can reject the visuals without
calling down, but must call down and return that result if it deems the visuals
equal.  This ensures that all layers agree that the visuals are equal.

Pass the screen of the other visual into the VisualsEqual callchain.

Don't free PanoramiXVisuals since we need it for PanoramiXTranslateVisualID.

Don't skip the first visual on the other screen in PanoramiXMaybeAddVisual.

Skip the loop in PanoramiXTranslateVisualID if screen is 0.
(cherry picked from commit c50b5d9789)
2008-05-12 16:43:50 -07:00
Julien Cristau
f2278a882f kdrive: allow disabling Composite
KdInitOutput() used to enable Composite when it was disabled by default,
but now this hack prevents ``-extension Composite'' from working.
Remove it, as Composite is enabled by default anyway.
(cherry picked from commit 9dfb525f6c)
2008-05-11 23:38:03 +02:00
Adam Jackson
64948dc667 Bug #13104: Remove broken XAA a1 glyph fast path.
(cherry picked from commit f17ba5d584)
2008-05-08 16:12:01 -04:00
Adam Jackson
f2aa0000a2 Bug #13104: Don't let XAA glyph pixmaps anywhere near video memory.
Since glyphs are stored in pixmaps now, they can make their way into VRAM,
which invalidates a bunch of fast-path assumptions in the XAA code.  Thus
you end up doing color-expands or WriteBitmap from la-la land and your
aliased glyphs go all funny.

Since XAA isn't ever growing the ability to do sane glyph accel, just force
glyph pixmaps into host memory by catching them at CreatePixmap time.
(cherry picked from commit 718652eaf9)
2008-05-08 16:09:56 -04:00
Daniel Stone
f7a9d30f82 XKB: Actually explain keymap failures
When something went wrong building a keymap, try to explain to the user
what it actually was, instead of the dreaded 'Failed to load XKB keymap'
catch-all.
(cherry picked from commit cf20df39cc)
2008-05-07 22:56:17 +03:00
Keith Packard
3e71527048 Empty the borderClip of manual redirect windows. (bug 15823)
Thanks to Owen Taylor for root-causing this one.

If a TreatAsTransparent window has any area in the borderClip, that will be
added to the totalClip region for use by other windows. That's wrong.
Instead, simply empty the borderClip for TreatAsTransparent windows right up
front.
(cherry picked from commit 6c1accce87)
2008-05-06 13:03:58 -04:00
Jordan Crouse
fd0ec73bcb xf86: Change AutoConfig driver for PCI ID 022:2091 to 'geode'
(cherry picked from commit 4fa89fbe18)
2008-04-30 11:51:08 +03:00
Alan Coopersmith
7c05b4c621 Bug 14247: If pkg-config can't find openssl.pc, just link with -lcrypto
X.Org bugzilla #14247 <http://bugs.freedesktop.org/show_bug.cgi?id=14247>
(cherry picked from b1ae7c79db commit)
2008-04-24 19:06:18 -07:00
Dave Airlie
947419bce2 glx: test for valid read and draw privates before using them
this should fix a bug where f-spot exiting blows up the X server
(cherry picked from commit ae982a27e4)
2008-04-24 16:58:14 +10:00
Dave Airlie
d7db6dd1a1 GLcore: make googleearth not crash the server on sw-rendering.
I don't think this is the 100% correct answer as I get log spam saying
(EE) DoSwapInterval: cx = 0x98b8998, GLX screen = 0x96dd780
(EE) AIGLX: cx->pGlxScreen->swapInterval == NULL

but thats better than X exiting in my book.
(cherry picked from commit a368ab757e)
2008-04-24 16:58:03 +10:00
Kristian Høgsberg
5a2b538c1b Make DRI2 a serverlayout/serverflags option.
Add xf86DRI2Enabled() to export the value of the setting.
(cherry picked from commit 35982bc109)
2008-04-15 11:48:33 +10:00
Tilman Sauerbeck
46b74e8450 EXA: Update pixmaps' accel_blocked field in ModifyPixmapHeader.
(cherry picked from commit f133d85778)
2008-04-15 11:48:28 +10:00
Tilman Sauerbeck
4161c9781b EXA: Teach exaCompositeFallbackPictDesc() about x8r8g8b8.
(cherry picked from commit bb8868540f)
2008-04-15 11:48:23 +10:00
Dave Airlie
32604d0f13 glx: silly nitpick...
even though i and j are the same, we use i to derefence visuals everywhere else
(cherry picked from commit 3e12c5bb67)
2008-04-15 11:48:10 +10:00
Dave Airlie
738aea7a94 glcore: make visualRating GLX_NONE - note GLX_NONE is not == 0
Finally glxinfo returns the set of 3 visuals and glxgears works again for me on
sw rendering
(cherry picked from commit 97565c0f39)
2008-04-15 11:48:03 +10:00
Dave Airlie
d6916b149d glcore: zero fbconfigs before filling them in.
I'm not sure this the complete proper solution, perhaps it should explicitly fill
in ever field.

This at least makes glxinfo on glcore return sensible information, it doesn't make
gears work yet though.
(cherry picked from commit c61087c827)
2008-04-15 11:47:56 +10:00
Matt Turner
db00d4a4dc Check for __x86_64__ when we check for __amd64__
It seems Intel C Compiler neglects to define __amd64__, __amd64, or
amd64, but *does* define __x86_64__.
(cherry picked from commit 1fa4de80fc)
2008-04-15 11:47:48 +10:00
Tilman Sauerbeck
d2f4471933 Fixed configure.ac for autoconf 2.62. 2008-04-15 11:47:23 +10:00
Peter Hutterer
099d1bef22 dix: Call DeleteInputDeviceRequest from CloseDownDevices (#14418)
The DDX (xfree86 anyway) maintains its own device list in addition to the one
in the DIX. CloseDevice will only remove it from the DIX, not the DDX. If the
server then restarts (last client disconnects), the DDX devices are still
there, will be re-initialised, then the hal devices come in and are added too.
This repeats until we run out of device ids.

This also requires us to strdup() the default pointer/keyboard in
checkCoreInputDevices.

X.Org Bug 14418 <http://bugs.freedesktop.org/show_bug.cgi?id=14418>
(cherry picked from commit 6d22a9615a)
2008-04-15 11:47:04 +10:00
Dave Airlie
566037a914 quirk: add quirk for ACR 640x350 default mode is wrong
RH #440186
(cherry picked from commit b19027fbae)
2008-04-15 11:46:36 +10:00
Michel Dänzer
0327322708 Fix off-by-one error in ProcXResQueryClients().
Fixes memory corruption reported at
http://bugs.freedesktop.org/show_bug.cgi?id=14004 .
(cherry picked from commit 0d1746995d)
2008-04-09 15:34:16 +02:00
Adam Tkac
85b855f26f Fix Xvfb input when building against current X sources.
(cherry picked from commit 726dcd9e4e)
2008-04-07 10:34:18 -04:00
Julien Cristau
fe87d921da Fix the clock_gettime check for glibc-based non-Linux systems
We need to define _POSIX_C_SOURCE on glibc, not just Linux, so add a new
test for the __GLIBC__ macro.
(cherry picked from commit 6c0cfe3d43)
2008-04-07 10:32:13 -04:00
Adam Jackson
9a908769e6 Fix PCI config space cycles from int10 emulator.
The top bit of 0xCF8 is an enable bit, not part of the domain.  Sending
cycles to domain 128 instead of domain 0 is rarely the right thing to do.
(cherry picked from commit cc7c045bae)
2008-04-07 10:32:07 -04:00
Eric Anholt
bd91565ac8 Fix clock_gettime presence detect on FreeBSD.
For non-Linux, _POSIX_C_SOURCE and friends restrict symbols defined rather
than enabling defines of symbols.  Additionally, CLOCK_MONOTONIC was
apparently added to the standard around 2000 anyway, not 1993.
(cherry picked from commit d1de3dda8e)
2008-04-07 10:32:04 -04:00
Dave Airlie
b2704de8a7 quirk: add quirk for ACER EDID
(cherry picked from commit f0915fb3c4)
2008-04-07 10:31:46 -04:00
Hong Liu
8ccdaa288a Bug #15160: quirk Proview AY765C
prefer first detailed timing
(cherry picked from commit ebc56aca8b)
2008-04-07 10:30:38 -04:00
Goneri Le Bouder
8059b57f9b xfree86: don't crash in AutoConfig if the primary device is not pci
Only call matchDriverFromFiles() if we found a pci device.
Debian bug#472823 (http://bugs.debian.org/472823).
(cherry picked from commit 9500033b9e)
2008-04-07 10:30:26 -04:00
Fredrik Höglund
841aa08ea4 EXA: Optimize the eviction scanning loop in exaOffscreenAlloc.
Reduce the cost of the inner loop, by keeping a set of pointers to the
first and the last areas in the series, subtracting the cost of the first
area from the score, and adding the cost of the last area while walking
the list.  This commit also moves the scanning loop from exaOffscreenAlloc
into a separate function.

Idea by Michel Dänzer.
(cherry picked from commit 8074676d2d)
2008-04-07 10:29:00 -04:00
Fredrik Höglund
2e4b72dd84 EXA: Improve the algorithm used for tracking offscreen pixmap use.
Replace the current score keeping algorithm with a rolling counter that's
incremented in ExaOffscreenMarkUsed, with the previous value being stored
in the area.  exaOffscreenAlloc uses the difference between the counter
value and the value in the area when deciding which area to evict.
It now also takes the size of the areas into account, and favors evicting
smaller areas.

The credit for these ideas goes to Michel Dänzer.
(cherry picked from commit 93d876891d)
2008-04-07 10:28:54 -04:00
Daniel Stone
32b5c67145 gitignore: Add two more bits
Get slightly better at ignoring vim swap files, and let people keep
local changes if they want to.
(cherry picked from commit 7034484f08)
2008-04-07 10:27:04 -04:00
Dave Airlie
a2fcdfd5f9 quirk: fix LPL monitors properly.
no point having a h cm fix when we really want to copy the sizes from the
other place.

RH BZ 435216
(cherry picked from commit c747030a49)
2008-04-07 10:26:59 -04:00
Hasso Tepper
db62e494ff configure.ac: DragonFly BSD support
Add support for DragonFly BSD, which is just the same as FreeBSD for all
of these cases.
(cherry picked from commit 0f87b41a43)
2008-04-07 14:11:03 +03:00
Owen W. Taylor
685a04c2bf EXA: Fix TS origin computation when implementing RenderComposite with tiling.
(cherry picked from commit 6b1a27023e)
2008-04-07 11:15:19 +02:00