| /linux/tools/bpf/bpftool/ |
| H A D | pids.c | 34 struct obj_refs *refs; in add_ref() local 40 refs = entry->pvalue; in add_ref() 42 for (i = 0; i < refs->ref_cnt; i++) { in add_ref() 43 if (refs->refs[i].pid == e->pid) in add_ref() 47 tmp = realloc(refs->refs, (refs->ref_cnt + 1) * sizeof(*ref)); in add_ref() 53 refs->refs = tmp; in add_ref() 54 ref = &refs->refs[refs->ref_cnt]; in add_ref() 58 refs->ref_cnt++; in add_ref() 64 refs = calloc(1, sizeof(*refs)); in add_ref() 65 if (!refs) { in add_ref() [all …]
|
| /linux/drivers/media/v4l2-core/ |
| H A D | v4l2-h264.c | 60 b->refs[i].longterm = true; in v4l2_h264_init_reflist_builder() 68 if (!b->refs[i].longterm && dpb[i].frame_num > cur_frame_num) in v4l2_h264_init_reflist_builder() 69 b->refs[i].frame_num = (int)dpb[i].frame_num - in v4l2_h264_init_reflist_builder() 72 b->refs[i].frame_num = dpb[i].frame_num; in v4l2_h264_init_reflist_builder() 74 b->refs[i].top_field_order_cnt = dpb[i].top_field_order_cnt; in v4l2_h264_init_reflist_builder() 75 b->refs[i].bottom_field_order_cnt = dpb[i].bottom_field_order_cnt; in v4l2_h264_init_reflist_builder() 113 return min(b->refs[ref->index].top_field_order_cnt, in v4l2_h264_get_poc() 114 b->refs[ref->index].bottom_field_order_cnt); in v4l2_h264_get_poc() 116 return b->refs[ref->index].top_field_order_cnt; in v4l2_h264_get_poc() 118 return b->refs[ref->index].bottom_field_order_cnt; in v4l2_h264_get_poc() [all …]
|
| /linux/drivers/xen/ |
| H A D | gntdev-dmabuf.c | 44 grant_ref_t *refs; member 428 int count, u32 domid, u32 *refs, u32 *fd) in dmabuf_exp_from_refs() argument 440 map->grants[i].ref = refs[i]; in dmabuf_exp_from_refs() 479 dmabuf_imp_grant_foreign_access(unsigned long *gfns, u32 *refs, in dmabuf_imp_grant_foreign_access() argument 503 refs[i] = cur_ref; in dmabuf_imp_grant_foreign_access() 513 static void dmabuf_imp_end_foreign_access(u32 *refs, int count) in dmabuf_imp_end_foreign_access() argument 518 if (refs[i] != INVALID_GRANT_REF) in dmabuf_imp_end_foreign_access() 519 gnttab_end_foreign_access(refs[i], NULL); in dmabuf_imp_end_foreign_access() 524 kfree(gntdev_dmabuf->u.imp.refs); in dmabuf_imp_free_storage() 537 gntdev_dmabuf->u.imp.refs = kzalloc_objs(gntdev_dmabuf->u.imp.refs[0], in dmabuf_imp_alloc_storage() [all …]
|
| /linux/fs/smb/client/ |
| H A D | dfs_cache.c | 254 static inline void dump_refs(const struct dfs_info3_param *refs, int numrefs) in dump_refs() argument 260 const struct dfs_info3_param *ref = &refs[i]; in dump_refs() 386 static int copy_ref_data(const struct dfs_info3_param *refs, int numrefs, in copy_ref_data() argument 395 t = alloc_target(refs[i].node_name, refs[i].path_consumed); in copy_ref_data() 412 ce->ttl = max_t(int, refs[0].ttl, CACHE_MIN_TTL); in copy_ref_data() 414 ce->srvtype = refs[0].server_type; in copy_ref_data() 415 ce->hdr_flags = refs[0].flags; in copy_ref_data() 416 ce->ref_flags = refs[0].ref_flag; in copy_ref_data() 417 ce->path_consumed = refs[0].path_consumed; in copy_ref_data() 424 static struct cache_entry *alloc_cache_entry(struct dfs_info3_param *refs, int numrefs) in alloc_cache_entry() argument [all …]
|
| /linux/drivers/gpu/drm/nouveau/nvkm/core/ |
| H A D | event.c | 34 if (--event->refs[index * event->types_nr + type] == 0) { in nvkm_event_put() 51 if (++event->refs[index * event->types_nr + type] == 1) { in nvkm_event_get() 175 if (!event->refs || WARN_ON(id >= event->index_nr)) in nvkm_event_ntfy() 194 if (event->refs) { in nvkm_event_fini() 195 kfree(event->refs); in nvkm_event_fini() 196 event->refs = NULL; in nvkm_event_fini() 204 event->refs = kzalloc(array3_size(index_nr, types_nr, sizeof(*event->refs)), GFP_KERNEL); in __nvkm_event_init() 205 if (!event->refs) in __nvkm_event_init()
|
| /linux/tools/lib/python/abi/ |
| H A D | system_symbols.py | 175 def check_file(self, refs, found): argument 181 for names in refs: 235 """Interactor to group refs into chunks.""" 238 refs = [] 241 refs.append(ref) 245 yield refs 247 refs = [] 249 yield refs 321 for refs in self.get_fileref(all_refs, chunk_size): 322 if refs [all...] |
| /linux/drivers/gpio/ |
| H A D | gpiolib-shared.c | 60 struct list_head refs; member 115 list_for_each_entry(ref, &entry->refs, list) { in gpio_shared_setup_reset_proxy() 127 list_add_tail(&ref->list, &entry->refs); in gpio_shared_setup_reset_proxy() 237 INIT_LIST_HEAD(&entry->refs); in gpio_shared_of_traverse() 272 if (!list_empty(&entry->refs)) in gpio_shared_of_traverse() 276 list_add_tail(&ref->list, &entry->refs); in gpio_shared_of_traverse() 389 list_for_each_entry(real_ref, &entry->refs, list) { in gpio_shared_dev_is_reset_gpio() 458 list_for_each_entry(ref, &entry->refs, list) { in gpio_shared_add_proxy_lookup() 521 list_for_each_entry(ref, &entry->refs, list) { in gpiochip_setup_shared() 542 if (list_count_nodes(&entry->refs) <= 1) in gpiochip_setup_shared() [all …]
|
| /linux/Documentation/userspace-api/media/dvb/ |
| H A D | headers.rst | 15 :generate-cross-refs: 24 :generate-cross-refs: 33 :generate-cross-refs: 42 :generate-cross-refs:
|
| /linux/net/ieee802154/6lowpan/ |
| H A D | reassembly.c | 35 int *refs); 49 int refs = 1; in lowpan_frag_expire() local 58 inet_frag_kill(&fq->q, &refs); in lowpan_frag_expire() 61 inet_frag_putn(&fq->q, refs); in lowpan_frag_expire() 88 int *refs) in lowpan_frag_queue() argument 149 res = lowpan_frag_reasm(fq, skb, prev_tail, ldev, refs); in lowpan_frag_queue() 169 int *refs) in lowpan_frag_reasm() argument 173 inet_frag_kill(&fq->q, refs); in lowpan_frag_reasm() 310 int ret, refs = 0; in lowpan_frag_rcv() local 313 ret = lowpan_frag_queue(fq, skb, frag_type, &refs); in lowpan_frag_rcv() [all …]
|
| /linux/mm/ |
| H A D | gup.c | 74 static inline struct folio *try_get_folio(struct page *page, int refs) in try_get_folio() argument 82 if (unlikely(!folio_ref_try_add(folio, refs))) in try_get_folio() 95 folio_put_refs(folio, refs); in try_get_folio() 102 static void gup_put_folio(struct folio *folio, int refs, unsigned int flags) in gup_put_folio() argument 107 node_stat_mod_folio(folio, NR_FOLL_PIN_RELEASED, refs); in gup_put_folio() 109 atomic_sub(refs, &folio->_pincount); in gup_put_folio() 111 refs *= GUP_PIN_COUNTING_BIAS; in gup_put_folio() 114 folio_put_refs(folio, refs); in gup_put_folio() 140 int __must_check try_grab_folio(struct folio *folio, int refs, in try_grab_folio() argument 150 folio_ref_add(folio, refs); in try_grab_folio() [all …]
|
| /linux/net/ipv6/netfilter/ |
| H A D | nf_conntrack_reasm.c | 127 int *refs); 172 int *refs) in nf_ct_frag6_queue() argument 226 inet_frag_kill(&fq->q, refs); in nf_ct_frag6_queue() 292 err = nf_ct_frag6_reasm(fq, skb, prev, dev, refs); in nf_ct_frag6_queue() 306 inet_frag_kill(&fq->q, refs); in nf_ct_frag6_queue() 321 int *refs) in nf_ct_frag6_reasm() argument 327 inet_frag_kill(&fq->q, refs); in nf_ct_frag6_reasm() 379 inet_frag_kill(&fq->q, refs); in nf_ct_frag6_reasm() 454 int refs = 0; in nf_ct_frag6_gather() local 492 ret = nf_ct_frag6_queue(fq, skb, fhdr, nhoff, &refs); in nf_ct_frag6_gather() [all …]
|
| /linux/io_uring/ |
| H A D | waitid.c | 29 atomic_t refs; member 133 WARN_ON_ONCE(!(atomic_read(&iw->refs) & IO_WAITID_REF_MASK)); in io_waitid_complete() 159 atomic_or(IO_WAITID_CANCEL_FLAG, &iw->refs); in __io_waitid_cancel() 162 if (atomic_fetch_inc(&iw->refs) & IO_WAITID_REF_MASK) in __io_waitid_cancel() 197 if (!atomic_sub_return(1, &iw->refs)) in io_waitid_drop_issue_ref() 238 if (!(atomic_read(&iw->refs) & IO_WAITID_CANCEL_FLAG)) { in io_waitid_cb() 271 if (atomic_fetch_inc(&iw->refs) & IO_WAITID_REF_MASK) in io_waitid_wait() 318 atomic_set(&iw->refs, 1); in io_waitid()
|
| H A D | eventfd.c | 19 refcount_t refs; member 38 if (refcount_dec_and_test(&ev_fd->refs)) in io_eventfd_put() 97 if (!io_eventfd_trigger(ev_fd) || !refcount_inc_not_zero(&ev_fd->refs)) in io_eventfd_signal() 153 refcount_set(&ev_fd->refs, 1); in io_eventfd_register()
|
| H A D | bpf_filter.c | 18 refcount_t refs; member 126 if (!refcount_dec_and_test(&f->refs)) in io_free_bpf_filters() 141 if (refcount_dec_and_test(&filters->refs)) in __io_put_bpf_filters() 164 refcount_set(&filters->refs, 1); in io_new_bpf_filters() 255 if (refcount_inc_not_zero(&src->bpf_filters->refs)) { in io_bpf_filter_clone() 299 if (!refcount_inc_not_zero(&srcf->refs)) in io_bpf_filter_cow() 410 refcount_set(&filter->refs, 1); in io_register_bpf_filter()
|
| /linux/drivers/clk/qcom/ |
| H A D | clk-ref.c | 20 struct qcom_clk_ref refs[] __counted_by(num_refs); 166 if (!provider->refs[idx].regmap) in qcom_clk_ref_provider_get() 169 return &provider->refs[idx].hw; in qcom_clk_ref_provider_get() 191 provider = devm_kzalloc(dev, struct_size(provider, refs, num_clk_refs), in qcom_clk_ref_probe() 198 ret = qcom_clk_ref_register(dev, regmap, provider->refs, descs, in qcom_clk_ref_probe()
|
| /linux/include/net/ |
| H A D | inet_frag.h | 129 void inet_frag_kill(struct inet_frag_queue *q, int *refs); 136 static inline void inet_frag_putn(struct inet_frag_queue *q, int refs) in inet_frag_putn() argument 138 if (refs && refcount_sub_and_test(refs, &q->refcnt)) in inet_frag_putn()
|
| /linux/fs/btrfs/ |
| H A D | delayed-inode.c | 59 refcount_set(&delayed_node->refs, 0); in btrfs_init_delayed_node() 78 refcount_inc(&node->refs); in btrfs_get_delayed_node() 88 refcount_inc(&node->refs); /* can be accessed */ in btrfs_get_delayed_node() 111 if (refcount_inc_not_zero(&node->refs)) { in btrfs_get_delayed_node() 112 refcount_inc(&node->refs); in btrfs_get_delayed_node() 156 refcount_set(&node->refs, 2); in btrfs_get_or_create_delayed_node() 208 refcount_inc(&node->refs); /* inserted into list */ in btrfs_queue_delayed_node() 225 refcount_dec(&node->refs); /* not in the list */ in btrfs_dequeue_delayed_node() 244 refcount_inc(&node->refs); in btrfs_first_delayed_node() 273 refcount_inc(&next->refs); in btrfs_next_delayed_node() [all …]
|
| /linux/tools/testing/selftests/net/ |
| H A D | nl_netdev.py | 211 refs = sum([pp["inflight"] for pp in pp_list]) 212 ksft_eq(refs, 0) 223 refs = sum([pp["inflight"] for pp in pp_list if pp.get("ifindex") == nsim.ifindex]) 224 ksft_ge(refs, 1) 230 refs = sum([pp["inflight"] for pp in pp_list]) 231 ksft_eq(refs, 1)
|
| /linux/drivers/gpu/drm/nouveau/nvkm/engine/fifo/ |
| H A D | cgrp.c | 39 if (refcount_dec_and_test(&ectx->refs)) { in nvkm_cgrp_ectx_put() 65 refcount_inc(&ectx->refs); in nvkm_cgrp_ectx_get() 76 refcount_set(&ectx->refs, 1); in nvkm_cgrp_ectx_get() 100 if (refcount_dec_and_test(&vctx->refs)) { in nvkm_cgrp_vctx_put() 130 refcount_inc(&vctx->refs); in nvkm_cgrp_vctx_get() 151 refcount_set(&vctx->refs, 1); in nvkm_cgrp_vctx_get()
|
| /linux/drivers/thermal/ |
| H A D | k3_j72xx_bandgap.c | 80 int refs[4]; member 92 idx1 = err_vals->refs[seg]; in create_table_segments() 94 idx2 = err_vals->refs[seg + 1]; in create_table_segments() 97 ref1 = err_vals->refs[seg]; in create_table_segments() 98 ref2 = err_vals->refs[seg + 1]; in create_table_segments() 492 err_vals.refs[0] = MINUS40CREF; in k3_j72xx_bandgap_probe() 493 err_vals.refs[1] = PLUS30CREF; in k3_j72xx_bandgap_probe() 494 err_vals.refs[2] = PLUS125CREF; in k3_j72xx_bandgap_probe() 495 err_vals.refs[3] = PLUS150CREF; in k3_j72xx_bandgap_probe()
|
| /linux/lib/ |
| H A D | refcount.c | 59 return atomic_try_cmpxchg_release(&r->refs, &val, 0); in refcount_dec_if_one() 76 unsigned int new, val = atomic_read(&r->refs); in refcount_dec_not_one() 91 } while (!atomic_try_cmpxchg_release(&r->refs, &val, new)); in refcount_dec_not_one()
|
| /linux/sound/hda/codecs/side-codecs/ |
| H A D | cirrus_scodec_test.c | 194 struct software_node_ref_args *refs; in cirrus_scodec_test_spkid_parse() local 199 refs = kunit_kcalloc(test, num_spk_id_refs, sizeof(*refs), GFP_KERNEL); in cirrus_scodec_test_spkid_parse() 200 KUNIT_ASSERT_NOT_NULL(test, refs); in cirrus_scodec_test_spkid_parse() 203 cirrus_scodec_test_set_gpio_ref_arg(&refs[i++], v++); in cirrus_scodec_test_spkid_parse() 218 ret = cirrus_scodec_test_set_spkid_swnode(test, dev, refs, num_spk_id_refs); in cirrus_scodec_test_spkid_parse()
|
| /linux/include/uapi/xen/ |
| H A D | gntdev.h | 70 struct ioctl_gntdev_grant_ref refs[1]; member 256 __u32 refs[1]; member 298 __u32 refs[1]; member
|
| /linux/tools/testing/selftests/bpf/progs/ |
| H A D | map_kptr.c | 330 if (p_st->cnt.refs.counter != ref) { in test_map_kptr_ref_pre() 340 if (p_st->cnt.refs.counter != ref) in test_map_kptr_ref_pre() 348 if (p_st->cnt.refs.counter != ref) in test_map_kptr_ref_pre() 360 if (p_st->cnt.refs.counter != ref) in test_map_kptr_ref_pre() 377 if (!p_st || p_st->cnt.refs.counter != ref) in test_map_kptr_ref_post() 383 if (p_st->cnt.refs.counter != ref) { in test_map_kptr_ref_post() 393 if (p_st->cnt.refs.counter != ref) in test_map_kptr_ref_post() 493 if (p->cnt.refs.counter != ref) { in test_map_kptr_ref3() 513 num_of_refs = p->cnt.refs.counter; in read_ref_count()
|
| /linux/drivers/net/ethernet/mellanox/mlx4/ |
| H A D | port.c | 69 table->refs[i] = 0; in mlx4_init_mac_table() 83 table->refs[i] = 0; in mlx4_init_vlan_table() 118 if (table->refs[i] && in find_index() 212 dup_table->refs[index_at_port]) { in __mlx4_register_mac() 222 if (!table->refs[index_at_dup_port] || in __mlx4_register_mac() 231 if (!table->refs[i]) { in __mlx4_register_mac() 235 if (!dup_table->refs[i]) in __mlx4_register_mac() 245 ++table->refs[i]; in __mlx4_register_mac() 288 table->refs[free] = 1; in __mlx4_register_mac() 292 dup_table->refs[free] = 0; in __mlx4_register_mac() [all …]
|