From: Idan Kedar Date: Fri, 30 Nov 2012 14:03:31 +0000 (+0200) Subject: exofs: clean up the correct page collection on write error X-Git-Tag: v3.8-rc1~70^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=af402ab2b0369c2b1acf4cde72c5ed5050c74e5b;p=pandora-kernel.git exofs: clean up the correct page collection on write error if ore_write() fails, we would unlock the pages of pcol, which is now empty, rather than pcol_copy which owns the pages when ore_write() is called. this means that no pages will actually be unlocked (pcol.nr_pages == 0) and the writing process (more accurately, the syncing process) will hang waiting for a writeback notification that never comes. moreover, if ore_write() fails, pcol_free() is called for pcol, whereas pcol_copy is the object owning the ore_io_state, thus leaking the ore_io_state. [Boaz] I have simplified Idan's original patch a bit, everything else still holds Signed-off-by: Idan Kedar Signed-off-by: Boaz Harrosh --- Reading git-diff-tree failed