/linux-6.6.21/drivers/infiniband/core/ |
D | uverbs_ioctl.c | 137 static bool uverbs_is_attr_cleared(const struct ib_uverbs_attr *uattr, in uverbs_is_attr_cleared() argument 140 if (uattr->len > sizeof_field(struct ib_uverbs_attr, data)) in uverbs_is_attr_cleared() 141 return ib_is_buffer_cleared(u64_to_user_ptr(uattr->data) + len, in uverbs_is_attr_cleared() 142 uattr->len - len); in uverbs_is_attr_cleared() 144 return !memchr_inv((const void *)&uattr->data + len, in uverbs_is_attr_cleared() 145 0, uattr->len - len); in uverbs_is_attr_cleared() 166 struct ib_uverbs_attr *uattr, in uverbs_process_idrs_array() argument 175 if (uattr->attr_data.reserved) in uverbs_process_idrs_array() 178 if (uattr->len % sizeof(u32)) in uverbs_process_idrs_array() 181 array_len = uattr->len / sizeof(u32); in uverbs_process_idrs_array() [all …]
|
D | uverbs_std_types_counters.c | 92 const struct uverbs_attr *uattr; in UVERBS_HANDLER() local 109 uattr = uverbs_attr_get(attrs, UVERBS_ATTR_READ_COUNTERS_BUFF); in UVERBS_HANDLER() 110 if (IS_ERR(uattr)) in UVERBS_HANDLER() 111 return PTR_ERR(uattr); in UVERBS_HANDLER() 112 read_attr.ncounters = uattr->ptr_attr.len / sizeof(u64); in UVERBS_HANDLER()
|
/linux-6.6.21/kernel/bpf/ |
D | syscall.c | 1506 static int map_update_elem(union bpf_attr *attr, bpfptr_t uattr) in map_update_elem() argument 1508 bpfptr_t ukey = make_bpfptr(attr->key, uattr.is_kernel); in map_update_elem() 1509 bpfptr_t uvalue = make_bpfptr(attr->value, uattr.is_kernel); in map_update_elem() 1562 static int map_delete_elem(union bpf_attr *attr, bpfptr_t uattr) in map_delete_elem() argument 1564 bpfptr_t ukey = make_bpfptr(attr->key, uattr.is_kernel); in map_delete_elem() 1683 union bpf_attr __user *uattr) in generic_map_delete_batch() argument 1702 if (put_user(0, &uattr->batch.count)) in generic_map_delete_batch() 1729 if (copy_to_user(&uattr->batch.count, &cp, sizeof(cp))) in generic_map_delete_batch() 1740 union bpf_attr __user *uattr) in generic_map_update_batch() argument 1762 if (put_user(0, &uattr->batch.count)) in generic_map_update_batch() [all …]
|
D | net_namespace.c | 247 union bpf_attr __user *uattr, in __netns_bpf_prog_query() argument 260 if (copy_to_user(&uattr->query.attach_flags, &flags, sizeof(flags))) in __netns_bpf_prog_query() 262 if (copy_to_user(&uattr->query.prog_cnt, &prog_cnt, sizeof(prog_cnt))) in __netns_bpf_prog_query() 272 union bpf_attr __user *uattr) in netns_bpf_prog_query() argument 290 ret = __netns_bpf_prog_query(attr, uattr, net, type); in netns_bpf_prog_query()
|
D | hashtab.c | 1677 union bpf_attr __user *uattr, in __htab_map_lookup_and_delete_batch() argument 1711 if (put_user(0, &uattr->batch.count)) in __htab_map_lookup_and_delete_batch() 1893 put_user(total, &uattr->batch.count)) in __htab_map_lookup_and_delete_batch() 1904 union bpf_attr __user *uattr) in htab_percpu_map_lookup_batch() argument 1906 return __htab_map_lookup_and_delete_batch(map, attr, uattr, false, in htab_percpu_map_lookup_batch() 1913 union bpf_attr __user *uattr) in htab_percpu_map_lookup_and_delete_batch() argument 1915 return __htab_map_lookup_and_delete_batch(map, attr, uattr, true, in htab_percpu_map_lookup_and_delete_batch() 1921 union bpf_attr __user *uattr) in htab_map_lookup_batch() argument 1923 return __htab_map_lookup_and_delete_batch(map, attr, uattr, false, in htab_map_lookup_batch() 1930 union bpf_attr __user *uattr) in htab_map_lookup_and_delete_batch() argument [all …]
|
D | mprog.c | 395 int bpf_mprog_query(const union bpf_attr *attr, union bpf_attr __user *uattr, in bpf_mprog_query() argument 414 if (copy_to_user(&uattr->query.attach_flags, &flags, sizeof(flags))) in bpf_mprog_query() 416 if (copy_to_user(&uattr->query.revision, &revision, sizeof(revision))) in bpf_mprog_query() 418 if (copy_to_user(&uattr->query.count, &count, sizeof(count))) in bpf_mprog_query()
|
D | tcx.c | 122 int tcx_prog_query(const union bpf_attr *attr, union bpf_attr __user *uattr) in tcx_prog_query() argument 135 ret = bpf_mprog_query(attr, uattr, tcx_entry_fetch(dev, ingress)); in tcx_prog_query()
|
D | cgroup.c | 1021 union bpf_attr __user *uattr) in __cgroup_bpf_query() argument 1065 if (copy_to_user(&uattr->query.attach_flags, &flags, sizeof(flags))) in __cgroup_bpf_query() 1067 if (copy_to_user(&uattr->query.prog_cnt, &total_cnt, sizeof(total_cnt))) in __cgroup_bpf_query() 1120 union bpf_attr __user *uattr) in cgroup_bpf_query() argument 1125 ret = __cgroup_bpf_query(cgrp, attr, uattr); in cgroup_bpf_query() 1319 union bpf_attr __user *uattr) in cgroup_bpf_prog_query() argument 1328 ret = cgroup_bpf_query(cgrp, attr, uattr); in cgroup_bpf_prog_query()
|
D | bpf_iter.c | 507 int bpf_iter_link_attach(const union bpf_attr *attr, bpfptr_t uattr, in bpf_iter_link_attach() argument 523 ulinfo = make_bpfptr(attr->link_create.iter_info, uattr.is_kernel); in bpf_iter_link_attach()
|
D | btf.c | 5459 static int finalize_log(struct bpf_verifier_log *log, bpfptr_t uattr, u32 uattr_size) in finalize_log() argument 5467 copy_to_bpfptr_offset(uattr, offsetof(union bpf_attr, btf_log_true_size), in finalize_log() 5474 static struct btf *btf_parse(const union bpf_attr *attr, bpfptr_t uattr, u32 uattr_size) in btf_parse() argument 5476 bpfptr_t btf_data = make_bpfptr(attr->btf, uattr.is_kernel); in btf_parse() 5555 err = finalize_log(&env->log, uattr, uattr_size); in btf_parse() 5567 ret = finalize_log(&env->log, uattr, uattr_size); in btf_parse() 7177 int btf_new_fd(const union bpf_attr *attr, bpfptr_t uattr, u32 uattr_size) in btf_new_fd() argument 7182 btf = btf_parse(attr, uattr, uattr_size); in btf_new_fd() 7229 union bpf_attr __user *uattr) in btf_get_info_by_fd() argument 7281 put_user(info_copy, &uattr->info.info_len)) in btf_get_info_by_fd()
|
D | verifier.c | 15420 bpfptr_t uattr) in check_btf_func() argument 15457 urecord = make_bpfptr(attr->func_info, uattr.is_kernel); in check_btf_func() 15475 if (copy_to_bpfptr_offset(uattr, in check_btf_func() 15566 bpfptr_t uattr) in check_btf_line() argument 15601 ulinfo = make_bpfptr(attr->line_info, uattr.is_kernel); in check_btf_line() 15609 if (copy_to_bpfptr_offset(uattr, in check_btf_line() 15694 bpfptr_t uattr) in check_core_relo() argument 15719 u_core_relo = make_bpfptr(attr->core_relos, uattr.is_kernel); in check_core_relo() 15732 if (copy_to_bpfptr_offset(uattr, in check_core_relo() 15763 bpfptr_t uattr) in check_btf_info() argument [all …]
|
/linux-6.6.21/net/bpf/ |
D | test_run.c | 436 union bpf_attr __user *uattr, const void *data, in bpf_test_finish() argument 489 if (copy_to_user(&uattr->test.data_size_out, &size, sizeof(size))) in bpf_test_finish() 491 if (copy_to_user(&uattr->test.retval, &retval, sizeof(retval))) in bpf_test_finish() 493 if (copy_to_user(&uattr->test.duration, &duration, sizeof(duration))) in bpf_test_finish() 653 union bpf_attr __user *uattr) in bpf_prog_test_run_tracing() argument 691 if (copy_to_user(&uattr->test.retval, &retval, sizeof(retval))) in bpf_prog_test_run_tracing() 718 union bpf_attr __user *uattr) in bpf_prog_test_run_raw_tp() argument 767 copy_to_user(&uattr->test.retval, &info.retval, sizeof(u32))) in bpf_prog_test_run_raw_tp() 806 union bpf_attr __user *uattr, const void *data, in bpf_ctx_finish() argument 823 if (copy_to_user(&uattr->test.ctx_size_out, &size, sizeof(size))) in bpf_ctx_finish() [all …]
|
D | bpf_dummy_struct_ops.c | 78 union bpf_attr __user *uattr) in bpf_struct_ops_test_run() argument 133 if (put_user(prog_ret, &uattr->test.retval)) in bpf_struct_ops_test_run()
|
/linux-6.6.21/include/linux/ |
D | bpf_lirc.h | 10 int lirc_prog_query(const union bpf_attr *attr, union bpf_attr __user *uattr); 24 union bpf_attr __user *uattr) in lirc_prog_query() argument
|
D | bpf-netns.h | 30 union bpf_attr __user *uattr); 38 union bpf_attr __user *uattr) in netns_bpf_prog_query() argument
|
D | bpf.h | 85 union bpf_attr __user *uattr); 90 union bpf_attr __user *uattr); 93 union bpf_attr __user *uattr); 95 union bpf_attr __user *uattr); 927 union bpf_attr __user *uattr); 1682 union bpf_attr __user *uattr); 2081 union bpf_attr __user *uattr); 2084 union bpf_attr __user *uattr); 2087 union bpf_attr __user *uattr); 2284 int bpf_iter_link_attach(const union bpf_attr *attr, bpfptr_t uattr, struct bpf_prog *prog); [all …]
|
D | btf.h | 130 int btf_new_fd(const union bpf_attr *attr, bpfptr_t uattr, u32 uattr_sz); 134 union bpf_attr __user *uattr);
|
D | bpf-cgroup.h | 417 union bpf_attr __user *uattr); 448 union bpf_attr __user *uattr) in cgroup_bpf_prog_query() argument
|
D | bpf_mprog.h | 331 int bpf_mprog_query(const union bpf_attr *attr, union bpf_attr __user *uattr,
|
/linux-6.6.21/arch/powerpc/platforms/book3s/ |
D | vas-api.c | 283 struct vas_tx_win_open_attr uattr; in coproc_ioc_tx_win_open() local 296 rc = copy_from_user(&uattr, uptr, sizeof(uattr)); in coproc_ioc_tx_win_open() 302 if (uattr.version != 1) { in coproc_ioc_tx_win_open() 312 txwin = cp_inst->coproc->vops->open_win(uattr.vas_id, uattr.flags, in coproc_ioc_tx_win_open()
|
/linux-6.6.21/include/net/ |
D | tcx.h | 169 union bpf_attr __user *uattr); 197 union bpf_attr __user *uattr) in tcx_prog_query() argument
|
/linux-6.6.21/drivers/media/rc/ |
D | bpf-lirc.c | 295 int lirc_prog_query(const union bpf_attr *attr, union bpf_attr __user *uattr) in lirc_prog_query() argument 322 if (copy_to_user(&uattr->query.prog_cnt, &cnt, sizeof(cnt))) { in lirc_prog_query() 327 if (copy_to_user(&uattr->query.attach_flags, &flags, sizeof(flags))) { in lirc_prog_query()
|
/linux-6.6.21/ipc/ |
D | mqueue.c | 1531 const struct compat_mq_attr __user *uattr) in get_compat_mq_attr() argument 1535 if (copy_from_user(&v, uattr, sizeof(*uattr))) in get_compat_mq_attr() 1547 struct compat_mq_attr __user *uattr) in put_compat_mq_attr() argument 1556 if (copy_to_user(uattr, &v, sizeof(*uattr))) in put_compat_mq_attr()
|
/linux-6.6.21/kernel/sched/ |
D | core.c | 7993 static int sched_copy_attr(struct sched_attr __user *uattr, struct sched_attr *attr) in sched_copy_attr() argument 8001 ret = get_user(size, &uattr->size); in sched_copy_attr() 8011 ret = copy_struct_from_user(attr, sizeof(*attr), uattr, size); in sched_copy_attr() 8031 put_user(sizeof(*attr), &uattr->size); in sched_copy_attr() 8079 SYSCALL_DEFINE3(sched_setattr, pid_t, pid, struct sched_attr __user *, uattr, in SYSCALL_DEFINE3() argument 8086 if (!uattr || pid < 0 || flags) in SYSCALL_DEFINE3() 8089 retval = sched_copy_attr(uattr, &attr); in SYSCALL_DEFINE3() 8195 sched_attr_copy_to_user(struct sched_attr __user *uattr, in sched_attr_copy_to_user() argument 8201 if (!access_ok(uattr, usize)) in sched_attr_copy_to_user() 8219 if (copy_to_user(uattr, kattr, kattr->size)) in sched_attr_copy_to_user() [all …]
|
/linux-6.6.21/net/core/ |
D | sock_map.c | 1509 union bpf_attr __user *uattr) in sock_map_bpf_prog_query() argument 1550 if (copy_to_user(&uattr->query.attach_flags, &flags, sizeof(flags)) || in sock_map_bpf_prog_query() 1552 copy_to_user(&uattr->query.prog_cnt, &prog_cnt, sizeof(prog_cnt))) in sock_map_bpf_prog_query()
|