]> git.ipfire.org Git - thirdparty/linux.git/commit
NFS: nfs_lock_and_join_requests and nfs_scan_commit_list can deadlock
authorTrond Myklebust <trond.myklebust@primarydata.com>
Sat, 9 Sep 2017 16:28:01 +0000 (12:28 -0400)
committerTrond Myklebust <trond.myklebust@primarydata.com>
Sat, 9 Sep 2017 16:28:01 +0000 (12:28 -0400)
commit137da553dba62dfc64fb8f4ccb5be769acbf615e
tree18e8bb3b882b37c585e0b498784fe627da90481a
parent196639ebbe63a037fe9a80669140bd292d8bcd80
NFS: nfs_lock_and_join_requests and nfs_scan_commit_list can deadlock

Since the commit list is not ordered, it is possible for nfs_scan_commit_list
to hold a request that nfs_lock_and_join_requests() is waiting for, while
at the same time trying to grab a request that nfs_lock_and_join_requests
already holds.

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
fs/nfs/pnfs_nfs.c
fs/nfs/write.c