Home
last modified time | relevance | path

Searched refs:dev_fd (Results 1 – 7 of 7) sorted by relevance

/linux-6.1.9/tools/testing/selftests/nci/
Dnci_dev.c324 int dev_fd; in virtual_dev_open() local
327 dev_fd = *(int *)data; in virtual_dev_open()
329 len = read(dev_fd, buf, 258); in virtual_dev_open()
336 write(dev_fd, nci_reset_rsp, sizeof(nci_reset_rsp)); in virtual_dev_open()
338 len = read(dev_fd, buf, 258); in virtual_dev_open()
345 write(dev_fd, nci_init_rsp, sizeof(nci_init_rsp)); in virtual_dev_open()
347 len = read(dev_fd, buf, 258); in virtual_dev_open()
354 write(dev_fd, nci_rf_disc_map_rsp, sizeof(nci_rf_disc_map_rsp)); in virtual_dev_open()
364 int dev_fd; in virtual_dev_open_v2() local
367 dev_fd = *(int *)data; in virtual_dev_open_v2()
[all …]
/linux-6.1.9/tools/testing/selftests/kvm/include/
Dkvm_util_base.h527 int __kvm_has_device_attr(int dev_fd, uint32_t group, uint64_t attr);
529 static inline void kvm_has_device_attr(int dev_fd, uint32_t group, uint64_t attr) in kvm_has_device_attr() argument
531 int ret = __kvm_has_device_attr(dev_fd, group, attr); in kvm_has_device_attr()
536 int __kvm_device_attr_get(int dev_fd, uint32_t group, uint64_t attr, void *val);
538 static inline void kvm_device_attr_get(int dev_fd, uint32_t group, in kvm_device_attr_get() argument
541 int ret = __kvm_device_attr_get(dev_fd, group, attr, val); in kvm_device_attr_get()
546 int __kvm_device_attr_set(int dev_fd, uint32_t group, uint64_t attr, void *val);
548 static inline void kvm_device_attr_set(int dev_fd, uint32_t group, in kvm_device_attr_set() argument
551 int ret = __kvm_device_attr_set(dev_fd, group, attr, val); in kvm_device_attr_set()
/linux-6.1.9/Documentation/userspace-api/
Dvduse.rst113 static int vduse_message_handler(int dev_fd)
119 len = read(dev_fd, &req, sizeof(req));
131 len = write(dev_fd, &resp, sizeof(resp));
185 static void *iova_to_va(int dev_fd, uint64_t iova, uint64_t *len)
199 fd = ioctl(dev_fd, VDUSE_IOTLB_GET_FD, &entry);
/linux-6.1.9/tools/testing/selftests/kvm/lib/
Dkvm_util.c1075 int dev_fd, ret; in vcpu_mmap_sz() local
1077 dev_fd = open_kvm_dev_path_or_exit(); in vcpu_mmap_sz()
1079 ret = ioctl(dev_fd, KVM_GET_VCPU_MMAP_SIZE, NULL); in vcpu_mmap_sz()
1083 close(dev_fd); in vcpu_mmap_sz()
1540 int __kvm_has_device_attr(int dev_fd, uint32_t group, uint64_t attr) in __kvm_has_device_attr() argument
1548 return ioctl(dev_fd, KVM_HAS_DEVICE_ATTR, &attribute); in __kvm_has_device_attr()
1575 int __kvm_device_attr_get(int dev_fd, uint32_t group, uint64_t attr, void *val) in __kvm_device_attr_get() argument
1584 return __kvm_ioctl(dev_fd, KVM_GET_DEVICE_ATTR, &kvmattr); in __kvm_device_attr_get()
1587 int __kvm_device_attr_set(int dev_fd, uint32_t group, uint64_t attr, void *val) in __kvm_device_attr_set() argument
1596 return __kvm_ioctl(dev_fd, KVM_SET_DEVICE_ATTR, &kvmattr); in __kvm_device_attr_set()
/linux-6.1.9/Documentation/target/
Dtcmu-design.rst308 int fd, dev_fd;
331 dev_fd = open("/dev/uio0", O_RDWR);
332 map = mmap(NULL, map_len, PROT_READ|PROT_WRITE, MAP_SHARED, dev_fd, 0);
340 int ret = read(dev_fd, buf, 4); /* will block */
342 handle_device_events(dev_fd, map);
/linux-6.1.9/Documentation/x86/
Dresctrl.rst929 int dev_fd;
942 dev_fd = open("/dev/pseudo_lock/newlock", O_RDWR);
943 if (dev_fd < 0) {
949 dev_fd, 0);
952 close(dev_fd);
961 close(dev_fd);
965 close(dev_fd);
/linux-6.1.9/Documentation/virt/kvm/
Dapi.rst164 vm_fd = ioctl(dev_fd, KVM_CREATE_VM, KVM_VM_TYPE_ARM_IPA_SIZE(48));