Home
last modified time | relevance | path

Searched refs:cpus (Results 1 – 25 of 834) sorted by relevance

12345678910>>...34

/linux/tools/lib/perf/
H A Dcpumap.c25 RC_STRUCT(perf_cpu_map) *cpus; in perf_cpu_map__alloc()
31 cpus = malloc(sizeof(*cpus) + sizeof(struct perf_cpu) * nr_cpus); in perf_cpu_map__alloc()
32 if (ADD_RC_CHK(result, cpus)) { in perf_cpu_map__alloc()
33 cpus->nr = nr_cpus; in perf_cpu_map__alloc()
34 refcount_set(&cpus->refcnt, 1); in perf_cpu_map__alloc()
41 struct perf_cpu_map *cpus = perf_cpu_map__alloc(1); in perf_cpu_map__new_any_cpu() local
43 if (cpus) in perf_cpu_map__new_any_cpu()
44 RC_CHK_ACCESS(cpus)->map[0].cpu = -1; in perf_cpu_map__new_any_cpu()
46 return cpus; in perf_cpu_map__new_any_cpu()
80 struct perf_cpu_map *cpus; cpu_map__new_sysconf() local
106 struct perf_cpu_map *cpus = NULL; cpu_map__new_sysfs_online() local
119 struct perf_cpu_map *cpus = cpu_map__new_sysfs_online(); perf_cpu_map__new_online_cpus() local
135 __perf_cpu_map__cpu(const struct perf_cpu_map * cpus,int idx) __perf_cpu_map__cpu() argument
143 struct perf_cpu_map *cpus = perf_cpu_map__alloc(nr_cpus); cpu_map__trim_new() local
167 struct perf_cpu_map *cpus = NULL; perf_cpu_map__new() local
247 struct perf_cpu_map *cpus = perf_cpu_map__alloc(1); perf_cpu_map__new_int() local
255 __perf_cpu_map__nr(const struct perf_cpu_map * cpus) __perf_cpu_map__nr() argument
260 perf_cpu_map__cpu(const struct perf_cpu_map * cpus,int idx) perf_cpu_map__cpu() argument
272 perf_cpu_map__nr(const struct perf_cpu_map * cpus) perf_cpu_map__nr() argument
295 perf_cpu_map__idx(const struct perf_cpu_map * cpus,struct perf_cpu cpu) perf_cpu_map__idx() argument
320 perf_cpu_map__has(const struct perf_cpu_map * cpus,struct perf_cpu cpu) perf_cpu_map__has() argument
[all...]
H A Devlist.c39 if (perf_cpu_map__is_empty(evsel->cpus)) { in __perf_evlist__propagate_maps()
52 evsel->cpus = perf_cpu_map__get(evlist->user_requested_cpus); in __perf_evlist__propagate_maps()
58 evsel->cpus = perf_cpu_map__get(evsel->pmu_cpus); in __perf_evlist__propagate_maps()
65 if (evsel->requires_cpu && perf_cpu_map__has_any_cpu(evsel->cpus)) { in __perf_evlist__propagate_maps()
66 perf_cpu_map__put(evsel->cpus); in __perf_evlist__propagate_maps()
67 evsel->cpus = perf_cpu_map__get(evsel->pmu_cpus); in __perf_evlist__propagate_maps()
76 if (!perf_cpu_map__equal(evsel->cpus, evlist->user_requested_cpus)) { in __perf_evlist__propagate_maps()
77 perf_cpu_map__put(evsel->cpus); in __perf_evlist__propagate_maps()
78 evsel->cpus = perf_cpu_map__get(evlist->user_requested_cpus); in __perf_evlist__propagate_maps()
83 if (!perf_cpu_map__has_any_cpu(evsel->cpus) && in __perf_evlist__propagate_maps()
[all …]
/linux/tools/testing/selftests/riscv/hwprobe/
H A Dwhich-cpus.c22 "which-cpus: [-h] [<key=value> [<key=value> ...]]\n\n" in help()
25 " <key=value>, outputs the cpulist for cpus which all match the given set\n" in help()
29 static void print_cpulist(cpu_set_t *cpus) in print_cpulist() argument
33 if (!CPU_COUNT(cpus)) { in print_cpulist()
34 printf("cpus: None\n"); in print_cpulist()
38 printf("cpus:"); in print_cpulist()
39 for (int i = 0, c = 0; i < CPU_COUNT(cpus); i++, c++) { in print_cpulist()
40 if (start != end && !CPU_ISSET(c, cpus)) in print_cpulist()
43 while (!CPU_ISSET(c, cpus)) in print_cpulist()
59 static void do_which_cpus(int argc, char **argv, cpu_set_t *cpus) in do_which_cpus() argument
87 cpu_set_t cpus_aff, cpus; main() local
[all...]
H A Dcbo.c119 cpu_set_t *cpus = (cpu_set_t *)arg; in test_zicbop() local
128 rc = riscv_hwprobe(&pair, 1, sizeof(cpu_set_t), (unsigned long *)cpus, 0); in test_zicbop()
157 cpu_set_t *cpus = (cpu_set_t *)arg; in test_zicbom() local
161 rc = riscv_hwprobe(&pair, 1, sizeof(cpu_set_t), (unsigned long *)cpus, 0); in test_zicbom()
181 cpu_set_t *cpus = (cpu_set_t *)arg; in test_zicboz() local
186 rc = riscv_hwprobe(&pair, 1, sizeof(cpu_set_t), (unsigned long *)cpus, 0); in test_zicboz()
224 static void check_no_zicbo_cpus(cpu_set_t *cpus, __u64 cbo) in check_no_zicbo_cpus() argument
234 while (i++ < CPU_COUNT(cpus)) { in check_no_zicbo_cpus()
235 while (!CPU_ISSET(c, cpus)) in check_no_zicbo_cpus()
303 cpu_set_t cpus; in main() local
[all …]
H A Dhwprobe.c8 unsigned long cpus; in main() local
15 cpus = -1; in main()
24 out = riscv_hwprobe(pairs, 8, 1, &cpus, 0); in main()
46 out = riscv_hwprobe(pairs, 8, 0, &cpus, 0); in main()
53 out = riscv_hwprobe(pairs, 1, 1, &cpus, 0); in main()
/linux/tools/lib/perf/tests/
H A Dtest-cpumap.c16 struct perf_cpu_map *cpus; in test_cpumap() local
24 cpus = perf_cpu_map__new_any_cpu(); in test_cpumap()
25 if (!cpus) in test_cpumap()
28 perf_cpu_map__get(cpus); in test_cpumap()
29 perf_cpu_map__put(cpus); in test_cpumap()
30 perf_cpu_map__put(cpus); in test_cpumap()
32 cpus = perf_cpu_map__new_online_cpus(); in test_cpumap()
33 if (!cpus) in test_cpumap()
36 perf_cpu_map__for_each_cpu(cpu, idx, cpus) in test_cpumap()
39 perf_cpu_map__put(cpus); in test_cpumap()
H A Dtest-evlist.c36 struct perf_cpu_map *cpus; in test_stat_cpu() local
49 cpus = perf_cpu_map__new_online_cpus(); in test_stat_cpu()
50 __T("failed to create cpus", cpus); in test_stat_cpu()
69 perf_evlist__set_maps(evlist, cpus, NULL); in test_stat_cpu()
75 cpus = perf_evsel__cpus(evsel); in test_stat_cpu()
77 for (idx = 0; idx < perf_cpu_map__nr(cpus); idx++) { in test_stat_cpu()
88 perf_cpu_map__put(cpus); in test_stat_cpu()
218 struct perf_cpu_map *cpus; in test_mmap_thread() local
264 cpus = perf_cpu_map__new_any_cpu(); in test_mmap_thread()
265 __T("failed to create cpus", cpus); in test_mmap_thread()
[all …]
/linux/arch/riscv/kernel/
H A Dsys_hwprobe.c36 const struct cpumask *cpus) in hwprobe_arch_id() argument
47 for_each_cpu(cpu, cpus) { in hwprobe_arch_id()
82 const struct cpumask *cpus) in hwprobe_isa_ext0() argument
101 for_each_cpu(cpu, cpus) { in hwprobe_isa_ext0()
187 const struct cpumask *cpus) in hwprobe_isa_ext1() argument
198 for_each_cpu(cpu, cpus) { in hwprobe_isa_ext1()
214 static bool hwprobe_ext0_has(const struct cpumask *cpus, u64 ext) in hwprobe_ext0_has() argument
218 hwprobe_isa_ext0(&pair, cpus); in hwprobe_ext0_has()
223 static u64 hwprobe_misaligned(const struct cpumask *cpus) in hwprobe_misaligned() argument
228 for_each_cpu(cpu, cpus) { in hwprobe_misaligned()
[all …]
/linux/sound/soc/intel/boards/
H A Dsof_board_helpers.c184 struct snd_soc_dai_link_component *cpus; in set_ssp_codec_link()
194 /* cpus */ in set_ssp_codec_link()
195 cpus = devm_kzalloc(dev, sizeof(struct snd_soc_dai_link_component), in set_ssp_codec_link()
197 if (!cpus) in set_ssp_codec_link()
202 cpus->dai_name = devm_kasprintf(dev, GFP_KERNEL, "ssp%d-port", in set_ssp_codec_link()
205 cpus->dai_name = devm_kasprintf(dev, GFP_KERNEL, "SSP%d Pin", in set_ssp_codec_link()
208 if (!cpus->dai_name) in set_ssp_codec_link()
211 link->cpus = cpus; in set_ssp_codec_link()
229 struct snd_soc_dai_link_component *cpus; in set_dmic_link()
182 struct snd_soc_dai_link_component *cpus; set_ssp_codec_link() local
227 struct snd_soc_dai_link_component *cpus; set_dmic_link() local
277 struct snd_soc_dai_link_component *cpus, *codecs; set_idisp_hdmi_link() local
336 struct snd_soc_dai_link_component *cpus; set_ssp_amp_link() local
375 struct snd_soc_dai_link_component *cpus; set_bt_offload_link() local
414 struct snd_soc_dai_link_component *cpus; set_hdmi_in_link() local
[all...]
H A Dsof_pcm512x.c226 struct snd_soc_dai_link_component *cpus; in sof_card_dai_links_create()
232 cpus = devm_kcalloc(dev, sof_audio_card_pcm512x.num_links, in sof_card_dai_links_create()
234 if (!links || !cpus) in sof_card_dai_links_create()
256 links[id].cpus = &cpus[id]; in sof_card_dai_links_create()
259 links[id].cpus->dai_name = devm_kasprintf(dev, GFP_KERNEL, in sof_card_dai_links_create()
262 if (!links[id].cpus->dai_name) in sof_card_dai_links_create()
265 links[id].cpus->dai_name = devm_kasprintf(dev, GFP_KERNEL, in sof_card_dai_links_create()
268 if (!links[id].cpus->dai_name) in sof_card_dai_links_create()
277 links[id].cpus in sof_card_dai_links_create()
225 struct snd_soc_dai_link_component *cpus; sof_card_dai_links_create() local
[all...]
/linux/tools/lib/perf/include/perf/
H A Dcpumap.h58 LIBPERF_API struct perf_cpu perf_cpu_map__cpu(const struct perf_cpu_map *cpus, unsigned int idx);
66 LIBPERF_API unsigned int perf_cpu_map__nr(const struct perf_cpu_map *cpus);
96 #define perf_cpu_map__for_each_cpu(cpu, idx, cpus) \
97 for ((idx) = 0, (cpu) = perf_cpu_map__cpu(cpus, idx); \
98 (idx) < perf_cpu_map__nr(cpus); \
99 (idx)++, (cpu) = perf_cpu_map__cpu(cpus, idx))
101 #define perf_cpu_map__for_each_cpu_skip_any(_cpu, idx, cpus) \ argument
102 for ((idx) = 0, (_cpu) = perf_cpu_map__cpu(cpus, idx); \
103 (idx) < perf_cpu_map__nr(cpus); \
104 (idx)++, (_cpu) = perf_cpu_map__cpu(cpus, id
90 perf_cpu_map__for_each_cpu(cpu,idx,cpus) global() argument
95 perf_cpu_map__for_each_cpu_skip_any(_cpu,idx,cpus) global() argument
[all...]
/linux/tools/testing/selftests/cgroup/
H A Dtest_cpuset_prs.sh25 SUBPARTS_CPUS=$CGROUP2/.__DEBUG__.cpuset.cpus.subpartitions
26 CPULIST=$(cat $CGROUP2/cpuset.cpus.effective)
29 [[ $NR_CPUS -lt 8 ]] && skip_test "Test needs at least 8 cpus available!"
79 echo 0-6 > test/cpuset.cpus
80 echo root > test/cpuset.cpus.partition
81 cat test/cpuset.cpus.partition | grep -q invalid
83 echo member > test/cpuset.cpus.partition
84 echo "" > test/cpuset.cpus
89 # cpuset.cpus.isolated), these isolated CPUs should be outside of CPUs 0-8
98 BOOT_ISOLCPUS=$(cat $CGROUP2/cpuset.cpus
[all...]
/linux/arch/riscv/kernel/vdso/
H A Dhwprobe.c12 size_t cpusetsize, unsigned long *cpus,
16 size_t cpusetsize, unsigned long *cpus, in riscv_vdso_get_values() argument
20 bool all_cpus = !cpusetsize && !cpus; in riscv_vdso_get_values()
31 return riscv_hwprobe(pairs, pair_count, cpusetsize, cpus, flags); in riscv_vdso_get_values()
50 size_t cpusetsize, unsigned long *cpus, in riscv_vdso_get_cpus() argument
56 unsigned char *c = (unsigned char *)cpus; in riscv_vdso_get_cpus()
61 if (!cpusetsize || !cpus) in riscv_vdso_get_cpus()
72 return riscv_hwprobe(pairs, pair_count, cpusetsize, cpus, flags); in riscv_vdso_get_cpus()
101 size_t cpusetsize, unsigned long *cpus,
105 size_t cpusetsize, unsigned long *cpus, in __vdso_riscv_hwprobe() argument
[all …]
/linux/drivers/clk/sunxi/
H A Dclk-sun9i-cpus.c52 struct sun9i_a80_cpus_clk *cpus = to_sun9i_a80_cpus_clk(hw); in sun9i_a80_cpus_clk_recalc_rate() local
57 reg = readl(cpus->reg); in sun9i_a80_cpus_clk_recalc_rate()
152 struct sun9i_a80_cpus_clk *cpus = to_sun9i_a80_cpus_clk(hw); in sun9i_a80_cpus_clk_set_rate() local
159 reg = readl(cpus->reg); in sun9i_a80_cpus_clk_set_rate()
167 writel(reg, cpus->reg); in sun9i_a80_cpus_clk_set_rate()
189 struct sun9i_a80_cpus_clk *cpus; in sun9i_a80_cpus_setup() local
194 cpus = kzalloc_obj(*cpus); in sun9i_a80_cpus_setup()
195 if (!cpus) in sun9i_a80_cpus_setup()
198 cpus->reg = of_io_request_and_map(node, 0, of_node_full_name(node)); in sun9i_a80_cpus_setup()
199 if (IS_ERR(cpus->reg)) in sun9i_a80_cpus_setup()
[all …]
/linux/tools/perf/tests/
H A Dopenat-syscall-all-cpus.c28 struct perf_cpu_map *cpus; in test__openat_syscall_event_on_all_cpus()
41 cpus = perf_cpu_map__new_online_cpus(); in test__openat_syscall_event_on_all_cpus()
42 if (cpus == NULL) { in test__openat_syscall_event_on_all_cpus()
57 if (evsel__open(evsel, cpus, threads) < 0) { in test__openat_syscall_event_on_all_cpus()
65 perf_cpu_map__for_each_cpu(cpu, idx, cpus) { in test__openat_syscall_event_on_all_cpus()
70 * without CPU_ALLOC. 1024 cpus in 2010 still seems in test__openat_syscall_event_on_all_cpus()
92 evsel->core.cpus = perf_cpu_map__get(cpus); in test__openat_syscall_event_on_all_cpus()
96 perf_cpu_map__for_each_cpu(cpu, idx, cpus) { in test__openat_syscall_event_on_all_cpus()
122 perf_cpu_map__put(cpus); in test__openat_syscall_event_on_all_cpus()
27 struct perf_cpu_map *cpus; test__openat_syscall_event_on_all_cpus() local
[all...]
H A Devent-times.c113 struct perf_cpu_map *cpus; in attach__cpu_disabled() local
118 cpus = perf_cpu_map__new("0"); in attach__cpu_disabled()
119 if (cpus == NULL) { in attach__cpu_disabled()
126 err = evsel__open_per_cpu(evsel, cpus, -1); in attach__cpu_disabled()
127 perf_cpu_map__put(cpus); in attach__cpu_disabled()
142 struct perf_cpu_map *cpus; in attach__cpu_enabled() local
147 cpus = perf_cpu_map__new("0"); in attach__cpu_enabled()
148 if (cpus == NULL) { in attach__cpu_enabled()
153 err = evsel__open_per_cpu(evsel, cpus, -1); in attach__cpu_enabled()
154 perf_cpu_map__put(cpus); in attach__cpu_enabled()
H A Dmmap-basic.c44 struct perf_cpu_map *cpus; in test__basic_mmap()
62 cpus = perf_cpu_map__new_online_cpus(); in test__basic_mmap()
63 if (cpus == NULL) { in test__basic_mmap()
69 CPU_SET(perf_cpu_map__cpu(cpus, 0).cpu, &cpu_set); in test__basic_mmap()
73 perf_cpu_map__cpu(cpus, 0).cpu, in test__basic_mmap()
84 perf_evlist__set_maps(&evlist->core, cpus, threads); in test__basic_mmap()
105 if (evsel__open(evsels[i], cpus, threads) < 0) { in test__basic_mmap()
178 perf_cpu_map__put(cpus);
267 if (pmu->cpus != NULL) in test_stat_user_read()
268 cpu_map__set_affinity(pmu->cpus); in test_stat_user_read()
40 struct perf_cpu_map *cpus; test__basic_mmap() local
364 struct perf_cpu_map *cpus = cpu_map__online(); test_stat_user_read() local
[all...]
/linux/drivers/cpufreq/
H A Dcpufreq-dt.c30 cpumask_var_t cpus; member
44 if (cpumask_test_cpu(cpu, priv->cpus)) in cpufreq_dt_find_data()
109 cpumask_copy(policy->cpus, priv->cpus); in cpufreq_init()
176 if (!zalloc_cpumask_var(&priv->cpus, GFP_KERNEL)) in dt_cpufreq_early_init()
179 cpumask_set_cpu(cpu, priv->cpus); in dt_cpufreq_early_init()
197 ret = dev_pm_opp_of_get_sharing_cpus(cpu_dev, priv->cpus); in dt_cpufreq_early_init()
207 if (dev_pm_opp_get_sharing_cpus(cpu_dev, priv->cpus)) in dt_cpufreq_early_init()
222 ret = dev_pm_opp_of_cpumask_add_table(priv->cpus); in dt_cpufreq_early_init()
241 cpumask_setall(priv->cpus); in dt_cpufreq_early_init()
242 ret = dev_pm_opp_set_sharing_cpus(cpu_dev, priv->cpus); in dt_cpufreq_early_init()
[all …]
/linux/tools/perf/util/
H A Dperf_api_probe.c63 struct perf_cpu_map *cpus; in perf_probe_api() local
67 cpus = perf_cpu_map__new_online_cpus(); in perf_probe_api()
68 if (!cpus) in perf_probe_api()
70 cpu = perf_cpu_map__cpu(cpus, 0); in perf_probe_api()
71 perf_cpu_map__put(cpus); in perf_probe_api()
150 struct perf_cpu_map *cpus; in perf_can_record_cpu_wide() local
154 cpus = perf_cpu_map__new_online_cpus(); in perf_can_record_cpu_wide()
155 if (!cpus) in perf_can_record_cpu_wide()
158 cpu = perf_cpu_map__cpu(cpus, 0); in perf_can_record_cpu_wide()
159 perf_cpu_map__put(cpus); in perf_can_record_cpu_wide()
/linux/Documentation/devicetree/bindings/csky/
H A Dcpus.txt6 the "cpus" node, which in turn contains a number of subnodes (ie "cpu")
9 Only SMP system need to care about the cpus node and single processor
10 needn't define cpus node at all.
13 cpus and cpu node bindings definition
16 - cpus node
20 The node name must be "cpus".
22 A cpus node must define the following properties:
59 cpus {
/linux/tools/testing/selftests/rcutorture/bin/
H A Djitter.sh74 if cpus=`grep 1 /sys/devices/system/cpu/*/online 2>&1 |
79 cpus=
82 cpus="$cpus $nohotplugcpus"
84 cpumask=`awk -v cpus="$cpus" -v me=$me -v n=$n 'BEGIN {
86 ncpus = split(cpus, ca);
/linux/scripts/gdb/linux/
H A Dinterrupts.py8 from linux import cpus
39 for cpu in cpus.each_online_cpu():
40 any_count += cpus.per_cpu(desc['kstat_irqs'], cpu)['cnt']
46 for cpu in cpus.each_online_cpu():
48 count = cpus.per_cpu(desc['kstat_irqs'], cpu)['cnt']
103 for cpu in cpus.each_online_cpu():
104 stat = cpus.per_cpu(irq_stat, cpu)
139 for cpu in cpus.each_online_cpu():
140 text += "%10u " % (cpus.per_cpu(desc['kstat_irqs'], cpu)['cnt'])
188 for cpu in cpus
[all...]
/linux/tools/perf/python/
H A Dtwatch.py12 cpus = perf.cpu_map()
28 evsel.open(cpus = cpus, threads = threads);
29 evlist = perf.evlist(cpus, threads)
34 for cpu in cpus:
/linux/tools/tracing/rtla/src/
H A Dtimerlat_bpf.c129 get_value(struct bpf_map * map_irq,struct bpf_map * map_thread,struct bpf_map * map_user,int key,long long * value_irq,long long * value_thread,long long * value_user,int cpus) get_value() argument
158 timerlat_bpf_get_hist_value(int key,long long * value_irq,long long * value_thread,long long * value_user,int cpus) timerlat_bpf_get_hist_value() argument
173 timerlat_bpf_get_summary_value(enum summary_field key,long long * value_irq,long long * value_thread,long long * value_user,int cpus) timerlat_bpf_get_summary_value() argument
/linux/samples/trace_events/
H A Dtrace-events-sample.h304 __bitmask( cpus, num_possible_cpus() )
318 __assign_bitmask(cpus, cpumask_bits(mask), num_possible_cpus());
373 __get_bitmask(cpus), __get_cpumask(cpum),
375 __get_dynamic_array_len(cpus),
376 __get_dynamic_array_len(cpus),
377 __get_dynamic_array(cpus))
574 TP_PROTO(const char *foo, int bar, unsigned long *mask, const cpumask_t *cpus),
576 TP_ARGS(foo, bar, mask, cpus),
591 __assign_rel_cpumask(cpumask, cpus);

12345678910>>...34