On 07/06/2016 03:57 PM, Vegard Nossum wrote: > If we hit this error when mounted with errors=continue or > errors=remount-ro: > > EXT4-fs error (device loop0): ext4_mb_mark_diskspace_used:2940: comm ext4.exe: Allocating blocks 5090-6081 which overlap fs metadata > > then ext4_mb_new_blocks() will call ext4_mb_release_context() and try to > continue. However, ext4_mb_release_context() is the wrong thing to call > here since we are still actually using the allocation context. > > Instead, handle it the same way that we handle other errors, except that > we retry the allocation instead of immediately returning an error (if we > were mounted with errors=continue, then ext4_mb_mark_diskspace_used() > should have fixed the original error and will either succeed or give a > different error; if we were mounted with errors=remount-ro, then it will > not be able to fix the original error and will raise a different error). This didn't really work as I thought and I'm now getting stuck in an infinite loop here where it tries (and fails) to allocate the same blocks over and over. The attached new patch just returns on error instead of trying to fix the problem. Vegard