freebsd-src/sys/ufs/ffs
Konstantin Belousov 71f2642988 ufs: apply suspension for non-forced rw unmounts.
Forced rw unmounts and remounts from rw to ro already suspend
filesystem, which closes races with writers instantiating new vnodes
while unmount flushes the queue.  Original intent of not including
non-forced unmounts into this regime was to allow such unmounts to
fail if writer was active, but this did not worked well.

Similar change, but causing all unmount, even involving only ro
filesystem, were proposed in D24088, but I believe that suspending ro
is undesirable, and definitely spends CPU time.

Reported by:	markj
Discussed with:	chs, mckusick
Tested by:	pho
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
2020-04-10 01:24:16 +00:00
..
ffs_alloc.c fd: use smr for managing struct pwd 2020-03-08 00:23:36 +00:00
ffs_balloc.c ufs: add a setter for inode i_flag field 2020-01-13 02:31:51 +00:00
ffs_extern.h Update ffs_getcg() function to accept a flags parameter to be passed 2019-10-04 05:28:36 +00:00
ffs_inode.c Fixing the soft update macros in -r359612 triggered a previously 2020-04-09 23:51:18 +00:00
ffs_rawread.c vfs: drop the mostly unused flags argument from VOP_UNLOCK 2020-01-03 22:29:58 +00:00
ffs_snapshot.c vfs: stop handling VI_OWEINACT in vget 2020-01-24 07:45:59 +00:00
ffs_softdep.c Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many) 2020-02-26 14:26:36 +00:00
ffs_subr.c When mounting a UFS filesystem, return EINTEGRITY rather than EIO 2020-03-11 21:00:40 +00:00
ffs_suspend.c Use the devfs vnode rather than the mntfs vnode for permissions checks. 2020-03-09 15:55:13 +00:00
ffs_tables.c sys: further adoption of SPDX licensing ID tags. 2017-11-20 19:43:44 +00:00
ffs_vfsops.c ufs: apply suspension for non-forced rw unmounts. 2020-04-10 01:24:16 +00:00
ffs_vnops.c VOP_GETPAGES_ASYNC(): consistently call iodone() callback in case of error. 2020-03-30 21:44:30 +00:00
fs.h Clarify comment that describes how the FS_METACKHASH is managed. 2019-08-13 20:56:44 +00:00
softdep.h With INVARIANTS, track all softdep dependency structures centrally 2020-02-03 17:47:14 +00:00