summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-09-05modesetting: Create scanout buffers using supported modifierslfrb-modifiers-v2Louis-Francis Ratté-Boulianne1-0/+56
Use most optimal buffer format (e.g. tiled/compressed) available for scanout. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05modesetting: Get supported formats/modifiers for scanoutLouis-Francis Ratté-Boulianne4-4/+126
Retrieve IN_FORMATS property from the plane. It gives the allowed formats and modifiers for BO allocation. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05modesetting: Use atomic modesetting to configure output/CRTCsLouis-Francis Ratté-Boulianne3-104/+316
To make sure we also use the same primary plane and to avoid mixing uses of two APIs, it is better to always use the atomic modesetting API when possible. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05modesetting: Add support for multi-plane pixmaps when page-flippingLouis-Francis Ratté-Boulianne3-7/+59
This allows the uses of CCS compressed or tiled pixmaps as BOs when page-flipping. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05modesetting: Use atomic modesetting API for pageflip if availableLouis-Francis Ratté-Boulianne7-4/+435
In order to flip between compressed and uncompressed buffers - something drmModePageFlip explicitly bans us from doing - we need to port use the atomic modesetting API. It's only 'fake' atomic though given we still commit for each CRTC separately and CRTC and connector properties are not set with the atomic API. The helper functions to retrieve DRM properties have been borrowed from Weston. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05glamor: Use gbm_bo_create_with_modifiers for internal pixmap allocationLouis-Francis Ratté-Boulianne2-8/+41
Using modifier might allow the driver to use a more optimal format (e.g. tiled/compressed). Let's try to use those if possible. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05glamor: Implement GetSupportedModifiersLouis-Francis Ratté-Boulianne6-14/+232
Implement function added in DRI3 v1.1. A newest version of libepoxy (>= 1.4.4) is required as earlier versions use a problematic version of Khronos EXT_image_dma_buf_import_modifiers spec. Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05glamor: Implement PixmapFromBuffers and BuffersFromPixmapLouis-Francis Ratté-Boulianne13-113/+407
It relies on GBM >= 17.1.0 where we can import BO with multiple planes and a format modifier (GBM_BO_IMPORT_FD_MODIFIER). Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-09-05dri3: Add multi-planar/modifier buffer requestsLouis-Francis Ratté-Boulianne5-25/+548
Initial implementation for DRI3 v1.1. Only the DRI3 implementation is there, backends need to implement the proper hooks. Version is still set to 1.0 so clients shouldn't use the new requests yet. Signed-off-by: Daniel Stone <daniels@collabora.com> Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
2017-08-11composite: Make compIsAlternateVisual safe even if Composite is offAdam Jackson1-1/+1
As of ea483af9 we're calling this unconditionally from the GLX code so the synthetic visual is in a lower select group. If Composite has been disabled then GetCompScreen() will return NULL, and this would crash. Rather than force the caller to check first, just always return FALSE if Composite is disabled (which is correct, since none of the visuals will be synthetic in that case). Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Aaron Plattner <aplattner@nvidia.com>
2017-08-11glx: remove unused GlxSetVisualConfigs stubEmil Velikov2-9/+0
The function was an empty since 2008 at least. Drop it since no drivers use it any more. Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
2017-08-11travis: Request a new docker image with xkb-data and xkbcomp installed.Eric Anholt1-1/+1
Xvfb was erroring out with: XKB: Failed to compile keymap Keyboard initialization failed. This could be a missing or incorrect setup of xkeyboard-config. (EE) Fatal server error: (EE) Failed to activate virtual core keyboard: 2(EE) With this change, we can now run my xsync regression test on Travis. Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Eric Anholt <eric@anholt.net>
2017-08-11travis: Set prefix to /usr, so we find xkbcomp.Eric Anholt1-1/+1
Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Eric Anholt <eric@anholt.net>
2017-08-02meson: Fix xwayland build since xwayland-keyboard-grab.Eric Anholt2-1/+4
The version detect was erroring out with 1.9 protos installed, and we weren't building the new code. Signed-off-by: Eric Anholt <eric@anholt.net> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-08-01xwayland: Add grab protocol supportOlivier Fourdan6-5/+114
The keyboard grabbing protocol for Xwayland is included in wayland-protocol 1.9. Update the wayland-protocol required version in both configure and meson builds and add support for this new protocol in Xwayland. Signed-off-by: Olivier Fourdan <ofourdan@redhat.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-31dix: unbreak --with-dtrace (default) on FreeBSD 11.1+Jan Beich1-0/+2
gmake[2]: Entering directory '/path/to/xserver/dix' /usr/sbin/dtrace -G -C -o dtrace-dix.o -s ../dix/Xserver.d .libs/atom.o ... dtrace: failed to compile script ../dix/Xserver.d: line 26: useless declaration gmake[2]: *** [Makefile:1007: dtrace-dix.o] Error 1 Signed-off-by: Jan Beich <jbeich@FreeBSD.org> Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2017-07-31glx: don't export __glXDRISWRastProviderEmil Velikov1-1/+1
The symbol is used only internally and is not part of the API/ABI. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-31glx: fix typo becuase -> becauseEmil Velikov1-1/+1
Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-31glx: Allow arbitrary context attributes for direct contextsAdam Jackson1-1/+3
For direct contexts, most context attributes don't require any particular awareness on the part of the server. Examples include GLX_ARB_create_context_no_error and GLX_ARB_context_flush_control, where all of the behavior change lives in the renderer; since that's on the client side for a direct context, there's no reason for the X server to validate the attribute. The context attributes will still be validated on the client side, and we still validate attributes for indirect contexts since the server implementation might need to handle them. For example, the indirect code might internally use ARB_context_flush_control for all contexts, in which case it would need to manually emit glFlush when the client switches between two indirect contexts that didn't request the no-flush attribute. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Eric Anholt <eric@anholt.net>
2017-07-31xfree86: Fix X -configure driver sort yet againAdam Jackson1-6/+5
There were two bugs here: The comparison function was not stable when one or more of the drivers being compared is a fallback, and the last driver in the list would never be moved. Signed-off-by: Adam Jackson <ajax@redhat.com>
2017-07-31modesetting: Fix PCI initialization on non-zero domainsAdam Jackson1-6/+4
libdrm's busid matching for the legacy three-integer bus string format simply ignores the domain number, rather than what we were doing here of packing the domain into the bus number. Whatever, just use the existing code to build a busid string, since that gets the domain right. Signed-off-by: Adam Jackson <ajax@redhat.com>
2017-07-20glx: Only include compositeext.h if COMPOSITE is supportedJeremy Huddleston Sequoia1-0/+3
Regressed-in: ea483af99a6351323afe00a0b630cd63310efdb1 Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
2017-07-20XQuartz: Hack around an issue that can occur on macOS due to background apps ↵Jeremy Huddleston Sequoia1-5/+24
incorrectly stealing focus Works around <rdar://problem/7150340>. Tested-by: Martin Otte <martinjotte@gmail.com> Tested-by: Tom Lane <tgl@sss.pgh.pa.us> Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
2017-07-11Xi: Test exact size of XIBarrierReleasePointerMichal Srb1-3/+6
Otherwise a client can send any value of num_barriers and cause reading or swapping of values on heap behind the receive buffer. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-06dri2: Sync i965_pci_ids.h from Mesa.Rodrigo Vivi1-0/+23
Copied from Mesa with no modifications. Gives us Coffee Lake and Cannon Lake PCI IDs. Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Acked-by: Kenneth Graunke <kenneth@whitecape.org>
2017-07-05glamor: update "required EGL extensions" commentEmil Velikov1-2/+1
The extensions listed have not been needed in a while. Replace with the only remaining requirement. Reviewed-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
2017-07-05wayland: Sync drm.xml with MesaAdam Jackson1-16/+19
... where it is named src/egl/wayland/wayland-drm/wayland-drm.xml and has its requests sorted by protocol version number, avoiding a warning from wayland-scanner. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Daniel Stone <daniels@collabora.com>
2017-07-04modesetting: handle NULL cursor in drmmode_set_cursor.Dave Airlie1-0/+3
We had a bug reported with a touchscreen where we could end up in here with a NULL cursor, so let's not crash the X server. Signed-off-by: Dave Airlie <airlied@redhat.com> Reviewed-and-Tested-by: Daniel Martin <consume.noise@gmail.com> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-04xfree86: link to libinput(4) from the xorg.conf man pagePeter Hutterer1-0/+1
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
2017-06-29automake: Add hw/xfree86/xkb/meson.build to EXTRA_DISTAdam Jackson1-0/+1
Signed-off-by: Adam Jackson <ajax@redhat.com>
2017-06-29glamor: remove no longer needed KHR_gl_texture_2D_image requirementEmil Velikov1-1/+0
The code that needed it was introduced with commit 7cfd9cc2327 ("Add DRI3 support to glamor") back in 2013. And was nuked a couple of years ago with commit 51984dddfcc ("glamor: Delay making pixmaps shareable until we need to.") Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Anholt <eric@anholt.net>
2017-06-27meson: Use --export-all-symbols when building PE/COFF objectsJon TURNEY1-2/+8
Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-06-27meson: Shuffle around subdirs so we build Xorg loadable modules after XorgJon TURNEY1-24/+26
Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-06-27Move statically linked xorgxkb files from dixmods to a separate directoryJon TURNEY11-23/+29
[ajax: Fixed test/Makefile.am as well] Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-06-22xfree86: Move DRICreatePCIBusID to xf86Pci.hAdam Jackson2-2/+1
xf86str.h is parsed into sdksyms unconditionally but the symbol is only defined when building with PCI support. Move the decl to a header that sdksyms only parses when building PCI support. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Jon Turney <jon.turney@dronecode.org.uk>
2017-06-20glx/drisw: Use scratch GCs for swrastPutImageAdam Jackson1-28/+5
The scratch GC defaults to the same state as our persistent GCs. Except for the "draw" GC, which would generate graphics exposures for... well, no reason really, PutImage doesn't generate graphics exposures. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2017-06-20glx/drisw: Remove unused glx_enable_bitsAdam Jackson1-2/+0
Sloppy of me! Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20glx/dri2: Don't chirp when falling back to softwareAdam Jackson1-2/+0
This isn't an error if the screen isn't accelerated in the first place. Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20glx: Remove some indirection around EXT_texture_from_pixmapAdam Jackson5-32/+15
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2017-06-20glx: Remove __glXReplyAdam Jackson9-74/+69
Static data bad, hulk smash. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2017-06-20dmx: Remove some not-very-interesting debug printsAdam Jackson1-63/+0
gcc/glibc think the snprintf in dmxExecOS() might truncate. Yes, it might, and we also don't care. Just delete all this. Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20dmx: Silence an unused-result warningAdam Jackson1-1/+2
Modern glibc is very insistent that you care about whether write() succeeds: ../hw/dmx/input/usb-keyboard.c: In function ‘kbdUSBCtrl’: ../hw/dmx/input/usb-keyboard.c:292:9: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Wunused-result] write(priv->fd, &event, sizeof(event)); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2017-06-20xfree86: Move DRICreatePCIBusID to the PCI codeAdam Jackson4-14/+14
This symbol is used by some DRI2+ drivers and there's nothing DRI1-specific about it. Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20xfree86: Remove unused xf86EnableVTSwitchAdam Jackson2-42/+3
Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20dix: Remove extension aliasesAdam Jackson5-61/+4
This appears to be essentially unused. The only known client-side library for the SELinux extension is xcb, which does not look for the name "Flask". The "SGI-GLX" alias for GLX appears to be a bit of superstition at this point, NVIDIA's driver does not expose it and Mesa does not check for it. Signed-off-by: Adam Jackson <ajax@redhat.com> Acked-by: Keith Packard <keithp@keithp.com>
2017-06-20include: Remove some unused macrosAdam Jackson1-5/+0
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2017-06-20xfree86: Document BusID PCI domain format in ddxDesign.xmlMichel Dänzer1-1/+2
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
2017-06-20xfree86: Document BusID PCI domain format in xorg.conf manpageMichel Dänzer1-4/+4
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
2017-06-20xfree86: Fix printing of PCI domain/bus in xf86MatchPciInstancesMichel Dänzer1-1/+1
It was attempting to use the <bus>@<domain> format accepted by the BusID stanza, but the two values were swapped. Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
2017-06-20xfree86: Print BusID stanza compatible bus IDs for found devicesMichel Dänzer1-2/+2
The PCI domain has to be specified like this: "PCI:<bus>@<domain>:<device>:<function>" Example before: (--) PCI:*(0:0:1:0) 1002:130f:1043:85cb [...] (--) PCI: (0:1:0:0) 1002:6939:1458:229d [...] after: (--) PCI:*(0@0:1:0) 1002:130f:1043:85cb [...] (--) PCI: (1@0:0:0) 1002:6939:1458:229d [...] Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>