Home
last modified time | relevance | path

Searched refs:id_map (Results 1 – 13 of 13) sorted by relevance

/linux/drivers/hwtracing/coresight/
H A Dcoresight-trace-id.c25 static void coresight_trace_id_dump_table(struct coresight_trace_id_map *id_map, in coresight_trace_id_dump_table() argument
29 pr_debug("Used = %*pb\n", CORESIGHT_TRACE_IDS_MAX, id_map->used_ids); in coresight_trace_id_dump_table()
43 static int _coresight_trace_id_read_cpu_id(int cpu, struct coresight_trace_id_map *id_map) in _coresight_trace_id_read_cpu_id() argument
45 return atomic_read(per_cpu_ptr(id_map->cpu_map, cpu)); in _coresight_trace_id_read_cpu_id()
49 static int coresight_trace_id_find_odd_id(struct coresight_trace_id_map *id_map) in coresight_trace_id_find_odd_id() argument
58 next_id = find_next_zero_bit(id_map->used_ids, in coresight_trace_id_find_odd_id()
76 static int coresight_trace_id_alloc_new_id(struct coresight_trace_id_map *id_map, in coresight_trace_id_alloc_new_id() argument
83 !test_bit(preferred_id, id_map->used_ids)) { in coresight_trace_id_alloc_new_id()
88 id = coresight_trace_id_find_odd_id(id_map); in coresight_trace_id_alloc_new_id()
97 id = find_next_zero_bit(id_map->used_ids, CORESIGHT_TRACE_ID_RES_TOP, 1); in coresight_trace_id_alloc_new_id()
[all …]
H A Dcoresight-trace-id.h65 int coresight_trace_id_get_cpu_id_map(int cpu, struct coresight_trace_id_map *id_map);
80 void coresight_trace_id_put_cpu_id_map(int cpu, struct coresight_trace_id_map *id_map);
106 int coresight_trace_id_read_cpu_id_map(int cpu, struct coresight_trace_id_map *id_map);
140 void coresight_trace_id_perf_start(struct coresight_trace_id_map *id_map);
148 void coresight_trace_id_perf_stop(struct coresight_trace_id_map *id_map);
H A Dcoresight-etm3x-core.c485 struct coresight_trace_id_map *id_map) in etm_enable_perf() argument
504 trace_id = coresight_trace_id_read_cpu_id_map(drvdata->cpu, id_map); in etm_enable_perf()
557 enum cs_mode mode, struct coresight_trace_id_map *id_map) in etm_enable() argument
572 ret = etm_enable_perf(csdev, event, id_map); in etm_enable()
H A Dcoresight-dummy.c25 __maybe_unused struct coresight_trace_id_map *id_map) in dummy_source_enable() argument
H A Dcoresight-etm4x-core.c756 struct coresight_trace_id_map *id_map) in etm4_enable_perf() argument
779 trace_id = coresight_trace_id_read_cpu_id_map(drvdata->cpu, id_map); in etm4_enable_perf()
841 enum cs_mode mode, struct coresight_trace_id_map *id_map) in etm4_enable() argument
855 ret = etm4_enable_perf(csdev, event, id_map); in etm4_enable()
H A Dcoresight-tpdm.c443 __maybe_unused struct coresight_trace_id_map *id_map) in tpdm_enable() argument
/linux/tools/lib/bpf/
H A Dbtf_relocate.c47 __u32 *id_map; member
78 *id = r->id_map[*id]; in btf_relocate_rewrite_type_id()
168 r->id_map[next_id] = BTF_IS_EMBEDDED; in btf_mark_embedded_composite_type_ids()
335 if (r->id_map[dist_info->id] == BTF_IS_EMBEDDED && in btf_relocate_map_distilled_base()
342 if (r->id_map[dist_info->id] && in btf_relocate_map_distilled_base()
343 r->id_map[dist_info->id] != BTF_IS_EMBEDDED) { in btf_relocate_map_distilled_base()
354 base_t->size, id, r->id_map[dist_info->id]); in btf_relocate_map_distilled_base()
359 r->id_map[dist_info->id] = id; in btf_relocate_map_distilled_base()
367 if (r->id_map[id] && r->id_map[id] != BTF_IS_EMBEDDED) in btf_relocate_map_distilled_base()
444 int btf_relocate(struct btf *btf, const struct btf *base_btf, __u32 **id_map) in btf_relocate() argument
[all …]
H A Dbtf.c5343 int *id_map; member
5368 if (dist->id_map[*id] > 0) in btf_add_distilled_type_ids()
5391 dist->id_map[*id] = *id; in btf_add_distilled_type_ids()
5429 if (!dist->id_map[i]) in btf_add_distilled_types()
5499 dist->id_map[i] = id++; in btf_add_distilled_types()
5520 if (dist->id_map[*id]) in btf_update_distilled_type_ids()
5521 *id = dist->id_map[*id]; in btf_update_distilled_type_ids()
5565 dist.id_map = calloc(n, sizeof(*dist.id_map)); in btf__distill_base()
5566 if (!dist.id_map) { in btf__distill_base()
5632 free(dist.id_map); in btf__distill_base()
/linux/drivers/greybus/
H A Dhd.c50 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_reserve() local
53 ret = ida_alloc_range(id_map, cport_id, cport_id, GFP_KERNEL); in gb_hd_cport_reserve()
65 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_release_reserved() local
67 ida_free(id_map, cport_id); in gb_hd_cport_release_reserved()
75 struct ida *id_map = &hd->cport_id_map; in gb_hd_cport_allocate() local
92 return ida_alloc_range(id_map, ida_start, ida_end, GFP_KERNEL); in gb_hd_cport_allocate()
H A Des2.c492 struct ida *id_map = &hd->cport_id_map; in es2_cport_allocate() local
525 return ida_alloc_range(id_map, ida_start, ida_end, GFP_KERNEL); in es2_cport_allocate()
/linux/tools/testing/selftests/filesystems/binderfs/
H A Dbinderfs_test.c328 char id_map[4096]; in change_idmaps()
337 snprintf(id_map, sizeof(id_map), "0 %d 1\n", getuid()); in change_idmaps()
338 ret = write_id_mapping(UID_MAP, pid, id_map, strlen(id_map)); in change_idmaps()
343 snprintf(id_map, sizeof(id_map), "0 %d 1\n", getgid()); in change_idmaps()
344 ret = write_id_mapping(GID_MAP, pid, id_map, strlen(id_map)); in change_idmaps()
329 char id_map[4096]; change_idmaps() local
/linux/drivers/staging/greybus/
H A Dfw-download.c40 struct ida id_map; member
66 ida_free(&fw_req->fw_download->id_map, fw_req->firmware_id); in fw_req_release()
173 ret = ida_alloc_range(&fw_download->id_map, 1, 255, GFP_KERNEL); in find_firmware()
214 ida_free(&fw_download->id_map, fw_req->firmware_id); in find_firmware()
418 ida_init(&fw_download->id_map); in gb_fw_download_connection_init()
430 ida_destroy(&fw_download->id_map); in gb_fw_download_connection_init()
463 ida_destroy(&fw_download->id_map); in gb_fw_download_connection_exit()
/linux/include/linux/
H A Dcoresight.h387 enum cs_mode mode, struct coresight_trace_id_map *id_map);