On Wed, Jun 03, 2009 at 12:14:19PM -0600, Andreas Dilger wrote: > > Since some applications open files with open(..., O_WRONLY|O_CREAT|O_TRUNC) > to avoid re-using existing files (and avoiding the need to check if the > file already exists to modify the flags), it would make sense to set > EXT4_STATE_DA_ALLOC_CLOSE only if the file previously had some data in it. > > By the time we get to ext4_truncate() i_size is overwritten already, but > it might make sense to also check i_disksize != 0 before setting this flag. > Otherwise delayed allocation may be inadvertently disabled for these apps > when it should not be. Agreed; I'll make such a change for the ext4 patch queue. We can propagate such a patch to the -stable kernels once it's in mainline. - 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