Home
last modified time | relevance | path

Searched refs:nr (Results 1 – 25 of 222) sorted by relevance

123456789

/tools/include/asm-generic/bitops/
A Dnon-atomic.h17 ___set_bit(unsigned long nr, volatile unsigned long *addr) in ___set_bit() argument
19 unsigned long mask = BIT_MASK(nr); in ___set_bit()
20 unsigned long *p = ((unsigned long *)addr) + BIT_WORD(nr); in ___set_bit()
26 ___clear_bit(unsigned long nr, volatile unsigned long *addr) in ___clear_bit() argument
28 unsigned long mask = BIT_MASK(nr); in ___clear_bit()
29 unsigned long *p = ((unsigned long *)addr) + BIT_WORD(nr); in ___clear_bit()
46 unsigned long mask = BIT_MASK(nr); in ___change_bit()
64 unsigned long mask = BIT_MASK(nr); in ___test_and_set_bit()
84 unsigned long mask = BIT_MASK(nr); in ___test_and_clear_bit()
96 unsigned long mask = BIT_MASK(nr); in ___test_and_change_bit()
[all …]
/tools/perf/trace/beauty/
A Dioctl.c41 if (nr < strarray__ioctl_tty_cmd.nr_entries && strarray__ioctl_tty_cmd.entries[nr] != NULL) in ioctl__scnprintf_tty_cmd()
52 if (nr < strarray__drm_ioctl_cmds.nr_entries && strarray__drm_ioctl_cmds.entries[nr] != NULL) in ioctl__scnprintf_drm_cmd()
63 …if (nr < strarray__sndrv_pcm_ioctl_cmds.nr_entries && strarray__sndrv_pcm_ioctl_cmds.entries[nr] !… in ioctl__scnprintf_sndrv_pcm_cmd()
74 …if (nr < strarray__sndrv_ctl_ioctl_cmds.nr_entries && strarray__sndrv_ctl_ioctl_cmds.entries[nr] !… in ioctl__scnprintf_sndrv_ctl_cmd()
85 if (nr < strarray__kvm_ioctl_cmds.nr_entries && strarray__kvm_ioctl_cmds.entries[nr] != NULL) in ioctl__scnprintf_kvm_cmd()
98 if (nr < s->nr_entries && s->entries[nr] != NULL) in ioctl__scnprintf_vhost_virtio_cmd()
99 return scnprintf(bf, size, "VHOST_%s", s->entries[nr]); in ioctl__scnprintf_vhost_virtio_cmd()
109 if (nr < strarray__perf_ioctl_cmds.nr_entries && strarray__perf_ioctl_cmds.entries[nr] != NULL) in ioctl__scnprintf_perf_cmd()
120 …if (nr < strarray__usbdevfs_ioctl_cmds.nr_entries && strarray__usbdevfs_ioctl_cmds.entries[nr] != … in ioctl__scnprintf_usbdevfs_cmd()
131 nr = _IOC_NR(cmd), in ioctl__scnprintf_cmd() local
[all …]
/tools/testing/selftests/bpf/progs/
A Dverifier_bits_iter.c70 nr++; in null_pointer()
84 nr++; in bits_copy()
99 nr++; in bits_memalloc()
131 nr++; in bits_too_big()
145 nr++; in fewer_words()
159 nr++; in zero_words()
173 nr++; in huge_words()
193 nr++; in max_words()
214 nr = 0; in bad_words()
216 nr++; in bad_words()
[all …]
/tools/include/linux/
A Dbits.h10 #define BIT_MASK(nr) (UL(1) << ((nr) % BITS_PER_LONG)) argument
11 #define BIT_WORD(nr) ((nr) / BITS_PER_LONG) argument
12 #define BIT_ULL_MASK(nr) (ULL(1) << ((nr) % BITS_PER_LONG_LONG)) argument
13 #define BIT_ULL_WORD(nr) ((nr) / BITS_PER_LONG_LONG) argument
66 #define BIT_INPUT_CHECK(type, nr) \ argument
67 BUILD_BUG_ON_ZERO(const_true((nr) >= BITS_PER_TYPE(type)))
69 #define BIT_TYPE(type, nr) ((type)(BIT_INPUT_CHECK(type, nr) + BIT_ULL(nr))) argument
71 #define BIT_U8(nr) BIT_TYPE(u8, nr) argument
72 #define BIT_U16(nr) BIT_TYPE(u16, nr) argument
73 #define BIT_U32(nr) BIT_TYPE(u32, nr) argument
[all …]
A Dbitops.h18 #define BITS_TO_LONGS(nr) DIV_ROUND_UP(nr, BITS_PER_TYPE(long)) argument
19 #define BITS_TO_U64(nr) DIV_ROUND_UP(nr, BITS_PER_TYPE(u64)) argument
20 #define BITS_TO_U32(nr) DIV_ROUND_UP(nr, BITS_PER_TYPE(u32)) argument
21 #define BITS_TO_BYTES(nr) DIV_ROUND_UP(nr, BITS_PER_TYPE(char)) argument
36 op(nr, addr)
38 #define __set_bit(nr, addr) bitop(___set_bit, nr, addr) argument
39 #define __clear_bit(nr, addr) bitop(___clear_bit, nr, addr) argument
40 #define __change_bit(nr, addr) bitop(___change_bit, nr, addr) argument
41 #define __test_and_set_bit(nr, addr) bitop(___test_and_set_bit, nr, addr) argument
42 #define __test_and_clear_bit(nr, addr) bitop(___test_and_clear_bit, nr, addr) argument
[all …]
/tools/lib/api/fd/
A Darray.c17 fda->nr = fda->nr_alloc = 0; in fdarray__init()
24 int nr_alloc = fda->nr_alloc + nr; in fdarray__grow()
78 int pos = fda->nr; in fdarray__add()
80 if (fda->nr == fda->nr_alloc && in fdarray__add()
86 fda->priv[fda->nr].flags = flags; in fdarray__add()
87 fda->nr++; in fdarray__add()
96 if (pos >= from->nr) in fdarray__dup_entry_from()
112 int fd, nr = 0; in fdarray__filter() local
114 if (fda->nr == 0) in fdarray__filter()
130 ++nr; in fdarray__filter()
[all …]
/tools/include/uapi/linux/
A Dseccomp.h63 int nr; member
141 #define SECCOMP_IO(nr) _IO(SECCOMP_IOC_MAGIC, nr) argument
142 #define SECCOMP_IOR(nr, type) _IOR(SECCOMP_IOC_MAGIC, nr, type) argument
143 #define SECCOMP_IOW(nr, type) _IOW(SECCOMP_IOC_MAGIC, nr, type) argument
144 #define SECCOMP_IOWR(nr, type) _IOWR(SECCOMP_IOC_MAGIC, nr, type) argument
/tools/lib/perf/
A Dthreadmap.c10 static void perf_thread_map__reset(struct perf_thread_map *map, int start, int nr) in perf_thread_map__reset() argument
12 size_t size = (nr - start) * sizeof(map->map[0]); in perf_thread_map__reset()
18 struct perf_thread_map *perf_thread_map__realloc(struct perf_thread_map *map, int nr) in perf_thread_map__realloc() argument
20 size_t size = sizeof(*map) + sizeof(map->map[0]) * nr; in perf_thread_map__realloc()
21 int start = map ? map->nr : 0; in perf_thread_map__realloc()
28 perf_thread_map__reset(map, start, nr); in perf_thread_map__realloc()
56 threads->nr = nr_threads; in perf_thread_map__new_array()
74 for (i = 0; i < threads->nr; i++) in perf_thread_map__delete()
95 return threads ? threads->nr : 1; in perf_thread_map__nr()
113 for (int i = 0; i < threads->nr; ++i) { in perf_thread_map__idx()
/tools/include/vdso/
A Dbits.h7 #define BIT(nr) (UL(1) << (nr)) argument
8 #define BIT_ULL(nr) (ULL(1) << (nr)) argument
/tools/include/asm-generic/
A Datomic-gcc.h73 static inline int test_and_set_bit(long nr, unsigned long *addr) in test_and_set_bit() argument
75 unsigned long mask = BIT_MASK(nr); in test_and_set_bit()
78 addr += BIT_WORD(nr); in test_and_set_bit()
84 static inline int test_and_clear_bit(long nr, unsigned long *addr) in test_and_clear_bit() argument
86 unsigned long mask = BIT_MASK(nr); in test_and_clear_bit()
89 addr += BIT_WORD(nr); in test_and_clear_bit()
/tools/perf/util/
A Dthread_map.c51 threads->nr = items; in thread_map__new_by_pid()
68 threads->nr = 1; in thread_map__new_by_tid()
90 threads->nr = 0; in thread_map__new_all_cpus()
131 threads->nr += items; in thread_map__new_all_cpus()
201 threads->nr = total_tasks; in thread_map__new_by_pid_str()
257 threads->nr = ntasks; in thread_map__new_by_tid_str()
285 threads->nr, threads->nr > 1 ? "s" : ""); in thread_map__fprintf()
350 threads->nr = (int) event->nr; in thread_map__copy_event()
387 if (threads->nr < 1) in thread_map__remove()
390 if (idx >= threads->nr) in thread_map__remove()
[all …]
A Dcputopo.c260 u32 nr, i, nr_addr; in cpu_topology__new() local
278 sz = nr * sizeof(char *); in cpu_topology__new()
297 for (i = 0; i < nr; i++) { in cpu_topology__new()
325 node->node = (u32) nr; in load_numa_node()
328 sysfs__mountpoint(), nr); in load_numa_node()
351 sysfs__mountpoint(), nr); in load_numa_node()
382 u32 nr, i; in numa_topology__new() local
410 tp->nr = nr; in numa_topology__new()
412 for (i = 0; i < nr; i++) { in numa_topology__new()
477 if (nr <= 1) in hybrid_topology__new()
[all …]
/tools/lib/perf/tests/
A Dtest-threadmap.c14 static int test_threadmap_array(int nr, pid_t *array) in test_threadmap_array() argument
19 threads = perf_thread_map__new_array(nr, array); in test_threadmap_array()
22 __T("Unexpected number of threads", perf_thread_map__nr(threads) == nr); in test_threadmap_array()
24 for (i = 0; i < nr; i++) { in test_threadmap_array()
29 for (i = 1; i < nr; i++) in test_threadmap_array()
35 for (i = 1; i < nr; i++) { in test_threadmap_array()
/tools/perf/bench/
A Dsched-pipe.c35 int nr; member
102 static int enter_cgroup(int nr) in enter_cgroup() argument
110 if (cgrp_names[nr] == NULL) in enter_cgroup()
113 if (cgrps[nr] == NULL) { in enter_cgroup()
114 cgrps[nr] = cgroup__new(cgrp_names[nr], /*do_open=*/true); in enter_cgroup()
115 if (cgrps[nr] == NULL) in enter_cgroup()
118 cgrp = cgrps[nr]; in enter_cgroup()
169 cgroup__put(cgrps[nr]); in exit_cgroup()
170 free(cgrp_names[nr]); in exit_cgroup()
193 ret = enter_cgroup(td->nr); in worker_thread()
[all …]
A Dsched-seccomp-notify.c49 static int user_notif_syscall(int nr, unsigned int flags) in user_notif_syscall() argument
53 offsetof(struct seccomp_data, nr)), in user_notif_syscall()
54 BPF_JUMP(BPF_JMP|BPF_JEQ|BPF_K, nr, 0, 1), in user_notif_syscall()
72 uint64_t nr; in user_notification_sync_loop() local
74 for (nr = 0; nr < loops; nr++) { in user_notification_sync_loop()
79 if (req.data.nr != __NR_gettid) in user_notification_sync_loop()
80 errx(EXIT_FAILURE, "unexpected syscall: %d", req.data.nr); in user_notification_sync_loop()
A Dpmu-scan.c80 int nr; in check_result() local
99 nr = perf_pmu__num_events(pmu); in check_result()
100 if (nr != r->nr_aliases) { in check_result()
102 pmu->name, r->nr_aliases, nr); in check_result()
106 nr = 0; in check_result()
108 nr++; in check_result()
109 if (nr != r->nr_formats) { in check_result()
111 pmu->name, r->nr_formats, nr); in check_result()
/tools/testing/selftests/x86/
A Dmov_ss_trap.c133 unsigned long nr; in main() local
146 asm volatile ("mov %[ss], %[tmp]" : [tmp] "=r" (nr) : [ss] "m" (ss)); in main()
167 nr = -1; in main()
169 : [tmp] "+r" (nr) : [ss] "m" (ss)); in main()
191 : [tmp] "=r" (nr) : [ss] "m" (ss)); in main()
213 nr = SYS_getpid; in main()
221 : "+a" (nr) : [ss] "m" (ss) in main()
246 nr = SYS_getpid; in main()
249 asm volatile ("xorl %%ebp, %%ebp; mov %[ss], %%ss; SYSENTER" : "+a" (nr) in main()
262 nr = 20; /* compat getpid */ in main()
[all …]
A Dsyscall_numbering.c124 long long nr = ((long long)msb << 32) | (unsigned int)lsb; in probe_syscall() local
137 : "a" (nr), "b" (nr), in probe_syscall()
180 for (int nr = start; nr <= end; nr++) { in _check_for() local
181 long long ret = probe_syscall(msb, nr); in _check_for()
185 syscall_str(msb, nr, nr), in _check_for()
212 static bool check_zero(int msb, int nr) in check_zero() argument
214 return check_for(msb, nr, nr, 0); in check_zero()
217 static bool check_enosys(int msb, int nr) in check_enosys() argument
219 return check_for(msb, nr, nr, -ENOSYS); in check_enosys()
/tools/testing/selftests/kvm/include/s390/
A Dfacility.h22 static inline bool test_bit_inv(unsigned long nr, const unsigned long *ptr) in test_bit_inv() argument
24 return test_bit(nr ^ (BITS_PER_LONG - 1), ptr); in test_bit_inv()
43 static inline bool test_facility(int nr) in test_facility() argument
47 return test_bit_inv(nr, stfl_doublewords); in test_facility()
/tools/testing/selftests/bpf/map_tests/
A Dtask_storage_map.c42 static void abort_lookup(struct lookup_ctx *ctx, pthread_t *tids, unsigned int nr) in abort_lookup() argument
48 for (i = 0; i < nr; i++) in abort_lookup()
55 unsigned int i, nr = 256, loop = 8192, cpu = 0; in test_task_storage_map_stress_lookup() local
65 nr = atoi(cfg); in test_task_storage_map_stress_lookup()
66 if (nr > MAX_NR_THREAD) in test_task_storage_map_stress_lookup()
67 nr = MAX_NR_THREAD; in test_task_storage_map_stress_lookup()
101 for (i = 0; i < nr; i++) { in test_task_storage_map_stress_lookup()
111 for (i = 0; i < nr; i++) in test_task_storage_map_stress_lookup()
/tools/objtool/
A Dorc_gen.c52 unsigned int nr = 0, idx = 0; in orc_create() local
80 nr++; in orc_create()
105 nr++; in orc_create()
117 nr++; in orc_create()
120 if (!nr) in orc_create()
130 sizeof(struct orc_entry), nr); in orc_create()
134 sec = elf_create_section_pair(file->elf, ".orc_unwind_ip", sizeof(int), nr, nr); in orc_create()
/tools/testing/selftests/net/mptcp/
A Ddiag.sh53 local nr
55 nr=$(eval $command)
58 if [ "$nr" != "$expected" ]; then
63 mptcp_lib_pr_fail "expected $expected found $nr"
100 local msg nr
108 nr=$(ss -inmHMN $ns | $condition)
109 [ $nr == $expected ] && break;
110 [ $nr -gt $max ] && max=$nr
120 elif [ $nr != $expected ]; then
121 mptcp_lib_pr_fail "expected $expected found $nr"
[all …]
/tools/arch/x86/include/asm/
A Datomic.h74 static inline int test_and_set_bit(long nr, unsigned long *addr) in test_and_set_bit() argument
76 GEN_BINARY_RMWcc(LOCK_PREFIX __ASM_SIZE(bts), *addr, "Ir", nr, "%0", "c"); in test_and_set_bit()
79 static inline int test_and_clear_bit(long nr, unsigned long *addr) in test_and_clear_bit() argument
81 GEN_BINARY_RMWcc(LOCK_PREFIX __ASM_SIZE(btc), *addr, "Ir", nr, "%0", "c"); in test_and_clear_bit()
/tools/arch/x86/kcpuid/
A Dkcpuid.c36 int nr; member
66 int nr; member
83 int nr; member
196 func->nr = 1; in cpuid_store()
198 s = func->nr; in cpuid_store()
203 func->nr++; in cpuid_store()
227 if (!func->nr) in raw_dump_range()
231 for (int i = 0; i < func->nr; i++) in raw_dump_range()
251 range->nr = 0; in setup_cpuid_range()
370 if (!func->nr) in parse_line()
[all …]
/tools/lib/subcmd/
A Dsubcmd-util.h38 #define ALLOC_GROW(x, nr, alloc) \ argument
40 if ((nr) > alloc) { \
41 if (alloc_nr(alloc) < (nr)) \
42 alloc = (nr); \

Completed in 791 milliseconds

123456789