1. 14 9月, 2015 1 次提交
    • T
      drm/vmwgfx: Fix up user_dmabuf refcounting · 54c12bc3
      Thomas Hellstrom 提交于
      If user space calls unreference on a user_dmabuf it will typically
      kill the struct ttm_base_object member which is responsible for the
      user-space visibility. However the dmabuf part may still be alive and
      refcounted. In some situations, like for shared guest-backed surface
      referencing/opening, the driver may try to reference the
      struct ttm_base_object member again, causing an immediate kernel warning
      and a later kernel NULL pointer dereference.
      
      Fix this by always maintaining a reference on the struct
      ttm_base_object member, in situations where it might subsequently be
      referenced.
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NThomas Hellstrom <thellstrom@vmware.com>
      Reviewed-by: NBrian Paul <brianp@vmware.com>
      Reviewed-by: NSinclair Yeh <syeh@vmware.com>
      54c12bc3
  2. 13 8月, 2015 3 次提交
  3. 05 8月, 2015 7 次提交
  4. 04 12月, 2014 1 次提交
  5. 30 9月, 2014 1 次提交
  6. 11 9月, 2014 1 次提交
  7. 02 9月, 2014 3 次提交
  8. 01 9月, 2014 2 次提交
  9. 22 7月, 2014 1 次提交
  10. 28 3月, 2014 2 次提交
  11. 02 3月, 2014 1 次提交
  12. 05 2月, 2014 1 次提交
    • T
      drm/vmwgfx: Reemit context bindings when necessary v2 · 30f82d81
      Thomas Hellstrom 提交于
      When a context is first referenced in the command stream, make sure that all
      scrubbed (as a result of eviction) bindings are re-emitted. Also make sure that
      all bound resources are put on the resource validate list.
      
      This is needed for legacy emulation, since legacy user-space drivers will
      typically not re-emit shader bindings. It also removes the requirement for
      user-space drivers to re-emit render-target- and texture bindings.
      
      Makes suspend and hibernate now also work with legacy user-space drivers on
      guest-backed devices.
      
      v2: Don't rebind on legacy devices.
      Signed-off-by: NThomas Hellstrom <thellstrom@vmware.com>
      Reviewed-by: NJakob Bornecrantz <jakob@vmware.com>
      30f82d81
  13. 17 1月, 2014 5 次提交
  14. 05 12月, 2013 2 次提交
  15. 18 11月, 2013 3 次提交
  16. 13 11月, 2013 1 次提交
  17. 16 10月, 2013 1 次提交
  18. 25 7月, 2013 1 次提交
    • D
      drm/ttm: convert to unified vma offset manager · 72525b3f
      David Herrmann 提交于
      Use the new vma-manager infrastructure. This doesn't change any
      implementation details as the vma-offset-manager is nearly copied 1-to-1
      from TTM.
      
      The vm_lock is moved into the offset manager so we can drop it from TTM.
      During lookup, we use the vma locking helpers to take a reference to the
      found object.
      In all other scenarios, locking stays the same as before. We always
      guarantee that drm_vma_offset_remove() is called only during destruction.
      Hence, helpers like drm_vma_node_offset_addr() are always safe as long as
      the node has a valid offset.
      
      This also drops the addr_space_offset member as it is a copy of vm_start
      in vma_node objects. Use the accessor functions instead.
      
      v4:
       - remove vm_lock
       - use drm_vma_offset_lock_lookup() to protect lookup (instead of vm_lock)
      
      Cc: Dave Airlie <airlied@redhat.com>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com>
      Cc: Martin Peres <martin.peres@labri.fr>
      Cc: Alex Deucher <alexander.deucher@amd.com>
      Cc: Thomas Hellstrom <thellstrom@vmware.com>
      Signed-off-by: NDavid Herrmann <dh.herrmann@gmail.com>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NDave Airlie <airlied@gmail.com>
      72525b3f
  19. 28 6月, 2013 2 次提交
  20. 28 2月, 2013 1 次提交