On Thu, Jul 03, 2008 at 08:11:38AM -0400, jim owens wrote: > Dave Chinner wrote: > >> xfs_bmap provides an atomic sync and mapping. If the >> FIEMAP_FLAG_SYNC is pushed down to the filesystem, then XFS >> and all other filesystems can provide that same atomicity if >> desired. > > That is exactly what I was afraid of. Why? Have you ever used an extent mapping interface before? > We are back to the "because XFS has it" argument. Given that one of the original desires was to have the fiemap ioctl *replace the XFS ioctl*, I'm kinda getting sick of people saying "we don't want this because only it's only an XFS feature" depsite the fact that wإat we are doing here is re-implemented long standing XFS interfaces. XFS is going to have to maintain two extent mapping interfaces forever more because we don't have everything in fiemap that we need to replace the XFS ioctl. The point of this SYNC flag is to ensure that you get nothing other than blocks mapped to disk - no delalloc regions, etc. The only sane way to do that is an atomic 'sync+map' operation. This is not a filesystem specific feature - it's what the SYNC flag should be defined as providing. The fact that it's only implemented in XFS right now has absolutely *zero* consideration in determining this feature is necessary or not. The fact that the only existing extent mapping interface in Linux already defines it this way and it is in use by existing userspace utilities that *expect this semantic* is much, much more important. Speaking of which, some of the features in fiemap are currently OCFS2 specific, some that are Lustre(!) specific or not even used by current filesystems or implementations of fiemap. However, nobody is complaining that they should be ripped out just because they are only implemented in filesystem X.... FWIW, if ext4 had this atomic sync+map (which it could do), would you still be complaining about it? Cheers, Dave. -- Dave Chinner david@xxxxxxxxxxxxx -- 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