drm/vmwgfx: use ttm_bo_is_reserved
authorMaarten Lankhorst <maarten.lankhorst@canonical.com>
Fri, 12 Oct 2012 14:59:50 +0000 (14:59 +0000)
committerDave Airlie <airlied@redhat.com>
Wed, 7 Nov 2012 00:58:20 +0000 (10:58 +1000)
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/vmwgfx/vmwgfx_dmabuf.c

index 3ce68a2e312dbba2e588a3e52595b0d7f060ef44..bd78257cba8bc9d2b47134c77f9fe9c51d2888f7 100644 (file)
@@ -304,7 +304,7 @@ void vmw_bo_pin(struct ttm_buffer_object *bo, bool pin)
        uint32_t old_mem_type = bo->mem.mem_type;
        int ret;
 
-       BUG_ON(!atomic_read(&bo->reserved));
+       BUG_ON(!ttm_bo_is_reserved(bo));
        BUG_ON(old_mem_type != TTM_PL_VRAM &&
               old_mem_type != VMW_PL_FLAG_GMR);