Home
last modified time | relevance | path

Searched refs:argp (Results 1 – 25 of 153) sorted by relevance

1234567

/drivers/staging/gasket/
Dgasket_ioctl.c28 struct gasket_interrupt_eventfd __user *argp) in gasket_set_event_fd() argument
32 if (copy_from_user(&die, argp, sizeof(struct gasket_interrupt_eventfd))) in gasket_set_event_fd()
43 struct gasket_page_table_ioctl __user *argp) in gasket_read_page_table_size() argument
48 if (copy_from_user(&ibuf, argp, sizeof(struct gasket_page_table_ioctl))) in gasket_read_page_table_size()
61 if (copy_to_user(argp, &ibuf, sizeof(ibuf))) in gasket_read_page_table_size()
69 struct gasket_page_table_ioctl __user *argp) in gasket_read_simple_page_table_size() argument
74 if (copy_from_user(&ibuf, argp, sizeof(struct gasket_page_table_ioctl))) in gasket_read_simple_page_table_size()
87 if (copy_to_user(argp, &ibuf, sizeof(ibuf))) in gasket_read_simple_page_table_size()
95 struct gasket_page_table_ioctl __user *argp) in gasket_partition_page_table() argument
101 if (copy_from_user(&ibuf, argp, sizeof(struct gasket_page_table_ioctl))) in gasket_partition_page_table()
[all …]
/drivers/sbus/char/
Dopenprom.c130 static int opromgetprop(void __user *argp, struct device_node *dp, struct openpromio *op, int bufsi… in opromgetprop() argument
138 return copyout(argp, op, sizeof(int)); in opromgetprop()
144 return copyout(argp, op, sizeof(int) + bufsize); in opromgetprop()
147 static int opromnxtprop(void __user *argp, struct device_node *dp, struct openpromio *op, int bufsi… in opromnxtprop() argument
153 return copyout(argp, op, sizeof(int)); in opromnxtprop()
157 return copyout(argp, op, sizeof(int)); in opromnxtprop()
165 return copyout(argp, op, sizeof(int)); in opromnxtprop()
174 return copyout(argp, op, sizeof(int) + bufsize); in opromnxtprop()
185 static int opromnext(void __user *argp, unsigned int cmd, struct device_node *dp, struct openpromio… in opromnext() argument
229 return copyout(argp, op, bufsize + sizeof(int)); in opromnext()
[all …]
/drivers/gpu/drm/
Ddrm_ioc32.c180 drm_map32_t __user *argp = (void __user *)arg; in compat_drm_getmap() local
185 if (copy_from_user(&m32, argp, sizeof(m32))) in compat_drm_getmap()
199 if (copy_to_user(argp, &m32, sizeof(m32))) in compat_drm_getmap()
208 drm_map32_t __user *argp = (void __user *)arg; in compat_drm_addmap() local
213 if (copy_from_user(&m32, argp, sizeof(m32))) in compat_drm_addmap()
233 if (copy_to_user(argp, &m32, sizeof(m32))) in compat_drm_addmap()
242 drm_map32_t __user *argp = (void __user *)arg; in compat_drm_rmmap() local
246 if (get_user(handle, &argp->handle)) in compat_drm_rmmap()
266 drm_client32_t __user *argp = (void __user *)arg; in compat_drm_getclient() local
270 if (copy_from_user(&c32, argp, sizeof(c32))) in compat_drm_getclient()
[all …]
/drivers/s390/block/
Ddasd_ioctl.c34 dasd_ioctl_api_version(void __user *argp) in dasd_ioctl_api_version() argument
37 return put_user(ver, (int __user *)argp); in dasd_ioctl_api_version()
259 dasd_ioctl_format(struct block_device *bdev, void __user *argp) in dasd_ioctl_format() argument
267 if (!argp) in dasd_ioctl_format()
277 if (copy_from_user(&fdata, argp, sizeof(struct format_data_t))) { in dasd_ioctl_format()
296 static int dasd_ioctl_check_format(struct block_device *bdev, void __user *argp) in dasd_ioctl_check_format() argument
302 if (!argp) in dasd_ioctl_check_format()
315 if (copy_from_user(&cdata, argp, sizeof(cdata))) { in dasd_ioctl_check_format()
324 if (copy_to_user(argp, &cdata, sizeof(cdata))) in dasd_ioctl_check_format()
347 static int dasd_ioctl_release_space(struct block_device *bdev, void __user *argp) in dasd_ioctl_release_space() argument
[all …]
/drivers/ide/
Dide-floppy_ioctl.c44 int __user *argp; in ide_floppy_get_format_capacities() local
64 argp = arg + 1; in ide_floppy_get_format_capacities()
80 if (put_user(blocks, argp)) in ide_floppy_get_format_capacities()
83 ++argp; in ide_floppy_get_format_capacities()
85 if (put_user(length, argp)) in ide_floppy_get_format_capacities()
88 ++argp; in ide_floppy_get_format_capacities()
257 void __user *argp) in ide_floppy_format_ioctl() argument
263 return ide_floppy_get_format_capacities(drive, pc, argp); in ide_floppy_format_ioctl()
267 return ide_floppy_format_unit(drive, pc, (int __user *)argp); in ide_floppy_format_ioctl()
269 return ide_floppy_get_format_progress(drive, pc, argp); in ide_floppy_format_ioctl()
[all …]
Dide-ioctls.c68 void __user *argp) in ide_get_identity_ioctl() argument
89 if (copy_to_user(argp, id, size)) in ide_get_identity_ioctl()
127 static int ide_cmd_ioctl(ide_drive_t *drive, void __user *argp) in ide_cmd_ioctl() argument
135 if (NULL == argp) { in ide_cmd_ioctl()
147 if (copy_from_user(args, argp, 4)) in ide_cmd_ioctl()
193 if (copy_to_user(argp, &args, 4)) in ide_cmd_ioctl()
196 if (copy_to_user((argp + 4), buf, bufsize)) in ide_cmd_ioctl()
248 void __user *argp = (void __user *)arg; in generic_ide_ioctl() local
251 argp = compat_ptr(arg); in generic_ide_ioctl()
262 return ide_get_identity_ioctl(drive, cmd, argp); in generic_ide_ioctl()
[all …]
/drivers/crypto/ccp/
Dsev-dev.c353 static int sev_ioctl_do_reset(struct sev_issue_cmd *argp, bool writable) in sev_ioctl_do_reset() argument
369 rc = sev_get_platform_state(&state, &argp->error); in sev_ioctl_do_reset()
377 rc = __sev_platform_shutdown_locked(&argp->error); in sev_ioctl_do_reset()
382 return __sev_do_cmd_locked(SEV_CMD_FACTORY_RESET, NULL, &argp->error); in sev_ioctl_do_reset()
385 static int sev_ioctl_do_platform_status(struct sev_issue_cmd *argp) in sev_ioctl_do_platform_status() argument
392 ret = __sev_do_cmd_locked(SEV_CMD_PLATFORM_STATUS, &data, &argp->error); in sev_ioctl_do_platform_status()
396 if (copy_to_user((void __user *)argp->data, &data, sizeof(data))) in sev_ioctl_do_platform_status()
402 static int sev_ioctl_do_pek_pdh_gen(int cmd, struct sev_issue_cmd *argp, bool writable) in sev_ioctl_do_pek_pdh_gen() argument
411 rc = __sev_platform_init_locked(&argp->error); in sev_ioctl_do_pek_pdh_gen()
416 return __sev_do_cmd_locked(cmd, NULL, &argp->error); in sev_ioctl_do_pek_pdh_gen()
[all …]
/drivers/mtd/
Dmtdchar.c585 struct mtd_write_req __user *argp) in mtdchar_write_ioctl() argument
593 if (copy_from_user(&req, argp, sizeof(req))) in mtdchar_write_ioctl()
637 void __user *argp = (void __user *)arg; in mtdchar_ioctl() local
687 if (copy_to_user(argp, &(mtd->numeraseregions), sizeof(int))) in mtdchar_ioctl()
695 struct region_info_user __user *ur = argp; in mtdchar_ioctl()
723 if (copy_to_user(argp, &info, sizeof(struct mtd_info_user))) in mtdchar_ioctl()
739 if (copy_from_user(&einfo64, argp, in mtdchar_ioctl()
749 if (copy_from_user(&einfo32, argp, in mtdchar_ioctl()
767 struct mtd_oob_buf __user *buf_user = argp; in mtdchar_ioctl()
770 if (copy_from_user(&buf, argp, sizeof(buf))) in mtdchar_ioctl()
[all …]
/drivers/video/fbdev/
Dsbuslib.c197 struct fbcmap32 __user *argp = (void __user *)arg; in fbiogetputcmap() local
202 ret = copy_in_user(p, argp, 2 * sizeof(int)); in fbiogetputcmap()
203 ret |= get_user(addr, &argp->red); in fbiogetputcmap()
205 ret |= get_user(addr, &argp->green); in fbiogetputcmap()
207 ret |= get_user(addr, &argp->blue); in fbiogetputcmap()
220 struct fbcursor32 __user *argp = (void __user *)arg; in fbiogscursor() local
224 ret = copy_in_user(p, argp, in fbiogscursor()
226 ret |= copy_in_user(&p->size, &argp->size, sizeof(struct fbcurpos)); in fbiogscursor()
227 ret |= copy_in_user(&p->cmap, &argp->cmap, 2 * sizeof(int)); in fbiogscursor()
228 ret |= get_user(addr, &argp->cmap.red); in fbiogscursor()
[all …]
/drivers/char/
Dppdev.c357 void __user *argp = (void __user *)arg; in pp_do_ioctl() local
424 if (copy_from_user(&mode, argp, sizeof(mode))) in pp_do_ioctl()
446 if (copy_to_user(argp, &mode, sizeof(mode))) in pp_do_ioctl()
454 if (copy_from_user(&phase, argp, sizeof(phase))) 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()
495 if (copy_from_user(&uflags, argp, sizeof(uflags))) in pp_do_ioctl()
506 if (copy_to_user(argp, &uflags, sizeof(uflags))) in pp_do_ioctl()
523 if (copy_to_user(argp, &reg, sizeof(reg))) in pp_do_ioctl()
528 if (copy_to_user(argp, &reg, sizeof(reg))) in pp_do_ioctl()
[all …]
/drivers/input/
Djoydev.c446 void __user *argp, size_t len) in joydev_handle_JSIOCSAXMAP() argument
455 abspam = memdup_user(argp, len); in joydev_handle_JSIOCSAXMAP()
477 void __user *argp, size_t len) in joydev_handle_JSIOCSBTNMAP() argument
489 keypam = memdup_user(argp, len); in joydev_handle_JSIOCSBTNMAP()
512 unsigned int cmd, void __user *argp) in joydev_ioctl_common() argument
523 return copy_from_user(&joydev->glue.JS_CORR, argp, in joydev_ioctl_common()
527 return copy_to_user(argp, &joydev->glue.JS_CORR, in joydev_ioctl_common()
531 return get_user(joydev->glue.JS_TIMEOUT, (s32 __user *) argp); in joydev_ioctl_common()
534 return put_user(joydev->glue.JS_TIMEOUT, (s32 __user *) argp); in joydev_ioctl_common()
537 return put_user(JS_VERSION, (__u32 __user *) argp); in joydev_ioctl_common()
[all …]
/drivers/vhost/
Dvdpa.c130 static long vhost_vdpa_get_device_id(struct vhost_vdpa *v, u8 __user *argp) in vhost_vdpa_get_device_id() argument
138 if (copy_to_user(argp, &device_id, sizeof(device_id))) in vhost_vdpa_get_device_id()
302 static long vhost_vdpa_get_vring_num(struct vhost_vdpa *v, u16 __user *argp) in vhost_vdpa_get_vring_num() argument
310 if (copy_to_user(argp, &num, sizeof(num))) in vhost_vdpa_get_vring_num()
324 static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp) in vhost_vdpa_set_config_call() argument
332 if (copy_from_user(&fd, argp, sizeof(fd))) in vhost_vdpa_set_config_call()
353 static long vhost_vdpa_get_iova_range(struct vhost_vdpa *v, u32 __user *argp) in vhost_vdpa_get_iova_range() argument
360 if (copy_to_user(argp, &range, sizeof(range))) in vhost_vdpa_get_iova_range()
366 void __user *argp) in vhost_vdpa_vring_ioctl() argument
377 r = get_user(idx, (u32 __user *)argp); in vhost_vdpa_vring_ioctl()
[all …]
/drivers/watchdog/
Dwdrtas.c275 int __user *argp = (void __user *)arg; in wdrtas_ioctl() local
285 if (copy_to_user(argp, &wdinfo, sizeof(wdinfo))) in wdrtas_ioctl()
291 return put_user(i, argp); in wdrtas_ioctl()
295 return put_user(i, argp); in wdrtas_ioctl()
302 return put_user(i, argp); in wdrtas_ioctl()
305 if (get_user(i, argp)) in wdrtas_ioctl()
323 if (get_user(i, argp)) in wdrtas_ioctl()
338 return put_user(wdrtas_interval, argp); in wdrtas_ioctl()
Driowd.c96 void __user *argp = (void __user *)arg; in riowd_ioctl() local
103 if (copy_to_user(argp, &info, sizeof(info))) in riowd_ioctl()
109 if (put_user(0, (int __user *)argp)) in riowd_ioctl()
118 if (copy_from_user(&options, argp, sizeof(options))) in riowd_ioctl()
131 if (get_user(new_margin, (int __user *)argp)) in riowd_ioctl()
140 return put_user(riowd_timeout * 60, (int __user *)argp); in riowd_ioctl()
Dsbc_epx_c3.c105 int __user *argp = (void __user *)arg; in epx_c3_ioctl() local
114 if (copy_to_user(argp, &ident, sizeof(ident))) in epx_c3_ioctl()
119 return put_user(0, argp); in epx_c3_ioctl()
121 if (get_user(options, argp)) in epx_c3_ioctl()
139 return put_user(WATCHDOG_TIMEOUT, argp); in epx_c3_ioctl()
Dgef_wdt.c163 void __user *argp = (void __user *)arg; in gef_wdt_ioctl() local
173 if (copy_to_user(argp, &info, sizeof(info))) in gef_wdt_ioctl()
179 if (put_user(wdt_status, (int __user *)argp)) in gef_wdt_ioctl()
185 if (get_user(options, (int __user *)argp)) in gef_wdt_ioctl()
201 if (get_user(timeout, (int __user *)argp)) in gef_wdt_ioctl()
207 if (put_user(gef_wdt_timeout, (int __user *)argp)) in gef_wdt_ioctl()
Drc32434_wdt.c191 void __user *argp = (void __user *)arg; in rc32434_wdt_ioctl() local
202 if (copy_to_user(argp, &ident, sizeof(ident))) in rc32434_wdt_ioctl()
208 if (copy_to_user(argp, &value, sizeof(int))) in rc32434_wdt_ioctl()
212 if (copy_from_user(&value, argp, sizeof(int))) in rc32434_wdt_ioctl()
229 if (copy_from_user(&new_timeout, argp, sizeof(int))) in rc32434_wdt_ioctl()
235 return copy_to_user(argp, &timeout, sizeof(int)) ? -EFAULT : 0; in rc32434_wdt_ioctl()
Dmv64x60_wdt.c180 void __user *argp = (void __user *)arg; in mv64x60_wdt_ioctl() local
191 if (copy_to_user(argp, &info, sizeof(info))) in mv64x60_wdt_ioctl()
197 if (put_user(wdt_status, (int __user *)argp)) in mv64x60_wdt_ioctl()
206 if (get_user(options, (int __user *)argp)) in mv64x60_wdt_ioctl()
222 if (get_user(timeout, (int __user *)argp)) in mv64x60_wdt_ioctl()
228 if (put_user(mv64x60_wdt_timeout, (int __user *)argp)) in mv64x60_wdt_ioctl()
Diop_wdt.c128 int __user *argp = (int __user *)arg; in iop_wdt_ioctl() local
132 if (copy_to_user(argp, &ident, sizeof(ident))) in iop_wdt_ioctl()
139 ret = put_user(0, argp); in iop_wdt_ioctl()
143 ret = put_user(boot_status, argp); in iop_wdt_ioctl()
172 ret = put_user(iop_watchdog_timeout(), argp); in iop_wdt_ioctl()
/drivers/fsi/
Dfsi-scom.c445 static int scom_raw_read(struct scom_device *scom, void __user *argp) in scom_raw_read() argument
451 if (copy_from_user(&acc, argp, sizeof(struct scom_access))) in scom_raw_read()
458 if (copy_to_user(argp, &acc, sizeof(struct scom_access))) in scom_raw_read()
463 static int scom_raw_write(struct scom_device *scom, void __user *argp) in scom_raw_write() argument
470 if (copy_from_user(&acc, argp, sizeof(struct scom_access))) in scom_raw_write()
489 if (copy_to_user(argp, &acc, sizeof(struct scom_access))) in scom_raw_write()
494 static int scom_reset(struct scom_device *scom, void __user *argp) in scom_reset() argument
499 if (get_user(flags, (__u32 __user *)argp)) in scom_reset()
510 static int scom_check(struct scom_device *scom, void __user *argp) in scom_check() argument
513 return put_user(SCOM_CHECK_SUPPORTED, (__u32 __user *)argp); in scom_check()
[all …]
/drivers/mtd/ubi/
Dcdev.c385 void __user *argp = (void __user *)arg; in vol_cdev_ioctl() local
398 err = copy_from_user(&bytes, argp, sizeof(int64_t)); in vol_cdev_ioctl()
433 err = copy_from_user(&req, argp, in vol_cdev_ioctl()
467 err = get_user(lnum, (__user int32_t *)argp); in vol_cdev_ioctl()
498 err = copy_from_user(&req, argp, sizeof(struct ubi_map_req)); in vol_cdev_ioctl()
512 err = get_user(lnum, (__user int32_t *)argp); in vol_cdev_ioctl()
526 err = get_user(lnum, (__user int32_t *)argp); in vol_cdev_ioctl()
540 err = copy_from_user(&req, argp, in vol_cdev_ioctl()
837 void __user *argp = (void __user *)arg; in ubi_cdev_ioctl() local
853 err = copy_from_user(&req, argp, sizeof(struct ubi_mkvol_req)); in ubi_cdev_ioctl()
[all …]
/drivers/platform/x86/intel_speed_select_if/
Disst_if_common.c264 static int isst_if_get_platform_info(void __user *argp) in isst_if_get_platform_info() argument
274 if (copy_to_user(argp, &info, sizeof(info))) in isst_if_get_platform_info()
442 static long isst_if_exec_multi_cmd(void __user *argp, struct isst_if_cmd_cb *cb) in isst_if_exec_multi_cmd() argument
451 if (copy_from_user(&cmd_count, argp, sizeof(cmd_count))) in isst_if_exec_multi_cmd()
462 ptr = argp + cb->offset; in isst_if_exec_multi_cmd()
497 void __user *argp = (void __user *)arg; in isst_if_def_ioctl() local
504 ret = isst_if_get_platform_info(argp); in isst_if_def_ioctl()
510 ret = isst_if_exec_multi_cmd(argp, &cmd_cb); in isst_if_def_ioctl()
515 ret = isst_if_exec_multi_cmd(argp, cb); in isst_if_def_ioctl()
520 ret = isst_if_exec_multi_cmd(argp, cb); in isst_if_def_ioctl()
[all …]
/drivers/s390/char/
Dsclp_ctl.c96 void __user *argp; in sclp_ctl_ioctl() local
99 argp = compat_ptr(arg); in sclp_ctl_ioctl()
101 argp = (void __user *) arg; in sclp_ctl_ioctl()
104 return sclp_ctl_ioctl_sccb(argp); in sclp_ctl_ioctl()
Dvmcp.c204 int __user *argp; in vmcp_ioctl() local
208 argp = compat_ptr(arg); in vmcp_ioctl()
210 argp = (int __user *)arg; in vmcp_ioctl()
215 ret = put_user(session->resp_code, argp); in vmcp_ioctl()
219 ret = get_user(session->bufsize, argp); in vmcp_ioctl()
228 ret = put_user(session->resp_size, argp); in vmcp_ioctl()
Dkeyboard.c480 void __user *argp; in kbd_ioctl() local
484 argp = (void __user *)arg; in kbd_ioctl()
496 return put_user(KB_101, (char __user *)argp); in kbd_ioctl()
499 return do_kdsk_ioctl(kbd, argp, cmd, perm); in kbd_ioctl()
502 return do_kdgkb_ioctl(kbd, argp, cmd, perm); in kbd_ioctl()
505 struct kbdiacrs __user *a = argp; in kbd_ioctl()
522 struct kbdiacrsuc __user *a = argp; in kbd_ioctl()
534 struct kbdiacrs __user *a = argp; in kbd_ioctl()
556 struct kbdiacrsuc __user *a = argp; in kbd_ioctl()

1234567