Lines Matching defs:file

104 static ssize_t read_mem(struct file *file, char __user *buf,
191 static ssize_t write_mem(struct file *file, const char __user *buf,
264 int __weak phys_mem_access_prot_allowed(struct file *file,
278 static int uncached_access(struct file *file, phys_addr_t addr)
289 * file pointer
292 if (file->f_flags & O_DSYNC)
299 static pgprot_t phys_mem_access_prot(struct file *file, unsigned long pfn,
305 if (uncached_access(file, offset))
313 static unsigned long get_unmapped_area_mem(struct file *file,
325 static unsigned memory_mmap_capabilities(struct file *file)
331 static unsigned zero_mmap_capabilities(struct file *file)
355 static int mmap_mem(struct file *file, struct vm_area_struct *vma)
377 if (!phys_mem_access_prot_allowed(file, vma->vm_pgoff, size,
381 vma->vm_page_prot = phys_mem_access_prot(file, vma->vm_pgoff,
398 static ssize_t read_port(struct file *file, char __user *buf,
416 static ssize_t write_port(struct file *file, const char __user *buf,
440 static ssize_t read_null(struct file *file, char __user *buf,
446 static ssize_t write_null(struct file *file, const char __user *buf,
470 static ssize_t splice_write_null(struct pipe_inode_info *pipe, struct file *out,
505 static ssize_t read_zero(struct file *file, char __user *buf,
532 static int mmap_zero(struct file *file, struct vm_area_struct *vma)
543 static unsigned long get_unmapped_area_zero(struct file *file,
550 * mmap_zero() will call shmem_zero_setup() to create a file,
552 * and pass NULL for file as in mmap.c's get_unmapped_area(),
559 return current->mm->get_unmapped_area(file, addr, len, pgoff, flags);
565 static ssize_t write_full(struct file *file, const char __user *buf,
576 static loff_t null_lseek(struct file *file, loff_t offset, int orig)
578 return file->f_pos = 0;
586 * also note that seeking relative to the "end of file" isn't supported:
589 static loff_t memory_lseek(struct file *file, loff_t offset, int orig)
593 inode_lock(file_inode(file));
596 offset += file->f_pos;
604 file->f_pos = offset;
605 ret = file->f_pos;
611 inode_unlock(file_inode(file));
615 static int open_port(struct inode *inode, struct file *filp)
715 static int memory_open(struct inode *inode, struct file *filp)