Skip to content

Commit

Permalink
iomap: renumber IOMAP_HOLE to 0
Browse files Browse the repository at this point in the history
Instead of keeping a separate unnamed state for uninitialized iomaps,
renumber IOMAP_HOLE to zero so that an uninitialized iomap is treated
as a hole.

Suggested-by: Darrick J. Wong <[email protected]>
Signed-off-by: Christoph Hellwig <[email protected]>
Reviewed-by: Darrick J. Wong <[email protected]>
Signed-off-by: Darrick J. Wong <[email protected]>
  • Loading branch information
Christoph Hellwig authored and djwong committed Oct 21, 2019
1 parent 32a38a4 commit eb81cf9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions include/linux/iomap.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ struct vm_fault;
/*
* Types of block ranges for iomap mappings:
*/
#define IOMAP_HOLE 0x01 /* no blocks allocated, need allocation */
#define IOMAP_DELALLOC 0x02 /* delayed allocation blocks */
#define IOMAP_MAPPED 0x03 /* blocks allocated at @addr */
#define IOMAP_UNWRITTEN 0x04 /* blocks allocated at @addr in unwritten state */
#define IOMAP_INLINE 0x05 /* data inline in the inode */
#define IOMAP_HOLE 0 /* no blocks allocated, need allocation */
#define IOMAP_DELALLOC 1 /* delayed allocation blocks */
#define IOMAP_MAPPED 2 /* blocks allocated at @addr */
#define IOMAP_UNWRITTEN 3 /* blocks allocated at @addr in unwritten state */
#define IOMAP_INLINE 4 /* data inline in the inode */

/*
* Flags reported by the file system from iomap_begin:
Expand Down

0 comments on commit eb81cf9

Please sign in to comment.