Re: [PATCH RFC] add FIEMAP_FLAG_DISCARD support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Nov 4, 2013, at 2:57 PM, Dave Chinner <david@xxxxxxxxxxxxx> wrote:
> On Sun, Nov 03, 2013 at 06:42:00PM -0500, Theodore Ts'o wrote:
>> On Mon, Nov 04, 2013 at 10:14:42AM +1100, Dave Chinner wrote:
>>> 
>>> FIEMAP is not the correct interface for data modifying operations.
>>> It is an interface that returns information about file metadata (i.e
>>> the layout of a file) - it is not an interface for modifying the
>>> contents of the file.
>> 
>> Well, it's been argued that FIEMAP was designed to be extensible, and
>> we should use it for other operations.  Where the bounds of that
>> stretches to is certainly an arguable point, and I can understand your
>> observation that something which causes a change to the contents of
>> the file might not be best choice.
> 
> Yes, I agree it is extensible, but it was never intended to be
> extended into a data modification ioctl. It's for querying metadata
> related to file data, not for modifying file data.

I’d agree with Dave here - there is nothing about FIEMAP that indicates
it is an interface for data modification, only for reporting out the
underlying layout of a file.  I think falloc() is already used in this
regard for hole punching, and it makes more sense to me to extend that
for the discard interface as well.

Cheers, Andreas





--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux