Lines Matching defs:file

10 #include <linux/file.h>
318 int hmdfs_iterate_merge(struct file *file, struct dir_context *ctx)
321 struct hmdfs_file_info *fi_head = hmdfs_f(file);
323 struct file *lower_file_iter = NULL;
343 // dev_id is changed, parameter is set 0 to get next file info
352 lower_file_iter->f_pos = file->f_pos;
354 file->f_pos = lower_file_iter->f_pos;
355 ctx->pos = file->f_pos;
367 file->f_pos = hmdfs_set_pos(fi_iter->device_id, 0, 0);
368 ctx->pos = file->f_pos;
372 trace_hmdfs_iterate_merge(file->f_path.dentry, start_pos, ctx->pos,
377 int do_dir_open_merge(struct file *file, const struct cred *cred,
381 struct hmdfs_dentry_info_merge *dim = hmdfs_dm(file->f_path.dentry);
384 struct path lo_p = { .mnt = file->f_path.mnt };
385 struct file *lower_file = NULL;
408 lower_file = dentry_open(&lo_p, file->f_flags, cred);
425 int hmdfs_dir_open_merge(struct inode *inode, struct file *file)
434 file->private_data = fi;
439 ret = do_dir_open_merge(file, hmdfs_sb(inode->i_sb)->cred, fi);
446 int hmdfs_dir_release_merge(struct inode *inode, struct file *file)
448 struct hmdfs_file_info *fi_head = hmdfs_f(file);
461 file->private_data = NULL;
467 static long hmdfs_ioc_get_dst_path(struct file *filp, unsigned long arg);
469 long hmdfs_dir_unlocked_ioctl_merge(struct file *file, unsigned int cmd,
472 struct hmdfs_file_info *fi_head = hmdfs_f(file);
475 struct file *lower_file = NULL;
479 return hmdfs_ioc_get_dst_path(file, arg);
495 long hmdfs_dir_compat_ioctl_merge(struct file *file, unsigned int cmd,
498 struct hmdfs_file_info *fi_head = hmdfs_f(file);
501 struct file *lower_file = NULL;
505 return hmdfs_ioc_get_dst_path(file, arg);
540 int hmdfs_file_open_merge(struct inode *inode, struct file *file)
543 struct file *lower_file = NULL;
544 struct path lo_p = { .mnt = file->f_path.mnt };
550 lo_p.dentry = hmdfs_get_fst_lo_d(file->f_path.dentry);
562 parent = dget_parent(file->f_path.dentry);
563 lower_file = dentry_open(&lo_p, file->f_flags, cred);
569 file->private_data = gfi;
570 hmdfs_update_upper_file(file, lower_file);
578 int hmdfs_file_flush_merge(struct file *file, fl_owner_t id)
580 struct hmdfs_file_info *gfi = hmdfs_f(file);
581 struct file *lower_file = gfi->lower_file;
589 static long hmdfs_ioc_get_writeopen_cnt(struct file *filp, unsigned long arg)
592 struct file *lower_file = gfi->lower_file;
763 static long hmdfs_ioc_get_dst_path(struct file *filp, unsigned long arg)
807 static long hmdfs_file_ioctl_merge(struct file *filp, unsigned int cmd, unsigned long arg)
820 * so file operations are same as device_view local operations.