aboutsummaryrefslogtreecommitdiff
path: root/sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c')
-rw-r--r--sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c b/sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c
index d193eb80dca2..c729947369c2 100644
--- a/sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c
+++ b/sys/contrib/openzfs/module/os/linux/zfs/zfs_file_os.c
@@ -260,24 +260,12 @@ zfs_file_fsync(zfs_file_t *filp, int flags)
{
int datasync = 0;
int error;
- int fstrans;
if (flags & O_DSYNC)
datasync = 1;
- /*
- * May enter XFS which generates a warning when PF_FSTRANS is set.
- * To avoid this the flag is cleared over vfs_sync() and then reset.
- */
- fstrans = __spl_pf_fstrans_check();
- if (fstrans)
- current->flags &= ~(__SPL_PF_FSTRANS);
-
error = -vfs_fsync(filp, datasync);
- if (fstrans)
- current->flags |= __SPL_PF_FSTRANS;
-
return (error);
}
@@ -292,14 +280,6 @@ int
zfs_file_deallocate(zfs_file_t *fp, loff_t offset, loff_t len)
{
/*
- * May enter XFS which generates a warning when PF_FSTRANS is set.
- * To avoid this the flag is cleared over vfs_sync() and then reset.
- */
- int fstrans = __spl_pf_fstrans_check();
- if (fstrans)
- current->flags &= ~(__SPL_PF_FSTRANS);
-
- /*
* When supported by the underlying file system preferentially
* use the fallocate() callback to preallocate the space.
*/
@@ -308,9 +288,6 @@ zfs_file_deallocate(zfs_file_t *fp, loff_t offset, loff_t len)
error = -fp->f_op->fallocate(fp,
FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, offset, len);
- if (fstrans)
- current->flags |= __SPL_PF_FSTRANS;
-
if (error)
return (SET_ERROR(error));