diff options
author | Conrad Meyer <cem@FreeBSD.org> | 2019-02-21 02:41:57 +0000 |
---|---|---|
committer | Conrad Meyer <cem@FreeBSD.org> | 2019-02-21 02:41:57 +0000 |
commit | f6ebb68395c6873d358262c2ce0d762d56df95f6 (patch) | |
tree | 0e19483a2394d9659ab177a3d0ff2c8b06fa6272 /sys/fs/fuse/fuse_vfsops.c | |
parent | c6da8eb21f495264af40fc4cd4bb336be0efab13 (diff) |
fuse: Fix a regression introduced in r337165
On systems with non-default DFLTPHYS and/or MAXBSIZE, FUSE would attempt to
use a buf cache block size in excess of permitted size. This did not affect
most configurations, since DFLTPHYS and MAXBSIZE both default to 64kB.
The issue was discovered and reported using a custom kernel with a DFLTPHYS
of 512kB.
PR: 230260 (comment #9)
Reported by: ken@
MFC after: π/𝑒 weeks
Notes
Notes:
svn path=/head/; revision=344407
Diffstat (limited to 'sys/fs/fuse/fuse_vfsops.c')
-rw-r--r-- | sys/fs/fuse/fuse_vfsops.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/fs/fuse/fuse_vfsops.c b/sys/fs/fuse/fuse_vfsops.c index 715a3c36b235..8ae82cca3c67 100644 --- a/sys/fs/fuse/fuse_vfsops.c +++ b/sys/fs/fuse/fuse_vfsops.c @@ -338,7 +338,7 @@ fuse_vfsop_mount(struct mount *mp) mp->mnt_kern_flag |= MNTK_USES_BCACHE; MNT_IUNLOCK(mp); /* We need this here as this slot is used by getnewvnode() */ - mp->mnt_stat.f_iosize = DFLTPHYS; + mp->mnt_stat.f_iosize = MIN(DFLTPHYS, MAXBSIZE); if (subtype) { strlcat(mp->mnt_stat.f_fstypename, ".", MFSNAMELEN); strlcat(mp->mnt_stat.f_fstypename, subtype, MFSNAMELEN); |