Home
last modified time | relevance | path

Searched refs:refcount (Results 1 - 25 of 1376) sorted by relevance

12345678910>>...56

/kernel/linux/linux-5.10/include/linux/
H A Dkref.h17 #include <linux/refcount.h>
20 refcount_t refcount; member
23 #define KREF_INIT(n) { .refcount = REFCOUNT_INIT(n), }
31 refcount_set(&kref->refcount, 1); in kref_init()
36 return refcount_read(&kref->refcount); in kref_read()
40 * kref_get - increment refcount for object.
45 refcount_inc(&kref->refcount); in kref_get()
49 * kref_put - decrement refcount for object.
56 * Decrement the refcount, and if 0, call release().
64 if (refcount_dec_and_test(&kref->refcount)) { in kref_put()
[all...]
/kernel/linux/linux-6.6/include/linux/
H A Dkref.h17 #include <linux/refcount.h>
20 refcount_t refcount; member
23 #define KREF_INIT(n) { .refcount = REFCOUNT_INIT(n), }
31 refcount_set(&kref->refcount, 1); in kref_init()
36 return refcount_read(&kref->refcount); in kref_read()
40 * kref_get - increment refcount for object.
45 refcount_inc(&kref->refcount); in kref_get()
49 * kref_put - decrement refcount for object.
56 * Decrement the refcount, and if 0, call release().
64 if (refcount_dec_and_test(&kref->refcount)) { in kref_put()
[all...]
/kernel/linux/linux-6.6/net/dsa/
H A Dtrace.h15 #include <linux/refcount.h>
58 * is first seen and its refcount is 1.
71 * when the refcount on shared ports reaches 0
86 const struct dsa_db *db, const refcount_t *refcount),
88 TP_ARGS(dp, addr, vid, db, refcount),
97 __field(unsigned int, refcount)
107 __entry->refcount = refcount_read(refcount);
110 TP_printk("%s %s port %d addr %pM vid %u db \"%s\" refcount %u",
112 __entry->vid, __entry->db_buf, __entry->refcount)
[all...]
/kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/dc/core/
H A Ddc_surface.c112 kref_init(&plane_state->refcount); in dc_create_plane_state()
178 kref_get(&plane_state->refcount); in dc_plane_state_retain()
183 struct dc_plane_state *plane_state = container_of(kref, struct dc_plane_state, refcount); in dc_plane_state_free()
190 kref_put(&plane_state->refcount, dc_plane_state_free); in dc_plane_state_release()
195 kref_get(&gamma->refcount); in dc_gamma_retain()
200 struct dc_gamma *gamma = container_of(kref, struct dc_gamma, refcount); in dc_gamma_free()
206 kref_put(&(*gamma)->refcount, dc_gamma_free); in dc_gamma_release()
217 kref_init(&gamma->refcount); in dc_create_gamma()
226 kref_get(&tf->refcount); in dc_transfer_func_retain()
231 struct dc_transfer_func *tf = container_of(kref, struct dc_transfer_func, refcount); in dc_transfer_func_free()
[all...]
H A Ddc_sink.c73 kref_get(&sink->refcount); in dc_sink_retain()
78 struct dc_sink *sink = container_of(kref, struct dc_sink, refcount); in dc_sink_free()
85 kref_put(&sink->refcount, dc_sink_free); in dc_sink_release()
98 kref_init(&sink->refcount); in dc_sink_create()
/kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/core/
H A Ddc_surface.c112 kref_init(&plane_state->refcount); in dc_create_plane_state()
177 kref_get(&plane_state->refcount); in dc_plane_state_retain()
182 struct dc_plane_state *plane_state = container_of(kref, struct dc_plane_state, refcount); in dc_plane_state_free()
189 kref_put(&plane_state->refcount, dc_plane_state_free); in dc_plane_state_release()
194 kref_get(&gamma->refcount); in dc_gamma_retain()
199 struct dc_gamma *gamma = container_of(kref, struct dc_gamma, refcount); in dc_gamma_free()
205 kref_put(&(*gamma)->refcount, dc_gamma_free); in dc_gamma_release()
216 kref_init(&gamma->refcount); in dc_create_gamma()
225 kref_get(&tf->refcount); in dc_transfer_func_retain()
230 struct dc_transfer_func *tf = container_of(kref, struct dc_transfer_func, refcount); in dc_transfer_func_free()
[all...]
H A Ddc_sink.c62 kref_get(&sink->refcount); in dc_sink_retain()
67 struct dc_sink *sink = container_of(kref, struct dc_sink, refcount); in dc_sink_free()
74 kref_put(&sink->refcount, dc_sink_free); in dc_sink_release()
87 kref_init(&sink->refcount); in dc_sink_create()
/kernel/linux/linux-5.10/drivers/gpu/drm/msm/disp/dpu1/
H A Ddpu_hw_blk.c32 atomic_set(&hw_blk->refcount, 0); in dpu_hw_blk_init()
54 if (atomic_read(&hw_blk->refcount)) in dpu_hw_blk_destroy()
55 pr_err("hw_blk:%d.%d invalid refcount\n", hw_blk->type, in dpu_hw_blk_destroy()
73 int rc, refcount; in dpu_hw_blk_get() local
81 atomic_read(&curr->refcount))) in dpu_hw_blk_get()
95 refcount = atomic_inc_return(&hw_blk->refcount); in dpu_hw_blk_get()
97 if (refcount == 1 && hw_blk->ops.start) { in dpu_hw_blk_get()
105 pr_debug("hw_blk:%d.%d refcount:%d\n", hw_blk->type, in dpu_hw_blk_get()
106 hw_blk->id, refcount); in dpu_hw_blk_get()
[all...]
/kernel/linux/linux-6.6/arch/arm64/kvm/hyp/include/nvhe/
H A Dmemory.h11 unsigned short refcount; member
43 * hyp_pool::lock must be held if atomic access to the refcount is required.
49 return p->refcount; in hyp_page_count()
54 BUG_ON(p->refcount == USHRT_MAX); in hyp_page_ref_inc()
55 p->refcount++; in hyp_page_ref_inc()
60 BUG_ON(!p->refcount); in hyp_page_ref_dec()
61 p->refcount--; in hyp_page_ref_dec()
67 return (p->refcount == 0); in hyp_page_ref_dec_and_test()
72 BUG_ON(p->refcount); in hyp_set_page_refcounted()
73 p->refcount in hyp_set_page_refcounted()
[all...]
/kernel/linux/linux-5.10/include/trace/events/
H A Dobjagg.h88 unsigned int refcount),
90 TP_ARGS(objagg, obj, refcount),
95 __field(unsigned int, refcount)
101 __entry->refcount = refcount;
104 TP_printk("objagg %p, obj %p, refcount %u",
105 __entry->objagg, __entry->obj, __entry->refcount)
111 unsigned int refcount),
113 TP_ARGS(objagg, obj, refcount),
118 __field(unsigned int, refcount)
[all...]
/kernel/linux/linux-6.6/include/trace/events/
H A Dobjagg.h88 unsigned int refcount),
90 TP_ARGS(objagg, obj, refcount),
95 __field(unsigned int, refcount)
101 __entry->refcount = refcount;
104 TP_printk("objagg %p, obj %p, refcount %u",
105 __entry->objagg, __entry->obj, __entry->refcount)
111 unsigned int refcount),
113 TP_ARGS(objagg, obj, refcount),
118 __field(unsigned int, refcount)
[all...]
/kernel/linux/linux-5.10/drivers/scsi/qedf/
H A Dqedf_els.c84 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_initiate_els()
97 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_initiate_els()
188 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_process_els_compl()
196 int refcount; in qedf_rrq_compl() local
211 refcount = kref_read(&orig_io_req->refcount); in qedf_rrq_compl()
213 " orig xid = 0x%x, rrq_xid = 0x%x, refcount=%d\n", in qedf_rrq_compl()
214 orig_io_req, orig_io_req->xid, rrq_req->xid, refcount); in qedf_rrq_compl()
221 if (orig_io_req && refcount > 0) in qedf_rrq_compl()
222 kref_put(&orig_io_req->refcount, qedf_release_cm in qedf_rrq_compl()
248 int refcount; qedf_send_rrq() local
549 int refcount; qedf_srr_compl() local
844 int refcount; qedf_rec_compl() local
[all...]
/kernel/linux/linux-6.6/drivers/scsi/qedf/
H A Dqedf_els.c84 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_initiate_els()
97 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_initiate_els()
188 kref_put(&els_req->refcount, qedf_release_cmd); in qedf_process_els_compl()
196 int refcount; in qedf_rrq_compl() local
211 refcount = kref_read(&orig_io_req->refcount); in qedf_rrq_compl()
213 " orig xid = 0x%x, rrq_xid = 0x%x, refcount=%d\n", in qedf_rrq_compl()
214 orig_io_req, orig_io_req->xid, rrq_req->xid, refcount); in qedf_rrq_compl()
221 if (orig_io_req && refcount > 0) in qedf_rrq_compl()
222 kref_put(&orig_io_req->refcount, qedf_release_cm in qedf_rrq_compl()
248 int refcount; qedf_send_rrq() local
549 int refcount; qedf_srr_compl() local
844 int refcount; qedf_rec_compl() local
[all...]
/kernel/linux/linux-5.10/drivers/infiniband/hw/hfi1/
H A Dmmu_rb.c63 static void release_immediate(struct kref *refcount);
149 kref_put(&rbnode->refcount, release_immediate); in hfi1_mmu_rb_unregister()
226 static void release_immediate(struct kref *refcount) in release_immediate() argument
229 container_of(refcount, struct mmu_rb_node, refcount); in release_immediate()
234 static void release_nolock(struct kref *refcount) in release_nolock() argument
237 container_of(refcount, struct mmu_rb_node, refcount); in release_nolock()
243 * struct mmu_rb_node->refcount kref_put() callback.
250 void hfi1_mmu_rb_release(struct kref *refcount) in hfi1_mmu_rb_release() argument
[all...]
/kernel/linux/linux-6.6/drivers/infiniband/hw/hfi1/
H A Dmmu_rb.c22 static void release_immediate(struct kref *refcount);
111 kref_put(&rbnode->refcount, release_immediate); in hfi1_mmu_rb_unregister()
188 static void release_immediate(struct kref *refcount) in release_immediate() argument
191 container_of(refcount, struct mmu_rb_node, refcount); in release_immediate()
197 static void release_nolock(struct kref *refcount) in release_nolock() argument
200 container_of(refcount, struct mmu_rb_node, refcount); in release_nolock()
206 * struct mmu_rb_node->refcount kref_put() callback.
213 void hfi1_mmu_rb_release(struct kref *refcount) in hfi1_mmu_rb_release() argument
[all...]
/kernel/linux/linux-6.6/net/batman-adv/
H A Doriginator.c75 if (!kref_get_unless_zero(&orig_node->refcount)) in batadv_orig_hash_find()
122 if (!kref_get_unless_zero(&tmp->refcount)) in batadv_orig_node_vlan_get()
163 kref_init(&vlan->refcount); in batadv_orig_node_vlan_new()
166 kref_get(&vlan->refcount); in batadv_orig_node_vlan_new()
184 orig_vlan = container_of(ref, struct batadv_orig_node_vlan, refcount); in batadv_orig_node_vlan_release()
228 neigh_ifinfo = container_of(ref, struct batadv_neigh_ifinfo, refcount); in batadv_neigh_ifinfo_release()
246 refcount); in batadv_hardif_neigh_release()
267 neigh_node = container_of(ref, struct batadv_neigh_node, refcount); in batadv_neigh_node_release()
307 if (router && !kref_get_unless_zero(&router->refcount)) in batadv_orig_router_get()
335 if (!kref_get_unless_zero(&tmp->refcount)) in batadv_orig_ifinfo_get()
[all...]
H A Dtypes.h189 /** @refcount: number of contexts the object is used */
190 struct kref refcount; member
273 /** @refcount: number of contexts the object is used */
274 struct kref refcount; member
342 * @refcount: number of context where this object is currently in use
344 struct kref refcount; member
496 /** @refcount: number of contexts the object is used */
497 struct kref refcount; member
571 /** @refcount: number of contexts the object is used */
572 struct kref refcount; member
631 struct kref refcount; global() member
666 struct kref refcount; global() member
735 struct kref refcount; global() member
1482 struct kref refcount; global() member
1510 struct kref refcount; global() member
1797 struct kref refcount; global() member
1829 struct kref refcount; global() member
1856 struct kref refcount; global() member
1916 struct kref refcount; global() member
1946 struct kref refcount; global() member
1985 struct kref refcount; global() member
2008 struct kref refcount; global() member
2270 struct kref refcount; global() member
2317 struct kref refcount; global() member
2359 struct kref refcount; global() member
[all...]
H A Doriginator.h96 kref_put(&orig_vlan->refcount, batadv_orig_node_vlan_release); in batadv_orig_node_vlan_put()
110 kref_put(&neigh_ifinfo->refcount, batadv_neigh_ifinfo_release); in batadv_neigh_ifinfo_put()
124 kref_put(&hardif_neigh->refcount, batadv_hardif_neigh_release); in batadv_hardif_neigh_put()
137 kref_put(&neigh_node->refcount, batadv_neigh_node_release); in batadv_neigh_node_put()
151 kref_put(&orig_ifinfo->refcount, batadv_orig_ifinfo_release); in batadv_orig_ifinfo_put()
164 kref_put(&orig_node->refcount, batadv_orig_node_release); in batadv_orig_node_put()
/kernel/linux/linux-6.6/mm/
H A Dzpool.c36 atomic_set(&driver->refcount, 0); in zpool_register_driver()
54 int ret = 0, refcount; in zpool_unregister_driver() local
57 refcount = atomic_read(&driver->refcount); in zpool_unregister_driver()
58 WARN_ON(refcount < 0); in zpool_unregister_driver()
59 if (refcount > 0) in zpool_unregister_driver()
80 atomic_inc(&driver->refcount); in zpool_get_driver()
92 atomic_dec(&driver->refcount); in zpool_put_driver()
/kernel/linux/linux-5.10/net/batman-adv/
H A Dtypes.h193 /** @refcount: number of contexts the object is used */
194 struct kref refcount; member
283 /** @refcount: number of contexts the object is used */
284 struct kref refcount; member
352 * @refcount: number of context where this object is currently in use
354 struct kref refcount; member
506 /** @refcount: number of contexts the object is used */
507 struct kref refcount; member
581 /** @refcount: number of contexts the object is used */
582 struct kref refcount; member
641 struct kref refcount; global() member
676 struct kref refcount; global() member
745 struct kref refcount; global() member
1499 struct kref refcount; global() member
1530 struct kref refcount; global() member
1864 struct kref refcount; global() member
1896 struct kref refcount; global() member
1923 struct kref refcount; global() member
1983 struct kref refcount; global() member
2013 struct kref refcount; global() member
2052 struct kref refcount; global() member
2075 struct kref refcount; global() member
2358 struct kref refcount; global() member
2405 struct kref refcount; global() member
2441 struct kref refcount; global() member
[all...]
H A Doriginator.h100 kref_put(&orig_vlan->refcount, batadv_orig_node_vlan_release); in batadv_orig_node_vlan_put()
114 kref_put(&neigh_ifinfo->refcount, batadv_neigh_ifinfo_release); in batadv_neigh_ifinfo_put()
128 kref_put(&hardif_neigh->refcount, batadv_hardif_neigh_release); in batadv_hardif_neigh_put()
141 kref_put(&neigh_node->refcount, batadv_neigh_node_release); in batadv_neigh_node_put()
155 kref_put(&orig_ifinfo->refcount, batadv_orig_ifinfo_release); in batadv_orig_ifinfo_put()
168 kref_put(&orig_node->refcount, batadv_orig_node_release); in batadv_orig_node_put()
/kernel/linux/linux-5.10/fs/xfs/scrub/
H A Drefcount.c33 * We want to count the reverse mappings overlapping a refcount record
34 * (bno, len, refcount), allowing for the possibility that some of the
39 * 1. For all reverse mappings overlapping the refcount extent,
45 * refcount record we want to find $refcount owners and we've already
47 * need to find ($refcount - $seen) owners for every block in the
61 * and that they all end at or beyond the end of the refcount extent.
63 * If the refcount is correct, all the check conditions in the algorithm
64 * should always hold true. If not, the refcount is incorrect.
75 /* refcount exten
78 xfs_nlink_t refcount; global() member
268 xchk_refcountbt_xref_rmap( struct xfs_scrub *sc, xfs_agblock_t bno, xfs_extlen_t len, xfs_nlink_t refcount) xchk_refcountbt_xref_rmap() argument
315 xchk_refcountbt_xref( struct xfs_scrub *sc, xfs_agblock_t agbno, xfs_extlen_t len, xfs_nlink_t refcount) xchk_refcountbt_xref() argument
340 xfs_nlink_t refcount; xchk_refcountbt_rec() local
[all...]
/kernel/linux/linux-5.10/drivers/net/ethernet/mellanox/mlx5/core/
H A Drl.c122 if (!table->rl_entry[i].refcount) in find_rl_entry()
127 if (table->rl_entry[i].refcount) { in find_rl_entry()
200 if (entry->refcount) { in mlx5_rl_add_rate_raw()
202 entry->refcount++; in mlx5_rl_add_rate_raw()
220 entry->refcount = 1; in mlx5_rl_add_rate_raw()
238 entry->refcount--; in mlx5_rl_remove_rate_raw()
239 if (!entry->refcount) in mlx5_rl_remove_rate_raw()
284 if (!entry || !entry->refcount) { in mlx5_rl_remove_rate()
290 entry->refcount--; in mlx5_rl_remove_rate()
291 if (!entry->refcount) in mlx5_rl_remove_rate()
[all...]
/kernel/linux/linux-5.10/mm/
H A Dzpool.c44 atomic_set(&driver->refcount, 0); in zpool_register_driver()
62 int ret = 0, refcount; in zpool_unregister_driver() local
65 refcount = atomic_read(&driver->refcount); in zpool_unregister_driver()
66 WARN_ON(refcount < 0); in zpool_unregister_driver()
67 if (refcount > 0) in zpool_unregister_driver()
88 atomic_inc(&driver->refcount); in zpool_get_driver()
100 atomic_dec(&driver->refcount); in zpool_put_driver()
/kernel/linux/linux-6.6/drivers/accel/habanalabs/common/
H A Dcontext.c33 container_of(ref, struct hl_cs_encaps_sig_handle, refcount); in hl_encaps_release_handle_and_put_ctx()
41 container_of(ref, struct hl_cs_encaps_sig_handle, refcount); in hl_encaps_release_handle_and_put_sob()
49 container_of(ref, struct hl_cs_encaps_sig_handle, refcount); in hl_encaps_release_handle_and_put_sob_ctx()
75 kref_put(&handle->refcount, hl_encaps_release_handle_and_put_sob); in hl_encaps_sig_mgr_fini()
134 ctx = container_of(ref, struct hl_ctx, refcount); in hl_ctx_do_release()
205 kref_init(&ctx->refcount); in hl_ctx_init()
291 return kref_get_unless_zero(&ctx->refcount); in hl_ctx_get_unless_zero()
296 kref_get(&ctx->refcount); in hl_ctx_get()
301 return kref_put(&ctx->refcount, hl_ctx_do_release); in hl_ctx_put()
441 kref_put(&ctx->refcount, hl_ctx_do_releas in hl_ctx_mgr_fini()
[all...]

Completed in 14 milliseconds

12345678910>>...56