On Thu, Apr 22, 2010 at 08:31:11AM +0400, Dmitry Monakhov wrote: > If i_data_sem was internally dropped due to transaction restart, it is > necessary to restart path look-up because extents tree was possibly > modified by ext4_get_block(). > > https://bugzilla.kernel.org/show_bug.cgi?id=15827 > > Signed-off-by: Dmitry Monakhov <dmonakhov@xxxxxxxxxx> I *think* it would be more efficient to add the additional change: if (ext4_ext_more_to_rm(path + i)) { to: if ((err != -EAGAIN) && ext4_ext_more_to_rm(path + i)) { in ext4_ext_remove_space() but I would like your opinion... If we do this optimization I'll probably do it in a separate patch. It just seems that we're doing a lot of extra work once we fail to extend the transaction, so it would be good to optimize more of this out. It also makes it easier to convince oneself that that all of the spinning around that happens after returning EAGAIN won't cause any harm. After going through the patch carefully I'm pretty sure the extra work is pointless, but not harmful, but it's better to skip it entirely if it's not needed. - Ted -- To unsubscribe from this list: send the line "unsubscribe linux-ext4" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html