/linux-6.6.21/drivers/misc/lkdtm/ |
D | usercopy.c | 91 if (copy_to_user((void __user *)user_addr, good_stack, in do_usercopy_stack() 98 if (copy_to_user((void __user *)user_addr, bad_stack, in do_usercopy_stack() 165 if (copy_to_user(test_user_addr, test_kern_addr, size / 2)) { in do_usercopy_slab_size() 171 if (copy_to_user(test_user_addr, test_kern_addr, size)) { in do_usercopy_slab_size() 242 if (copy_to_user(user_addr, buf + offset, size)) { in do_usercopy_slab_whitelist() 248 if (copy_to_user(user_addr, buf + offset - 1, size)) { in do_usercopy_slab_whitelist() 325 if (copy_to_user((void __user *)user_addr, test_text, in lkdtm_USERCOPY_KERNEL() 333 if (copy_to_user((void __user *)user_addr, vm_mmap, in lkdtm_USERCOPY_KERNEL() 370 if (copy_to_user((void __user *)uaddr, kaddr, in do_usercopy_page_span() 378 if (copy_to_user((void __user *)uaddr, kaddr, unconst + PAGE_SIZE)) { in do_usercopy_page_span()
|
/linux-6.6.21/drivers/accel/habanalabs/common/ |
D | habanalabs_ioctl.c | 42 return copy_to_user(out, &dev_stat, in device_status_info() 112 return copy_to_user(out, &hw_ip, in hw_ip_info() 132 return copy_to_user(out, arr, min(max_size, size)) ? -EFAULT : 0; in hw_events_info() 149 return copy_to_user(out, &events_mask, sizeof(u64)) ? -EFAULT : 0; in events_info() 172 return copy_to_user(out, &dram_usage, in dram_usage_info() 191 return copy_to_user(out, &hw_idle, in hw_idle() 244 if (output && copy_to_user((void __user *) (uintptr_t) args->output_ptr, in debug_coresight() 274 return copy_to_user(out, &device_util, in device_utilization() 292 return copy_to_user(out, &clk_rate, min_t(size_t, max_size, sizeof(clk_rate))) in get_clk_rate() 308 return copy_to_user(out, &reset_count, in get_reset_count() [all …]
|
/linux-6.6.21/drivers/media/v4l2-core/ |
D | v4l2-compat-ioctl32.c | 88 if (copy_to_user(p32, &w32, sizeof(w32))) in put_v4l2_window32() 187 return copy_to_user(&p32->fmt.pix, &p64->fmt.pix, in put_v4l2_format32() 191 return copy_to_user(&p32->fmt.pix_mp, &p64->fmt.pix_mp, in put_v4l2_format32() 198 return copy_to_user(&p32->fmt.vbi, &p64->fmt.vbi, in put_v4l2_format32() 202 return copy_to_user(&p32->fmt.sliced, &p64->fmt.sliced, in put_v4l2_format32() 206 return copy_to_user(&p32->fmt.sdr, &p64->fmt.sdr, in put_v4l2_format32() 210 return copy_to_user(&p32->fmt.meta, &p64->fmt.meta, in put_v4l2_format32() 220 if (copy_to_user(p32, p64, in put_v4l2_create32() 224 copy_to_user(p32->reserved, p64->reserved, sizeof(p64->reserved))) in put_v4l2_create32() 250 copy_to_user(p32->name, p64->name, sizeof(p32->name)) || in put_v4l2_standard32() [all …]
|
/linux-6.6.21/virt/kvm/ |
D | binary_stats.c | 87 if (copy_to_user(dest, src, copylen)) in kvm_stats_read() 107 if (copy_to_user(dest, src, copylen)) in kvm_stats_read() 125 if (copy_to_user(dest, src, copylen)) in kvm_stats_read() 137 if (copy_to_user(dest, src, copylen)) in kvm_stats_read()
|
/linux-6.6.21/sound/firewire/motu/ |
D | motu-hwdep.c | 54 if (copy_to_user(buf, &event, count)) in hwdep_read() 63 if (copy_to_user(buf, &event, count)) in hwdep_read() 86 if (copy_to_user(buf, &event, sizeof(event.motu_register_dsp_change))) in hwdep_read() 130 if (copy_to_user(arg, &info, sizeof(info))) in hwdep_get_info() 210 err = copy_to_user((void __user *)arg, meter, sizeof(*meter)); in hwdep_ioctl() 232 err = copy_to_user((void __user *)arg, meter, sizeof(*meter)); in hwdep_ioctl() 254 err = copy_to_user((void __user *)arg, param, sizeof(*param)); in hwdep_ioctl()
|
/linux-6.6.21/kernel/bpf/ |
D | log.c | 87 copy_to_user(log->ubuf + cur_pos, log->kbuf, new_n)) in bpf_verifier_vlog() 124 if (copy_to_user(log->ubuf + buf_start, in bpf_verifier_vlog() 130 if (copy_to_user(log->ubuf + buf_start, in bpf_verifier_vlog() 134 if (copy_to_user(log->ubuf, in bpf_verifier_vlog() 211 if (copy_to_user(log->ubuf + start, rbuf, nn)) in bpf_vlog_reverse_ubuf() 213 if (copy_to_user(log->ubuf + end - nn, lbuf, nn)) in bpf_vlog_reverse_ubuf()
|
D | mprog.c | 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() 436 if (copy_to_user(uprog_id + i, &id, sizeof(id))) in bpf_mprog_query() 439 copy_to_user(uprog_flags + i, &flags, sizeof(flags))) in bpf_mprog_query() 443 copy_to_user(ulink_id + i, &id, sizeof(id))) in bpf_mprog_query() 446 copy_to_user(ulink_flags + i, &flags, sizeof(flags))) in bpf_mprog_query()
|
/linux-6.6.21/net/ethtool/ |
D | ioctl.c | 107 if (copy_to_user(useraddr, &cmd, sizeof(cmd))) in ethtool_get_features() 110 if (copy_to_user(useraddr, features, in ethtool_get_features() 254 if (copy_to_user(useraddr, &edata, sizeof(edata))) in ethtool_get_one_feature() 510 if (copy_to_user(to, &link_usettings, sizeof(link_usettings))) in store_link_ksettings_for_user() 546 if (copy_to_user(useraddr, &link_ksettings.base, in ethtool_get_link_ksettings() 667 if (copy_to_user(useraddr, &cmd, sizeof(cmd))) in ethtool_get_settings() 809 if (copy_to_user(useraddr, &info, sizeof(info))) in ethtool_get_sset_info() 813 if (copy_to_user(useraddr, info_buf, array_size(idx, sizeof(u32)))) in ethtool_get_sset_info() 904 if (copy_to_user(useraddr, &crxnfc, min(size, sizeof(crxnfc)))) in ethtool_rxnfc_copy_to_compat() 953 ret = copy_to_user(useraddr, rxnfc, size); in ethtool_rxnfc_copy_to_user() [all …]
|
/linux-6.6.21/drivers/vfio/pci/ |
D | vfio_pci_igd.c | 54 if (copy_to_user(dst + (*off), src, bytes)) in igd_opregion_shift_copy() 142 copy_to_user(buf + off, opregionvbt->vbt_ex + (pos - OPREGION_SIZE), in vfio_pci_igd_rw() 303 if (copy_to_user(buf + count - size, &val, 1)) in vfio_pci_igd_cfg_rw() 319 if (copy_to_user(buf + count - size, &lval, 2)) in vfio_pci_igd_cfg_rw() 335 if (copy_to_user(buf + count - size, &lval, 4)) in vfio_pci_igd_cfg_rw() 351 if (copy_to_user(buf + count - size, &lval, 2)) in vfio_pci_igd_cfg_rw() 365 if (copy_to_user(buf + count - size, &val, 1)) in vfio_pci_igd_cfg_rw()
|
/linux-6.6.21/drivers/char/ |
D | uv_mmtimer.c | 106 if (copy_to_user((unsigned long __user *)arg, in uv_mmtimer_ioctl() 112 if (copy_to_user((unsigned long __user *)arg, in uv_mmtimer_ioctl() 127 if (copy_to_user((unsigned long __user *)arg, in uv_mmtimer_ioctl()
|
D | ppdev.c | 185 if (bytes_read > 0 && copy_to_user(buf, kbuffer, bytes_read)) in pp_read() 446 if (copy_to_user(argp, &mode, sizeof(mode))) in pp_do_ioctl() 473 if (copy_to_user(argp, &phase, sizeof(phase))) in pp_do_ioctl() 487 if (copy_to_user(argp, &modes, sizeof(modes))) in pp_do_ioctl() 506 if (copy_to_user(argp, &uflags, sizeof(uflags))) in pp_do_ioctl() 523 if (copy_to_user(argp, ®, sizeof(reg))) in pp_do_ioctl() 528 if (copy_to_user(argp, ®, sizeof(reg))) in pp_do_ioctl() 533 if (copy_to_user(argp, ®, sizeof(reg))) in pp_do_ioctl() 609 if (copy_to_user(argp, &ret, sizeof(ret))) in pp_do_ioctl() 640 if (copy_to_user(argp, time32, sizeof(time32))) in pp_do_ioctl() [all …]
|
/linux-6.6.21/drivers/gpu/drm/amd/amdgpu/ |
D | amdgpu_kms.c | 554 return copy_to_user(out, &ui32, min(size, 4u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 570 return copy_to_user(out, &ui32, min(size, 4u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 579 ret = copy_to_user(out, &ip, min_t(size_t, size, sizeof(ip))); in amdgpu_info_ioctl() 623 return copy_to_user(out, &count, min(size, 4u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 627 return copy_to_user(out, &ui64, min(size, 8u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 640 return copy_to_user(out, &fw_info, in amdgpu_info_ioctl() 645 return copy_to_user(out, &ui64, min(size, 8u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 648 return copy_to_user(out, &ui64, min(size, 8u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 651 return copy_to_user(out, &ui64, min(size, 8u)) ? -EFAULT : 0; in amdgpu_info_ioctl() 654 return copy_to_user(out, &ui64, min(size, 8u)) ? -EFAULT : 0; in amdgpu_info_ioctl() [all …]
|
/linux-6.6.21/drivers/input/ |
D | input-compat.c | 50 if (copy_to_user(buffer, &compat_event, in input_event_to_user() 55 if (copy_to_user(buffer, event, sizeof(struct input_event))) in input_event_to_user() 111 if (copy_to_user(buffer, event, sizeof(struct input_event))) in input_event_to_user()
|
/linux-6.6.21/sound/firewire/tascam/ |
D | tascam-hwdep.c | 32 if (copy_to_user(buf, &event, count)) in tscm_hwdep_read_locked() 78 if (copy_to_user(pos, &entries[head_pos], length)) in tscm_hwdep_read_queue() 92 if (copy_to_user(buf, &type, sizeof(type))) in tscm_hwdep_read_queue() 160 if (copy_to_user(arg, &info, sizeof(info))) in hwdep_get_info() 204 if (copy_to_user(arg, tscm->state, sizeof(tscm->state))) in tscm_hwdep_state()
|
/linux-6.6.21/drivers/misc/vmw_vmci/ |
D | vmci_host.c | 216 *retval = copy_to_user(user_buf_uva, in drv_cp_harray_to_user() 341 if (copy_to_user(uptr, &init_block, sizeof(init_block))) { in vmci_host_do_init_context() 413 return copy_to_user(uptr, &send_info, sizeof(send_info)) ? -EFAULT : 0; in vmci_host_do_send_datagram() 439 retval = copy_to_user(ubuf, dg, VMCI_DG_SIZE(dg)); in vmci_host_do_receive_datagram() 445 return copy_to_user(uptr, &recv_info, sizeof(recv_info)) ? -EFAULT : 0; in vmci_host_do_receive_datagram() 731 retval = copy_to_user(ubuf, cpt_buf, get_info.buf_size); in vmci_host_do_ctx_get_cpt_state() 738 return copy_to_user(uptr, &get_info, sizeof(get_info)) ? -EFAULT : 0; in vmci_host_do_ctx_get_cpt_state() 767 retval = copy_to_user(uptr, &set_info, sizeof(set_info)) ? -EFAULT : 0; in vmci_host_do_ctx_set_cpt_state() 805 return copy_to_user(uptr, ¬ify_info, sizeof(notify_info)) ? in vmci_host_do_set_notify() 856 return copy_to_user(uptr, &info, sizeof(info)) ? -EFAULT : 0; in vmci_host_do_notify_resource() [all …]
|
/linux-6.6.21/fs/xfs/ |
D | xfs_ioctl.c | 116 if (copy_to_user(hreq->ohandle, &handle, hsize) || in xfs_find_handle() 117 copy_to_user(hreq->ohandlen, &hsize, sizeof(__s32))) in xfs_find_handle() 433 if (copy_to_user(ubuf, buffer, bufsize) || in xfs_ioc_attr_list() 434 copy_to_user(ucursor, &context.cursor, sizeof(context.cursor))) in xfs_ioc_attr_list() 491 if (copy_to_user(ubuf, args.value, args.valuelen)) in xfs_attrmulti_attr_get() 622 if (copy_to_user(am_hreq.ops, ops, size)) in xfs_attrmulti_by_handle() 640 if (copy_to_user(breq->ubuffer, &bs1, sizeof(bs1))) in xfs_fsbulkstat_one_fmt() 653 if (copy_to_user(breq->ubuffer, &ig1, sizeof(struct xfs_inogrp))) in xfs_fsinumbers_fmt() 727 copy_to_user(bulkreq.lastip, &lastino, sizeof(xfs_ino_t))) in xfs_ioc_fsbulkstat() 731 copy_to_user(bulkreq.ocount, &breq.ocount, sizeof(__s32))) in xfs_ioc_fsbulkstat() [all …]
|
/linux-6.6.21/net/bluetooth/bnep/ |
D | sock.c | 85 if (copy_to_user(argp, &ca, sizeof(ca))) in do_bnep_sock_ioctl() 109 if (!err && copy_to_user(argp, &cl, sizeof(cl))) in do_bnep_sock_ioctl() 119 if (!err && copy_to_user(argp, &ci, sizeof(ci))) in do_bnep_sock_ioctl() 125 if (copy_to_user(argp, &supp_feat, sizeof(supp_feat))) in do_bnep_sock_ioctl()
|
/linux-6.6.21/arch/alpha/kernel/ |
D | osf_sys.c | 138 copy_to_user(dirent->d_name, name, namlen) || in osf_filldir() 300 return copy_to_user(osf_stat, &tmp, sizeof(tmp)) ? -EFAULT : 0; in linux_to_osf_stat() 321 return copy_to_user(osf_stat, &tmp_stat, bufsiz) ? -EFAULT : 0; in linux_to_osf_statfs() 341 return copy_to_user(osf_stat, &tmp_stat, bufsiz) ? -EFAULT : 0; in linux_to_osf_statfs64() 543 if (copy_to_user(name, tmp, sizeof(tmp))) in SYSCALL_DEFINE1() 577 if (copy_to_user(name, tmp, len)) in SYSCALL_DEFINE2() 757 if (copy_to_user(buf, tmp, len)) in SYSCALL_DEFINE3() 808 if (copy_to_user(buffer, hwrpb, nbytes) != 0) in SYSCALL_DEFINE5() 960 return copy_to_user(o, &(struct timeval32){ in put_tv32() 969 return copy_to_user(o, &(struct timeval32){ in put_tv_to_tv32() [all …]
|
/linux-6.6.21/arch/sparc/kernel/ |
D | sigutil_64.c | 23 err |= copy_to_user(&fpu->si_float_regs[0], fpregs, in save_fpu_state() 26 err |= copy_to_user(&fpu->si_float_regs[32], fpregs+16, in save_fpu_state() 67 err |= copy_to_user(&rwin->reg_window[i], rp, in save_rwin_state()
|
/linux-6.6.21/drivers/s390/char/ |
D | uvdevice.c | 77 if (copy_to_user(user_buf_arg, &uvdev_info, sizeof(uvdev_info))) in uvio_uvdev_info() 116 if (copy_to_user(user_buf_meas, measurement, uvio_attest->meas_len)) in uvio_copy_attest_result_to_user() 118 if (add_data && copy_to_user(user_buf_add, add_data, uvio_attest->add_data_len)) in uvio_copy_attest_result_to_user() 120 if (copy_to_user(user_buf_uid, uvcb_attest->config_uid, sizeof(uvcb_attest->config_uid))) in uvio_copy_attest_result_to_user() 337 if (copy_to_user(user_buf_arg, secrets, UVIO_LIST_SECRETS_LEN)) in uvio_list_secrets() 439 if (copy_to_user(argp, &uv_ioctl, sizeof(uv_ioctl))) in uvio_ioctl()
|
/linux-6.6.21/net/atm/ |
D | resources.c | 185 error = copy_to_user(arg, &tmp, sizeof(tmp)); in fetch_stats() 220 error = ((copy_to_user(buf, tmp_buf, size)) || in atm_getnames() 244 if (copy_to_user(buf, dev->type, size)) { in atm_dev_ioctl() 251 if (copy_to_user(buf, dev->esi, size)) { in atm_dev_ioctl() 297 if (copy_to_user(buf, &dev->ci_range, size)) { in atm_dev_ioctl() 304 if (copy_to_user(buf, &dev->link_rate, size)) { in atm_dev_ioctl()
|
/linux-6.6.21/lib/ |
D | test_user_copy.c | 87 ret |= test(copy_to_user(umem, kmem, size), in test_check_nonzero_user() 124 ret |= test(copy_to_user(umem, umem_src, size), in test_copy_struct_from_user() 214 ret |= test(copy_to_user(usermem, kmem, PAGE_SIZE), in test_user_copy_init() 280 ret |= test(!copy_to_user((char __user *)kmem, kmem + PAGE_SIZE, in test_user_copy_init() 283 ret |= test(!copy_to_user((char __user *)kmem, bad_usermem, in test_user_copy_init()
|
/linux-6.6.21/drivers/sbus/char/ |
D | envctrl.c | 555 if (copy_to_user(buf, data, ret)) in envctrl_read() 565 if (copy_to_user(buf, data, ret)) in envctrl_read() 573 if (copy_to_user(buf, data, ret)) in envctrl_read() 583 if (copy_to_user(buf, data, ret)) in envctrl_read() 593 if (copy_to_user(buf, data, ret)) in envctrl_read() 601 if (copy_to_user(buf, data, ret)) in envctrl_read() 609 if (copy_to_user(buf, data, ret)) in envctrl_read() 618 if (copy_to_user(buf, data, ret)) in envctrl_read() 627 if (copy_to_user(buf, data, ret)) in envctrl_read() 638 if (copy_to_user(buf, data, ret)) in envctrl_read()
|
/linux-6.6.21/sound/core/ |
D | control_compat.c | 40 if (copy_to_user(data32, &data, 4 * sizeof(u32))) in snd_ctl_elem_list_compat() 105 if (copy_to_user(&data32->id, &data->id, sizeof(data->id)) || in snd_ctl_elem_info_compat() 106 copy_to_user(&data32->type, &data->type, 3 * sizeof(u32))) in snd_ctl_elem_info_compat() 119 if (copy_to_user(&data32->value.integer64, in snd_ctl_elem_info_compat() 125 if (copy_to_user(&data32->value.enumerated, in snd_ctl_elem_info_compat() 281 if (copy_to_user(valuep, data->value.bytes.data, size)) in copy_ctl_value_to_user() 284 if (copy_to_user(&data32->id, &data->id, sizeof(data32->id))) in copy_ctl_value_to_user()
|
/linux-6.6.21/drivers/gpu/drm/ |
D | drm_ioc32.c | 122 if (copy_to_user((void __user *)arg, &v32, sizeof(v32))) in compat_drm_version() 154 if (copy_to_user((void __user *)arg, &uq32, sizeof(uq32))) in compat_drm_getunique() 198 if (copy_to_user(argp, &m32, sizeof(m32))) in compat_drm_getmap() 232 if (copy_to_user(argp, &m32, sizeof(m32))) in compat_drm_addmap() 287 if (copy_to_user(argp, &c32, sizeof(c32))) in compat_drm_getclient() 346 if (copy_to_user(argp, &desc32, sizeof(drm_buf_desc32_t))) in compat_drm_addbufs() 384 if (copy_to_user(to + count, &v, offsetof(drm_buf_desc32_t, flags))) in copy_one_buf32() 444 if (copy_to_user(to, &v, sizeof(v))) in map_one_buf32() 542 if (copy_to_user(argp, &req32, sizeof(req32))) in compat_drm_getsareactx() 571 if (copy_to_user(argp, &res32, sizeof(res32))) in compat_drm_resctx() [all …]
|