1. 30 Nov, 2018 2 commits
    • Nicholas Kazlauskas's avatar
      Support CRTC variable refresh for windows using Present flips · b11ee02c
      Nicholas Kazlauskas authored
      This patch adds support for setting the CRTC variable refresh property
      for suitable windows flipping via the Present extension.
      The "VariableRefresh" Option is added to AMDGPU in this patch. This
      option defaults to false, and must be set to "true" in an X conf
      file for variable refresh support in the driver.
      In order for a window to be suitable for variable refresh it must have
      the _VARIABLE_REFRESH property with a 32-bit CARDINAL value of 1.
      Then the window must pass the checks required to be suitable for
      Present extension flips - it must cover the entire X screen and no
      other window may already be flipping.
      With these conditions met every CRTC for the X screen will have their
      variable refresh property set to true.
      Signed-off-by: Nicholas Kazlauskas's avatarNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
    • Nicholas Kazlauskas's avatar
      Check last flip window instead of screen root before flipping · 2d18b371
      Nicholas Kazlauskas authored
      A significant amount of time can pass between the X call into
      check_flip for a window and when amdgpu_present_flip actually occurs.
      To ensure that flipping is still possible there was an additional check
      performed on screen->root in amdgpu_present_flip - but what should
      be checked instead is the window itself. This only really worked before
      because X ensures that the window has the same dimensions as the screen
      to allow for present extension flipping.
      This patch tracks the flip window between calls to check_flip and flip
      and uses that window instead of screen->root.
      Signed-off-by: Nicholas Kazlauskas's avatarNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
  2. 20 Nov, 2018 1 commit
  3. 16 Nov, 2018 3 commits
  4. 15 Nov, 2018 1 commit
  5. 14 Nov, 2018 1 commit
  6. 29 Oct, 2018 2 commits
  7. 25 Oct, 2018 1 commit
    • Michel Dänzer's avatar
      Detect and fix up non-premultiplied cursor data · ad6dfb01
      Michel Dänzer authored
      X server >= 1.18 already had code for this, but it only caught cases
      where some pixels have 0 for alpha and non-0 for a non-alpha component.
      Turns out some apps (e.g. the Civilization VI game) use
      non-premultiplied cursor data which doesn't have such pixels, but can
      still result in visual artifacts.
      This uses the method suggested by Kamil in
      https://bugs.freedesktop.org/92309#c19: check for pixels where any
      colour component value is larger than the alpha value, which isn't
      possible with premultiplied alpha.
      There can still be non-premultiplied data which won't be caught by this,
      but that should result in slightly incorrect colours and/or blending at
      the worst, not wildly incorrect colours such as shown in the bug report
      * Disable the check with current xserver Git master, which already does
        the same check now.
      Bugzilla: https://bugs.freedesktop.org/108355Suggested-by: default avatarKamil Páral <kamil.paral@gmail.com>
      Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
  8. 11 Oct, 2018 1 commit
    • Michel Dänzer's avatar
      Allow up to six instances in Zaphod mode · c9d43c1d
      Michel Dänzer authored
      Corresponding to up to six CRTCs being available in the hardware.
      * Move instance overflow check from PreInit to the probe hooks, in
        order to further minimize wasted effort.
      Reviewed-by: Alex Deucher <alexander.deucher@amd.com> # v1
  9. 10 Oct, 2018 1 commit
  10. 02 Oct, 2018 3 commits
    • Michel Dänzer's avatar
      Add GitLab CI configuration · 05a1ba9a
      Michel Dänzer authored
      Builds the driver against all supported versions of xserver, with both
      gcc and clang for xserver >= 1.18 (older versions cause warnings with
      clang). Compiler warnings are treated as errors.
      The xserver 1.15 build uses standalone glamor, the xserver 1.13 & 1.14
      builds use --disable-glamor.
      With the latest xserver version, make install and make distcheck are
      tested as well.
    • Michel Dänzer's avatar
      Fix --disable-glamor build · babbd380
      Michel Dänzer authored
      We were still relying on the glamor.h header being picked up implicitly.
    • Michel Dänzer's avatar
      Cast return value of amdgpu_get_marketing_name to char* · b6ee7f92
      Michel Dänzer authored
      Avoids compiler warning with xserver < 1.16:
      ../../src/amdgpu_kms.c: In function ‘AMDGPUPreInitChipType_KMS’:
      ../../src/amdgpu_kms.c:1203:17: warning: assignment discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
        pScrn->chipset = amdgpu_get_marketing_name(pAMDGPUEnt->pDev);
  11. 26 Sep, 2018 2 commits
  12. 20 Sep, 2018 2 commits
  13. 14 Sep, 2018 1 commit
  14. 13 Sep, 2018 1 commit
  15. 05 Sep, 2018 2 commits
  16. 31 Aug, 2018 2 commits
  17. 30 Aug, 2018 1 commit
  18. 29 Aug, 2018 1 commit
  19. 24 Aug, 2018 2 commits
  20. 16 Aug, 2018 7 commits
  21. 02 Aug, 2018 1 commit
  22. 27 Jul, 2018 1 commit
    • Michel Dänzer's avatar
      Store FB for each CRTC in drmmode_flipdata_rec · 9b6782c8
      Michel Dänzer authored
      We were only storing the FB provided by the client, but on CRTCs with
      TearFree enabled, we use a separate FB. This could cause
      drmmode_flip_handler to fail to clear drmmode_crtc->flip_pending, which
      could result in a hang when waiting for the pending flip to complete. We
      were trying to avoid that by always clearing drmmode_crtc->flip_pending
      when TearFree is enabled, but that wasn't reliable, because
      drmmode_crtc->tear_free can already be FALSE at this point when
      disabling TearFree.
      Now that we're keeping track of each CRTC's flip FB separately,
      drmmode_flip_handler can reliably clear flip_pending, and we no longer
      need the TearFree hack.
      Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
  23. 25 Jul, 2018 1 commit