search for: f_path

Displaying 20 results from an estimated 47 matches for "f_path".

Did you mean: ft_path
2013 Jul 25
0
[PATCH V8 21/33] ocfs2: add support for read_iter and write_iter
...ter file limit checks */ loff_t old_size, *ppos = &iocb->ki_pos; u32 old_clusters; @@ -2239,11 +2237,11 @@ static ssize_t ocfs2_file_aio_write(struct kiocb *iocb, OCFS2_MOUNT_COHERENCY_BUFFERED); int unaligned_dio = 0; - trace_ocfs2_file_aio_write(inode, file, file->f_path.dentry, + trace_ocfs2_file_write_iter(inode, file, file->f_path.dentry, (unsigned long long)OCFS2_I(inode)->ip_blkno, file->f_path.dentry->d_name.len, file->f_path.dentry->d_name.name, - (unsigned int)nr_segs); + (unsigned long long)pos); if (iocb->ki_left == 0)...
2013 Jun 30
1
why check f_path.mnt is equal for source and dest in btrfs_ioctl_clone()?
This gives EXDEV for clone operations that btrfs could otherwise execute and with slight change of circumstances will actually execute fine. Imagine we have a btrfs on /dev/mapper/foobar with subvols /foo and /bar. Let’s also imagine top of said fs in mounted at /mnt. In this case, a cross-subvol clone of /mnt/foo/srcfile to /mnt/bar/dstfile will
2012 Mar 27
13
Create subvolume from a directory?
Hi all, Just a quick question but can''t find an obvious answer. Can I create/convert a existing (btrfs) directory into a subvolume? It would be very helpful when transferring ''partitions'' into btrfs. I found a similar question way back in google, but that site is down now generally. Thanks in advance. -- To unsubscribe from this list: send the line
2009 Jun 13
1
[PATCH 1/3] Add ioctl to set per file 'compress' flag
...#47;fs/btrfs/ioctl.c +++ newformat2/fs/btrfs/ioctl.c @@ -1240,6 +1240,54 @@ out: return ret; } +/* Ioctl function to set or clear a flag on the file. */ +static long btrfs_ioctl_inode_flag(struct file *file, + u32 flag, int set) +{ + struct inode *inode = file->f_path.dentry->d_inode; + struct btrfs_inode *ip = BTRFS_I(inode); + struct btrfs_root *root = ip->root; + struct btrfs_trans_handle *trans; + int ret; + + if (!is_owner_or_cap(inode)) + return -EACCES; + + mutex_lock(&inode->i_mutex); + + /* Bail out if already set / cleared. */...
2011 Mar 31
15
[PATCH 1/3] VFS/ioctl: Add punching-hole support to ioctl().
...y the l_start, l_len and l_whence fields of the ''struct space_resv'' * are used here, rest are ignored. */ -int ioctl_preallocate(struct file *filp, void __user *argp) +int ioctl_preallocate(struct file *filp, void __user *argp, int mode) { struct inode *inode = filp->f_path.dentry->d_inode; struct space_resv sr; @@ -443,7 +443,7 @@ int ioctl_preallocate(struct file *filp, void __user *argp) return -EINVAL; } - return do_fallocate(filp, FALLOC_FL_KEEP_SIZE, sr.l_start, sr.l_len); + return do_fallocate(filp, mode, sr.l_start, sr.l_len); } static int file...
2011 Mar 31
15
[PATCH 1/3] VFS/ioctl: Add punching-hole support to ioctl().
...y the l_start, l_len and l_whence fields of the ''struct space_resv'' * are used here, rest are ignored. */ -int ioctl_preallocate(struct file *filp, void __user *argp) +int ioctl_preallocate(struct file *filp, void __user *argp, int mode) { struct inode *inode = filp->f_path.dentry->d_inode; struct space_resv sr; @@ -443,7 +443,7 @@ int ioctl_preallocate(struct file *filp, void __user *argp) return -EINVAL; } - return do_fallocate(filp, FALLOC_FL_KEEP_SIZE, sr.l_start, sr.l_len); + return do_fallocate(filp, mode, sr.l_start, sr.l_len); } static int file...
2009 Nov 03
2
[PATCH]] Btrfs: fix destroy snapshot to get the right parent dentry
...c index cdbb054..fe6ac9a 100644 --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c @@ -741,7 +741,7 @@ out: static noinline int btrfs_ioctl_snap_destroy(struct file *file, void __user *arg) { - struct dentry *parent = fdentry(file); + struct dentry *parent = file->f_path.dentry->d_parent; struct dentry *dentry; struct inode *dir = parent->d_inode; struct inode *inode; @@ -793,9 +793,6 @@ static noinline int btrfs_ioctl_snap_destroy(struct file *file, dest = BTRFS_I(inode)->root; mutex_lock(&inode->i_mutex); - err = d_invalidate(dentry);...
2010 Nov 19
16
[PATCH 1/1] Ocfs2: Teach ''coherency=full'' O_DIRECT writes to correctly up_read i_alloc_sem.
...a/fs/ocfs2/aops.c b/fs/ocfs2/aops.c index f1e962c..fd0713c 100644 --- a/fs/ocfs2/aops.c +++ b/fs/ocfs2/aops.c @@ -568,7 +568,7 @@ static void ocfs2_dio_end_io(struct kiocb *iocb, bool is_async) { struct inode *inode = iocb->ki_filp->f_path.dentry->d_inode; - int level; + int level, coherency; /* this io''s submitter should not have unlocked this before we could */ BUG_ON(!ocfs2_iocb_is_rw_locked(iocb)); @@ -576,7 +576,12 @@ static void ocfs2_dio_end_io(struct kiocb *iocb, ocfs2_iocb_clear_rw_locked(iocb);...
2012 Nov 12
0
[PATCH 3/3] ocfs2: Add freeze protection to ocfs2_file_splice_write()
...ertions(+), 0 deletions(-) diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index 93ef34d..9907243 100644 --- a/fs/ocfs2/file.c +++ b/fs/ocfs2/file.c @@ -2486,6 +2486,9 @@ static ssize_t ocfs2_file_splice_write(struct pipe_inode_info *pipe, out->f_path.dentry->d_name.len, out->f_path.dentry->d_name.name, len); + if (!sb_start_file_write(out)) + return -EAGAIN; + if (pipe->inode) mutex_lock_nested(&pipe->inode->i_mutex, I_MUTEX_PARENT); @@ -2527,6 +2530,7 @@ static ssize_t ocfs2_file_splice_write(struct pipe_ino...
2009 Jun 19
2
[PATCH] ocfs2: Update atime in splice read if necessary.
...ac34..95cba48 100644 --- a/fs/ocfs2/file.c +++ b/fs/ocfs2/file.c @@ -2025,7 +2025,7 @@ static ssize_t ocfs2_file_splice_read(struct file *in, size_t len, unsigned int flags) { - int ret = 0; + int ret = 0, lock_level = 0; struct inode *inode = in->f_path.dentry->d_inode; mlog_entry("(0x%p, 0x%p, %u, ''%.*s'')\n", in, pipe, @@ -2036,12 +2036,12 @@ static ssize_t ocfs2_file_splice_read(struct file *in, /* * See the comment in ocfs2_file_aio_read() */ - ret = ocfs2_inode_lock(inode, NULL, 0); + ret = oc...
2019 Apr 04
2
[PATCH v4 5/5] xfs: disable map_sync for async flush
...it a/include/linux/fs.h b/include/linux/fs.h index 8b42df09b04c..add017de3dd7 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -2162,6 +2162,20 @@ static inline void file_accessed(struct file *file) touch_atime(&file->f_path); } +struct dax_device; +extern bool dax_synchronous(struct dax_device *dax_dev); +static inline int is_synchronous(struct file *filp, struct dax_device *dax_dev) +{ + struct inode *inode = file_inode(filp); + + if (!IS_DAX(inode)) + return -EOPNOTSUPP; + if (!dax...
2019 Apr 04
2
[PATCH v4 5/5] xfs: disable map_sync for async flush
...it a/include/linux/fs.h b/include/linux/fs.h index 8b42df09b04c..add017de3dd7 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -2162,6 +2162,20 @@ static inline void file_accessed(struct file *file) touch_atime(&file->f_path); } +struct dax_device; +extern bool dax_synchronous(struct dax_device *dax_dev); +static inline int is_synchronous(struct file *filp, struct dax_device *dax_dev) +{ + struct inode *inode = file_inode(filp); + + if (!IS_DAX(inode)) + return -EOPNOTSUPP; + if (!dax...
2011 Aug 17
2
[PATCH] btrfs: fix d_off in the first dirent
...IR); + over = filldir(dirent, ".", 1, + filp->f_pos, inode->i_ino, DT_DIR); if (over) return 0; filp->f_pos = 1; @@ -4134,7 +4135,7 @@ static int btrfs_real_readdir(struct file *filp, void *dirent, if (filp->f_pos == 1) { u64 pino = parent_ino(filp->f_path.dentry); over = filldir(dirent, "..", 2, - 2, pino, DT_DIR); + filp->f_pos, pino, DT_DIR); if (over) return 0; filp->f_pos = 2; -- 1.7.6 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to...
2013 Aug 06
6
[PATCH 0/4] btrfs: out-of-band (aka offline) dedupe v4
Hi, The following series of patches implements in btrfs an ioctl to do out-of-band deduplication of file extents. To be clear, this means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software initiates a dedupe. The primary patch is loosely based off of one sent by Josef Bacik back in January, 2011.
2008 Apr 29
26
Btrfs v0.14 Released
Hello everyone, Btrfs v0.14 is now available for download. Please note the disk format has changed, and it is not compatible with older versions of Btrfs. For downloads and documention, please see the Btrfs project page: http://btrfs.wiki.kernel.org The oss.oracle.com Btrfs project page will soon start redirecting here. v0.14 has a few performance fixes and closes some races that
2019 Apr 04
2
[Qemu-devel] [PATCH v4 5/5] xfs: disable map_sync for async flush
...#47;linux/fs.h > > index 8b42df09b04c..add017de3dd7 100644 > > --- a/include/linux/fs.h > > +++ b/include/linux/fs.h > > @@ -2162,6 +2162,20 @@ static inline void file_accessed(struct file *file) > > touch_atime(&file->f_path); > > } > > > > +struct dax_device; > > +extern bool dax_synchronous(struct dax_device *dax_dev); > > +static inline int is_synchronous(struct file *filp, struct dax_device > > *dax_dev) > > +{ > > + struct inode *inode = file_inode(filp); &g...
2019 Apr 04
2
[Qemu-devel] [PATCH v4 5/5] xfs: disable map_sync for async flush
...#47;linux/fs.h > > index 8b42df09b04c..add017de3dd7 100644 > > --- a/include/linux/fs.h > > +++ b/include/linux/fs.h > > @@ -2162,6 +2162,20 @@ static inline void file_accessed(struct file *file) > > touch_atime(&file->f_path); > > } > > > > +struct dax_device; > > +extern bool dax_synchronous(struct dax_device *dax_dev); > > +static inline int is_synchronous(struct file *filp, struct dax_device > > *dax_dev) > > +{ > > + struct inode *inode = file_inode(filp); &g...
2009 Jan 28
24
[PATCH] fs: Add new pre-allocation ioctls to vfs for compatibility with legacy xfs ioctls
...-allocation ioctls + * which predate the fallocate syscall. + * + * Only the l_start, l_len and l_whence fields of the ''struct space_resv'' + * are used here, rest are ignored. + */ +int ioctl_preallocate(struct file *filp, unsigned long arg) +{ + struct inode *inode = filp->f_path.dentry->d_inode; + struct space_resv sr; + + if (copy_from_user(&sr, (struct space_resv __user *) arg, sizeof(sr))) + return -EFAULT; + + switch (sr.l_whence) { + case SEEK_SET: + break; + case SEEK_CUR: + sr.l_start += filp->f_pos; + break; + case SEEK_END: + sr.l_start += i_size_re...
2008 Dec 11
0
[PATCH] btrfs: mnt_drop_write in ioctl_trans_end
...ctl.c index 6228b69..69c4a07 100644 --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c @@ -1059,6 +1059,8 @@ long btrfs_ioctl_trans_end(struct file *file) root->fs_info->open_ioctl_trans--; mutex_unlock(&root->fs_info->trans_mutex); + mnt_drop_write(file->f_path.mnt); + out: return ret; } -- 1.5.6.5 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
2010 Jul 01
0
[PATCH] btrfs: handle errors for FS_IOC_SETFLAGS
...fs_update_inode(trans, root, inode); - BUG_ON(ret); + if (ret) + goto out_endtrans; btrfs_update_iflags(inode); inode->i_ctime = CURRENT_TIME; - btrfs_end_transaction(trans, root); + ret = 0; +out_endtrans: + btrfs_end_transaction(trans, root); +out_drop_write: mnt_drop_write(file->f_path.mnt); - out_unlock: +out_unlock: mutex_unlock(&inode->i_mutex); - return 0; + return ret; } static int btrfs_ioctl_getversion(struct file *file, int __user *arg) -- 1.7.1 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to m...