Lines Matching defs:file

8 #include <linux/file.h>
26 struct file *file = NULL;
51 file = anon_inode_getfile(name, fops, thr, fd_flags);
52 ret = PTR_ERR_OR_ZERO(file);
58 fd_install(fd, file);
109 static ssize_t thread_with_stdio_read(struct file *file, char __user *ubuf,
113 container_of(file->private_data, struct thread_with_stdio, thr);
118 if (!(file->f_flags & O_NONBLOCK)) {
149 static int thread_with_stdio_release(struct inode *inode, struct file *file)
152 container_of(file->private_data, struct thread_with_stdio, thr);
162 static ssize_t thread_with_stdio_write(struct file *file, const char __user *ubuf,
166 container_of(file->private_data, struct thread_with_stdio, thr);
200 if ((file->f_flags & O_NONBLOCK)) {
215 static __poll_t thread_with_stdio_poll(struct file *file, struct poll_table_struct *wait)
218 container_of(file->private_data, struct thread_with_stdio, thr);
220 poll_wait(file, &thr->stdio.output.wait, wait);
221 poll_wait(file, &thr->stdio.input.wait, wait);
234 static __poll_t thread_with_stdout_poll(struct file *file, struct poll_table_struct *wait)
237 container_of(file->private_data, struct thread_with_stdio, thr);
239 poll_wait(file, &thr->stdio.output.wait, wait);
250 static int thread_with_stdio_flush(struct file *file, fl_owner_t id)
253 container_of(file->private_data, struct thread_with_stdio, thr);
258 static long thread_with_stdio_ioctl(struct file *file, unsigned int cmd, unsigned long p)
261 container_of(file->private_data, struct thread_with_stdio, thr);
334 * we're waiting on user input (or for the file descriptor to be