mirror of
https://github.com/opnsense/src.git
synced 2026-02-27 03:40:37 -05:00
When coding the pNFS server, I added several vn_start_write() calls done while the vnode was locked, not realizing I had introduced LORs and possible deadlock when an exported file system on the MDS is suspended. This patch fixes this by removing the added vn_start_write() calls and modifying the code so that the extant vn_start_write() call before the NFS RPC/operation is done when needed by the pNFS server. Flags are changed so that LayoutCommit and LayoutReturn now get a vn_start_write() done for them. When the pNFS server is enabled, the code now also changes the flags for Getattr, so that the vn_start_write() is done for Getattr, since it may need to do a vn_set_extattr(). The nfs_writerpc flag array was made global to the NFS server and renamed nfsrv_writerpc, which is consistent naming for globals in the NFS server. Thanks go to kib@ for reporting that doing vn_start_write() while the vnode is locked results in a LOR. This patch only affects the behaviour of the pNFS server. |
||
|---|---|---|
| .. | ||
| nfs_fha_new.c | ||
| nfs_fha_new.h | ||
| nfs_nfsdcache.c | ||
| nfs_nfsdkrpc.c | ||
| nfs_nfsdport.c | ||
| nfs_nfsdserv.c | ||
| nfs_nfsdsocket.c | ||
| nfs_nfsdstate.c | ||
| nfs_nfsdsubs.c | ||