@@ -272,12 +272,6 @@ static void submit_cleanup_bo(struct msm_gem_submit *submit, int i,
dma_resv_unlock(obj->resv);
}
-static void submit_unlock_unpin_bo(struct msm_gem_submit *submit, int i)
-{
- unsigned cleanup_flags = BO_PINNED | BO_LOCKED;
- submit_cleanup_bo(submit, i, cleanup_flags);
-}
-
/* This is where we make sure all the bo's are reserved and pin'd: */
static int submit_lock_objects(struct msm_gem_submit *submit)
{
@@ -313,10 +307,10 @@ static int submit_lock_objects(struct msm_gem_submit *submit)
}
for (; i >= 0; i--)
- submit_unlock_unpin_bo(submit, i);
+ submit_cleanup_bo(submit, i, BO_LOCKED);
if (slow_locked > 0)
- submit_unlock_unpin_bo(submit, slow_locked);
+ submit_cleanup_bo(submit, slow_locked, BO_LOCKED);
if (ret == -EDEADLK) {
struct drm_gem_object *obj = submit->bos[contended].obj;