diff --git a/UPDATING b/UPDATING index b68fa1db6edd..71a7de51c624 100644 --- a/UPDATING +++ b/UPDATING @@ -32,9 +32,14 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 13.x IS SLOW: "ln -s 'abort:false,junk:false' /etc/malloc.conf".) 20190513: - The "-o sync_unmount" and "-o init_backgrounded" options have been - removed from mount_fusefs(8). You can safely remove them from your - scripts, because they had no effect. + The vfs.fusefs.sync_unmount and vfs.fusefs.init_backgrounded sysctls + and the "-o sync_unmount" and "-o init_backgrounded" mount options have + been removed from mount_fusefs(8). You can safely remove them from + your scripts, because they had no effect. + + The vfs.fusefs.fix_broken_io sysctl has been removed. If you felt the + need to set it to a non-default value, please tell asomers@FreeBSD.org + why. 20190507: The IPSEC option has been removed from GENERIC. Users requiring diff --git a/sys/fs/fuse/fuse_io.c b/sys/fs/fuse/fuse_io.c index 5148d24eb895..9b7b152cc596 100644 --- a/sys/fs/fuse/fuse_io.c +++ b/sys/fs/fuse/fuse_io.c @@ -776,11 +776,7 @@ fuse_io_strategy(struct vnode *vp, struct buf *bp) uiop->uio_offset = ((off_t)bp->b_blkno) * biosize; error = fuse_read_directbackend(vp, uiop, cred, fufh); - /* XXXCEM: Potentially invalid access to cached_attrs here */ - if ((!error && uiop->uio_resid) || - (fsess_opt_brokenio(vnode_mount(vp)) && error == EIO && - uiop->uio_offset < fvdat->filesize && fvdat->filesize > 0 && - uiop->uio_offset >= fvdat->cached_attrs.va_size)) { + if (!error && uiop->uio_resid) { /* * If we had a short read with no error, we must have * hit a file hole. We should zero-fill the remainder. @@ -792,14 +788,6 @@ fuse_io_strategy(struct vnode *vp, struct buf *bp) int nread = bp->b_bcount - uiop->uio_resid; int left = uiop->uio_resid; - if (error != 0) { - printf("FUSE: Fix broken io: offset %ju, " - " resid %zd, file size %ju/%ju\n", - (uintmax_t)uiop->uio_offset, - uiop->uio_resid, fvdat->filesize, - fvdat->cached_attrs.va_size); - error = 0; - } if (left > 0) bzero((char *)bp->b_data + nread, left); uiop->uio_resid = 0; diff --git a/sys/fs/fuse/fuse_ipc.h b/sys/fs/fuse/fuse_ipc.h index ff7ca0a2df61..a288acc4584b 100644 --- a/sys/fs/fuse/fuse_ipc.h +++ b/sys/fs/fuse/fuse_ipc.h @@ -220,7 +220,6 @@ struct fuse_data { #define FSESS_NO_DATACACHE 0x0200 /* disable buffer cache */ #define FSESS_NO_NAMECACHE 0x0400 /* disable name cache */ #define FSESS_NO_MMAP 0x0800 /* disable mmap */ -#define FSESS_BROKENIO 0x1000 /* fix broken io */ #define FSESS_POSIX_LOCKS 0x2000 /* daemon supports POSIX locks */ enum fuse_data_cache_mode { @@ -233,7 +232,6 @@ extern int fuse_data_cache_mode; extern int fuse_data_cache_invalidate; extern int fuse_mmap_enable; extern int fuse_sync_resize; -extern int fuse_fix_broken_io; static inline struct fuse_data * fuse_get_mpdata(struct mount *mp) @@ -276,14 +274,6 @@ fsess_opt_mmap(struct mount *mp) return ((data->dataflags & (FSESS_NO_DATACACHE | FSESS_NO_MMAP)) == 0); } -static inline bool -fsess_opt_brokenio(struct mount *mp) -{ - struct fuse_data *data = fuse_get_mpdata(mp); - - return (fuse_fix_broken_io || (data->dataflags & FSESS_BROKENIO)); -} - /* Insert a new upgoing message */ static inline void fuse_ms_push(struct fuse_ticket *ftick) diff --git a/sys/fs/fuse/fuse_node.c b/sys/fs/fuse/fuse_node.c index 96d60dda0fd7..8bf5693d6480 100644 --- a/sys/fs/fuse/fuse_node.c +++ b/sys/fs/fuse/fuse_node.c @@ -142,13 +142,6 @@ SYSCTL_INT(_vfs_fusefs, OID_AUTO, sync_resize, CTLFLAG_RW, "If a cached write extended a file, inform FUSE filesystem of the changed" "size immediately subsequent to the issued writes"); -int fuse_fix_broken_io = 0; - -SYSCTL_INT(_vfs_fusefs, OID_AUTO, fix_broken_io, CTLFLAG_RW, - &fuse_fix_broken_io, 0, - "If non-zero, print a diagnostic warning if a userspace filesystem returns" - " EIO on reads of recently extended portions of files"); - static int sysctl_fuse_cache_mode(SYSCTL_HANDLER_ARGS) { diff --git a/sys/fs/fuse/fuse_vfsops.c b/sys/fs/fuse/fuse_vfsops.c index 8a98d6c4e8c5..230084c9554a 100644 --- a/sys/fs/fuse/fuse_vfsops.c +++ b/sys/fs/fuse/fuse_vfsops.c @@ -273,7 +273,6 @@ fuse_vfsop_mount(struct mount *mp) FUSE_FLAGOPT(no_datacache, FSESS_NO_DATACACHE); FUSE_FLAGOPT(no_namecache, FSESS_NO_NAMECACHE); FUSE_FLAGOPT(no_mmap, FSESS_NO_MMAP); - FUSE_FLAGOPT(brokenio, FSESS_BROKENIO); (void)vfs_scanopt(opts, "max_read=", "%u", &max_read); if (vfs_scanopt(opts, "timeout=", "%u", &daemon_timeout) == 1) {