From: Aneesh Kumar K.V Date: Sat, 2 Aug 2008 22:51:32 +0000 (-0400) Subject: ext4: Fix data corruption when writing to prealloc area X-Git-Tag: v2.6.27-rc2~71^2~17 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d03856bd5e5abac717da137dc60fe4a691769bd0;p=pandora-kernel.git ext4: Fix data corruption when writing to prealloc area Inserting an extent can cause a new entry in the already existing index block. That doesn't increase the depth of the instead. Instead it adds a new leaf block. Now with the new leaf block the path information corresponding to the logical block should be fetched from the new block. The old path will be pointing to the old leaf block. We need to recalucate the path information on extent insert even if depth doesn't change. Without this change, the extent merge after converting an unwritten extent to initialized extent takes the wrong extent and cause data corruption. Signed-off-by: Aneesh Kumar K.V Signed-off-by: Mingming Cao Signed-off-by: "Theodore Ts'o" --- Reading git-diff-tree failed