freebsd-nq/sys/nfsclient
Brian Feldman cc3149b1ea Fix a serious deadlock with the NFS client. Given a large enough
atomic write request, it can fill the buffer cache with the entirety
of that write in order to handle retries.  However, it never drops
the vnode lock, or else it wouldn't be atomic, so it ends up waiting
indefinitely for more buf memory that cannot be gotten as it has it
all, and it waits in an uncancellable state.

To fix this, hibufspace is exported and scaled to a reasonable
fraction.  This is used as the limit of how much of an atomic write
request by the NFS client will be handled asynchronously.  If the
request is larger than this, it will be turned into a synchronous
request which won't deadlock the system.  It's possible this value is
far off from what is required by some, so it shall be tunable as soon
as mount_nfs(8) learns of the new field.

The slowdown between an asynchronous and a synchronous write on NFS
appears to be on the order of 2x-4x.

General nod by:	gad
MFC after:	2 weeks
More testing:	wes
PR:		kern/79208
2005-06-10 23:50:41 +00:00
..
bootp_subr.c When netbooting, as soon as we've figured out which interface we booted 2005-04-26 20:45:29 +00:00
krpc_subr.c MFp4: use the function to fix the packet header length instead of rolling 2005-03-16 08:13:08 +00:00
krpc.h
nfs_bio.c Fix a serious deadlock with the NFS client. Given a large enough 2005-06-10 23:50:41 +00:00
nfs_diskless.c While I'm here, list the new kenv (boot.netif.name) along with the others. 2005-04-26 20:47:59 +00:00
nfs_lock.c For reasons unknown, the nfs locking code used a fifo to send requests to 2004-12-06 08:31:32 +00:00
nfs_lock.h For reasons unknown, the nfs locking code used a fifo to send requests to 2004-12-06 08:31:32 +00:00
nfs_nfsiod.c Drop Giant before calling kthread_exit(). 2005-02-07 18:21:50 +00:00
nfs_node.c - LK_NOPAUSE is a nop now. 2005-03-31 04:37:09 +00:00
nfs_socket.c set R_MUSTRESEND flag in mark_for_reconnect so re-connected requests get 2005-05-10 14:25:14 +00:00
nfs_subs.c - The VI_DOOMED flag now signals the end of a vnode's relationship with 2005-03-13 12:14:56 +00:00
nfs_vfsops.c Fix a serious deadlock with the NFS client. Given a large enough 2005-06-10 23:50:41 +00:00
nfs_vnops.c - cache_lookup() relocks the parent in the DOTDOT case for us. 2005-04-14 07:08:34 +00:00
nfs.h Remove unused cred arg from nfs_vinvalbuf() and many bogus arguments 2005-01-24 12:31:06 +00:00
nfsargs.h Fix a serious deadlock with the NFS client. Given a large enough 2005-06-10 23:50:41 +00:00
nfsdiskless.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
nfsm_subs.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
nfsmount.h Fix a serious deadlock with the NFS client. Given a large enough 2005-06-10 23:50:41 +00:00
nfsnode.h Use vfs_hash. 2005-03-16 11:28:19 +00:00
nfsstats.h /* -> /*- for license, minor formatting changes 2005-01-07 01:45:51 +00:00
nlminfo.h