#
309208 |
|
27-Nov-2016 |
kib |
MFC r308618: Provide simple mutual exclusion between mount point update and unmount. In the update path in ffs_mount(), drop vfs_busy() reference around namei().
|
#
309173 |
|
25-Nov-2016 |
mckusick |
MFC r308064: Avoid possible overflow when calclating malloc size for auxillary data structure sizes when mounting and reloading UFS/FFS filesystems.
|
#
306175 |
|
22-Sep-2016 |
kib |
MFC r305592: Partially lift suspension when ffs_reload() finished with cgs and going to re-read inodes.
|
#
301310 |
|
04-Jun-2016 |
kib |
MFC r300364: Improve handling of rdev->si_mountpt on mount and unmount of FFS volumes. Treat the field as a semaphore protecting availability of the device for mounting. Do no access devvp->v_rdev without the vnode lock owned.
Protect change of the devvp->v_bufobj bo_ops vector with the vnode lock.
|
#
300601 |
|
24-May-2016 |
kib |
MFC r300084: Do enable io accounting for read-only mounts and mounts which are remounted to writeable after initial read-only. Assign to dev->si_mountpt earlier to account the accesses done at the mount time.
|
#
300598 |
|
24-May-2016 |
kib |
MFC r300030: Fix comments.
|
#
297787 |
|
10-Apr-2016 |
kib |
MFC r297311: Ensure that TRIMs are finished before unmount destroys ufsmount.
|
#
292895 |
|
29-Dec-2015 |
mckusick |
MFC of 291244, 291380, 291459, 291460, 291671, and 291743:
This MFC includes changes to better manage the vnode freelist and to streamline the allocation and freeing of vnodes.
Note that to maintain the KPI the VI_AGE flag is left defined in sys/vnode.h though its use is dropped as described in 291380. To maintain KBI the vfs.vlru_alloc_cache_src sysctl variable remains though it no longer has any effect as described in 291244.
MFC of 291244: Move the comment about resident pages preventing vnode from leaving active list, into the header comment for vdrop(), which is the function that decides whether to leave the vnode on the list. Note that dirty page write-out in vinactive() is asynchronous.
Discussed with: alc Sponsored by: The FreeBSD Foundation
MFC of 291380: Remove VI_AGE vnode iflag, it is unused.
Noted by: bde Sponsored by: The FreeBSD Foundation
MFC of 291459: For performance reasons, it is useful to have a single string used as the name of a filesystem when setting it as the first parameter to the getnewvnode() function. Most filesystems call getnewvnode from just one place so can use a literal string as the first parameter. However, NFS calls getnewvnode from two places, so we create a global constant string that can be used by the two instances. This change also collapses two instances of getnewvnode() in the UFS filesystem to a single call.
Reviewed by: kib Tested by: Peter Holm
MFC of 291460: As the kernel allocates and frees vnodes, it fully initializes them on every allocation and fully releases them on every free. These are not trivial costs: it starts by zeroing a large structure then initializes a mutex, a lock manager lock, an rw lock, four lists, and six pointers. And looking at vfs.vnodes_created, these operations are being done millions of times an hour on a busy machine.
As a performance optimization, this code update uses the uma_init and uma_fini routines to do these initializations and cleanups only as the vnodes enter and leave the vnode_zone. With this change the initializations are only done kern.maxvnodes times at system startup and then only rarely again. The frees are done only if the vnode_zone shrinks which never happens in practice. For those curious about the avoided work, look at the vnode_init() and vnode_fini() functions in kern/vfs_subr.c to see the code that has been removed from the main vnode allocation/free path.
Reviewed by: kib Tested by: Peter Holm
MFC of 291671: We need to zero out the union of pointers in a freed vnode structure.
Fix from: Mateusz Guzik Tested by: Jason Unovitch
MFC of 291743: We need to zero out the clustering variables in a freed vnode structure. For completeness add a VNASSERT that there are no threads waiting on a range lock (this was previously checked on every vnode free).
Reported by; Rick Macklem Fix from: Mateusz Guzik
|
#
285402 |
|
11-Jul-2015 |
kib |
MFC r284887: Handle errors from background write of the cylinder group blocks.
MFC r284927: Simplify code.
Approved by: re (gjb)
|
#
284993 |
|
01-Jul-2015 |
kib |
MFC r284495: Keep a vnode which is freed but still owing inactivation, on the active list. This closes a race where such vnode is not msync-ed until reboot.
|
#
284021 |
|
05-Jun-2015 |
kib |
MFC r283735: Remove several write-only variables.
|
#
283640 |
|
27-May-2015 |
mckusick |
MFC of 269533:
Limit the number of cylinder groups that will be searched when trying to build a cluster. The limit is tunable using the sysctl vfs.ffs.maxclustersearch. The current limit is 10 cylinder groups per block allocation. It was previously limited to the number of cylinder groups in the filesystem per block allocation. When there were no clusters of the needed size left, it repeatedly searched the whole filesystem for a non-existent cluster on every block allocation. The result was very slow filesystem allocation with 100% CPU utilization. The old behavior can be had by setting vfs.ffs.maxclustersearch to a huge number (1,000,000).
This change affects only the layout policy routines so is not able to interfere with the integrity of the filesystem.
Reported by: Dmitry Sivachenko (demon@) Tested by: Dmitry Sivachenko (demon@)
|
#
282270 |
|
30-Apr-2015 |
rmacklem |
MFC: r281562 File systems that do not use the buffer cache (such as ZFS) must use VOP_FSYNC() to perform the NFS server's Commit operation. This patch adds a mnt_kern_flag called MNTK_USES_BCACHE which is set by file systems that use the buffer cache. If this flag is not set, the NFS server always does a VOP_FSYNC(). This should be ok for old file system modules that do not set MNTK_USES_BCACHE, since calling VOP_FSYNC() is correct, although it might not be optimal for file systems that use the buffer cache.
|
#
281350 |
|
10-Apr-2015 |
kib |
MFC r280760: Fix the hand after the immediate reboot after the init binary is unlinked.
MFC r280763: Fix build (with gcc).
|
#
270694 |
|
26-Aug-2014 |
kib |
MFC r270203: Correct the test for condition to suspend UFS filesystem during unmount.
|
#
269171 |
|
27-Jul-2014 |
kib |
MFC r268612: Add helper helper vfs_write_suspend_umnt().
Fix the bug in the FFS unmount, when suspension failed, the ufs extattrs were not reinitialized.
|
#
262779 |
|
05-Mar-2014 |
pfg |
MFC r262678; ufs: small formatting fixes.
Cleanup some extra space. Use of tabs vs. spaces. No functional change.
Reviewed by: mckusick
|
#
260078 |
|
30-Dec-2013 |
mckusick |
MFC of 256801, 256803, 256808, 256812, 256817, 256845, and 256860. This set of changes puts in place the infrastructure to allow soft updates to be multi-threaded. It introduces no functional changes from its current operation.
MFC of 256860:
Allow kernels without options SOFTUPDATES to build. This should fix the embedded tinderboxes.
Reviewed by: emaste
MFC of 256845:
Fix build problem on ARM (which defaults to building without soft updates).
Reported by: Tinderbox Sponsored by: Netflix
MFC of 256817:
Restructuring of the soft updates code to set it up so that the single kernel-wide soft update lock can be replaced with a per-filesystem soft-updates lock. This per-filesystem lock will allow each filesystem to have its own soft-updates flushing thread rather than being limited to a single soft-updates flushing thread for the entire kernel.
Move soft update variables out of the ufsmount structure and into their own mount_softdeps structure referenced by ufsmount field um_softdep. Eventually the per-filesystem lock will be in this structure. For now there is simply a pointer to the kernel-wide soft updates lock.
Change all instances of ACQUIRE_LOCK and FREE_LOCK to pass the lock pointer in the mount_softdeps structure instead of a pointer to the kernel-wide soft-updates lock.
Replace the five hash tables used by soft updates with per-filesystem copies of these tables allocated in the mount_softdeps structure.
Several functions that flush dependencies when too many are allocated in the kernel used to operate across all filesystems. They are now parameterized to flush dependencies from a specified filesystem. For now, we stick with the round-robin flushing strategy when the kernel as a whole has too many dependencies allocated.
While there are many lines of changes, there should be no functional change in the operation of soft updates.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256812:
Fourth of several cleanups to soft dependency implementation. Add KASSERTS that soft dependency functions only get called for filesystems running with soft dependencies. Calling these functions when soft updates are not compiled into the system become panic's.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256808:
Third of several cleanups to soft dependency implementation. Ensure that softdep_unmount() and softdep_setup_sbupdate() only get called for filesystems running with soft dependencies.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256803:
Second of several cleanups to soft dependency implementation. Delete two unused functions in ffs_sofdep.c.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256801:
First of several cleanups to soft dependency implementation. Convert three functions exported from ffs_softdep.c to static functions as they are not used outside of ffs_softdep.c.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
|
#
285402 |
|
11-Jul-2015 |
kib |
MFC r284887: Handle errors from background write of the cylinder group blocks.
MFC r284927: Simplify code.
Approved by: re (gjb)
|
#
284993 |
|
01-Jul-2015 |
kib |
MFC r284495: Keep a vnode which is freed but still owing inactivation, on the active list. This closes a race where such vnode is not msync-ed until reboot.
|
#
284021 |
|
05-Jun-2015 |
kib |
MFC r283735: Remove several write-only variables.
|
#
283640 |
|
27-May-2015 |
mckusick |
MFC of 269533:
Limit the number of cylinder groups that will be searched when trying to build a cluster. The limit is tunable using the sysctl vfs.ffs.maxclustersearch. The current limit is 10 cylinder groups per block allocation. It was previously limited to the number of cylinder groups in the filesystem per block allocation. When there were no clusters of the needed size left, it repeatedly searched the whole filesystem for a non-existent cluster on every block allocation. The result was very slow filesystem allocation with 100% CPU utilization. The old behavior can be had by setting vfs.ffs.maxclustersearch to a huge number (1,000,000).
This change affects only the layout policy routines so is not able to interfere with the integrity of the filesystem.
Reported by: Dmitry Sivachenko (demon@) Tested by: Dmitry Sivachenko (demon@)
|
#
282270 |
|
30-Apr-2015 |
rmacklem |
MFC: r281562 File systems that do not use the buffer cache (such as ZFS) must use VOP_FSYNC() to perform the NFS server's Commit operation. This patch adds a mnt_kern_flag called MNTK_USES_BCACHE which is set by file systems that use the buffer cache. If this flag is not set, the NFS server always does a VOP_FSYNC(). This should be ok for old file system modules that do not set MNTK_USES_BCACHE, since calling VOP_FSYNC() is correct, although it might not be optimal for file systems that use the buffer cache.
|
#
281350 |
|
10-Apr-2015 |
kib |
MFC r280760: Fix the hand after the immediate reboot after the init binary is unlinked.
MFC r280763: Fix build (with gcc).
|
#
270694 |
|
26-Aug-2014 |
kib |
MFC r270203: Correct the test for condition to suspend UFS filesystem during unmount.
|
#
269171 |
|
27-Jul-2014 |
kib |
MFC r268612: Add helper helper vfs_write_suspend_umnt().
Fix the bug in the FFS unmount, when suspension failed, the ufs extattrs were not reinitialized.
|
#
262779 |
|
05-Mar-2014 |
pfg |
MFC r262678; ufs: small formatting fixes.
Cleanup some extra space. Use of tabs vs. spaces. No functional change.
Reviewed by: mckusick
|
#
260078 |
|
30-Dec-2013 |
mckusick |
MFC of 256801, 256803, 256808, 256812, 256817, 256845, and 256860. This set of changes puts in place the infrastructure to allow soft updates to be multi-threaded. It introduces no functional changes from its current operation.
MFC of 256860:
Allow kernels without options SOFTUPDATES to build. This should fix the embedded tinderboxes.
Reviewed by: emaste
MFC of 256845:
Fix build problem on ARM (which defaults to building without soft updates).
Reported by: Tinderbox Sponsored by: Netflix
MFC of 256817:
Restructuring of the soft updates code to set it up so that the single kernel-wide soft update lock can be replaced with a per-filesystem soft-updates lock. This per-filesystem lock will allow each filesystem to have its own soft-updates flushing thread rather than being limited to a single soft-updates flushing thread for the entire kernel.
Move soft update variables out of the ufsmount structure and into their own mount_softdeps structure referenced by ufsmount field um_softdep. Eventually the per-filesystem lock will be in this structure. For now there is simply a pointer to the kernel-wide soft updates lock.
Change all instances of ACQUIRE_LOCK and FREE_LOCK to pass the lock pointer in the mount_softdeps structure instead of a pointer to the kernel-wide soft-updates lock.
Replace the five hash tables used by soft updates with per-filesystem copies of these tables allocated in the mount_softdeps structure.
Several functions that flush dependencies when too many are allocated in the kernel used to operate across all filesystems. They are now parameterized to flush dependencies from a specified filesystem. For now, we stick with the round-robin flushing strategy when the kernel as a whole has too many dependencies allocated.
While there are many lines of changes, there should be no functional change in the operation of soft updates.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256812:
Fourth of several cleanups to soft dependency implementation. Add KASSERTS that soft dependency functions only get called for filesystems running with soft dependencies. Calling these functions when soft updates are not compiled into the system become panic's.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256808:
Third of several cleanups to soft dependency implementation. Ensure that softdep_unmount() and softdep_setup_sbupdate() only get called for filesystems running with soft dependencies.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256803:
Second of several cleanups to soft dependency implementation. Delete two unused functions in ffs_sofdep.c.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
MFC of 256801:
First of several cleanups to soft dependency implementation. Convert three functions exported from ffs_softdep.c to static functions as they are not used outside of ffs_softdep.c.
No functional change.
Tested by: Peter Holm and Scott Long Sponsored by: Netflix
|