/tools/testing/selftests/membarrier/ |
D | membarrier_test_impl.h | 12 static int sys_membarrier(int cmd, int flags) in sys_membarrier() argument 14 return syscall(__NR_membarrier, cmd, flags); in sys_membarrier() 19 int cmd = -1, flags = 0; in test_membarrier_cmd_fail() local 22 if (sys_membarrier(cmd, flags) != -1) { in test_membarrier_cmd_fail() 25 test_name, cmd, flags); in test_membarrier_cmd_fail() 30 test_name, flags, EINVAL, strerror(EINVAL), in test_membarrier_cmd_fail() 36 test_name, cmd, flags, errno); in test_membarrier_cmd_fail() 42 int cmd = MEMBARRIER_CMD_QUERY, flags = 1; in test_membarrier_flags_fail() local 45 if (sys_membarrier(cmd, flags) != -1) { in test_membarrier_flags_fail() 48 test_name, flags); in test_membarrier_flags_fail() [all …]
|
/tools/include/linux/ |
D | irqflags.h | 20 #define raw_local_irq_save(flags) ((flags) = 0) argument 21 #define raw_local_irq_restore(flags) ((void)(flags)) argument 22 #define raw_local_save_flags(flags) ((flags) = 0) argument 23 #define raw_irqs_disabled_flags(flags) ((void)(flags)) argument 29 #define local_irq_save(flags) ((flags) = 0) argument 30 #define local_irq_restore(flags) ((void)(flags)) argument 31 #define local_save_flags(flags) ((flags) = 0) argument 33 #define irqs_disabled_flags(flags) ((void)(flags), 0) argument
|
/tools/testing/selftests/core/ |
D | close_range_test.c | 48 unsigned int flags) in sys_close_range() argument 50 return syscall(__NR_close_range, fd, max_fd, flags); in sys_close_range() 122 .flags = CLONE_FILES, in TEST() 211 .flags = CLONE_FILES, in TEST() 286 int flags = fcntl(open_fds[i], F_GETFD); in TEST() local 288 EXPECT_GT(flags, -1); in TEST() 289 EXPECT_EQ(flags & FD_CLOEXEC, FD_CLOEXEC); in TEST() 293 int flags = fcntl(open_fds[i], F_GETFD); in TEST() local 295 EXPECT_GT(flags, -1); in TEST() 296 EXPECT_EQ(flags & FD_CLOEXEC, 0); in TEST() [all …]
|
/tools/testing/selftests/x86/ |
D | test_FCOMI.c | 36 int test(long flags) in test() argument 72 : "r" (flags) in test() 75 printf("[BAD]\tfcomi_1_pi with flags:%lx\n", flags); in test() 79 printf("[BAD]\tfcomi_pi_1 with flags:%lx->%lx\n", flags, res_fcomi_pi_1 & ARITH); in test() 83 printf("[BAD]\tfcomi_1_1 with flags:%lx\n", flags); in test() 93 int test_qnan(long flags) in test_qnan() argument 109 : "r" (flags) in test_qnan() 112 printf("[BAD]\tfcomi_qnan_1 with flags:%lx\n", flags); in test_qnan() 122 int testu_qnan(long flags) in testu_qnan() argument 138 : "r" (flags) in testu_qnan() [all …]
|
/tools/testing/selftests/powerpc/tm/ |
D | tm-unavailable.c | 48 } flags; variable 52 if (flags.touch_fp && flags.exception == FP_UNA_EXCEPTION) in expecting_failure() 55 if (flags.touch_vec && flags.exception == VEC_UNA_EXCEPTION) in expecting_failure() 65 if ((flags.touch_fp && flags.touch_vec) && in expecting_failure() 66 flags.exception == VSX_UNA_EXCEPTION) in expecting_failure() 111 printf("If MSR.FP=%d MSR.VEC=%d: ", flags.touch_fp, flags.touch_vec); in tm_una_ping() 113 if (flags.exception != FP_UNA_EXCEPTION && in tm_una_ping() 114 flags.exception != VEC_UNA_EXCEPTION && in tm_una_ping() 115 flags.exception != VSX_UNA_EXCEPTION) { in tm_una_ping() 214 : [touch_fp] "r" (flags.touch_fp), in tm_una_ping() [all …]
|
/tools/testing/selftests/vm/ |
D | va_128TBswitch.c | 36 unsigned long flags; member 50 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 62 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 73 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 80 .flags = MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED, 86 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 93 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 100 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 107 .flags = MAP_PRIVATE | MAP_ANONYMOUS, 114 .flags = MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED, [all …]
|
D | map_fixed_noreplace.c | 31 unsigned long flags; in find_base_addr() local 33 flags = MAP_PRIVATE | MAP_ANONYMOUS; in find_base_addr() 34 addr = mmap(NULL, size, PROT_NONE, flags, -1, 0); in find_base_addr() 50 unsigned long flags, addr, size, page_size; in main() local 63 flags = MAP_PRIVATE | MAP_ANONYMOUS | MAP_FIXED_NOREPLACE; in main() 69 p = mmap((void *)addr, size, PROT_NONE, flags, -1, 0); in main() 90 p = mmap((void *)addr, size, PROT_NONE, flags, -1, 0); in main() 110 p = mmap((void *)addr, size, PROT_NONE, flags, -1, 0); in main() 131 p = mmap((void *)addr, size, PROT_NONE, flags, -1, 0); in main() 151 p = mmap((void *)addr, size, PROT_NONE, flags, -1, 0); in main() [all …]
|
/tools/testing/selftests/openat2/ |
D | openat2_test.c | 57 .arg.inner.flags = O_RDONLY, in test_openat2_struct() 61 .arg.inner.flags = O_RDONLY, in test_openat2_struct() 68 .arg.inner.flags = O_RDONLY, .size = 0, .err = -EINVAL }, in test_openat2_struct() 70 .arg.inner.flags = O_RDONLY, in test_openat2_struct() 75 .arg.inner.flags = O_RDONLY, .arg.extra1 = 0xdeadbeef, in test_openat2_struct() 78 .arg.inner.flags = O_RDONLY, .arg.extra2 = 0xfeedcafe, in test_openat2_struct() 81 .arg.inner.flags = O_RDONLY, .arg.extra3 = 0xabad1dea, in test_openat2_struct() 169 .how.flags = O_TMPFILE | O_PATH | O_RDWR, .err = -EINVAL }, in test_openat2_flags() 171 .how.flags = O_TMPFILE | O_CREAT | O_RDWR, .err = -EINVAL }, in test_openat2_flags() 175 .how.flags = O_PATH | O_CLOEXEC }, in test_openat2_flags() [all …]
|
/tools/perf/trace/beauty/ |
D | mount_flags.c | 14 static size_t mount__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool show_prefix) in mount__scnprintf_flags() argument 19 return strarray__scnprintf_flags(&strarray__mount_flags, bf, size, show_prefix, flags); in mount__scnprintf_flags() 22 …long syscall_arg__mask_val_mount_flags(struct syscall_arg *arg __maybe_unused, unsigned long flags) in syscall_arg__mask_val_mount_flags() argument 32 if ((flags & MS_MGC_MSK) == MS_MGC_VAL) in syscall_arg__mask_val_mount_flags() 33 flags &= ~MS_MGC_MSK; in syscall_arg__mask_val_mount_flags() 35 return flags; in syscall_arg__mask_val_mount_flags() 40 unsigned long flags = arg->val; in syscall_arg__scnprintf_mount_flags() local 42 return mount__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_mount_flags()
|
D | statx.c | 18 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_statx_flags() local 20 if (flags == 0) in syscall_arg__scnprintf_statx_flags() 23 if (flags & AT_##n) { \ in syscall_arg__scnprintf_statx_flags() 25 flags &= ~AT_##n; \ in syscall_arg__scnprintf_statx_flags() 38 if (flags) in syscall_arg__scnprintf_statx_flags() 39 printed += scnprintf(bf + printed, size - printed, "%s%#x", printed ? "|" : "", flags); in syscall_arg__scnprintf_statx_flags() 48 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_statx_mask() local 51 if (flags & STATX_##n) { \ in syscall_arg__scnprintf_statx_mask() 53 flags &= ~STATX_##n; \ in syscall_arg__scnprintf_statx_mask() 72 if (flags) in syscall_arg__scnprintf_statx_mask() [all …]
|
D | open_flags.c | 25 size_t open__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool show_prefix) in open__scnprintf_flags() argument 30 if ((flags & O_ACCMODE) == O_RDONLY) in open__scnprintf_flags() 32 if (flags == 0) in open__scnprintf_flags() 35 if (flags & O_##n) { \ in open__scnprintf_flags() 37 flags &= ~O_##n; \ in open__scnprintf_flags() 62 if ((flags & O_SYNC) == O_SYNC) in open__scnprintf_flags() 74 if (flags) in open__scnprintf_flags() 75 printed += scnprintf(bf + printed, size - printed, "%s%#x", printed ? "|" : "", flags); in open__scnprintf_flags() 82 int flags = arg->val; in syscall_arg__scnprintf_open_flags() local 84 if (!(flags & O_CREAT)) in syscall_arg__scnprintf_open_flags() [all …]
|
D | clone.c | 13 static size_t clone__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool show_prefix) in clone__scnprintf_flags() argument 19 if (flags & CLONE_##n) { \ in clone__scnprintf_flags() 21 flags &= ~CLONE_##n; \ in clone__scnprintf_flags() 52 if (flags) in clone__scnprintf_flags() 53 printed += scnprintf(bf + printed, size - printed, "%s%#x", printed ? "|" : "", flags); in clone__scnprintf_flags() 60 unsigned long flags = arg->val; in syscall_arg__scnprintf_clone_flags() local 68 if (!(flags & CLONE_PARENT_SETTID)) in syscall_arg__scnprintf_clone_flags() 71 if (!(flags & (CLONE_CHILD_SETTID | CLONE_CHILD_CLEARTID))) in syscall_arg__scnprintf_clone_flags() 74 if (!(flags & CLONE_SETTLS)) in syscall_arg__scnprintf_clone_flags() 77 return clone__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_clone_flags()
|
D | sync_file_range.c | 12 static size_t sync_file_range__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool sho… in sync_file_range__scnprintf_flags() argument 18 if ((flags & SYNC_FILE_RANGE_WRITE_AND_WAIT) == SYNC_FILE_RANGE_WRITE_AND_WAIT) { in sync_file_range__scnprintf_flags() 20 flags &= ~SYNC_FILE_RANGE_WRITE_AND_WAIT; in sync_file_range__scnprintf_flags() 23 …cnprintf_flags(&strarray__sync_file_range_flags, bf + printed, size - printed, show_prefix, flags); in sync_file_range__scnprintf_flags() 28 unsigned long flags = arg->val; in syscall_arg__scnprintf_sync_file_range_flags() local 30 return sync_file_range__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_sync_file_range_flags()
|
D | fsmount.c | 12 static size_t fsmount__scnprintf_attr_flags(unsigned long flags, char *bf, size_t size, bool show_p… in fsmount__scnprintf_attr_flags() argument 18 if ((flags & ~MOUNT_ATTR__ATIME) != 0) in fsmount__scnprintf_attr_flags() 19 … printed += strarray__scnprintf_flags(&strarray__fsmount_attr_flags, bf, size, show_prefix, flags); in fsmount__scnprintf_attr_flags() 21 if ((flags & MOUNT_ATTR__ATIME) == MOUNT_ATTR_RELATIME) { in fsmount__scnprintf_attr_flags() 31 unsigned long flags = arg->val; in syscall_arg__scnprintf_fsmount_attr_flags() local 33 return fsmount__scnprintf_attr_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_fsmount_attr_flags()
|
D | mmap.c | 27 static size_t mmap__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool show_prefix) in mmap__scnprintf_flags() argument 29 return strarray__scnprintf_flags(&strarray__mmap_flags, bf, size, show_prefix, flags); in mmap__scnprintf_flags() 35 unsigned long flags = arg->val; in syscall_arg__scnprintf_mmap_flags() local 37 if (flags & MAP_ANONYMOUS) in syscall_arg__scnprintf_mmap_flags() 40 return mmap__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_mmap_flags() 48 static size_t mremap__scnprintf_flags(unsigned long flags, char *bf, size_t size, bool show_prefix) in mremap__scnprintf_flags() argument 50 return strarray__scnprintf_flags(&strarray__mremap_flags, bf, size, show_prefix, flags); in mremap__scnprintf_flags() 55 unsigned long flags = arg->val; in syscall_arg__scnprintf_mremap_flags() local 57 if (!(flags & MREMAP_FIXED)) in syscall_arg__scnprintf_mremap_flags() 60 return mremap__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_mremap_flags()
|
D | eventfd.c | 18 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_eventfd_flags() local 20 if (flags == 0) in syscall_arg__scnprintf_eventfd_flags() 23 if (flags & EFD_##n) { \ in syscall_arg__scnprintf_eventfd_flags() 25 flags &= ~EFD_##n; \ in syscall_arg__scnprintf_eventfd_flags() 33 if (flags) in syscall_arg__scnprintf_eventfd_flags() 34 printed += scnprintf(bf + printed, size - printed, "%s%#x", printed ? "|" : "", flags); in syscall_arg__scnprintf_eventfd_flags()
|
/tools/lib/subcmd/ |
D | parse-options.c | 20 static int opterror(const struct option *opt, const char *reason, int flags) in opterror() argument 22 if (flags & OPT_SHORT) in opterror() 24 else if (flags & OPT_UNSET) in opterror() 38 static void optwarning(const struct option *opt, const char *reason, int flags) in optwarning() argument 40 if (flags & OPT_SHORT) in optwarning() 42 else if (flags & OPT_UNSET) in optwarning() 49 int flags, const char **arg) in get_arg() argument 56 } else if ((opt->flags & PARSE_OPT_LASTARG_DEFAULT) && (p->argc == 1 || in get_arg() 63 return opterror(opt, "requires a value", flags); in get_arg() 70 const struct option *opt, int flags) in get_value() argument [all …]
|
/tools/testing/selftests/watchdog/ |
D | watchdog-test.c | 96 int flags; in main() local 139 flags = 0; in main() 141 ret = ioctl(fd, WDIOC_GETBOOTSTATUS, &flags); in main() 143 printf("Last boot is caused by: %s.\n", (flags != 0) ? in main() 149 flags = WDIOS_DISABLECARD; in main() 150 ret = ioctl(fd, WDIOC_SETOPTIONS, &flags); in main() 159 flags = WDIOS_ENABLECARD; in main() 160 ret = ioctl(fd, WDIOC_SETOPTIONS, &flags); in main() 175 flags = strtoul(optarg, NULL, 0); in main() 176 ret = ioctl(fd, WDIOC_SETTIMEOUT, &flags); in main() [all …]
|
/tools/power/cpupower/ |
D | cpupower-completion.sh | 9 …local flags="-f -w -l -d -p -g -a -s -y -o -m -n --freq --hwfreq --hwlimits --driver --policy --go… 13 frequency-info) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 19 local flags="-f -g --freq --governor -d --min -u --max -r --related" 31 frequency-set) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 37 local flags="-f --silent" 41 idle-info) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 47 local flags="-d --disable -e --enable -D --disable-by-latency -E --enable-all" 51 idle-set) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; 57 local flags="--perf-bias, -b" 61 set) COMPREPLY=($(compgen -W "$flags" -- "$cur")) ;; [all …]
|
/tools/testing/selftests/timers/ |
D | set-timer-lat.c | 115 void describe_timer(int flags, int interval) in describe_timer() argument 119 flags ? "ABSTIME":"RELTIME", in describe_timer() 123 int setup_timer(int clock_id, int flags, int interval, timer_t *tm1) in setup_timer() argument 145 flags ? "ABSTIME":"RELTIME"); in setup_timer() 154 if (flags) { in setup_timer() 164 err = timer_settime(*tm1, flags, &its1, &its2); in setup_timer() 173 int check_timer_latency(int flags, int interval) in check_timer_latency() argument 177 describe_timer(flags, interval); in check_timer_latency() 186 describe_timer(flags, interval); in check_timer_latency() 198 int check_alarmcount(int flags, int interval) in check_alarmcount() argument [all …]
|
/tools/testing/selftests/pidfd/ |
D | pidfd.h | 97 static inline int sys_pidfd_open(pid_t pid, unsigned int flags) in sys_pidfd_open() argument 99 return syscall(__NR_pidfd_open, pid, flags); in sys_pidfd_open() 103 unsigned int flags) in sys_pidfd_send_signal() argument 105 return syscall(__NR_pidfd_send_signal, pidfd, sig, info, flags); in sys_pidfd_send_signal() 108 static inline int sys_pidfd_getfd(int pidfd, int fd, int flags) in sys_pidfd_getfd() argument 110 return syscall(__NR_pidfd_getfd, pidfd, fd, flags); in sys_pidfd_getfd() 113 static inline int sys_memfd_create(const char *name, unsigned int flags) in sys_memfd_create() argument 115 return syscall(__NR_memfd_create, name, flags); in sys_memfd_create()
|
/tools/vm/ |
D | page-types.c | 200 #define HASH_KEY(flags) (flags & HASH_MASK) argument 238 static int checked_open(const char *pathname, int flags) in checked_open() argument 240 int fd = open(pathname, flags); in checked_open() 329 static char *page_flag_name(uint64_t flags) in page_flag_name() argument 336 present = (flags >> i) & 1; in page_flag_name() 348 static char *page_flag_longname(uint64_t flags) in page_flag_longname() argument 356 if ((flags >> i) & 1) in page_flag_longname() 373 unsigned long size, uint64_t flags, in show_page_range() argument 383 if (flags == flags0 && cgroup == cgroup0 && mapcnt == mapcnt0 && in show_page_range() 402 flags0 = flags; in show_page_range() [all …]
|
/tools/testing/selftests/kvm/x86_64/ |
D | vmx_set_nested_state_test.c | 70 state->flags = KVM_STATE_NESTED_RUN_PENDING | in set_default_state() 80 state->flags = KVM_STATE_NESTED_EVMCS; in set_default_vmx_state() 85 state->hdr.vmx.smm.flags = 0; in set_default_vmx_state() 118 state->flags = KVM_STATE_NESTED_EVMCS; in test_vmx_nested_state() 121 state->flags = 0; in test_vmx_nested_state() 138 state->flags &= KVM_STATE_NESTED_EVMCS; in test_vmx_nested_state() 146 state->hdr.vmx.smm.flags = 1; in test_vmx_nested_state() 151 state->hdr.vmx.flags = ~0; in test_vmx_nested_state() 157 state->flags = 0; in test_vmx_nested_state() 170 state->flags = KVM_STATE_NESTED_GUEST_MODE | in test_vmx_nested_state() [all …]
|
/tools/testing/selftests/net/mptcp/ |
D | mptcp_join.sh | 360 ip netns exec $ns1 ./pm_nl_ctl add $addr flags signal 392 flags="subflow" 394 flags="${flags},fullmesh" 409 ip netns exec $ns2 ./pm_nl_ctl add $addr flags $flags 992 ip netns exec $ns2 ./pm_nl_ctl add 10.0.3.2 flags subflow 999 ip netns exec $ns2 ./pm_nl_ctl add 10.0.3.2 flags subflow 1007 ip netns exec $ns2 ./pm_nl_ctl add 10.0.3.2 flags subflow 1015 ip netns exec $ns2 ./pm_nl_ctl add 10.0.3.2 flags subflow 1016 ip netns exec $ns2 ./pm_nl_ctl add 10.0.2.2 flags subflow 1024 ip netns exec $ns2 ./pm_nl_ctl add 10.0.3.2 flags subflow [all …]
|
/tools/arch/x86/tools/ |
D | gen-insn-attr-x86.awk | 290 flags = null 296 flags = convert_operands(count, opnds) 311 flags = add_flags(flags, "INAT_MAKE_GROUP(" group[opcode] ")") 315 flags = add_flags(flags, "INAT_FORCE64") 319 flags = add_flags(flags, "INAT_MAKE_PREFIX(INAT_PFX_REX)") 323 flags = add_flags(flags, "INAT_MODRM") 327 flags = add_flags(flags, "INAT_VEXOK | INAT_EVEXONLY") 329 flags = add_flags(flags, "INAT_VEXOK | INAT_VEXONLY") 331 flags = add_flags(flags, "INAT_VEXOK") 337 flags = add_flags(flags, "INAT_MAKE_PREFIX(" prefix_num[opcode] ")") [all …]
|