@@ -315,7 +315,7 @@ nouveau_bo_pin(struct nouveau_bo *nvbo, uint32_t memtype)
315315
316316 nouveau_bo_placement_set (nvbo , memtype , 0 );
317317
318- ret = nouveau_bo_validate (nvbo , false, false, false );
318+ ret = nouveau_bo_validate (nvbo , false, false);
319319 if (ret == 0 ) {
320320 switch (bo -> mem .mem_type ) {
321321 case TTM_PL_VRAM :
@@ -351,7 +351,7 @@ nouveau_bo_unpin(struct nouveau_bo *nvbo)
351351
352352 nouveau_bo_placement_set (nvbo , bo -> mem .placement , 0 );
353353
354- ret = nouveau_bo_validate (nvbo , false, false, false );
354+ ret = nouveau_bo_validate (nvbo , false, false);
355355 if (ret == 0 ) {
356356 switch (bo -> mem .mem_type ) {
357357 case TTM_PL_VRAM :
@@ -392,12 +392,12 @@ nouveau_bo_unmap(struct nouveau_bo *nvbo)
392392
393393int
394394nouveau_bo_validate (struct nouveau_bo * nvbo , bool interruptible ,
395- bool no_wait_reserve , bool no_wait_gpu )
395+ bool no_wait_gpu )
396396{
397397 int ret ;
398398
399- ret = ttm_bo_validate (& nvbo -> bo , & nvbo -> placement , interruptible ,
400- no_wait_reserve , no_wait_gpu );
399+ ret = ttm_bo_validate (& nvbo -> bo , & nvbo -> placement ,
400+ interruptible , no_wait_gpu );
401401 if (ret )
402402 return ret ;
403403
@@ -556,8 +556,7 @@ nouveau_bo_evict_flags(struct ttm_buffer_object *bo, struct ttm_placement *pl)
556556static int
557557nouveau_bo_move_accel_cleanup (struct nouveau_channel * chan ,
558558 struct nouveau_bo * nvbo , bool evict ,
559- bool no_wait_reserve , bool no_wait_gpu ,
560- struct ttm_mem_reg * new_mem )
559+ bool no_wait_gpu , struct ttm_mem_reg * new_mem )
561560{
562561 struct nouveau_fence * fence = NULL ;
563562 int ret ;
@@ -567,7 +566,7 @@ nouveau_bo_move_accel_cleanup(struct nouveau_channel *chan,
567566 return ret ;
568567
569568 ret = ttm_bo_move_accel_cleanup (& nvbo -> bo , fence , evict ,
570- no_wait_reserve , no_wait_gpu , new_mem );
569+ no_wait_gpu , new_mem );
571570 nouveau_fence_unref (& fence );
572571 return ret ;
573572}
@@ -965,8 +964,7 @@ nouveau_vma_getmap(struct nouveau_channel *chan, struct nouveau_bo *nvbo,
965964
966965static int
967966nouveau_bo_move_m2mf (struct ttm_buffer_object * bo , int evict , bool intr ,
968- bool no_wait_reserve , bool no_wait_gpu ,
969- struct ttm_mem_reg * new_mem )
967+ bool no_wait_gpu , struct ttm_mem_reg * new_mem )
970968{
971969 struct nouveau_drm * drm = nouveau_bdev (bo -> bdev );
972970 struct nouveau_channel * chan = chan = drm -> channel ;
@@ -995,7 +993,6 @@ nouveau_bo_move_m2mf(struct ttm_buffer_object *bo, int evict, bool intr,
995993 ret = drm -> ttm .move (chan , bo , & bo -> mem , new_mem );
996994 if (ret == 0 ) {
997995 ret = nouveau_bo_move_accel_cleanup (chan , nvbo , evict ,
998- no_wait_reserve ,
999996 no_wait_gpu , new_mem );
1000997 }
1001998
@@ -1064,8 +1061,7 @@ nouveau_bo_move_init(struct nouveau_drm *drm)
10641061
10651062static int
10661063nouveau_bo_move_flipd (struct ttm_buffer_object * bo , bool evict , bool intr ,
1067- bool no_wait_reserve , bool no_wait_gpu ,
1068- struct ttm_mem_reg * new_mem )
1064+ bool no_wait_gpu , struct ttm_mem_reg * new_mem )
10691065{
10701066 u32 placement_memtype = TTM_PL_FLAG_TT | TTM_PL_MASK_CACHING ;
10711067 struct ttm_placement placement ;
@@ -1078,28 +1074,27 @@ nouveau_bo_move_flipd(struct ttm_buffer_object *bo, bool evict, bool intr,
10781074
10791075 tmp_mem = * new_mem ;
10801076 tmp_mem .mm_node = NULL ;
1081- ret = ttm_bo_mem_space (bo , & placement , & tmp_mem , intr , no_wait_reserve , no_wait_gpu );
1077+ ret = ttm_bo_mem_space (bo , & placement , & tmp_mem , intr , no_wait_gpu );
10821078 if (ret )
10831079 return ret ;
10841080
10851081 ret = ttm_tt_bind (bo -> ttm , & tmp_mem );
10861082 if (ret )
10871083 goto out ;
10881084
1089- ret = nouveau_bo_move_m2mf (bo , true, intr , no_wait_reserve , no_wait_gpu , & tmp_mem );
1085+ ret = nouveau_bo_move_m2mf (bo , true, intr , no_wait_gpu , & tmp_mem );
10901086 if (ret )
10911087 goto out ;
10921088
1093- ret = ttm_bo_move_ttm (bo , true, no_wait_reserve , no_wait_gpu , new_mem );
1089+ ret = ttm_bo_move_ttm (bo , true, no_wait_gpu , new_mem );
10941090out :
10951091 ttm_bo_mem_put (bo , & tmp_mem );
10961092 return ret ;
10971093}
10981094
10991095static int
11001096nouveau_bo_move_flips (struct ttm_buffer_object * bo , bool evict , bool intr ,
1101- bool no_wait_reserve , bool no_wait_gpu ,
1102- struct ttm_mem_reg * new_mem )
1097+ bool no_wait_gpu , struct ttm_mem_reg * new_mem )
11031098{
11041099 u32 placement_memtype = TTM_PL_FLAG_TT | TTM_PL_MASK_CACHING ;
11051100 struct ttm_placement placement ;
@@ -1112,15 +1107,15 @@ nouveau_bo_move_flips(struct ttm_buffer_object *bo, bool evict, bool intr,
11121107
11131108 tmp_mem = * new_mem ;
11141109 tmp_mem .mm_node = NULL ;
1115- ret = ttm_bo_mem_space (bo , & placement , & tmp_mem , intr , no_wait_reserve , no_wait_gpu );
1110+ ret = ttm_bo_mem_space (bo , & placement , & tmp_mem , intr , no_wait_gpu );
11161111 if (ret )
11171112 return ret ;
11181113
1119- ret = ttm_bo_move_ttm (bo , true, no_wait_reserve , no_wait_gpu , & tmp_mem );
1114+ ret = ttm_bo_move_ttm (bo , true, no_wait_gpu , & tmp_mem );
11201115 if (ret )
11211116 goto out ;
11221117
1123- ret = nouveau_bo_move_m2mf (bo , true, intr , no_wait_reserve , no_wait_gpu , new_mem );
1118+ ret = nouveau_bo_move_m2mf (bo , true, intr , no_wait_gpu , new_mem );
11241119 if (ret )
11251120 goto out ;
11261121
@@ -1195,8 +1190,7 @@ nouveau_bo_vm_cleanup(struct ttm_buffer_object *bo,
11951190
11961191static int
11971192nouveau_bo_move (struct ttm_buffer_object * bo , bool evict , bool intr ,
1198- bool no_wait_reserve , bool no_wait_gpu ,
1199- struct ttm_mem_reg * new_mem )
1193+ bool no_wait_gpu , struct ttm_mem_reg * new_mem )
12001194{
12011195 struct nouveau_drm * drm = nouveau_bdev (bo -> bdev );
12021196 struct nouveau_bo * nvbo = nouveau_bo (bo );
@@ -1220,23 +1214,26 @@ nouveau_bo_move(struct ttm_buffer_object *bo, bool evict, bool intr,
12201214
12211215 /* CPU copy if we have no accelerated method available */
12221216 if (!drm -> ttm .move ) {
1223- ret = ttm_bo_move_memcpy (bo , evict , no_wait_reserve , no_wait_gpu , new_mem );
1217+ ret = ttm_bo_move_memcpy (bo , evict , no_wait_gpu , new_mem );
12241218 goto out ;
12251219 }
12261220
12271221 /* Hardware assisted copy. */
12281222 if (new_mem -> mem_type == TTM_PL_SYSTEM )
1229- ret = nouveau_bo_move_flipd (bo , evict , intr , no_wait_reserve , no_wait_gpu , new_mem );
1223+ ret = nouveau_bo_move_flipd (bo , evict , intr ,
1224+ no_wait_gpu , new_mem );
12301225 else if (old_mem -> mem_type == TTM_PL_SYSTEM )
1231- ret = nouveau_bo_move_flips (bo , evict , intr , no_wait_reserve , no_wait_gpu , new_mem );
1226+ ret = nouveau_bo_move_flips (bo , evict , intr ,
1227+ no_wait_gpu , new_mem );
12321228 else
1233- ret = nouveau_bo_move_m2mf (bo , evict , intr , no_wait_reserve , no_wait_gpu , new_mem );
1229+ ret = nouveau_bo_move_m2mf (bo , evict , intr ,
1230+ no_wait_gpu , new_mem );
12341231
12351232 if (!ret )
12361233 goto out ;
12371234
12381235 /* Fallback to software copy. */
1239- ret = ttm_bo_move_memcpy (bo , evict , no_wait_reserve , no_wait_gpu , new_mem );
1236+ ret = ttm_bo_move_memcpy (bo , evict , no_wait_gpu , new_mem );
12401237
12411238out :
12421239 if (nv_device (drm -> device )-> card_type < NV_50 ) {
@@ -1343,7 +1340,7 @@ nouveau_ttm_fault_reserve_notify(struct ttm_buffer_object *bo)
13431340 nvbo -> placement .fpfn = 0 ;
13441341 nvbo -> placement .lpfn = mappable ;
13451342 nouveau_bo_placement_set (nvbo , TTM_PL_FLAG_VRAM , 0 );
1346- return nouveau_bo_validate (nvbo , false, true, false);
1343+ return nouveau_bo_validate (nvbo , false, false);
13471344}
13481345
13491346static int
0 commit comments