1. 26 Jul, 2019 1 commit
    • Alex Goins's avatar
      xsync: Fix SyncAwaitTriggerFired SIGSEGV during CloseDownClient · 7c3f316d
      Alex Goins authored
      When destroying a sync fence with a pending Await, we call through
      SyncAwaitTriggerFired, which finally unblocks the client using AttendClient.
      AttendClient assumes that the client is alive, but it's possible for us to
      destroy a sync fence as part of CloseDownClient, after CloseDownConnection has
      already been called. This results in a segfault:
          Thread 1 "X" received signal SIGSEGV, Segmentation fault.
          AttendClient (client=0x5571c4aed9a0) at ../os/connection.c:942
          (gdb) bt
          #0  AttendClient (client=0x5571c4aed9a0) at ../os/connection.c:942
          #1  0x00005571c3dbb865 in SyncAwaitTriggerFired (pTrigger=<optimized out>) at ../Xext/sync.c:694
          #2  0x00005571c3dd5749 in miSyncDestroyFence (pFence=0x5571c5063980) at ../miext/sync/misync.c:120
          #3  0x00005571c3dbbc69 in FreeFence (obj=<optimized out>, id=<optimized out>) at ../Xext/sync.c:1909
          #4  0x00005571c3d7a01d in doFreeResource (res=0x5571c506e3d0, skip=skip@entry=0) at ../dix/resource.c:880
          #5  0x00005571c3d7b1dc in FreeClientResources (client=0x5571c4aed9a0) at ../dix/resource.c:1146
          #6  FreeClientResources (client=0x5571c4aed9a0) at ../dix/resource.c:1109
          #7  0x00005571c3d5525f in CloseDownClient (client=0x5571c4aed9a0) at ../dix/dispatch.c:3473
          #8  0x00005571c3d55eeb in Dispatch () at ../dix/dispatch.c:492
          #9  0x00005571c3d59e96 in dix_main (argc=3, argv=0x7ffe7854bc28, envp=<optimized out>) at ../dix/main.c:276
          #10 0x00007fea4837cb6b in __libc_start_main (main=0x5571c3d1d060 <main>, argc=3, argv=0x7ffe7854bc28, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffe7854bc18) at ../csu/libc-start.c:308
          #11 0x00005571c3d1d09a in _start () at ../Xext/sync.c:2378
          (gdb) print client->osPrivate
          $1 = (void *) 0x0
      By checking that the client isn't gone before calling AttendClient, we avoid
      the crash. In this case, there's no need to unblock the client anyway, since
      it's already gone.
      Signed-off-by: Alex Goins's avatarAlex Goins <agoins@nvidia.com>
  2. 23 Jul, 2019 4 commits
  3. 22 Jul, 2019 1 commit
  4. 21 Jul, 2019 6 commits
  5. 17 Jul, 2019 3 commits
  6. 16 Jul, 2019 1 commit
  7. 15 Jul, 2019 1 commit
  8. 12 Jul, 2019 1 commit
  9. 10 Jul, 2019 2 commits
  10. 03 Jul, 2019 1 commit
  11. 01 Jul, 2019 2 commits
    • Samuel Thibault's avatar
      Fix crash on XkbSetMap · fabc4219
      Samuel Thibault authored
      Since group_info and width are used for the key actions allocations,
      when modifying them we need to take care of reallocation key actions if
    • Samuel Thibault's avatar
      Fix crash on XkbSetMap · 8469bfea
      Samuel Thibault authored
      Some devices may not have keyboard information.
      Fixes #574
  12. 28 Jun, 2019 6 commits
  13. 20 Jun, 2019 2 commits
    • Adam Jackson's avatar
      present: Require presentproto 1.2 · e39dc0f5
      Adam Jackson authored
      The PresentOptionSuboptimal support code is not optional (once you've
      enabled building Present at all), so require a protocol package version
      that defines what we need.
      Fixes: xorg/xserver#821
    • Adam Jackson's avatar
      linux: Fix platform device PCI detection for complex bus topologies · 9acff309
      Adam Jackson authored and Adam Jackson's avatar Adam Jackson committed
      Suppose you're in a Hyper-V guest and are trying to use PCI passthrough.
      The ID_PATH that udev will construct for that looks something like
      "acpi-VMBUS:00-pci-b8c8:00:00.0", and obviously looking for "pci-" in
      the first four characters of that is going to not work.
      Instead, strstr. I suppose it's possible you could have _multiple_ PCI
      buses in the path, in which case you'd want strrstr, if that were a
  14. 19 Jun, 2019 2 commits
    • Olivier Fourdan's avatar
      xwayland: Add "-listenfd" option · b3f3d65e
      Olivier Fourdan authored and Adam Jackson's avatar Adam Jackson committed
      Using the existing command line option "-listen" for passing file
      descriptors between the Wayland compositor and Xwayland is misleading,
      Xwayland should add is own command line option for that specific use.
      As XWayland is spawned by the Wayland compositor, we cannot just change
      the option, as that would break all existing Wayland compositors using
      Xwayland, so we add a new options "-listenfd" and mark the previous one
      as deprecated and log a warning, but it still works for backward
      Signed-off-by: Olivier Fourdan's avatarOlivier Fourdan <ofourdan@redhat.com>
    • Olivier Fourdan's avatar
      xwayland: Allow for regular transport types for listen · 4a287cc2
      Olivier Fourdan authored and Adam Jackson's avatar Adam Jackson committed
      Xwayland uses the command line option “-listen” to pass file descriptors
      from the Wayland compositor.
      That breaks the traditional, documented behavior of the “-listen”
      command line option which is to enable a transport type.
      Checks if the given option starts with a digit, otherwise treat it as a
      regular transport type.
      Closes: xorg/xserver#817
      Suggested-by: Rodrigo Exterckötter Tjäder
      Signed-off-by: Olivier Fourdan's avatarOlivier Fourdan <ofourdan@redhat.com>
  15. 18 Jun, 2019 1 commit
    • Adam Jackson's avatar
      xwayland-glx: Fix GLX visual mask setup · 0dc0cef4
      Adam Jackson authored
      a2rgb10 configs would end up with channel masks corresponding to
      argb8888. This would confuse the GLX core code into matching an a2rgb10
      config to the root window visual, and that would make things look wrong
      and bad.
      Fix this by handling more cases. We're still not fully general here, and
      this could still be wrong on big-endian. The XXX comment about doing
      something less ugly still applies, ideally we would get this information
      out of EGL instead of making lucky guesses. Still, better than it was.
      Fixes: #824
  16. 17 Jun, 2019 6 commits
    • Jon Turney's avatar
      hw/xwin: Add an option to use alpha channel in multiwindow mode · 2afee831
      Jon Turney authored
      Add an option to turn on the use of the X window's alpha channel in
      multiwindow mode, i.e. this uses the X window's alpha channel for
      compositing into the native desktop.
      This works on W7/Vista (using DwmEnableBlurBehindWindow()), and Windows
      10 (using the undocumented SetWindowCompositionAttribute()), but not on
      Windows 8/8.1
      -compositewm must be enabled for this to be useful, as we only have a
      pixmap with an alpha channel for the X window in that case.  The
      framebuffer/root window doesn't have one (unless perhaps you are using
      the rootless extension, maybe...).
      Update meson.build
      Future work:
      A window property to control use of alpha?
      Option to turn off blur on W7/Vista
      Implement _NET_WM_WINDOW_OPACITY
    • Jon Turney's avatar
      hw/xwin: Set convenience variables for WM_CREATE as well · 2e1bc743
      Jon Turney authored
      Set convenience variables in winTopLevelWindowProc() for WM_CREATE as
    • Jon Turney's avatar
      hw/xwin: Improve performance of -compositewm · f6791835
      Jon Turney authored
      I think that a major cost in the current implementation is doing a
      CreateDIBSection()/DestroyObject() on every refresh.  So provide our own
      CreatePixmap() instead, which does the CreateDIBSection(), once.
      Testcase: glxgears or foobillard with direct swrast
      Testcase: scrolling in a full-screen xterm
      Fix handling of RENDER Scratch Pixmaps
      (A problem easily shown with gitk or emacs)
      Note that we don't own screen pixmap to release in DestroyPixmap
      Log if unimplemented slow-path ever gets hit
    • Jon Turney's avatar
      hw/xwin: Avoid artefacts when resizing a window · 6865fe71
      Jon Turney authored
      Fill the area outside the current window size with black, rather than
      leaking framebuffer contents or leaving it undrawn.
    • Jon Turney's avatar
      hw/xwin: A simpleminded attempt at composition · ebcea16e
      Jon Turney authored
      Rather than drawing the window contents from the shadow framebuffer, use
      Composite extension redirection to cause the server to maintain a bitmap
      image of each top-level X window, and draw the window contents from
      that, so that window contents which are occluded in the framebuffer show
      correctly in the task bar and task switcher previews.
      Fix incorrect use of memset() found by gcc5
      hw/xwin/winshadgdi.c: In function ‘winBltExposedWindowRegionShadowGDI’:
      hw/xwin/winshadgdi.c:861:9: warning: ‘memset’ used with constant zero length parameter; this could be due to transposed parameters [-Wmemset-transposed-args]
      Turn on -compositewm by default
      Ignore -swcursor if -compositewm
      -swcursor is not compatible with -compositewm (because the window
      contents are drawn from an off-screen pixmap, not from the screen
      pixmap, where the software cursor will be drawn).
      Update meson.build also
      Add -compositewm option to help output
      Update CI to install prerequisites
    • Jon Turney's avatar
      hw/xwin: Push multiwindow wndproc WM_PAINT down into drawing engine · adebc376
      Jon Turney authored
      Push the multiwindow wndproc WM_PAINT handling down into the drawing
      engine.  Only the GDI engine is supported in multiwindow mode currently,
      so we only need to do this in the GDI engine.