summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-12-10present: recursively set window pixmaps on flipHEADmasterKeith Packard1-7/+37
Newly created windows inherit the pixmap of their parent, similarly, reparenting a tree inherits the pixmap of the destination tree. Making present preserve the invariant that unredirected windows always have the same pixmap as their parent ensures that the above cases work correctly. v2: name the recursive function to 'set_tree_pixmap' instead of 'set_window_pixmap' Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-10Bump version to 1.14.99.904 (1.15 RC4)xorg-server-1.14.99.904Keith Packard1-3/+3
Signed-off-by: Keith Packard <keithp@keithp.com>
2013-12-10hw/xwin/glx: Rewrite WGL wrappers after Xserver conversion to direct GL dispatchJon TURNEY8-399/+653
v1: Rewrite by Marc Haesen of the WGL wrapper function generation script to use Khronos group XML. v2: Remove -dispatchheader option, since dispatch.h doesn't exist anymore, use the private glapi interface to construct the GL dispatch table for the native WGL thunks. v3: Rewrite to generate shims for the OpenGL 1.2.1 (GL 1.2 + GL_ARB_imaging +GL_ARB_multitexture + GL_ARB_texture_compression(?)) functions the server links directly with rather than libGL. These shims dispatch to either the mesa GL DLL, or a thunking DLL containing cdecl-to-stcall wrapper functions for the native GL DLL. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-10glx: Consistently use ARB-suffixed names for ARB_multitexture functionsJon TURNEY2-49/+49
At the moment we have a mix of ARB and non-ARB suffixed forms for ARB_multitexture functions e.g. glMultiTexCoord1fvARB and glMultiTexCoord1dv Consistently use the ARB-suffixed form, assuming that is present in all libGL which provide the OpenGL 1.2.1 ABI we expect to be able to directly link with. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-10ephyr: Fix compilation when ./configure'd with --enable-debugJon TURNEY1-4/+4
/jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessMouseMotion’: /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:946:188: error: ‘ephyrCurScreen’ undeclared (first use in this function) /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessButtonPress’: /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:980:186: error: ‘ephyrCurScreen’ undeclared (first use in this function) /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c: In function ‘ephyrProcessButtonRelease’: /jhbuild/checkout/xorg/xserver/hw/kdrive/ephyr/ephyr.c:1007:186: error: ‘ephyrCurScreen’ undeclared (first use in this function) Fix ephyr compilation when ./configure'd with --enable-debug after commit 46cf6bf5692ef751ec9d17ae2292565d4b13f14b, some instances of ephyrCurScreen were not converted to screen->pScreen->myNum. v2: Don't use a trivial local variable which will be unused when ./configure'd with --disable-debug Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-10configure.ac: Link XWin with present extension if we are building with it ↵Jon TURNEY1-1/+1
enabled Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-10xquartz/glx: Convert to non-glapi dispatchAdam Jackson1-13/+13
CGL doesn't have anything like glXGetProcAddress, and the old code just called down to dlsym in any case. It's a little mind-warping since dlopening a framework actually loads multiple dylibs, but that's just how OSX rolls. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
2013-12-10drisw: Wire up GetProcAddressAdam Jackson1-0/+5
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2013-12-10dri2: wire up GetProcAddressAdam Jackson1-1/+5
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2013-12-10glx: Untangle the prototypes around the GetProcAddress thunkAdam Jackson2-3/+5
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2013-12-10glx: Remove function stubsAdam Jackson2-51/+0
Now that we're calling non-1.2 ABI things by function pointer this is no longer needed. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2013-12-10glx: Convert non-generated function pointer thunkingAdam Jackson3-14/+44
Same concept as the generated code conversion. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jon TURNEY <jon.turney@dronecode.org.uk>
2013-12-10glx: Convert generated code function pointer thunkingAdam Jackson2-544/+977
We're meant not to call these by name due to ABI. Rather than try to generate a bunch of little stub functions that do the lookup, just inline it all directly into the calling function. This does not cache results. That's fine, this is not a performance path, and if we're atop WGL then we effectively have to do this every time anyway because wglGetProcAddress results are context-dependent. Signed-off-by: Adam Jackson <ajax@redhat.com> Jon TURNEY <jon.turney@dronecode.org.uk>
2013-12-10Depend on latest glproto (1.4.17)Keith Packard1-1/+1
Signed-off-by: Keith Packard <keithp@keithp.com>
2013-12-09damageext: Die if we can't create the Xinerama resource typeAdam Jackson1-0/+2
Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09damageext: Xineramify (v7)Adam Jackson3-52/+341
v7: Don't bother making resources for the backing listeners. [keithp] This is now slightly unlike how other resources are xineramified. We create N+1 internal damage listeners, one that's a real resource and reflects the protocol view, and then one per backend screen where the report function piles onto the protocol view. The internal listeners are not stored in the resource database directly, they just hang off the xinerama resource. We don't wrap Subtract at the dispatch level, but we do extend it for the Xinerama case to clip to the root window geometry. As a result of the N+1 design here, the damage reports we generate are not quite minimal. However they are indistinguishable from sequential rendering events happening before the client hears damage, and we don't need to add a post-dispatch callback just for this one extension. Add is probably (still) somewhat broken since it will only hit screen 0, but Add really only exists for DRI1's sake, and DRI1 disables itself with Xinerama enabled anyway. In the absence of a use case, I'm leaving it unwrapped under Xinerama; if someone wants to define how it ought to work, be my guest. Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09fixes: Fix PanoramiXSetWindowShapeRegion for root windows (v2)Adam Jackson1-0/+13
Root windows in Xinerama are in the coordinate space of their root window pixmap, not in protocol space. v2: Only translate for root windows, sice the window shape is drawable-relative. Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09fixes: Fix PanoramiXSetPictureClipRegion for root windows (v2)Adam Jackson1-0/+13
Root windows in Xinerama are in the coordinate space of their root window pixmap, not in protocol space. This fixes 'xcompmgr -n' when Xinerama is active. v2: Only translate for root windows, since the clip origin is drawable-relative. Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09composite: Fix COW creation for Xinerama (v2)Adam Jackson1-1/+4
Say you have two 800x600 screens left/right of each other. A window that's 200x200 at +700+0 in protocol coordinate space will appear to be at -100+0 in the coordinate space of the right hand screen. Put another way: windows are in the coordinate space of their root window pixmap. We weren't doing this translation for the COW, so when rendering came in to it you'd see the top-left chunk of the COW on all screens. Cool effect and all, but wrong. v2: Only translate when Xinerama is active [keithp] Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09xinerama: Export the screen regionAdam Jackson2-1/+2
damageext wants this so it can intersect subtract requests against the root window geometry. Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09xfree86: Prefer fbdev to vesaAdam Jackson2-9/+10
On UEFI machines you'd prefer fbdev to grab efifb instead of vesa trying to initialize and failing in a way we can't unwind from. On BIOS machines this is harmless: either there is an fbdev driver and it'll probably be more capable, or there's not and vesa will kick in anyway. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09composite: Don't double-redirect if someone asks for backing store twiceAdam Jackson1-2/+2
v2: Belt-and-suspenders the unredirection path [vsyrjala] Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09composite: Automatically enable backing store support on the screenAdam Jackson2-0/+8
... unless you explicitly disabled it with -bs on the command line, or with the corresponding thing in xorg.conf. v2: Drop a bogus hunk from compChangeWindowAttributes [vsyrjala] v3: s/TRUE/WhenMapped/ [jcristau] Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09bs: Set the screen's bs support level to WhenMappedAdam Jackson2-2/+6
Since we're using RedirectAutomatic to do this, we don't actually preserve contents when unmapped. v2: Don't say WhenMapped if Composite didn't initialize [vsyrjala] Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09smartsched: Tweak the default scheduler intervalsAdam Jackson1-2/+3
A default timeslice of 20ms means a pathological client can ruin up to two frames per scheduler tick. And a fifth of a second is just insane. Pick two different numbers out of the hat. A 5ms slice means you can probably keep up with two or three abusive clients, and letting it burst to 15ms should give you about all the timeslice you need for a fullscreen game (that's doing server-side rendering for some reason). If you're running on a system with a 10ms granularity on SIGALRM, then this effectively changes the intervals to 10ms and 30ms. Which is still better, just not as better. I suspect this is about as good as we can do without actually going preemptive, which is an entire other nightmare. Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09dri3: Disable when Xinerama is activeAdam Jackson1-0/+5
Pretty sure this can't work. Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09dri2: Disable when Xinerama is activeAdam Jackson1-0/+5
Would only work on ScreenRec 0, which means it's broken. Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-09present: Disable when Xinerama is activeAdam Jackson1-0/+5
Among much else Present depends on RANDR types, and RANDR isn't properly Xinerama-aware yet anyway. Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
2013-12-05glx: Fix incorrect use of dri_interface.h version defines in driver probing.Eric Anholt1-2/+2
If we extend __DRI_CORE or __DRI_SWRAST in dri_interface.h to allow a new version, it shouldn't make old server code retroactively require the new version from swrast drivers. Notably, new Mesa defines __DRI_SWRAST version 4, but we still want to be able to probe version 1 drivers, since we don't use any features beyond version 1 of the struct. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2013-12-05glx: Fix incorrect use of dri_interface.h version defines in extensions.Eric Anholt3-4/+4
Those defines are so you can compile-time check "do I have a dri_interface.h that defines this new field of the struct?" You don't want the server to claim it implements the new struct just because you installed a new copy of Mesa. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2013-12-05configure.ac: Fixup for "Require libpciaccess for int10"Jon TURNEY1-1/+1
On 16/11/2013 01:00, Connor Behan wrote: > A --disable-pciaccess build will fail with an int10 module other than > stub. > > Signed-off-by: Connor Behan <connor.behan-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> > --- > configure.ac | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/configure.ac b/configure.ac > index 5e621e0..a843770 100644 > --- a/configure.ac > +++ b/configure.ac > @@ -1822,6 +1822,9 @@ if test "x$XORG" = xyes; then > if test "x$CONFIG_UDEV_KMS" = xyes; then > AC_MSG_ERROR([Platform device enumeration requires libpciaccess]) > fi > + if test "x$INT10" != xstub; then > + AC_MSG_ERROR([Cannot build int10 without libpciaccess]) > + fi > fi > AC_MSG_RESULT([$PCI]) > This causes my build to fail where --disable-int10-module --disable-pciaccess is the default (as INT10 still has the default value 'x86emu') Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Tested-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2013-12-05present: Report damage when flippingKeith Packard1-0/+11
Limit damage to the 'update' region. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Also set the root window pixmap when flippingKeith Packard1-0/+3
This makes sure that things like software cursors continue to work while the screen is flipped. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Clear target_crtc if driver lacks Present supportKeith Packard1-1/+3
If the driver doesn't have the necessary hooks for Present, then the target_crtc needs to be set to NULL to make sure the extension uses the present_fake code. Signed-off-by: Keith Packard <keithp@keithp.com> Tested-by: Fredrik Höglund <fredrik@kde.org> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Send GLX_BufferSwapComplete events from present extensionKeith Packard7-23/+105
This allows GL to support the GLX_INTEL_swap_event extension. v2: Return GLX_BLIT_COMPLETE_INTEL for unknown swap types Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Set window pixmap to flipped pixmapKeith Packard1-4/+20
This makes other drawing to the window appear on the screen. Note that no child windows can be affected because only full-screen windows are eligible for flipping, and so we only need to set pixmap for the window itself. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Leave vblank on window list until flip completeKeith Packard2-8/+13
If the window is destroyed, then we've got cleanup work to do, even if the vblank has already been executed -- we need to clear the window pointer so that we don't try to deliver events to it. Leaving it on the window list meant that when walking that list, we need to know whether the vblank is waiting to be executed or waiting for the flip to complete, so a new 'queued' flag was added to the vblank to distinguish between the two states. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-05present: Add a debug output line when skipping a pending presentKeith Packard1-0/+5
When an application provides two pixmaps for the same MSC, the previous one is skipped. This just dumps out some information at that point Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Adam Jackson <ajax@redhat.com>
2013-12-02miext/sync: Handle libxshmfence API changeKeith Packard2-2/+2
libxshmfence had an unfortunate 'int32_t' type for the mapped fence. That changed to exposing a 'struct shmfence' instead, which is nice and opaque and offers fine type checking across the API. This patch requires the newer version of the library and uses the new interface type. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Julien Cristau <jcristau@debian.org>
2013-12-02miext: Move SyncShm FDs out of the way of clientsKeith Packard3-0/+30
Applications may end up allocating a bunch of shmfence objects, each of which uses a file descriptor, which must be kept open lest some other client ask for a copy of it later on. Lacking an API that can turn a memory mapping back into a file descriptor, about the best we can do is push the file descriptors out of the way of other X clients so that we don't run out of the ability to accept new connections. This uses fcntl F_GETFD to push the FD up above MAXCLIENTS. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Julien Cristau <jcristau@debian.org>
2013-12-02Xext: Use SHMDIR and O_TMPFILE when creating mapping filesKeith Packard1-3/+31
ShmCreateSegment asks for a file descriptor for a memory mapped file created by the X server. This patch uses O_TMPFILE where available, and also uses the SHMDIR directory to store the files, both for the O_TMPFILE and mkstemp cases. Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Julien Cristau <jcristau@debian.org>
2013-12-02Select directory for MIT-SHM temp files at configure timeKeith Packard2-0/+46
By default, this looks through a list of directories to find one which exists, but can be overridden with --with-shared-memory-dir=PATH This patch doesn't actually do anything with this directory, just makes it available in the configuration Signed-off-by: Keith Packard <keithp@keithp.com> Reviewed-by: Julien Cristau <jcristau@debian.org>
2013-11-26Xdmx: Initialize DMX extension even if not built with GLX supportAlan Coopersmith1-1/+3
dmxAddExtensions takes an argument to determine if it should just initialize the DMX extension, or both DMX & GLX, but if GLX wasn't compiled in, the entire call was #ifdef'ed out, leaving the DMX extension unavailable. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Keith Packard <keithp@keithp.com>
2013-11-26configure.ac: Require libpciaccess for int10Connor Behan1-0/+3
A --disable-pciaccess build will fail with an int10 module other than stub. Signed-off-by: Connor Behan <connor.behan@gmail.com> Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2013-11-26configure.ac: Require libpciaccess for platform bus supportConnor Behan1-0/+4
There is currently no reason to build with --enable-config-udev-kms and --disable-pciaccess but anyone who tries this should know that the build will fail. Signed-off-by: Connor Behan <connor.behan@gmail.com> Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2013-11-26configure.ac: Add whitespace near PCI configurationConnor Behan1-18/+17
Signed-off-by: Connor Behan <connor.behan@gmail.com> Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2013-11-23Bump release to 1.14.99.903 (1.15 RC3)xorg-server-1.14.99.903Keith Packard1-3/+3
Signed-off-by: Keith Packard <keithp@keithp.com>
2013-11-23miext: Ensure xshmfence is only called when driver supports itKeith Packard6-10/+162
This provides a place for drivers to insert their own FD-based SyncFence implementations, and prevents applications from using DRI3 SyncFence creation functions unless the driver has some support for them. Signed-off-by: Keith Packard <keithp@keithp.com> Tested-by: Fredrik Höglund <fredrik@kde.org>
2013-11-23Xext: Recover from miSyncInitFenceFromFD failure without crashingKeith Packard1-1/+1
miSyncDestroyFence must not be called unless miSyncInitFence has been invoked, so if miSyncInitFenceFromFD fails, we must free the fence manually. Signed-off-by: Keith Packard <keithp@keithp.com> Tested-by: Fredrik Höglund <fredrik@kde.org>
2013-11-23glx/glxdri2: Unwrap EnterVT/LeaveVT upon CloseScreenChris Wilson1-0/+4
In a similar spirit to commit d75e8146c414bfd512ba5dbd4a83acb334bbe19b Author: Keith Packard <keithp@keithp.com> Date: Mon Jul 12 16:01:34 2010 -0700 Unwrap/rewrap EnterVT/LeaveVT completely, Fixes 28998 we need to unwrap our pScrn->EnterVT/LeaveVT hooks around server regeneration or else we cause an infinite recursion on the next VT switch afterwards. Bugzilla: https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/1235516 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Keith Packard <keithp@keithp.com>