[Top] [All Lists]

Re: [PATCH] xfstests 255: add a seek_data/seek_hole tester

To: P?draig Brady <P@xxxxxxxxxxxxxx>
Subject: Re: [PATCH] xfstests 255: add a seek_data/seek_hole tester
From: Christoph Hellwig <hch@xxxxxxxxxxxxx>
Date: Fri, 1 Jul 2011 05:37:02 -0400
Cc: Christoph Hellwig <hch@xxxxxxxxxxxxx>, linux-kernel@xxxxxxxxxxxxxxx, Josef Bacik <josef@xxxxxxxxxx>, xfs@xxxxxxxxxxx, viro@xxxxxxxxxxxxxxxxxx, linux-fsdevel@xxxxxxxxxxxxxxx, linux-btrfs@xxxxxxxxxxxxxxx
In-reply-to: <4E0B019E.8080800@xxxxxxxxxxxxxx>
References: <1309275199-10801-1-git-send-email-josef@xxxxxxxxxx> <1309275199-10801-5-git-send-email-josef@xxxxxxxxxx> <20110629065306.GC1026@dastard> <20110629074021.GA26086@xxxxxxxxxxxxx> <4E0B019E.8080800@xxxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Wed, Jun 29, 2011 at 11:42:38AM +0100, P?draig Brady wrote:
> There is the argument, that if this interface can distinguish
> these dirty unwritten extents, then why can't the fiemap interface too?
> The advantage of the fiemap interface is that it can distinguish
> empty extents vs holes. Empty extents will become increasingly common
> I think, given the fragmentation and space guarantee benefits they give.
> It would be cool for cp for example to be able to efficiently copy
> empty extents from source to dest.

That brings us back to square one.  FIEMAP is supposed to tell you about
the physical layout on disk.  Unwritten extents physically always are
there, but whether they might have to be copied depends entirely on
in-core state.  Finding that incore state in addition is not all that
easy compared to simply walking the extents.  People might decide it's
worth for an interface like SEEK_HOLE specificly asking for that, but
grafting it into FIEMAP through the backdoor is a horrible idea.

<Prev in Thread] Current Thread [Next in Thread>
  • Re: [PATCH] xfstests 255: add a seek_data/seek_hole tester, Christoph Hellwig <=