Commits
Trond Myklebust authored and Pavel Emelianov committed fe6a0550cb9
[PATCH] nfs: fix req refcnt leak preventing umount Original Denis Lunev analyses: - nfs_direct_req_alloc creates dreq with dreq->kref->refcount == 2 - on success path the kref_put is called in nfs_direct_read_schedule -> nfs_direct_complete and in nfs_direct_wait - on error path only first put occured The same problem occures on direct_write path Mainstream patch version from Trond Myklebust <Trond.Myklebust@netapp.com>: The current code is leaking a reference to dreq->kref when the calls to nfs_direct_read_schedule() and nfs_direct_write_schedule() return an error. Thanks to Denis V. Lunev for spotting the bug and proposing the original fix. Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>