Lines Matching refs:file
953 __poll_t vb2_poll(struct vb2_queue *q, struct file *file, poll_table *wait) in vb2_poll() argument
955 struct video_device *vfd = video_devdata(file); in vb2_poll()
958 res = vb2_core_poll(q, file, wait); in vb2_poll()
961 struct v4l2_fh *fh = file->private_data; in vb2_poll()
963 poll_wait(file, &fh->wait, wait); in vb2_poll()
981 static inline bool vb2_queue_is_busy(struct video_device *vdev, struct file *file) in vb2_queue_is_busy() argument
983 return vdev->queue->owner && vdev->queue->owner != file->private_data; in vb2_queue_is_busy()
988 int vb2_ioctl_reqbufs(struct file *file, void *priv, in vb2_ioctl_reqbufs() argument
991 struct video_device *vdev = video_devdata(file); in vb2_ioctl_reqbufs()
997 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_reqbufs()
1003 vdev->queue->owner = p->count ? file->private_data : NULL; in vb2_ioctl_reqbufs()
1008 int vb2_ioctl_create_bufs(struct file *file, void *priv, in vb2_ioctl_create_bufs() argument
1011 struct video_device *vdev = video_devdata(file); in vb2_ioctl_create_bufs()
1025 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_create_bufs()
1030 vdev->queue->owner = file->private_data; in vb2_ioctl_create_bufs()
1035 int vb2_ioctl_prepare_buf(struct file *file, void *priv, in vb2_ioctl_prepare_buf() argument
1038 struct video_device *vdev = video_devdata(file); in vb2_ioctl_prepare_buf()
1040 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_prepare_buf()
1046 int vb2_ioctl_querybuf(struct file *file, void *priv, struct v4l2_buffer *p) in vb2_ioctl_querybuf() argument
1048 struct video_device *vdev = video_devdata(file); in vb2_ioctl_querybuf()
1055 int vb2_ioctl_qbuf(struct file *file, void *priv, struct v4l2_buffer *p) in vb2_ioctl_qbuf() argument
1057 struct video_device *vdev = video_devdata(file); in vb2_ioctl_qbuf()
1059 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_qbuf()
1065 int vb2_ioctl_dqbuf(struct file *file, void *priv, struct v4l2_buffer *p) in vb2_ioctl_dqbuf() argument
1067 struct video_device *vdev = video_devdata(file); in vb2_ioctl_dqbuf()
1069 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_dqbuf()
1071 return vb2_dqbuf(vdev->queue, p, file->f_flags & O_NONBLOCK); in vb2_ioctl_dqbuf()
1075 int vb2_ioctl_streamon(struct file *file, void *priv, enum v4l2_buf_type i) in vb2_ioctl_streamon() argument
1077 struct video_device *vdev = video_devdata(file); in vb2_ioctl_streamon()
1079 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_streamon()
1085 int vb2_ioctl_streamoff(struct file *file, void *priv, enum v4l2_buf_type i) in vb2_ioctl_streamoff() argument
1087 struct video_device *vdev = video_devdata(file); in vb2_ioctl_streamoff()
1089 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_streamoff()
1095 int vb2_ioctl_expbuf(struct file *file, void *priv, struct v4l2_exportbuffer *p) in vb2_ioctl_expbuf() argument
1097 struct video_device *vdev = video_devdata(file); in vb2_ioctl_expbuf()
1099 if (vb2_queue_is_busy(vdev, file)) in vb2_ioctl_expbuf()
1107 int vb2_fop_mmap(struct file *file, struct vm_area_struct *vma) in vb2_fop_mmap() argument
1109 struct video_device *vdev = video_devdata(file); in vb2_fop_mmap()
1115 int _vb2_fop_release(struct file *file, struct mutex *lock) in _vb2_fop_release() argument
1117 struct video_device *vdev = video_devdata(file); in _vb2_fop_release()
1121 if (file->private_data == vdev->queue->owner) { in _vb2_fop_release()
1127 return v4l2_fh_release(file); in _vb2_fop_release()
1131 int vb2_fop_release(struct file *file) in vb2_fop_release() argument
1133 struct video_device *vdev = video_devdata(file); in vb2_fop_release()
1136 return _vb2_fop_release(file, lock); in vb2_fop_release()
1140 ssize_t vb2_fop_write(struct file *file, const char __user *buf, in vb2_fop_write() argument
1143 struct video_device *vdev = video_devdata(file); in vb2_fop_write()
1151 if (vb2_queue_is_busy(vdev, file)) in vb2_fop_write()
1154 file->f_flags & O_NONBLOCK); in vb2_fop_write()
1156 vdev->queue->owner = file->private_data; in vb2_fop_write()
1164 ssize_t vb2_fop_read(struct file *file, char __user *buf, in vb2_fop_read() argument
1167 struct video_device *vdev = video_devdata(file); in vb2_fop_read()
1175 if (vb2_queue_is_busy(vdev, file)) in vb2_fop_read()
1178 file->f_flags & O_NONBLOCK); in vb2_fop_read()
1180 vdev->queue->owner = file->private_data; in vb2_fop_read()
1188 __poll_t vb2_fop_poll(struct file *file, poll_table *wait) in vb2_fop_poll() argument
1190 struct video_device *vdev = video_devdata(file); in vb2_fop_poll()
1207 res = vb2_poll(vdev->queue, file, wait); in vb2_fop_poll()
1211 q->owner = file->private_data; in vb2_fop_poll()
1219 unsigned long vb2_fop_get_unmapped_area(struct file *file, unsigned long addr, in vb2_fop_get_unmapped_area() argument
1222 struct video_device *vdev = video_devdata(file); in vb2_fop_get_unmapped_area()