* A buffer object shrink method that tries to swap out the first
* buffer object on the bo_global::swap_lru list.
*/
-int ttm_bo_swapout(struct ttm_bo_global *glob, struct ttm_operation_ctx *ctx)
+int ttm_bo_swapout(struct ttm_operation_ctx *ctx)
{
+ struct ttm_bo_global *glob = &ttm_bo_glob;
struct ttm_buffer_object *bo;
int ret = -EBUSY;
bool locked;
.no_wait_gpu = false
};
- while (ttm_bo_swapout(&ttm_bo_glob, &ctx) == 0);
+ while (ttm_bo_swapout(&ctx) == 0);
}
EXPORT_SYMBOL(ttm_bo_swapout_all);
while (ttm_zones_above_swap_target(glob, from_wq, extra)) {
spin_unlock(&glob->lock);
- ret = ttm_bo_swapout(&ttm_bo_glob, ctx);
+ ret = ttm_bo_swapout(ctx);
spin_lock(&glob->lock);
if (unlikely(ret != 0))
break;
const char __user *wbuf, char __user *rbuf,
size_t count, loff_t *f_pos, bool write);
-int ttm_bo_swapout(struct ttm_bo_global *glob,
- struct ttm_operation_ctx *ctx);
+int ttm_bo_swapout(struct ttm_operation_ctx *ctx);
void ttm_bo_swapout_all(void);
/**