From: Theodore Ts'o Date: Thu, 27 Dec 2012 06:42:48 +0000 (-0500) Subject: ext4: lock i_mutex when truncating orphan inodes X-Git-Tag: v3.2.47~56 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=547bb54d9d41a867765cb414754472a437ad279f;p=pandora-kernel.git ext4: lock i_mutex when truncating orphan inodes commit 721e3eba21e43532e438652dd8f1fcdfce3187e7 upstream. Commit c278531d39 added a warning when ext4_flush_unwritten_io() is called without i_mutex being taken. It had previously not been taken during orphan cleanup since races weren't possible at that point in the mount process, but as a result of this c278531d39, we will now see a kernel WARN_ON in this case. Take the i_mutex in ext4_orphan_cleanup() to suppress this warning. Reported-by: Alexander Beregalov Signed-off-by: "Theodore Ts'o" Reviewed-by: Zheng Liu Signed-off-by: Ben Hutchings --- Reading git-diff-tree failed