On Tue, Mar 29, 2016 at 09:21:28AM +0200, Christoph Hellwig wrote: > On Mon, Mar 28, 2016 at 12:51:40PM -0700, Darrick J. Wong wrote: > > > /* > > > + * The pNFS block layout spec actually supports reflink like > > > + * functionality, but the Linux pNFS server doesn't implement it yet. > > > + */ > > > + if (!xfs_is_reflink_inode(ip)) > > > + return -ENXIO; > > > > /me isn't familiar with pNFS, but doesn't this make it so that > > xfs_fs_map_blocks /only/ works on reflinked files? Maybe I'm misreading the > > comment, but it sounds to me like Linux doesn't support reflinked files over > > pNFS and therefore we want to disable this iomapping functionality any time we > > find a reflinked file. > > > > But maybe there's a subtlety here that I'm missing? > > You jsut missed me fat fingering the check :) Fair enough, I'll integrate this patch, but with: if (xfs_is_reflink_inode(ip)) return -ENXIO; > Btw, we'll need something similar to prevent swapfiles which just use > ->bmap, but unfortunately swap just checks for the existences of method, > so I'll probably have to do some VFS changes to properly support that. Yes, please. ocfs2 will gladly let you call swapon on a reflinked file, and totally fails to CoW it properly. :) --D > > _______________________________________________ > xfs mailing list > xfs@xxxxxxxxxxx > http://oss.sgi.com/mailman/listinfo/xfs _______________________________________________ xfs mailing list xfs@xxxxxxxxxxx http://oss.sgi.com/mailman/listinfo/xfs