From: Trond Myklebust Date: Wed, 9 May 2012 18:30:35 +0000 (-0400) Subject: NFS: Prevent a deadlock in the new writeback code X-Git-Tag: v3.5-rc1~52^2~82 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3aff4ebb95b20ad8db2c1447e8c52097d89af5a7;p=pandora-kernel.git NFS: Prevent a deadlock in the new writeback code We have to unlock the nfs_page before we call nfs_end_page_writeback to avoid races with functions that expect the page to be unlocked when PG_locked and PG_writeback are not set. The problem is that nfs_unlock_request also releases the nfs_page, causing a deadlock if the release of the nfs_open_context triggers an iput() while the PG_writeback flag is still set... The solution is to separate the unlocking and release of the nfs_page, so that we can do the former before nfs_end_page_writeback and the latter after. Signed-off-by: Trond Myklebust Cc: Fred Isaman --- Reading git-diff-tree failed