1. 24 3月, 2021 1 次提交
    • I
      drm/i915: Fix the GT fence revocation runtime PM logic · 8840e3bd
      Imre Deak 提交于
      To optimize some task deferring it until runtime resume unless someone
      holds a runtime PM reference (because in this case the task can be done
      w/o the overhead of runtime resume), we have to use the runtime PM
      get-if-active logic: If the runtime PM usage count is 0 (and so
      get-if-in-use would return false) the runtime suspend handler is not
      necessarily called yet (it could be just pending), so the device is not
      necessarily powered down, and so the runtime resume handler is not
      guaranteed to be called.
      
      The fence revocation depends on the above deferral, so add a
      get-if-active helper and use it during fence revocation.
      
      v2:
      - Add code comment explaining the fence reg programming deferral logic
        to i915_vma_revoke_fence(). (Chris)
      - Add Cc: stable and Fixes: tags. (Chris)
      - Fix the function docbook comment.
      
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: <stable@vger.kernel.org> # v4.12+
      Fixes: 181df2d4 ("drm/i915: Take rpm wakelock for releasing the fence on unbind")
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210322204223.919936-1-imre.deak@intel.com
      (cherry picked from commit 9d58aa46)
      Signed-off-by: NRodrigo Vivi <rodrigo.vivi@intel.com>
      8840e3bd
  2. 23 3月, 2021 5 次提交
  3. 20 3月, 2021 2 次提交
  4. 19 3月, 2021 1 次提交
    • T
      nouveau: Skip unvailable ttm page entries · e94c55b8
      Tobias Klausmann 提交于
      Starting with commit f295c8cf
      ("drm/nouveau: fix dma syncing warning with debugging on.")
      the following oops occures:
      
         BUG: kernel NULL pointer dereference, address: 0000000000000000
         #PF: supervisor read access in kernel mode
         #PF: error_code(0x0000) - not-present page
         PGD 0 P4D 0
         Oops: 0000 [#1] PREEMPT SMP PTI
         CPU: 6 PID: 1013 Comm: Xorg.bin Tainted: G E     5.11.0-desktop-rc0+ #2
         Hardware name: Acer Aspire VN7-593G/Pluto_KLS, BIOS V1.11 08/01/2018
         RIP: 0010:nouveau_bo_sync_for_device+0x40/0xb0 [nouveau]
         Call Trace:
          nouveau_bo_validate+0x5d/0x80 [nouveau]
          nouveau_gem_ioctl_pushbuf+0x662/0x1120 [nouveau]
          ? nouveau_gem_ioctl_new+0xf0/0xf0 [nouveau]
          drm_ioctl_kernel+0xa6/0xf0 [drm]
          drm_ioctl+0x1f4/0x3a0 [drm]
          ? nouveau_gem_ioctl_new+0xf0/0xf0 [nouveau]
          nouveau_drm_ioctl+0x50/0xa0 [nouveau]
          __x64_sys_ioctl+0x7e/0xb0
          do_syscall_64+0x33/0x80
          entry_SYSCALL_64_after_hwframe+0x44/0xae
         ---[ end trace ccfb1e7f4064374f ]---
         RIP: 0010:nouveau_bo_sync_for_device+0x40/0xb0 [nouveau]
      
      The underlying problem is not introduced by the commit, yet it uncovered the
      underlying issue. The cited commit relies on valid pages. This is not given for
      due to some bugs. For now, just warn and work around the issue by just ignoring
      the bad ttm objects.
      Below is some debug info gathered while debugging this issue:
      
      nouveau 0000:01:00.0: DRM: ttm_dma->num_pages: 2048
      nouveau 0000:01:00.0: DRM: ttm_dma->pages is NULL
      nouveau 0000:01:00.0: DRM: ttm_dma: 00000000e96058e7
      nouveau 0000:01:00.0: DRM: ttm_dma->page_flags:
      nouveau 0000:01:00.0: DRM: ttm_dma:   Populated: 1
      nouveau 0000:01:00.0: DRM: ttm_dma:   No Retry: 0
      nouveau 0000:01:00.0: DRM: ttm_dma:   SG: 256
      nouveau 0000:01:00.0: DRM: ttm_dma:   Zero Alloc: 0
      nouveau 0000:01:00.0: DRM: ttm_dma:   Swapped: 0
      Signed-off-by: NTobias Klausmann <tobias.klausmann@freenet.de>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210313222159.3346-1-tobias.klausmann@freenet.de
      e94c55b8
  5. 18 3月, 2021 2 次提交
  6. 17 3月, 2021 3 次提交
  7. 16 3月, 2021 2 次提交
  8. 14 3月, 2021 1 次提交
  9. 12 3月, 2021 2 次提交
  10. 11 3月, 2021 21 次提交