Tristan Ye 9a790ba1ec ocfs2: skip existing hole when removing the last extent_rec in punching-hole codes.
In the case of removing a partial extent record which covers a hole, current
punching-hole logic will try to remove more than the length of whole extent
record, which leads to the failure of following assert(fs/ocfs2/alloc.c):

5507         BUG_ON(cpos < le32_to_cpu(rec->e_cpos) || trunc_range > rec_range);

This patch tries to skip existing hole at the last attempt of removing a partial
extent record, what's more, it also adds some necessary comments for better
understanding of punching-hole codes.

Signed-off-by: Tristan Ye <tristan.ye@oracle.com>
Signed-off-by: Joel Becker <jlbec@evilplan.org>
2011-05-13 11:26:20 -07:00
..
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-17 14:02:57 +01:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2010-09-08 14:25:53 +08:00
2010-09-10 09:18:15 -07:00
2009-04-03 11:39:16 -07:00
2011-03-31 11:26:23 -03:00
2010-09-10 09:18:15 -07:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-07 16:43:21 +08:00
2011-02-21 11:18:23 +08:00
2011-03-17 14:02:57 +01:00
2011-02-22 21:59:46 +08:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-07 16:43:21 +08:00
2011-02-24 16:22:20 +08:00
2011-03-31 11:26:23 -03:00