Lines Matching refs:shared_count

127 		for (i = 0; i < robj->fence->shared_count; i++) {  in dma_resv_fini()
338 if (list->shared_count > UINT32_MAX - num_fences) in dma_resv_reserve_shared()
342 n = list->shared_count + num_fences; in dma_resv_reserve_shared()
476 unsigned shared_count = 0; in dma_resv_get_shared_reader() local
484 shared_count = list ? atomic_load_relaxed(&list->shared_count) : 0; in dma_resv_get_shared_reader()
496 *shared_countp = shared_count; in dma_resv_get_shared_reader()
586 old_shared_count = old_list->shared_count; in dma_resv_add_excl_fence()
594 old_list->shared_count = 0; in dma_resv_add_excl_fence()
649 KASSERT(list->shared_count < list->shared_max); in dma_resv_add_shared_fence()
655 for (i = 0; i < list->shared_count; i++) { in dma_resv_add_shared_fence()
664 if (i == list->shared_count) { in dma_resv_add_shared_fence()
665 atomic_store_relaxed(&list->shared[list->shared_count], in dma_resv_add_shared_fence()
667 atomic_store_relaxed(&list->shared_count, in dma_resv_add_shared_fence()
668 list->shared_count + 1); in dma_resv_add_shared_fence()
679 uint32_t shared_count = (list == NULL? 0 : list->shared_count); in dma_resv_add_shared_fence() local
682 KASSERT(shared_count < prealloc->shared_max); in dma_resv_add_shared_fence()
688 for (i = 0; i < shared_count; i++) { in dma_resv_add_shared_fence()
697 prealloc->shared_count = shared_count; in dma_resv_add_shared_fence()
701 KASSERT(prealloc->shared_count < prealloc->shared_max); in dma_resv_add_shared_fence()
702 prealloc->shared[prealloc->shared_count++] = fence; in dma_resv_add_shared_fence()
771 unsigned shared_alloc = 0, shared_count, i; in dma_resv_get_fences_rcu() local
781 if (!dma_resv_get_shared_reader(robj, &list, &shared_count, &ticket)) in dma_resv_get_fences_rcu()
792 KASSERT(shared_count <= list->shared_max); in dma_resv_get_fences_rcu()
841 for (i = 0; i < shared_count; i++) in dma_resv_get_fences_rcu()
857 for (i = 0; i < shared_count; i++) { in dma_resv_get_fences_rcu()
864 KASSERT(shared_count <= shared_alloc); in dma_resv_get_fences_rcu()
865 KASSERT(shared_alloc == 0 || shared_count < shared_alloc); in dma_resv_get_fences_rcu()
870 if (shared_count) { in dma_resv_get_fences_rcu()
871 shared[shared_count++] = fence; in dma_resv_get_fences_rcu()
875 shared_count = 1; in dma_resv_get_fences_rcu()
878 *nsharedp = shared_count; in dma_resv_get_fences_rcu()
916 uint32_t shared_count, i; in dma_resv_copy_fences() local
929 if (!dma_resv_get_shared_reader(src_robj, &src_list, &shared_count, in dma_resv_copy_fences()
935 dst_list = objlist_tryalloc(shared_count); in dma_resv_copy_fences()
936 if (dst_list == NULL || dst_list->shared_max < shared_count) { in dma_resv_copy_fences()
942 dst_list = objlist_alloc(shared_count); in dma_resv_copy_fences()
943 dst_list->shared_count = 0; /* paranoia */ in dma_resv_copy_fences()
948 dst_list->shared_count = 0; in dma_resv_copy_fences()
949 for (i = 0; i < shared_count; i++) { in dma_resv_copy_fences()
959 dst_list->shared[dst_list->shared_count++] = fence; in dma_resv_copy_fences()
1008 for (i = old_list->shared_count; i --> 0;) { in dma_resv_copy_fences()
1023 for (i = dst_list->shared_count; i --> 0;) { in dma_resv_copy_fences()
1050 uint32_t i, shared_count; in dma_resv_test_signaled_rcu() local
1061 if (!dma_resv_get_shared_reader(robj, &list, &shared_count, in dma_resv_test_signaled_rcu()
1066 shared_count = 0; in dma_resv_test_signaled_rcu()
1075 for (i = 0; i < shared_count; i++) { in dma_resv_test_signaled_rcu()
1091 if (shared_count) in dma_resv_test_signaled_rcu()
1137 uint32_t i, shared_count; in dma_resv_wait_timeout_rcu() local
1151 if (!dma_resv_get_shared_reader(robj, &list, &shared_count, in dma_resv_wait_timeout_rcu()
1156 shared_count = 0; in dma_resv_wait_timeout_rcu()
1165 for (i = 0; i < shared_count; i++) { in dma_resv_wait_timeout_rcu()
1180 if (shared_count) in dma_resv_wait_timeout_rcu()
1293 uint32_t i, shared_count; in dma_resv_do_poll() local
1317 if (!dma_resv_get_shared_reader(robj, &list, &shared_count, in dma_resv_do_poll()
1322 shared_count = 0; in dma_resv_do_poll()
1331 for (i = 0; i < shared_count; i++) { in dma_resv_do_poll()
1346 if (i == shared_count) in dma_resv_do_poll()
1370 for (i = 0; i < shared_count; i++) { in dma_resv_do_poll()