# Re: Concurrent FIEMAP on reflinked files serialises on the AGF buffer lock

- From: Christoph Hellwig \<hch@infradead.org\>
- Date: 2026-11-06 15:20:04 
- List: linux-api
- Page: https://ratatoskr.run/linux-api/2026/11/17879347
- Thread: https://ratatoskr.run/linux-xfs/2026/11/17847165/t.md

```text
On Fri, Nov 06, 2026 at 02:23:55PM +0200, Lauri Gates wrote:
> Mirroring XFS_DIFLAG2_REFLINK, the flag would mean "may have shared
> extents", which is all a du tool needs to decide whether to look
> closer. If it helps, I can write the patch.

Please do.  The main question are:

 - do we want it in fileattr_get or as a STATX_ATTR_ in statx.
 - how do we make the query reliable, and do we even need to?

Besides xfs, btrfs and ocfs2 also support reflinks, and nfs (and maybe
cifs?) can export the semanics remotely.  So we really need a way
to indicate if the file system could support reflinks to start with,
and then one that the file could, so we probably need two bits

```
