From ecd50729f772f0b982ddbb76c16ee4bc8f495e17 Mon Sep 17 00:00:00 2001 From: Christoph Hellwig Date: Mon, 19 Sep 2016 11:24:37 +1000 Subject: [PATCH] iomap: add IOMAP_F_NEW flag Signed-off-by: Christoph Hellwig Reviewed-by: Ross Zwisler Signed-off-by: Dave Chinner --- fs/xfs/xfs_iomap.c | 1 + include/linux/iomap.h | 1 + 2 files changed, 2 insertions(+) diff --git a/fs/xfs/xfs_iomap.c b/fs/xfs/xfs_iomap.c index f96c8ffce5f4..ac677d032e3a 100644 --- a/fs/xfs/xfs_iomap.c +++ b/fs/xfs/xfs_iomap.c @@ -1000,6 +1000,7 @@ xfs_file_iomap_begin( if (error) return error; + iomap->flags = IOMAP_F_NEW; trace_xfs_iomap_alloc(ip, offset, length, 0, &imap); } else { ASSERT(nimaps); diff --git a/include/linux/iomap.h b/include/linux/iomap.h index 3d70ece10313..14d7067f8b06 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h @@ -22,6 +22,7 @@ struct vm_fault; * Flags for iomap mappings: */ #define IOMAP_F_MERGED 0x01 /* contains multiple blocks/extents */ +#define IOMAP_F_NEW 0x02 /* blocks have been newly allocated */ /* * Magic value for blkno: -- 2.11.0