Lines Matching refs:pool
106 struct iommu_pool *pool; in iommu_tbl_range_alloc() local
126 pool = &(iommu->large_pool); in iommu_tbl_range_alloc()
131 pool = &(iommu->pools[pool_nr]); in iommu_tbl_range_alloc()
133 spin_lock_irqsave(&pool->lock, flags); in iommu_tbl_range_alloc()
137 (*handle >= pool->start) && (*handle < pool->end)) in iommu_tbl_range_alloc()
140 start = pool->hint; in iommu_tbl_range_alloc()
142 limit = pool->end; in iommu_tbl_range_alloc()
151 start = pool->start; in iommu_tbl_range_alloc()
160 spin_unlock(&(pool->lock)); in iommu_tbl_range_alloc()
161 pool = &(iommu->pools[0]); in iommu_tbl_range_alloc()
162 spin_lock(&(pool->lock)); in iommu_tbl_range_alloc()
163 start = pool->start; in iommu_tbl_range_alloc()
190 pool->hint = pool->start; in iommu_tbl_range_alloc()
195 spin_unlock(&(pool->lock)); in iommu_tbl_range_alloc()
197 pool = &(iommu->pools[pool_nr]); in iommu_tbl_range_alloc()
198 spin_lock(&(pool->lock)); in iommu_tbl_range_alloc()
199 pool->hint = pool->start; in iommu_tbl_range_alloc()
210 (n < pool->hint || need_flush(iommu))) { in iommu_tbl_range_alloc()
216 pool->hint = end; in iommu_tbl_range_alloc()
222 spin_unlock_irqrestore(&(pool->lock), flags); in iommu_tbl_range_alloc()
254 struct iommu_pool *pool; in iommu_tbl_range_free() local
260 pool = get_pool(iommu, entry); in iommu_tbl_range_free()
262 spin_lock_irqsave(&(pool->lock), flags); in iommu_tbl_range_free()
264 spin_unlock_irqrestore(&(pool->lock), flags); in iommu_tbl_range_free()