diff options
author | Maarten Lankhorst <m.b.lankhorst@gmail.com> | 2012-11-28 06:25:40 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2012-12-10 05:13:49 -0500 |
commit | 6ed9ccb41209b93409c92eb8c130eada4e0832ef (patch) | |
tree | 17bd70937cff95c50dedc1a7d36aa95a118fe906 /drivers | |
parent | 4154f051e74e6a5db174c8f4fc8a2f9c8a6b2541 (diff) |
drm/radeon: allow move_notify to be called without reservation
The few places that care should have those checks instead.
This allows destruction of bo backed memory without a reservation.
It's required for being able to rework the delayed destroy path,
as it is no longer guaranteed to hold a reservation before unlocking.
However any previous wait is still guaranteed to complete, and it's
one of the last things to be done before the buffer object is freed.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_gart.c | 1 | ||||
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_object.c | 2 |
2 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_gart.c b/drivers/gpu/drm/radeon/radeon_gart.c index 8690be757d80..6e24f84755b5 100644 --- a/drivers/gpu/drm/radeon/radeon_gart.c +++ b/drivers/gpu/drm/radeon/radeon_gart.c | |||
@@ -1237,7 +1237,6 @@ void radeon_vm_bo_invalidate(struct radeon_device *rdev, | |||
1237 | { | 1237 | { |
1238 | struct radeon_bo_va *bo_va; | 1238 | struct radeon_bo_va *bo_va; |
1239 | 1239 | ||
1240 | BUG_ON(!radeon_bo_is_reserved(bo)); | ||
1241 | list_for_each_entry(bo_va, &bo->va, bo_list) { | 1240 | list_for_each_entry(bo_va, &bo->va, bo_list) { |
1242 | bo_va->valid = false; | 1241 | bo_va->valid = false; |
1243 | } | 1242 | } |
diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon/radeon_object.c index fe6fe2527b95..e6ee65cdfb5c 100644 --- a/drivers/gpu/drm/radeon/radeon_object.c +++ b/drivers/gpu/drm/radeon/radeon_object.c | |||
@@ -530,7 +530,7 @@ void radeon_bo_get_tiling_flags(struct radeon_bo *bo, | |||
530 | int radeon_bo_check_tiling(struct radeon_bo *bo, bool has_moved, | 530 | int radeon_bo_check_tiling(struct radeon_bo *bo, bool has_moved, |
531 | bool force_drop) | 531 | bool force_drop) |
532 | { | 532 | { |
533 | BUG_ON(!radeon_bo_is_reserved(bo)); | 533 | BUG_ON(!radeon_bo_is_reserved(bo) && !force_drop); |
534 | 534 | ||
535 | if (!(bo->tiling_flags & RADEON_TILING_SURFACE)) | 535 | if (!(bo->tiling_flags & RADEON_TILING_SURFACE)) |
536 | return 0; | 536 | return 0; |