1. 19 6月, 2021 2 次提交
  2. 07 6月, 2021 1 次提交
  3. 06 6月, 2021 2 次提交
  4. 01 5月, 2021 1 次提交
  5. 26 4月, 2021 1 次提交
  6. 09 4月, 2021 1 次提交
  7. 26 3月, 2021 3 次提交
  8. 25 3月, 2021 1 次提交
  9. 24 3月, 2021 1 次提交
    • M
      drm/i915: Do not share hwsp across contexts any more, v8. · 12ca695d
      Maarten Lankhorst 提交于
      Instead of sharing pages with breadcrumbs, give each timeline a
      single page. This allows unrelated timelines not to share locks
      any more during command submission.
      
      As an additional benefit, seqno wraparound no longer requires
      i915_vma_pin, which means we no longer need to worry about a
      potential -EDEADLK at a point where we are ready to submit.
      
      Changes since v1:
      - Fix erroneous i915_vma_acquire that should be a i915_vma_release (ickle).
      - Extra check for completion in intel_read_hwsp().
      Changes since v2:
      - Fix inconsistent indent in hwsp_alloc() (kbuild)
      - memset entire cacheline to 0.
      Changes since v3:
      - Do same in intel_timeline_reset_seqno(), and clflush for good measure.
      Changes since v4:
      - Use refcounting on timeline, instead of relying on i915_active.
      - Fix waiting on kernel requests.
      Changes since v5:
      - Bump amount of slots to maximum (256), for best wraparounds.
      - Add hwsp_offset to i915_request to fix potential wraparound hang.
      - Ensure timeline wrap test works with the changes.
      - Assign hwsp in intel_timeline_read_hwsp() within the rcu lock to
        fix a hang.
      Changes since v6:
      - Rename i915_request_active_offset to i915_request_active_seqno(),
        and elaborate the function. (tvrtko)
      Changes since v7:
      - Move hunk to where it belongs. (jekstrand)
      - Replace CACHELINE_BYTES with TIMELINE_SEQNO_BYTES. (jekstrand)
      Signed-off-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Reviewed-by: Thomas Hellström <thomas.hellstrom@intel.com> #v1
      Reported-by: Nkernel test robot <lkp@intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210323155059.628690-2-maarten.lankhorst@linux.intel.com
      12ca695d
  10. 15 1月, 2021 3 次提交
  11. 10 1月, 2021 1 次提交
  12. 31 12月, 2020 3 次提交
  13. 24 12月, 2020 1 次提交
  14. 21 12月, 2020 1 次提交
  15. 16 12月, 2020 1 次提交
  16. 27 11月, 2020 1 次提交
  17. 24 11月, 2020 1 次提交
  18. 20 11月, 2020 2 次提交
  19. 13 10月, 2020 1 次提交
  20. 01 10月, 2020 2 次提交
  21. 29 9月, 2020 1 次提交
  22. 26 9月, 2020 1 次提交
  23. 16 9月, 2020 1 次提交
    • C
      drm/i915: Be wary of data races when reading the active execlists · b82a8b93
      Chris Wilson 提交于
      To implement preempt-to-busy (and so efficient timeslicing and best utilization
      of the hardware submission ports) we let the GPU run asynchronously in respect
      to the ELSP submission queue. This created challenges in keeping and accessing
      the driver state mirroring the asynchronous GPU execution.
      
      The latest occurence of this was spotted by KCSAN:
      
      [ 1413.563200] BUG: KCSAN: data-race in __await_execution+0x217/0x370 [i915]
      [ 1413.563221]
      [ 1413.563236] race at unknown origin, with read to 0xffff88885bb6c478 of 8 bytes by task 9654 on cpu 1:
      [ 1413.563548]  __await_execution+0x217/0x370 [i915]
      [ 1413.563891]  i915_request_await_dma_fence+0x4eb/0x6a0 [i915]
      [ 1413.564235]  i915_request_await_object+0x421/0x490 [i915]
      [ 1413.564577]  i915_gem_do_execbuffer+0x29b7/0x3c40 [i915]
      [ 1413.564967]  i915_gem_execbuffer2_ioctl+0x22f/0x5c0 [i915]
      [ 1413.564998]  drm_ioctl_kernel+0x156/0x1b0
      [ 1413.565022]  drm_ioctl+0x2ff/0x480
      [ 1413.565046]  __x64_sys_ioctl+0x87/0xd0
      [ 1413.565069]  do_syscall_64+0x4d/0x80
      [ 1413.565094]  entry_SYSCALL_64_after_hwframe+0x44/0xa9
      
      To complicate matters, we have to both avoid the read tearing of *active and
      avoid any write tearing as perform the pending[] -> inflight[] promotion of the
      execlists.
      
      This is because we cannot rely on the memcpy doing u64 aligned copies on all
      kernels/platforms and so we opt to open-code it with explicit WRITE_ONCE
      annotations to satisfy KCSAN.
      
      v2: When in doubt, write the same comment again.
      v3: Expanded commit message.
      
      Fixes: b55230e5 ("drm/i915: Check for awaits on still currently executing requests")
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20200716142207.13003-1-chris@chris-wilson.co.ukSigned-off-by: NRodrigo Vivi <rodrigo.vivi@intel.com>
      [Joonas: Rebased and reordered into drm-intel-gt-next branch]
      [Joonas: Added expanded commit message from Tvrtko and Chris]
      Signed-off-by: NJoonas Lahtinen <joonas.lahtinen@linux.intel.com>
      (cherry picked from commit b4d9145b)
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      b82a8b93
  24. 07 9月, 2020 7 次提交