Home
last modified time | relevance | path

Searched refs:pool (Results 1 – 25 of 683) sorted by relevance

12345678910>>...28

/linux-6.3-rc2/net/core/
A Dpage_pool.c141 memcpy(&pool->p, params, sizeof(pool->p)); in page_pool_init()
255 pool->alloc.cache[pool->alloc.count++] = page; in page_pool_refill_alloc_cache()
271 page = pool->alloc.cache[--pool->alloc.count]; in page_pool_refill_alloc_cache()
286 page = pool->alloc.cache[--pool->alloc.count]; in __page_pool_get_cached()
336 pool->p.init_callback(page, pool->p.init_arg); in page_pool_set_pp_info()
387 return pool->alloc.cache[--pool->alloc.count]; in __page_pool_alloc_pages_slow()
409 pool->alloc.cache[pool->alloc.count++] = page; in __page_pool_alloc_pages_slow()
418 page = pool->alloc.cache[--pool->alloc.count]; in __page_pool_alloc_pages_slow()
542 pool->alloc.cache[pool->alloc.count++] = page; in page_pool_recycle_in_cache()
756 pool->disconnect(pool); in page_pool_free()
[all …]
/linux-6.3-rc2/net/xdp/
A Dxsk_buff_pool.c37 if (!pool) in xp_destroy()
42 kvfree(pool); in xp_destroy()
65 if (!pool) in xp_create_and_assign_umem()
99 xskb->pool = pool; in xp_create_and_assign_umem()
105 xp_init_xskb_addr(xskb, pool, i * pool->chunk_size); in xp_create_and_assign_umem()
191 bpf.xsk.pool = pool; in xp_assign_dev()
225 if (!pool->fq || !pool->cq) in xp_assign_dev_shared()
241 xsk_clear_pool_at_qid(pool->netdev, pool->queue_id); in xp_clear_dev()
276 if (!pool) in xp_put_pool()
466 *addr + pool->chunk_size > pool->addrs_cnt || in xp_check_unaligned()
[all …]
/linux-6.3-rc2/mm/
A Dmempool.c129 BUG_ON(pool->curr_nr >= pool->min_nr); in add_element()
132 pool->elements[pool->curr_nr++] = element; in add_element()
137 void *element = pool->elements[--pool->curr_nr]; in remove_element()
160 pool->free(element, pool->pool_data); in mempool_exit()
204 while (pool->curr_nr < pool->min_nr) { in mempool_init_node()
207 element = pool->alloc(gfp_mask, pool->pool_data); in mempool_init_node()
318 pool->free(element, pool->pool_data); in mempool_resize()
345 while (pool->curr_nr < pool->min_nr) { in mempool_resize()
351 if (pool->curr_nr < pool->min_nr) { in mempool_resize()
499 if (likely(pool->curr_nr < pool->min_nr)) { in mempool_free()
[all …]
A Ddmapool.c95 pages * (pool->allocation / pool->size), in pools_show()
226 page->vaddr = dma_alloc_coherent(pool->dev, pool->allocation, in pool_alloc_page()
278 if (pool->dev && list_empty(&pool->dev->dma_pools)) in dma_pool_destroy()
287 if (pool->dev) in dma_pool_destroy()
300 kfree(pool); in dma_pool_destroy()
354 if (pool->dev) in dma_pool_alloc()
414 if (pool->dev) in dma_pool_free()
429 if (pool->dev) in dma_pool_free()
445 if (pool->dev) in dma_pool_free()
508 if (pool) in dmam_pool_create()
[all …]
A Dzbud.c218 if (!pool) in zbud_create_pool()
225 pool->pages_nr = 0; in zbud_create_pool()
226 return pool; in zbud_create_pool()
237 kfree(pool); in zbud_destroy_pool()
294 pool->pages_nr++; in zbud_alloc()
361 pool->pages_nr--; in zbud_free()
437 ret = pool->zpool_ops->evict(pool->zpool, first_handle); in zbud_reclaim_page()
442 ret = pool->zpool_ops->evict(pool->zpool, last_handle); in zbud_reclaim_page()
455 pool->pages_nr--; in zbud_reclaim_page()
524 if (pool) { in zbud_zpool_create()
[all …]
A Dz3fold.c210 slots->pool = (unsigned long)pool; in alloc_slots()
351 zhdr->pool = pool; in init_z3fold_page()
463 queue_work(pool->release_wq, &pool->work); in __release_z3fold_page()
914 if (!pool) in z3fold_create_pool()
944 return pool; in z3fold_create_pool()
953 kfree(pool); in z3fold_create_pool()
980 kfree(pool); in z3fold_destroy_pool()
1221 slots.pool = (unsigned long)pool | (1 << HANDLES_NOFREE); in z3fold_reclaim_page()
1319 ret = pool->zpool_ops->evict(pool->zpool, last_handle); in z3fold_reclaim_page()
1588 if (pool) { in z3fold_zpool_create()
[all …]
/linux-6.3-rc2/drivers/net/ethernet/ti/
A Dk3-cppi-desc-pool.c29 if (!pool) in k3_cppi_desc_pool_destroy()
37 dma_free_coherent(pool->dev, pool->mem_size, pool->cpumem, in k3_cppi_desc_pool_destroy()
52 pool = devm_kzalloc(dev, sizeof(*pool), GFP_KERNEL); in k3_cppi_desc_pool_create_name()
53 if (!pool) in k3_cppi_desc_pool_create_name()
59 pool->mem_size = pool->num_desc * pool->desc_size; in k3_cppi_desc_pool_create_name()
76 pool->cpumem = dma_alloc_coherent(pool->dev, pool->mem_size, in k3_cppi_desc_pool_create_name()
83 (phys_addr_t)pool->dma_addr, pool->mem_size, in k3_cppi_desc_pool_create_name()
90 return pool; in k3_cppi_desc_pool_create_name()
93 dma_free_coherent(pool->dev, pool->mem_size, pool->cpumem, in k3_cppi_desc_pool_create_name()
98 devm_kfree(pool->dev, pool); in k3_cppi_desc_pool_create_name()
[all …]
/linux-6.3-rc2/drivers/md/
A Ddm-thin.c625 struct pool *pool = tc->pool; in requeue_deferred_cells() local
678 struct pool *pool = tc->pool; in get_bio_block() local
695 struct pool *pool = tc->pool; in get_bio_block_range() local
719 struct pool *pool = tc->pool; in remap() local
756 struct pool *pool = tc->pool; in issue() local
884 struct pool *pool = tc->pool; in cell_defer_no_holder() local
962 struct pool *pool = tc->pool; in complete_overwrite_bio() local
995 struct pool *pool = tc->pool; in process_prepared_mapping() local
1087 struct pool *pool = tc->pool; in passdown_double_checking_shared_status() local
1151 struct pool *pool = tc->pool; in process_prepared_discard_passdown_pt1() local
[all …]
/linux-6.3-rc2/sound/core/seq/
A Dseq_memory.c24 return pool->total_elements - atomic_read(&pool->counter); in snd_seq_pool_available()
29 return snd_seq_pool_available(pool) >= pool->room; in snd_seq_output_ok()
183 pool = cell->pool; in snd_seq_cell_free()
234 while (pool->free == NULL && ! nonblock && ! pool->closing) { in snd_seq_cell_alloc()
400 cellptr->pool = pool; in snd_seq_pool_init()
404 pool->room = (pool->size + 1) / 2; in snd_seq_pool_init()
408 pool->total_elements = pool->size; in snd_seq_pool_init()
464 pool = kzalloc(sizeof(*pool), GFP_KERNEL); in snd_seq_pool_new()
465 if (!pool) in snd_seq_pool_new()
479 return pool; in snd_seq_pool_new()
[all …]
/linux-6.3-rc2/include/net/
A Dxdp_sock_drv.h36 return pool->chunk_size; in xsk_pool_get_chunk_size()
41 return xsk_pool_get_chunk_size(pool) - xsk_pool_get_headroom(pool); in xsk_pool_get_rx_frame_size()
47 xp_set_rxq_info(pool, rxq); in xsk_pool_set_rxq_info()
53 return pool->heads[0].xdp.rxq->napi_id; in xsk_pool_get_napi_id()
62 xp_dma_unmap(pool, attrs); in xsk_pool_dma_unmap()
68 struct xdp_umem *umem = pool->umem; in xsk_pool_dma_map()
89 return xp_alloc(pool); in xsk_buff_alloc()
100 return xp_can_alloc(pool, count); in xsk_buff_can_alloc()
120 return xp_raw_get_dma(pool, addr); in xsk_buff_raw_get_dma()
125 return xp_raw_get_data(pool, addr); in xsk_buff_raw_get_data()
[all …]
A Dpage_pool.h218 return page_pool_alloc_pages(pool, gfp); in page_pool_dev_alloc_pages()
239 return pool->p.dma_dir; in page_pool_get_dma_dir()
333 if (!page_pool_is_last_frag(pool, page)) in page_pool_put_page()
351 page_pool_put_full_page(pool, page, true); in page_pool_recycle_direct()
392 if (unlikely(pool->p.nid != new_nid)) in page_pool_nid_changed()
393 page_pool_update_nid(pool, new_nid); in page_pool_nid_changed()
397 __acquires(&pool->ring.producer_lock) in page_pool_ring_lock()
400 spin_lock(&pool->ring.producer_lock); in page_pool_ring_lock()
402 spin_lock_bh(&pool->ring.producer_lock); in page_pool_ring_lock()
406 __releases(&pool->ring.producer_lock) in page_pool_ring_unlock()
[all …]
A Dxsk_buff_pool.h29 struct xsk_buff_pool *pool; member
120 xskb->xdp.data_hard_start = pool->addrs + addr + pool->headroom; in xp_init_xskb_addr()
162 if (!pool->dma_need_sync) in xp_dma_sync_for_device()
183 if (pool->dma_pages_cnt) { in xp_desc_crosses_non_contig_pg()
189 return addr + len > pool->addrs_cnt; in xp_desc_crosses_non_contig_pg()
194 return addr & pool->chunk_mask; in xp_aligned_extract_addr()
215 return xp_aligned_extract_addr(pool, addr) >> pool->chunk_shift; in xp_aligned_extract_idx()
220 if (xskb->pool->unaligned) in xp_release()
221 xskb->pool->free_heads[xskb->pool->free_heads_cnt++] = xskb; in xp_release()
228 offset += xskb->pool->headroom; in xp_get_handle()
[all …]
/linux-6.3-rc2/net/ceph/
A Dmsgpool.c17 msg = ceph_msg_new2(pool->type, pool->front_len, pool->max_data_items, in msgpool_alloc()
23 msg->pool = pool; in msgpool_alloc()
34 msg->pool = NULL; in msgpool_free()
43 pool->type = type; in ceph_msgpool_init()
46 pool->pool = mempool_create(size, msgpool_alloc, msgpool_free, pool); in ceph_msgpool_init()
47 if (!pool->pool) in ceph_msgpool_init()
49 pool->name = name; in ceph_msgpool_init()
56 mempool_destroy(pool->pool); in ceph_msgpool_destroy()
68 pool->front_len, pool->max_data_items); in ceph_msgpool_get()
76 msg = mempool_alloc(pool->pool, GFP_NOFS); in ceph_msgpool_get()
[all …]
/linux-6.3-rc2/drivers/staging/media/atomisp/pci/runtime/rmgr/src/
A Drmgr_vbuf.c134 assert(pool); in ia_css_rmgr_init_vbuf()
135 if (!pool) in ia_css_rmgr_init_vbuf()
138 if (pool->recycle && pool->size) { in ia_css_rmgr_init_vbuf()
142 pool->size; in ia_css_rmgr_init_vbuf()
144 if (pool->handles) in ia_css_rmgr_init_vbuf()
150 pool->size = 0; in ia_css_rmgr_init_vbuf()
151 pool->handles = NULL; in ia_css_rmgr_init_vbuf()
166 if (!pool) { in ia_css_rmgr_uninit_vbuf()
170 if (pool->handles) { in ia_css_rmgr_uninit_vbuf()
203 assert(pool); in rmgr_push_handle()
[all …]
/linux-6.3-rc2/drivers/net/ethernet/mellanox/mlx5/core/steering/
A Ddr_icm_pool.c119 icm_mr->dmn = pool->dmn; in dr_icm_pool_mr_create()
265 buddy->pool = pool; in dr_icm_buddy_create()
402 mlx5dr_err(pool->dmn, in dr_icm_handle_buddies_get_mem()
457 struct mlx5dr_icm_pool *pool = buddy->pool; in mlx5dr_icm_free_chunk() local
468 hot_chunk = &pool->hot_chunks_arr[pool->hot_chunks_num++]; in mlx5dr_icm_free_chunk()
504 pool = kvzalloc(sizeof(*pool), GFP_KERNEL); in mlx5dr_icm_pool_create()
505 if (!pool) in mlx5dr_icm_pool_create()
508 pool->dmn = dmn; in mlx5dr_icm_pool_create()
531 return pool; in mlx5dr_icm_pool_create()
534 kvfree(pool); in mlx5dr_icm_pool_create()
[all …]
/linux-6.3-rc2/drivers/gpu/drm/amd/display/dc/dce80/
A Ddce80_resource.c930 *pool = NULL; in dce80_destroy_resource_pool()
1040 if (!pool->base.irqs) in dce80_construct()
1134 if (!pool) in dce80_create_resource_pool()
1138 return &pool->base; in dce80_create_resource_pool()
1140 kfree(pool); in dce80_create_resource_pool()
1240 if (!pool->base.irqs) in dce81_construct()
1334 if (!pool) in dce81_create_resource_pool()
1338 return &pool->base; in dce81_create_resource_pool()
1340 kfree(pool); in dce81_create_resource_pool()
1530 if (!pool) in dce83_create_resource_pool()
[all …]
/linux-6.3-rc2/drivers/gpu/drm/amd/display/dc/dce60/
A Ddce60_resource.c927 *pool = NULL; in dce60_destroy_resource_pool()
1031 if (!pool->base.irqs) in dce60_construct()
1125 if (!pool) in dce60_create_resource_pool()
1129 return &pool->base; in dce60_create_resource_pool()
1131 kfree(pool); in dce60_create_resource_pool()
1323 if (!pool) in dce61_create_resource_pool()
1327 return &pool->base; in dce61_create_resource_pool()
1329 kfree(pool); in dce61_create_resource_pool()
1517 if (!pool) in dce64_create_resource_pool()
1521 return &pool->base; in dce64_create_resource_pool()
[all …]
/linux-6.3-rc2/drivers/net/ethernet/mellanox/mlx5/core/
A Dirq_affinity.c10 pool->irqs_per_cpu[cpu]--; in cpu_put()
15 pool->irqs_per_cpu[cpu]++; in cpu_get()
27 if (!pool->irqs_per_cpu[cpu]) { in cpu_get_least_loaded()
33 if (pool->irqs_per_cpu[cpu] < pool->irqs_per_cpu[best_cpu]) in cpu_get_least_loaded()
42 pool->irqs_per_cpu[best_cpu]++; in cpu_get_least_loaded()
57 err = xa_alloc(&pool->irqs, &irq_index, NULL, pool->xa_num_irqs, GFP_KERNEL); in irq_pool_request_irq()
60 if (pool->irqs_per_cpu) { in irq_pool_request_irq()
127 mutex_lock(&pool->lock); in mlx5_irq_affinity_request()
157 mutex_unlock(&pool->lock); in mlx5_irq_affinity_request()
173 if (pool->irqs_per_cpu) in mlx5_irq_affinity_irqs_release()
[all …]
/linux-6.3-rc2/arch/arm64/kvm/hyp/nvhe/
A Dpage_alloc.c45 if (addr < pool->range_start || addr >= pool->range_end) in __find_buddy_nocheck()
103 if (phys < pool->range_start || phys >= pool->range_end) in __hyp_attach_page()
156 __hyp_attach_page(pool, p); in __hyp_put_page()
170 hyp_spin_lock(&pool->lock); in hyp_put_page()
171 __hyp_put_page(pool, p); in hyp_put_page()
172 hyp_spin_unlock(&pool->lock); in hyp_put_page()
179 hyp_spin_lock(&pool->lock); in hyp_get_page()
203 hyp_spin_lock(&pool->lock); in hyp_alloc_pages()
206 while (i < pool->max_order && list_empty(&pool->free_area[i])) in hyp_alloc_pages()
208 if (i >= pool->max_order) { in hyp_alloc_pages()
[all …]
/linux-6.3-rc2/drivers/net/ethernet/mellanox/mlx5/core/lib/
A Dcrypto.c19 #define MLX5_CRYPTO_DEK_POOL_CALC_FREED(pool) MLX5_CRYPTO_DEK_CALC_FREED(pool) argument
412 pool->avail_deks--; in mlx5_crypto_dek_pool_pop()
413 pool->in_use_deks++; in mlx5_crypto_dek_pool_pop()
460 if (pool->syncing) in mlx5_crypto_dek_pool_push()
595 err = mlx5_crypto_cmd_sync_crypto(pool->mdev, BIT(pool->key_purpose)); in mlx5_crypto_dek_sync_work_fn()
676 mlx5_crypto_dek_pool_splice_destroy_list(pool, &pool->destroy_list, in mlx5_crypto_dek_destroy_work_fn()
686 pool = kzalloc(sizeof(*pool), GFP_KERNEL); in mlx5_crypto_dek_pool_create()
687 if (!pool) in mlx5_crypto_dek_pool_create()
690 pool->mdev = mdev; in mlx5_crypto_dek_pool_create()
704 return pool; in mlx5_crypto_dek_pool_create()
[all …]
/linux-6.3-rc2/net/rds/
A Dib_rdma.c275 struct rds_ib_mr_pool *pool = ibmr->pool; in rds_ib_teardown_mr() local
423 &pool->clean_list); in rds_ib_flush_mr_pool()
450 if (atomic_inc_return(&pool->item_count) <= pool->max_items) in rds_ib_try_reuse_ibmr()
487 struct rds_ib_mr_pool *pool = ibmr->pool; in rds_ib_free_mr() local
509 if (atomic_read(&pool->free_pinned) >= pool->max_free_pinned || in rds_ib_free_mr()
510 atomic_read(&pool->dirty_count) >= pool->max_items / 5) in rds_ib_free_mr()
640 kfree(pool); in rds_ib_destroy_mr_pool()
648 pool = kzalloc(sizeof(*pool), GFP_KERNEL); in rds_ib_create_mr_pool()
649 if (!pool) in rds_ib_create_mr_pool()
671 pool->max_free_pinned = pool->max_items * pool->max_pages / 4; in rds_ib_create_mr_pool()
[all …]
/linux-6.3-rc2/drivers/net/ethernet/mellanox/mlxsw/
A Dspectrum_cnt.c127 pool = kzalloc(struct_size(pool, sub_pools, sub_pools_count), in mlxsw_sp_counter_pool_init()
129 if (!pool) in mlxsw_sp_counter_pool_init()
134 flex_array_size(pool, sub_pools, pool->sub_pools_count)); in mlxsw_sp_counter_pool_init()
139 &pool->pool_size); in mlxsw_sp_counter_pool_init()
145 pool->usage = bitmap_zalloc(pool->pool_size, GFP_KERNEL); in mlxsw_sp_counter_pool_init()
146 if (!pool->usage) { in mlxsw_sp_counter_pool_init()
158 bitmap_free(pool->usage); in mlxsw_sp_counter_pool_init()
163 kfree(pool); in mlxsw_sp_counter_pool_init()
173 WARN_ON(find_first_bit(pool->usage, pool->pool_size) != in mlxsw_sp_counter_pool_fini()
176 bitmap_free(pool->usage); in mlxsw_sp_counter_pool_fini()
[all …]
/linux-6.3-rc2/include/linux/
A Dgenalloc.h52 void *data, struct gen_pool *pool,
104 return gen_pool_add_owner(pool, addr, phys, size, nid, NULL); in gen_pool_add_virt()
122 return gen_pool_add_virt(pool, addr, -1, size, nid); in gen_pool_add()
131 return gen_pool_alloc_algo_owner(pool, size, pool->algo, pool->data, in gen_pool_alloc_owner()
153 return gen_pool_alloc_algo(pool, size, pool->algo, pool->data); in gen_pool_alloc()
172 gen_pool_free_owner(pool, addr, size, NULL); in gen_pool_free()
185 struct gen_pool *pool, unsigned long start_addr);
189 void *data, struct gen_pool *pool, unsigned long start_addr);
193 void *data, struct gen_pool *pool, unsigned long start_addr);
198 void *data, struct gen_pool *pool, unsigned long start_addr);
[all …]
/linux-6.3-rc2/drivers/gpu/drm/i915/gt/
A Dintel_gt_buffer_pool.c24 if (n >= ARRAY_SIZE(pool->cache_list)) in bucket_for_size()
25 n = ARRAY_SIZE(pool->cache_list) - 1; in bucket_for_size()
27 return &pool->cache_list[n]; in bucket_for_size()
73 spin_unlock_irq(&pool->lock); in pool_free_older_than()
89 struct intel_gt_buffer_pool *pool = in pool_free_work() local
101 struct intel_gt_buffer_pool *pool = node->pool; in pool_retire() local
119 schedule_delayed_work(&pool->work, in pool_retire()
150 node->pool = pool; in node_create()
195 spin_lock_irq(&pool->lock); in intel_gt_get_buffer_pool()
197 spin_unlock_irq(&pool->lock); in intel_gt_get_buffer_pool()
[all …]
/linux-6.3-rc2/lib/
A Dgenalloc.c156 if (pool != NULL) { in gen_pool_create()
164 return pool; in gen_pool_create()
258 kfree(pool); in gen_pool_destroy()
341 return gen_pool_dma_alloc_algo(pool, size, dma, pool->algo, pool->data); in gen_pool_dma_alloc()
365 if (!pool) in gen_pool_dma_alloc_algo()
419 return gen_pool_dma_zalloc_algo(pool, size, dma, pool->algo, pool->data); in gen_pool_dma_zalloc()
625 if (!pool->algo) in gen_pool_set_algo()
848 if (!pool) in devm_gen_pool_create()
851 *ptr = pool; in devm_gen_pool_create()
855 return pool; in devm_gen_pool_create()
[all …]

Completed in 107 milliseconds

12345678910>>...28