Home
last modified time | relevance | path

Searched refs:vdev (Results 1 – 25 of 82) sorted by relevance

1234

/linux-4.19.296/include/linux/
Dvirtio_config.h67 void (*get)(struct virtio_device *vdev, unsigned offset,
69 void (*set)(struct virtio_device *vdev, unsigned offset,
71 u32 (*generation)(struct virtio_device *vdev);
72 u8 (*get_status)(struct virtio_device *vdev);
73 void (*set_status)(struct virtio_device *vdev, u8 status);
74 void (*reset)(struct virtio_device *vdev);
80 u64 (*get_features)(struct virtio_device *vdev);
81 int (*finalize_features)(struct virtio_device *vdev);
82 const char *(*bus_name)(struct virtio_device *vdev);
85 const struct cpumask *(*get_vq_affinity)(struct virtio_device *vdev,
[all …]
/linux-4.19.296/drivers/media/v4l2-core/
Dv4l2-dev.c52 struct video_device *vdev = to_video_device(cd); in index_show() local
54 return sprintf(buf, "%i\n", vdev->index); in index_show()
61 struct video_device *vdev = to_video_device(cd); in dev_debug_show() local
63 return sprintf(buf, "%i\n", vdev->dev_debug); in dev_debug_show()
69 struct video_device *vdev = to_video_device(cd); in dev_debug_store() local
77 vdev->dev_debug = value; in dev_debug_store()
85 struct video_device *vdev = to_video_device(cd); in name_show() local
87 return sprintf(buf, "%.*s\n", (int)sizeof(vdev->name), vdev->name); in name_show()
131 static inline void devnode_set(struct video_device *vdev) in devnode_set() argument
133 set_bit(vdev->num, devnode_bits(vdev->vfl_type)); in devnode_set()
[all …]
Dv4l2-fh.c29 void v4l2_fh_init(struct v4l2_fh *fh, struct video_device *vdev) in v4l2_fh_init() argument
31 fh->vdev = vdev; in v4l2_fh_init()
33 fh->ctrl_handler = vdev->ctrl_handler; in v4l2_fh_init()
35 set_bit(V4L2_FL_USES_V4L2_FH, &fh->vdev->flags); in v4l2_fh_init()
41 set_bit(_IOC_NR(VIDIOC_G_PRIORITY), vdev->valid_ioctls); in v4l2_fh_init()
42 set_bit(_IOC_NR(VIDIOC_S_PRIORITY), vdev->valid_ioctls); in v4l2_fh_init()
56 v4l2_prio_open(fh->vdev->prio, &fh->prio); in v4l2_fh_add()
57 spin_lock_irqsave(&fh->vdev->fh_lock, flags); in v4l2_fh_add()
58 list_add(&fh->list, &fh->vdev->fh_list); in v4l2_fh_add()
59 spin_unlock_irqrestore(&fh->vdev->fh_lock, flags); in v4l2_fh_add()
[all …]
Dv4l2-device.c218 static void v4l2_device_release_subdev_node(struct video_device *vdev) in v4l2_device_release_subdev_node() argument
220 struct v4l2_subdev *sd = video_get_drvdata(vdev); in v4l2_device_release_subdev_node()
222 kfree(vdev); in v4l2_device_release_subdev_node()
227 struct video_device *vdev; in v4l2_device_register_subdev_nodes() local
241 vdev = kzalloc(sizeof(*vdev), GFP_KERNEL); in v4l2_device_register_subdev_nodes()
242 if (!vdev) { in v4l2_device_register_subdev_nodes()
247 video_set_drvdata(vdev, sd); in v4l2_device_register_subdev_nodes()
248 strlcpy(vdev->name, sd->name, sizeof(vdev->name)); in v4l2_device_register_subdev_nodes()
249 vdev->v4l2_dev = v4l2_dev; in v4l2_device_register_subdev_nodes()
250 vdev->fops = &v4l2_subdev_fops; in v4l2_device_register_subdev_nodes()
[all …]
Dv4l2-event.c40 spin_lock_irqsave(&fh->vdev->fh_lock, flags); in __v4l2_event_dequeue()
43 spin_unlock_irqrestore(&fh->vdev->fh_lock, flags); in __v4l2_event_dequeue()
58 spin_unlock_irqrestore(&fh->vdev->fh_lock, flags); in __v4l2_event_dequeue()
72 if (fh->vdev->lock) in v4l2_event_dequeue()
73 mutex_unlock(fh->vdev->lock); in v4l2_event_dequeue()
84 if (fh->vdev->lock) in v4l2_event_dequeue()
85 mutex_lock(fh->vdev->lock); in v4l2_event_dequeue()
97 assert_spin_locked(&fh->vdev->fh_lock); in v4l2_event_subscribed()
157 void v4l2_event_queue(struct video_device *vdev, const struct v4l2_event *ev) in v4l2_event_queue() argument
163 if (vdev == NULL) in v4l2_event_queue()
[all …]
/linux-4.19.296/drivers/misc/mic/vop/
Dvop_vringh.c32 static inline struct device *vop_dev(struct vop_vdev *vdev) in vop_dev() argument
34 return vdev->vpdev->dev.parent; in vop_dev()
38 static inline int vop_vdev_inited(struct vop_vdev *vdev) in vop_vdev_inited() argument
40 if (!vdev) in vop_vdev_inited()
43 if (!vdev->dd || !vdev->dd->type) { in vop_vdev_inited()
44 dev_err(vop_dev(vdev), "%s %d err %d\n", in vop_vdev_inited()
49 if (vdev->dd->type == -1) { in vop_vdev_inited()
50 dev_dbg(vop_dev(vdev), "%s %d err %d\n", in vop_vdev_inited()
60 struct vop_vdev *vdev = vvrh->vdev; in _vop_notify() local
61 struct vop_device *vpdev = vdev->vpdev; in _vop_notify()
[all …]
Dvop_main.c59 struct virtio_device vdev; member
73 #define to_vopvdev(vd) container_of(vd, struct _vop_vdev, vdev)
78 static inline struct device *_vop_dev(struct _vop_vdev *vdev) in _vop_dev() argument
80 return vdev->vdev.dev.parent; in _vop_dev()
116 static u64 vop_get_features(struct virtio_device *vdev) in vop_get_features() argument
120 struct mic_device_desc __iomem *desc = to_vopvdev(vdev)->desc; in vop_get_features()
124 bits = min_t(unsigned, feature_len, sizeof(vdev->features)) * 8; in vop_get_features()
132 static int vop_finalize_features(struct virtio_device *vdev) in vop_finalize_features() argument
135 struct mic_device_desc __iomem *desc = to_vopvdev(vdev)->desc; in vop_finalize_features()
142 vring_transport_features(vdev); in vop_finalize_features()
[all …]
/linux-4.19.296/include/media/
Dv4l2-dev.h289 void (*release)(struct video_device *vdev);
342 int __must_check __video_register_device(struct video_device *vdev,
364 static inline int __must_check video_register_device(struct video_device *vdev, in video_register_device() argument
368 return __video_register_device(vdev, type, nr, 1, vdev->fops->owner); in video_register_device()
392 video_register_device_no_warn(struct video_device *vdev, in video_register_device_no_warn() argument
395 return __video_register_device(vdev, type, nr, 0, vdev->fops->owner); in video_register_device_no_warn()
405 void video_unregister_device(struct video_device *vdev);
421 void video_device_release(struct video_device *vdev);
436 void video_device_release_empty(struct video_device *vdev);
453 static inline void v4l2_disable_ioctl(struct video_device *vdev, in v4l2_disable_ioctl() argument
[all …]
/linux-4.19.296/drivers/misc/mic/bus/
Dvop_bus.c150 struct vop_device *vdev; in vop_register_device() local
152 vdev = kzalloc(sizeof(*vdev), GFP_KERNEL); in vop_register_device()
153 if (!vdev) in vop_register_device()
156 vdev->dev.parent = pdev; in vop_register_device()
157 vdev->id.device = id; in vop_register_device()
158 vdev->id.vendor = VOP_DEV_ANY_ID; in vop_register_device()
159 vdev->dev.dma_ops = dma_ops; in vop_register_device()
160 vdev->dev.dma_mask = &vdev->dev.coherent_dma_mask; in vop_register_device()
161 dma_set_mask(&vdev->dev, DMA_BIT_MASK(64)); in vop_register_device()
162 vdev->dev.release = vop_release_dev; in vop_register_device()
[all …]
/linux-4.19.296/drivers/virtio/
Dvirtio_input.c10 struct virtio_device *vdev; member
32 struct virtio_input *vi = vq->vdev->priv; in virtinput_recv_events()
90 struct virtio_input *vi = vq->vdev->priv; in virtinput_recv_status()
114 virtio_cwrite(vi->vdev, struct virtio_input_config, select, &select); in virtinput_cfg_select()
115 virtio_cwrite(vi->vdev, struct virtio_input_config, subsel, &subsel); in virtinput_cfg_select()
116 virtio_cread(vi->vdev, struct virtio_input_config, size, &size); in virtinput_cfg_select()
141 virtio_cread_bytes(vi->vdev, offsetof(struct virtio_input_config, in virtinput_cfg_bits()
159 virtio_cread(vi->vdev, struct virtio_input_config, u.abs.min, &mi); in virtinput_cfg_abs()
160 virtio_cread(vi->vdev, struct virtio_input_config, u.abs.max, &ma); in virtinput_cfg_abs()
161 virtio_cread(vi->vdev, struct virtio_input_config, u.abs.res, &re); in virtinput_cfg_abs()
[all …]
Dvirtio_mmio.c86 container_of(_plat_dev, struct virtio_mmio_device, vdev)
89 struct virtio_device vdev; member
112 static u64 vm_get_features(struct virtio_device *vdev) in vm_get_features() argument
114 struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vdev); in vm_get_features()
127 static int vm_finalize_features(struct virtio_device *vdev) in vm_finalize_features() argument
129 struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vdev); in vm_finalize_features()
132 vring_transport_features(vdev); in vm_finalize_features()
136 !__virtio_test_bit(vdev, VIRTIO_F_VERSION_1)) { in vm_finalize_features()
137 …dev_err(&vdev->dev, "New virtio-mmio devices (version 2) must provide VIRTIO_F_VERSION_1 feature!\… in vm_finalize_features()
142 writel((u32)(vdev->features >> 32), in vm_finalize_features()
[all …]
Dvirtio_pci_common.c31 void vp_synchronize_vectors(struct virtio_device *vdev) in vp_synchronize_vectors() argument
33 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_synchronize_vectors()
57 virtio_config_changed(&vp_dev->vdev); in vp_config_changed()
105 static int vp_request_msix_vectors(struct virtio_device *vdev, int nvectors, in vp_request_msix_vectors() argument
108 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_request_msix_vectors()
109 const char *name = dev_name(&vp_dev->vdev.dev); in vp_request_msix_vectors()
177 static struct virtqueue *vp_setup_vq(struct virtio_device *vdev, unsigned index, in vp_setup_vq() argument
183 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_setup_vq()
216 struct virtio_pci_device *vp_dev = to_vp_device(vq->vdev); in vp_del_vq()
229 void vp_del_vqs(struct virtio_device *vdev) in vp_del_vqs() argument
[all …]
Dvirtio_pci_legacy.c23 static u64 vp_get_features(struct virtio_device *vdev) in vp_get_features() argument
25 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get_features()
33 static int vp_finalize_features(struct virtio_device *vdev) in vp_finalize_features() argument
35 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_finalize_features()
38 vring_transport_features(vdev); in vp_finalize_features()
41 BUG_ON((u32)vdev->features != vdev->features); in vp_finalize_features()
44 iowrite32(vdev->features, vp_dev->ioaddr + VIRTIO_PCI_GUEST_FEATURES); in vp_finalize_features()
50 static void vp_get(struct virtio_device *vdev, unsigned offset, in vp_get() argument
53 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get()
65 static void vp_set(struct virtio_device *vdev, unsigned offset, in vp_set() argument
[all …]
Dvirtio_balloon.c49 struct virtio_device *vdev; member
103 struct virtio_balloon *vb = vq->vdev->priv; in balloon_ack()
136 pfns[i] = cpu_to_virtio32(vb->vdev, in set_page_pfns()
155 dev_info_ratelimited(&vb->vdev->dev, in fill_balloon()
175 if (!virtio_has_feature(vb->vdev, in fill_balloon()
196 if (!virtio_has_feature(vb->vdev, in release_pages_balloon()
244 vb->stats[idx].tag = cpu_to_virtio16(vb->vdev, tag); in update_stat()
245 vb->stats[idx].val = cpu_to_virtio64(vb->vdev, val); in update_stat()
301 struct virtio_balloon *vb = vq->vdev->priv; in stats_request()
325 static void virtballoon_changed(struct virtio_device *vdev) in virtballoon_changed() argument
[all …]
Dvirtio_ring.c33 dev_err(&(_vq)->vq.vdev->dev, \
50 dev_err(&_vq->vq.vdev->dev, \
144 static bool vring_use_dma_api(struct virtio_device *vdev) in vring_use_dma_api() argument
146 if (!virtio_has_iommu_quirk(vdev)) in vring_use_dma_api()
171 return vq->vq.vdev->dev.parent; in vring_dma_dev()
179 if (!vring_use_dma_api(vq->vq.vdev)) in vring_map_one_sg()
196 if (!vring_use_dma_api(vq->vq.vdev)) in vring_map_single()
208 if (!vring_use_dma_api(vq->vq.vdev)) in vring_unmap_one()
211 flags = virtio16_to_cpu(vq->vq.vdev, desc->flags); in vring_unmap_one()
215 virtio64_to_cpu(vq->vq.vdev, desc->addr), in vring_unmap_one()
[all …]
Dvirtio_pci_common.h47 struct virtio_device vdev; member
121 static struct virtio_pci_device *to_vp_device(struct virtio_device *vdev) in to_vp_device() argument
123 return container_of(vdev, struct virtio_pci_device, vdev); in to_vp_device()
127 void vp_synchronize_vectors(struct virtio_device *vdev);
131 void vp_del_vqs(struct virtio_device *vdev);
133 int vp_find_vqs(struct virtio_device *vdev, unsigned nvqs,
137 const char *vp_bus_name(struct virtio_device *vdev);
146 const struct cpumask *vp_get_vq_affinity(struct virtio_device *vdev, int index);
Dvirtio_pci_modern.c143 static u64 vp_get_features(struct virtio_device *vdev) in vp_get_features() argument
145 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_get_features()
156 static void vp_transport_features(struct virtio_device *vdev, u64 features) in vp_transport_features() argument
158 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_transport_features()
163 __virtio_set_bit(vdev, VIRTIO_F_SR_IOV); in vp_transport_features()
167 static int vp_finalize_features(struct virtio_device *vdev) in vp_finalize_features() argument
169 struct virtio_pci_device *vp_dev = to_vp_device(vdev); in vp_finalize_features()
170 u64 features = vdev->features; in vp_finalize_features()
173 vring_transport_features(vdev); in vp_finalize_features()
176 vp_transport_features(vdev, features); in vp_finalize_features()
[all …]
/linux-4.19.296/drivers/char/hw_random/
Dvirtio-rng.c52 struct virtrng_info *vi = vq->vdev->priv; in random_recv_done()
141 static int probe_common(struct virtio_device *vdev) in probe_common() argument
165 vdev->priv = vi; in probe_common()
168 vi->vq = virtio_find_single_vq(vdev, random_recv_done, "input"); in probe_common()
186 static void remove_common(struct virtio_device *vdev) in remove_common() argument
188 struct virtrng_info *vi = vdev->priv; in remove_common()
194 vdev->config->reset(vdev); in remove_common()
197 vdev->config->del_vqs(vdev); in remove_common()
202 static int virtrng_probe(struct virtio_device *vdev) in virtrng_probe() argument
204 return probe_common(vdev); in virtrng_probe()
[all …]
/linux-4.19.296/drivers/media/common/videobuf2/
Dvideobuf2-v4l2.c703 static inline bool vb2_queue_is_busy(struct video_device *vdev, struct file *file) in vb2_queue_is_busy() argument
705 return vdev->queue->owner && vdev->queue->owner != file->private_data; in vb2_queue_is_busy()
713 struct video_device *vdev = video_devdata(file); in vb2_ioctl_reqbufs() local
714 int res = vb2_verify_memory_type(vdev->queue, p->memory, p->type); in vb2_ioctl_reqbufs()
718 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_reqbufs()
720 res = vb2_core_reqbufs(vdev->queue, p->memory, &p->count); in vb2_ioctl_reqbufs()
724 vdev->queue->owner = p->count ? file->private_data : NULL; in vb2_ioctl_reqbufs()
732 struct video_device *vdev = video_devdata(file); in vb2_ioctl_create_bufs() local
733 int res = vb2_verify_memory_type(vdev->queue, p->memory, in vb2_ioctl_create_bufs()
736 p->index = vdev->queue->num_buffers; in vb2_ioctl_create_bufs()
[all …]
/linux-4.19.296/drivers/char/
Dvirtio_console.c159 struct virtio_device *vdev; member
351 static bool is_rproc_serial(const struct virtio_device *vdev) in is_rproc_serial() argument
353 return is_rproc_enabled && vdev->id.device == VIRTIO_ID_RPROC_SERIAL; in is_rproc_serial()
362 if (!portdev->vdev) in use_multiport()
364 return __virtio_test_bit(portdev->vdev, VIRTIO_CONSOLE_F_MULTIPORT); in use_multiport()
425 static struct port_buffer *alloc_buf(struct virtio_device *vdev, size_t buf_size, in alloc_buf() argument
447 if (is_rproc_serial(vdev)) { in alloc_buf()
454 if (!vdev->dev.parent || !vdev->dev.parent->parent) in alloc_buf()
456 buf->dev = vdev->dev.parent->parent; in alloc_buf()
574 portdev->cpkt.id = cpu_to_virtio32(portdev->vdev, port_id); in __send_control_msg()
[all …]
/linux-4.19.296/drivers/media/usb/usbvision/
Dusbvision-video.c160 struct video_device *vdev = to_video_device(cd); in cd_to_usbvision() local
161 return video_get_drvdata(vdev); in cd_to_usbvision()
174 struct video_device *vdev = to_video_device(cd); in show_model() local
175 struct usb_usbvision *usbvision = video_get_drvdata(vdev); in show_model()
184 struct video_device *vdev = to_video_device(cd); in show_hue() local
185 struct usb_usbvision *usbvision = video_get_drvdata(vdev); in show_hue()
196 struct video_device *vdev = to_video_device(cd); in show_contrast() local
197 struct usb_usbvision *usbvision = video_get_drvdata(vdev); in show_contrast()
208 struct video_device *vdev = to_video_device(cd); in show_brightness() local
209 struct usb_usbvision *usbvision = video_get_drvdata(vdev); in show_brightness()
[all …]
/linux-4.19.296/drivers/char/tpm/
Dtpm_ibmvtpm.c51 static int ibmvtpm_send_crq_word(struct vio_dev *vdev, u64 w1) in ibmvtpm_send_crq_word() argument
53 return plpar_hcall_norets(H_SEND_CRQ, vdev->unit_address, w1, 0); in ibmvtpm_send_crq_word()
93 static int ibmvtpm_send_crq(struct vio_dev *vdev, in ibmvtpm_send_crq() argument
98 return ibmvtpm_send_crq_word(vdev, w1); in ibmvtpm_send_crq()
155 rc = ibmvtpm_send_crq_word(ibmvtpm->vdev, INIT_CRQ_CMD); in ibmvtpm_crq_send_init()
180 ibmvtpm->vdev->unit_address); in tpm_ibmvtpm_resume()
188 rc = vio_enable_interrupts(ibmvtpm->vdev); in tpm_ibmvtpm_resume()
249 rc = ibmvtpm_send_crq(ibmvtpm->vdev, in tpm_ibmvtpm_send()
294 rc = ibmvtpm_send_crq(ibmvtpm->vdev, in ibmvtpm_crq_get_rtce_size()
317 rc = ibmvtpm_send_crq(ibmvtpm->vdev, in ibmvtpm_crq_get_version()
[all …]
/linux-4.19.296/drivers/media/common/saa7146/
Dsaa7146_fops.c197 struct video_device *vdev = video_devdata(file); in fops_open() local
202 DEB_EE("file:%p, dev:%s\n", file, video_device_node_name(vdev)); in fops_open()
204 if (mutex_lock_interruptible(vdev->lock)) in fops_open()
224 v4l2_fh_init(&fh->fh, vdev); in fops_open()
229 if (vdev->vfl_type == VFL_TYPE_VBI) { in fops_open()
256 mutex_unlock(vdev->lock); in fops_open()
262 struct video_device *vdev = video_devdata(file); in fops_release() local
268 mutex_lock(vdev->lock); in fops_release()
270 if (vdev->vfl_type == VFL_TYPE_VBI) { in fops_release()
285 mutex_unlock(vdev->lock); in fops_release()
[all …]
/linux-4.19.296/drivers/s390/virtio/
Dvirtio_ccw.c50 struct virtio_device vdev; member
166 static struct virtio_ccw_device *to_vc_device(struct virtio_device *vdev) in to_vc_device() argument
168 return container_of(vdev, struct virtio_ccw_device, vdev); in to_vc_device()
400 vcdev = to_vc_device(info->vq->vdev); in virtio_ccw_kvm_notify()
426 struct virtio_ccw_device *vcdev = to_vc_device(vq->vdev); in virtio_ccw_del_vq()
463 dev_warn(&vq->vdev->dev, "Error %d while deleting queue %d\n", in virtio_ccw_del_vq()
473 static void virtio_ccw_del_vqs(struct virtio_device *vdev) in virtio_ccw_del_vqs() argument
477 struct virtio_ccw_device *vcdev = to_vc_device(vdev); in virtio_ccw_del_vqs()
485 list_for_each_entry_safe(vq, n, &vdev->vqs, list) in virtio_ccw_del_vqs()
491 static struct virtqueue *virtio_ccw_setup_vq(struct virtio_device *vdev, in virtio_ccw_setup_vq() argument
[all …]
/linux-4.19.296/drivers/media/radio/
Dradio-keene.c59 struct video_device vdev; member
103 dev_warn(&radio->vdev.dev, "%s failed (%d)\n", __func__, ret); in keene_cmd_main()
132 dev_warn(&radio->vdev.dev, "%s failed (%d)\n", __func__, ret); in keene_cmd_set()
149 video_unregister_device(&radio->vdev); in usb_keene_disconnect()
365 strlcpy(radio->vdev.name, radio->v4l2_dev.name, in usb_keene_probe()
366 sizeof(radio->vdev.name)); in usb_keene_probe()
367 radio->vdev.v4l2_dev = &radio->v4l2_dev; in usb_keene_probe()
368 radio->vdev.fops = &usb_keene_fops; in usb_keene_probe()
369 radio->vdev.ioctl_ops = &usb_keene_ioctl_ops; in usb_keene_probe()
370 radio->vdev.lock = &radio->lock; in usb_keene_probe()
[all …]

1234