@@ -141,7 +141,7 @@ static void vmw_resource_release(struct kref *kref)
141141 if (res -> coherent )
142142 vmw_bo_dirty_release (res -> guest_memory_bo );
143143 ttm_bo_unreserve (bo );
144- vmw_bo_unreference (& res -> guest_memory_bo );
144+ vmw_user_bo_unref (& res -> guest_memory_bo );
145145 }
146146
147147 if (likely (res -> hw_destroy != NULL )) {
@@ -338,7 +338,7 @@ static int vmw_resource_buf_alloc(struct vmw_resource *res,
338338 return 0 ;
339339 }
340340
341- ret = vmw_bo_create (res -> dev_priv , & bo_params , & gbo );
341+ ret = vmw_gem_object_create (res -> dev_priv , & bo_params , & gbo );
342342 if (unlikely (ret != 0 ))
343343 goto out_no_bo ;
344344
@@ -457,11 +457,11 @@ void vmw_resource_unreserve(struct vmw_resource *res,
457457 vmw_resource_mob_detach (res );
458458 if (res -> coherent )
459459 vmw_bo_dirty_release (res -> guest_memory_bo );
460- vmw_bo_unreference (& res -> guest_memory_bo );
460+ vmw_user_bo_unref (& res -> guest_memory_bo );
461461 }
462462
463463 if (new_guest_memory_bo ) {
464- res -> guest_memory_bo = vmw_bo_reference (new_guest_memory_bo );
464+ res -> guest_memory_bo = vmw_user_bo_ref (new_guest_memory_bo );
465465
466466 /*
467467 * The validation code should already have added a
@@ -551,7 +551,7 @@ vmw_resource_check_buffer(struct ww_acquire_ctx *ticket,
551551 ttm_bo_put (val_buf -> bo );
552552 val_buf -> bo = NULL ;
553553 if (guest_memory_dirty )
554- vmw_bo_unreference (& res -> guest_memory_bo );
554+ vmw_user_bo_unref (& res -> guest_memory_bo );
555555
556556 return ret ;
557557}
@@ -727,7 +727,7 @@ int vmw_resource_validate(struct vmw_resource *res, bool intr,
727727 goto out_no_validate ;
728728 else if (!res -> func -> needs_guest_memory && res -> guest_memory_bo ) {
729729 WARN_ON_ONCE (vmw_resource_mob_attached (res ));
730- vmw_bo_unreference (& res -> guest_memory_bo );
730+ vmw_user_bo_unref (& res -> guest_memory_bo );
731731 }
732732
733733 return 0 ;
0 commit comments