Re: [V3 PATCH 1/2] tmpfs: add fallocate support

From: Pekka Enberg
Date: Wed Nov 23 2011 - 16:11:28 EST


On Wed, Nov 23, 2011 at 9:59 PM, KOSAKI Motohiro
<kosaki.motohiro@xxxxxxxxxxxxxx> wrote:
>> +
>> +       goto unlock;
>> +
>> +undo:
>> +       while (index > start) {
>> +               shmem_truncate_page(inode, index);
>> +               index--;
>
> Hmmm...
> seems too aggressive truncate if the file has pages before starting fallocate.
> but I have no idea to make better undo. ;)

Why do we need to undo anyway?

Pekka
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/