1. 29 Apr, 2021 1 commit
    • Erik Kurzinger's avatar
      xwayland-eglstream: fix X11 rendering to flipping GL / VK window · 07f26e16
      Erik Kurzinger authored
      
      
      If a window is being used for direct rendering with OpenGL or Vulkan, and is
      using the flipping path for presentation, it's pixmap will be set to a dma-buf
      backed pixmap created by the client-side GL driver. However, this means that
      xwl_glamor_eglstream_post_damage won't work since it requires that the pixmap
      has an EGLSurface that it can render to, which dma-buf backed pixmaps do not.
      
      In this case, though, xwl_glamor_eglstream_post_damage is not necessary since
      glamor will have rendered directly to the pixmap, so we can simply pass it
      directly to the compositor. There's no need for the intermediate copy we
      normally do in that function.
      
      Therefore, this change adds an early-return case to post_damage for dma-buf
      backed pixmaps, and removes the corresponding asserts from that function and
      allow_commits.
      Signed-off-by: Erik Kurzinger's avatarErik Kurzinger <ekurzinger@nvidia.com>
      Acked-by: Olivier Fourdan's avatarOlivier Fourdan <ofourdan@redhat.com>
      07f26e16
  2. 24 Apr, 2021 3 commits
  3. 16 Apr, 2021 7 commits
  4. 13 Apr, 2021 1 commit
  5. 09 Apr, 2021 13 commits
  6. 08 Apr, 2021 4 commits
  7. 07 Apr, 2021 2 commits
  8. 06 Apr, 2021 1 commit
  9. 05 Apr, 2021 1 commit
    • Aaron Plattner's avatar
      modesetting: Defer crtc gamma size upgrade to drmmode_setup_colormap · b75d0cca
      Aaron Plattner authored
      Rather than trying to create a gamma ramp array of the appropriate size in
      drmmode_crtc_init when the GAMMA_LUT property should be used, just flag the crtc
      as wanting to use the GAMMA_LUT property and then replace the gamma ramp later,
      right before calling xf86HandleColormaps. This avoids a problem during initial
      startup where xf86RandR12CreateObjects12 hard-codes a gamma ramp size of 256,
      causing xf86RandR12CrtcSetGamma to read past the end of the DIX layer's RandR
      gamma ramp array:
      
        PreInit
          drmmode_pre_init
            drmmode_crtc_init
              crtc->gamma_size = 1024
      
        ScreenInit
          xf86CrtcScreenInit
            xf86RandR12Init
              xf86RandR12Init12
                xf86RandR12CreateObjects12
                  RRCrtcCreate
                    randr_crtc->gammaSize = 0
                xf86RandR12InitGamma(pScrn, 256)
                  RRCrtcGammaSetSize
                    randr_crtc->gammaSize = 256
                xf86RandR12InitGamma
                  xf86RandR12CrtcInitGamma
                    RRCrtcGammaSet
                      xf86RandR12CrtcSetGamma
                        // crtc->gamma_size is 1024 here, while randr_crtc->gammaRed
                        // is a 256-element array.
                        memcpy(crtc->gamma_red, randr_crtc->gammaRed, crtc->gamma_size * sizeof(crtc->gamma_red[0]));
          drmmode_setup_colormap
            xf86HandleColormaps
              xf86RandR12InitGamma
                RRCrtcGammaSetSize
                  randr_crtc->gammaSize = 1024
      
      Fixes: 245b9db0 - modesetting: Use GAMMA_LUT when available
      Closes: #1126
      
      Signed-off-by: Aaron Plattner's avatarAaron Plattner <aplattner@nvidia.com>
      Reviewed-by: Robert Morell's avatarRobert Morell <rmorell@nvidia.com>
      b75d0cca
  10. 04 Apr, 2021 1 commit
  11. 30 Mar, 2021 1 commit
  12. 26 Mar, 2021 5 commits