Lines Matching refs:file
407 static int usblp_open(struct inode *inode, struct file *file)
441 file->private_data = usblp;
450 file->private_data = NULL;
474 static int usblp_release(struct inode *inode, struct file *file)
476 struct usblp *usblp = file->private_data;
495 static __poll_t usblp_poll(struct file *file, struct poll_table_struct *wait)
497 struct usblp *usblp = file->private_data;
501 /* Should we check file->f_mode & FMODE_WRITE before poll_wait()? */
502 poll_wait(file, &usblp->rwait, wait);
503 poll_wait(file, &usblp->wwait, wait);
519 static long usblp_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
521 struct usblp *usblp = file->private_data;
742 static ssize_t usblp_write(struct file *file, const char __user *buffer, size_t count, loff_t *ppos)
744 struct usblp *usblp = file->private_data;
754 if ((rv = usblp_wwait(usblp, !!(file->f_flags & O_NONBLOCK))) < 0)
794 rv = usblp_wwait(usblp, !!(file->f_flags&O_NONBLOCK));
841 static ssize_t usblp_read(struct file *file, char __user *buffer, size_t len, loff_t *ppos)
843 struct usblp *usblp = file->private_data;
851 rv = usblp_rwait_and_lock(usblp, !!(file->f_flags & O_NONBLOCK));