/tools/perf/trace/beauty/ |
D | fcntl.c | 18 static size_t syscall_arg__scnprintf_fcntl_getfd(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_fcntl_getfd() argument 20 return fcntl__scnprintf_getfd(arg->val, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_fcntl_getfd() 31 static size_t syscall_arg__scnprintf_fcntl_getlease(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_fcntl_getlease() argument 33 return fcntl__scnprintf_getlease(arg->val, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_fcntl_getlease() 36 size_t syscall_arg__scnprintf_fcntl_cmd(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_fcntl_cmd() argument 38 if (arg->val == F_GETFL) { in syscall_arg__scnprintf_fcntl_cmd() 39 syscall_arg__set_ret_scnprintf(arg, syscall_arg__scnprintf_open_flags); in syscall_arg__scnprintf_fcntl_cmd() 42 if (arg->val == F_GETFD) { in syscall_arg__scnprintf_fcntl_cmd() 43 syscall_arg__set_ret_scnprintf(arg, syscall_arg__scnprintf_fcntl_getfd); in syscall_arg__scnprintf_fcntl_cmd() 46 if (arg->val == F_DUPFD_CLOEXEC || arg->val == F_DUPFD) { in syscall_arg__scnprintf_fcntl_cmd() [all …]
|
D | beauty.h | 112 unsigned long syscall_arg__val(struct syscall_arg *arg, u8 idx); 114 size_t syscall_arg__scnprintf_strarray_flags(char *bf, size_t size, struct syscall_arg *arg); 117 size_t syscall_arg__scnprintf_strarrays(char *bf, size_t size, struct syscall_arg *arg); 120 size_t syscall_arg__scnprintf_fd(char *bf, size_t size, struct syscall_arg *arg); 123 size_t syscall_arg__scnprintf_hex(char *bf, size_t size, struct syscall_arg *arg); 126 size_t syscall_arg__scnprintf_ptr(char *bf, size_t size, struct syscall_arg *arg); 129 size_t syscall_arg__scnprintf_int(char *bf, size_t size, struct syscall_arg *arg); 132 size_t syscall_arg__scnprintf_long(char *bf, size_t size, struct syscall_arg *arg); 135 size_t syscall_arg__scnprintf_pid(char *bf, size_t size, struct syscall_arg *arg); 138 size_t syscall_arg__scnprintf_clone_flags(char *bf, size_t size, struct syscall_arg *arg); [all …]
|
D | kcmp.c | 16 size_t syscall_arg__scnprintf_kcmp_idx(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_kcmp_idx() argument 18 unsigned long fd = arg->val; in syscall_arg__scnprintf_kcmp_idx() 19 int type = syscall_arg__val(arg, 2); in syscall_arg__scnprintf_kcmp_idx() 23 return syscall_arg__scnprintf_long(bf, size, arg); in syscall_arg__scnprintf_kcmp_idx() 25 pid = syscall_arg__val(arg, arg->idx == 3 ? 0 : 1); /* idx1 -> pid1, idx2 -> pid2 */ in syscall_arg__scnprintf_kcmp_idx() 26 return pid__scnprintf_fd(arg->trace, pid, fd, bf, size); in syscall_arg__scnprintf_kcmp_idx() 35 size_t syscall_arg__scnprintf_kcmp_type(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_kcmp_type() argument 37 unsigned long type = arg->val; in syscall_arg__scnprintf_kcmp_type() 40 arg->mask |= (1 << 3) | (1 << 4); /* Ignore idx1 and idx2 */ in syscall_arg__scnprintf_kcmp_type() 42 return kcmp__scnprintf_type(type, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_kcmp_type()
|
D | prctl.c | 26 size_t syscall_arg__scnprintf_prctl_arg2(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_prctl_arg2() argument 28 int option = syscall_arg__val(arg, 0); in syscall_arg__scnprintf_prctl_arg2() 31 return prctl__scnprintf_set_mm(arg->val, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_prctl_arg2() 37 return syscall_arg__scnprintf_hex(bf, size, arg); in syscall_arg__scnprintf_prctl_arg2() 39 return syscall_arg__scnprintf_long(bf, size, arg); in syscall_arg__scnprintf_prctl_arg2() 42 size_t syscall_arg__scnprintf_prctl_arg3(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_prctl_arg3() argument 44 int option = syscall_arg__val(arg, 0); in syscall_arg__scnprintf_prctl_arg3() 47 return syscall_arg__scnprintf_hex(bf, size, arg); in syscall_arg__scnprintf_prctl_arg3() 49 return syscall_arg__scnprintf_long(bf, size, arg); in syscall_arg__scnprintf_prctl_arg3() 52 size_t syscall_arg__scnprintf_prctl_option(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_prctl_option() argument [all …]
|
D | futex_op.c | 20 static size_t syscall_arg__scnprintf_futex_op(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_futex_op() argument 22 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_futex_op() 32 int op = arg->val; in syscall_arg__scnprintf_futex_op() 38 P_FUTEX_OP(WAIT); arg->mask |= SCF_VAL3|SCF_UADDR2; break; in syscall_arg__scnprintf_futex_op() 39 P_FUTEX_OP(WAKE); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() 40 P_FUTEX_OP(FD); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() 41 P_FUTEX_OP(REQUEUE); arg->mask |= SCF_VAL3|SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() 42 P_FUTEX_OP(CMP_REQUEUE); arg->mask |= SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() 43 P_FUTEX_OP(CMP_REQUEUE_PI); arg->mask |= SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() 45 P_FUTEX_OP(LOCK_PI); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; in syscall_arg__scnprintf_futex_op() [all …]
|
D | mmap.c | 6 struct syscall_arg *arg) in syscall_arg__scnprintf_mmap_prot() argument 9 int printed = 0, prot = arg->val; in syscall_arg__scnprintf_mmap_prot() 10 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_mmap_prot() 45 struct syscall_arg *arg) in syscall_arg__scnprintf_mmap_flags() argument 47 unsigned long flags = arg->val; in syscall_arg__scnprintf_mmap_flags() 50 arg->mask |= (1 << 4) | (1 << 5); /* Mask 4th ('fd') and 5th ('offset') args, ignored */ in syscall_arg__scnprintf_mmap_flags() 52 return mmap__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_mmap_flags() 58 struct syscall_arg *arg) in syscall_arg__scnprintf_mremap_flags() argument 61 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_mremap_flags() 62 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_mremap_flags() [all …]
|
D | socket.c | 20 size_t syscall_arg__scnprintf_socket_protocol(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_socket_protocol() argument 22 int domain = syscall_arg__val(arg, 0); in syscall_arg__scnprintf_socket_protocol() 25 return socket__scnprintf_ipproto(arg->val, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_socket_protocol() 27 return syscall_arg__scnprintf_int(bf, size, arg); in syscall_arg__scnprintf_socket_protocol()
|
D | seccomp.c | 9 static size_t syscall_arg__scnprintf_seccomp_op(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_seccomp_op() argument 11 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_seccomp_op() 13 int op = arg->val; in syscall_arg__scnprintf_seccomp_op() 34 struct syscall_arg *arg) in syscall_arg__scnprintf_seccomp_flags() argument 36 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_seccomp_flags() 38 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_seccomp_flags()
|
D | mount_flags.c | 22 unsigned long syscall_arg__mask_val_mount_flags(struct syscall_arg *arg __maybe_unused, unsigned lo… in syscall_arg__mask_val_mount_flags() 38 size_t syscall_arg__scnprintf_mount_flags(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_mount_flags() argument 40 unsigned long flags = arg->val; in syscall_arg__scnprintf_mount_flags() 42 return mount__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_mount_flags()
|
D | clone.c | 56 size_t syscall_arg__scnprintf_clone_flags(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_clone_flags() argument 58 unsigned long flags = arg->val; in syscall_arg__scnprintf_clone_flags() 67 arg->mask |= SCC_PARENT_TIDPTR; in syscall_arg__scnprintf_clone_flags() 70 arg->mask |= SCC_CHILD_TIDPTR; in syscall_arg__scnprintf_clone_flags() 73 arg->mask |= SCC_TLS; in syscall_arg__scnprintf_clone_flags() 75 return clone__scnprintf_flags(flags, bf, size, arg->show_string_prefix); in syscall_arg__scnprintf_clone_flags()
|
D | statx.c | 14 size_t syscall_arg__scnprintf_statx_flags(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_statx_flags() argument 16 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_statx_flags() 18 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_statx_flags() 44 size_t syscall_arg__scnprintf_statx_mask(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_statx_mask() argument 46 bool show_prefix = arg->show_string_prefix; in syscall_arg__scnprintf_statx_mask() 48 int printed = 0, flags = arg->val; in syscall_arg__scnprintf_statx_mask()
|
D | sockaddr.c | 55 static size_t syscall_arg__scnprintf_augmented_sockaddr(struct syscall_arg *arg, char *bf, size_t s… in syscall_arg__scnprintf_augmented_sockaddr() argument 57 struct sockaddr *sa = (struct sockaddr *)arg->augmented.args; in syscall_arg__scnprintf_augmented_sockaddr() 61 …strarray__scnprintf(&strarray__socket_families, family, sizeof(family), "%d", arg->show_string_pre… in syscall_arg__scnprintf_augmented_sockaddr() 70 size_t syscall_arg__scnprintf_sockaddr(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_sockaddr() argument 72 if (arg->augmented.args) in syscall_arg__scnprintf_sockaddr() 73 return syscall_arg__scnprintf_augmented_sockaddr(arg, bf, size); in syscall_arg__scnprintf_sockaddr() 75 return scnprintf(bf, size, "%#x", arg->val); in syscall_arg__scnprintf_sockaddr()
|
/tools/lib/traceevent/ |
D | parse-filter.c | 189 static void free_arg(struct tep_filter_arg *arg) in free_arg() argument 191 if (!arg) in free_arg() 194 switch (arg->type) { in free_arg() 200 free_arg(arg->num.left); in free_arg() 201 free_arg(arg->num.right); in free_arg() 205 free_arg(arg->exp.left); in free_arg() 206 free_arg(arg->exp.right); in free_arg() 210 free(arg->str.val); in free_arg() 211 regfree(&arg->str.reg); in free_arg() 212 free(arg->str.buffer); in free_arg() [all …]
|
D | event-parse.c | 99 struct tep_event *event, struct tep_print_arg *arg); 868 static void free_arg(struct tep_print_arg *arg) in free_arg() argument 872 if (!arg) in free_arg() 875 switch (arg->type) { in free_arg() 877 free(arg->atom.atom); in free_arg() 880 free(arg->field.name); in free_arg() 883 free_arg(arg->flags.field); in free_arg() 884 free(arg->flags.delim); in free_arg() 885 free_flag_sym(arg->flags.flags); in free_arg() 888 free_arg(arg->symbol.field); in free_arg() [all …]
|
/tools/perf/ |
D | builtin-config.c | 121 static int parse_config_arg(char *arg, char **var, char **value) in parse_config_arg() argument 123 const char *last_dot = strchr(arg, '.'); in parse_config_arg() 129 if (last_dot == NULL || last_dot == arg) { in parse_config_arg() 130 pr_err("The config variable does not contain a section name: %s\n", arg); in parse_config_arg() 134 pr_err("The config variable does not contain a variable name: %s\n", arg); in parse_config_arg() 138 *value = strchr(arg, '='); in parse_config_arg() 140 *var = arg; in parse_config_arg() 142 pr_err("The config variable does not contain a value: %s\n", arg); in parse_config_arg() 146 *var = strsep(&arg, "="); in parse_config_arg() 148 pr_err("invalid config variable: %s\n", arg); in parse_config_arg() [all …]
|
D | builtin-trace.c | 95 size_t (*scnprintf)(char *bf, size_t size, struct syscall_arg *arg); 96 bool (*strtoul)(char *bf, size_t size, struct syscall_arg *arg, u64 *val); 97 unsigned long (*mask_val)(struct syscall_arg *arg, unsigned long val); 110 struct syscall_arg_fmt arg[RAW_SYSCALL_ARGS_NUM]; member 439 struct syscall_arg *arg) in __syscall_arg__scnprintf_strarray() argument 441 return strarray__scnprintf(arg->parm, bf, size, intfmt, arg->show_string_prefix, arg->val); in __syscall_arg__scnprintf_strarray() 445 struct syscall_arg *arg) in syscall_arg__scnprintf_strarray() argument 447 return __syscall_arg__scnprintf_strarray(bf, size, "%d", arg); in syscall_arg__scnprintf_strarray() 452 size_t syscall_arg__scnprintf_strarray_flags(char *bf, size_t size, struct syscall_arg *arg) in syscall_arg__scnprintf_strarray_flags() argument 454 return strarray__scnprintf_flags(arg->parm, bf, size, arg->show_string_prefix, arg->val); in syscall_arg__scnprintf_strarray_flags() [all …]
|
/tools/lib/subcmd/ |
D | parse-options.c | 49 int flags, const char **arg) in get_arg() argument 64 if (arg) in get_arg() 65 *arg = res; in get_arg() 72 const char *s, *arg = NULL; in get_value() local 246 if (get_arg(p, opt, flags, &arg)) in get_value() 248 return (*opt->callback)(opt, arg, 0) ? (-1) : 0; in get_value() 259 if (get_arg(p, opt, flags, &arg)) in get_value() 261 *(int *)opt->value = strtol(arg, (char **)&s, 10); in get_value() 275 if (get_arg(p, opt, flags, &arg)) in get_value() 277 if (arg[0] == '-') in get_value() [all …]
|
/tools/testing/selftests/bpf/progs/ |
D | test_btf_nokv.c | 26 static int test_long_fname_2(struct dummy_tracepoint_args *arg) in test_long_fname_2() argument 31 if (!arg->sock) in test_long_fname_2() 44 static int test_long_fname_1(struct dummy_tracepoint_args *arg) in test_long_fname_1() argument 46 return test_long_fname_2(arg); in test_long_fname_1() 50 int _dummy_tracepoint(struct dummy_tracepoint_args *arg) in _dummy_tracepoint() argument 52 return test_long_fname_1(arg); in _dummy_tracepoint()
|
D | test_btf_haskv.c | 28 static int test_long_fname_2(struct dummy_tracepoint_args *arg) in test_long_fname_2() argument 33 if (!arg->sock) in test_long_fname_2() 46 static int test_long_fname_1(struct dummy_tracepoint_args *arg) in test_long_fname_1() argument 48 return test_long_fname_2(arg); in test_long_fname_1() 52 int _dummy_tracepoint(struct dummy_tracepoint_args *arg) in _dummy_tracepoint() argument 54 return test_long_fname_1(arg); in _dummy_tracepoint()
|
D | test_btf_newkv.c | 36 static int test_long_fname_2(struct dummy_tracepoint_args *arg) in test_long_fname_2() argument 41 if (!arg->sock) in test_long_fname_2() 59 static int test_long_fname_1(struct dummy_tracepoint_args *arg) in test_long_fname_1() argument 61 return test_long_fname_2(arg); in test_long_fname_1() 65 int _dummy_tracepoint(struct dummy_tracepoint_args *arg) in _dummy_tracepoint() argument 67 return test_long_fname_1(arg); in _dummy_tracepoint()
|
/tools/perf/util/intel-pt-decoder/ |
D | intel-pt-log.h | 38 #define intel_pt_log_packet(arg, ...) \ argument 41 __intel_pt_log_packet(arg, ##__VA_ARGS__); \ 44 #define intel_pt_log_insn(arg, ...) \ argument 47 __intel_pt_log_insn(arg, ##__VA_ARGS__); \ 50 #define intel_pt_log_insn_no_data(arg, ...) \ argument 53 __intel_pt_log_insn_no_data(arg, ##__VA_ARGS__); \
|
/tools/testing/selftests/ptrace/ |
D | peeksiginfo.c | 46 struct ptrace_peeksiginfo_args arg; in check_error_paths() local 68 arg.nr = SIGNR; in check_error_paths() 69 arg.off = 0; in check_error_paths() 72 arg.flags = ~0; in check_error_paths() 73 ret = sys_ptrace(PTRACE_PEEKSIGINFO, child, &arg, addr_rw); in check_error_paths() 80 arg.flags = 0; in check_error_paths() 83 ret = sys_ptrace(PTRACE_PEEKSIGINFO, child, &arg, in check_error_paths() 91 ret = sys_ptrace(PTRACE_PEEKSIGINFO, child, &arg, addr_ro); in check_error_paths() 107 struct ptrace_peeksiginfo_args arg = {.flags = 0, .nr = nr, .off = 0}; in check_direct_path() local 113 arg.flags = PTRACE_PEEKSIGINFO_SHARED; in check_direct_path() [all …]
|
/tools/perf/examples/bpf/ |
D | augmented_raw_syscalls.c | 75 struct augmented_arg arg, arg2; member 97 unsigned int augmented_arg__read_str(struct augmented_arg *augmented_arg, const void *arg, unsigned… in augmented_arg__read_str() argument 100 int string_len = probe_read_str(&augmented_arg->value, arg_len, arg); in augmented_arg__read_str() 183 …len += augmented_arg__read_str(&augmented_args->arg, filename_arg, sizeof(augmented_args->arg.valu… in sys_enter_open() 198 …len += augmented_arg__read_str(&augmented_args->arg, filename_arg, sizeof(augmented_args->arg.valu… in sys_enter_openat() 214 …ldpath_len = augmented_arg__read_str(&augmented_args->arg, oldpath_arg, sizeof(augmented_args->arg… in sys_enter_rename() 215 …mented_arg__read_str((void *)(&augmented_args->arg) + oldpath_len, newpath_arg, sizeof(augmented_a… in sys_enter_rename() 231 …ldpath_len = augmented_arg__read_str(&augmented_args->arg, oldpath_arg, sizeof(augmented_args->arg… in sys_enter_renameat() 232 …mented_arg__read_str((void *)(&augmented_args->arg) + oldpath_len, newpath_arg, sizeof(augmented_a… in sys_enter_renameat()
|
/tools/perf/scripts/python/bin/ |
D | mem-phys-addr-record | 17 arg=$(echo $load | tr -d ' ') 18 arg="$arg:P" 19 perf record --phys-data -e $arg $@
|
/tools/testing/selftests/cgroup/ |
D | cgroup_util.h | 34 int (*fn)(const char *cgroup, void *arg), 35 void *arg); 39 int (*fn)(const char *cgroup, void *arg), 40 void *arg); 43 extern int alloc_anon(const char *cgroup, void *arg);
|