1 /* 2 * This header was generated from the Linux kernel headers by update_headers.py, 3 * to provide necessary information from kernel to userspace, such as constants, 4 * structures, and macros, and thus, contains no copyrightable information. 5 */ 6 #ifndef _LINUX_FIEMAP_H 7 #define _LINUX_FIEMAP_H 8 #include <linux/types.h> 9 struct fiemap_extent { 10 __u64 fe_logical; 11 __u64 fe_physical; 12 __u64 fe_length; 13 __u64 fe_reserved64[2]; 14 __u32 fe_flags; 15 __u32 fe_reserved[3]; 16 }; 17 struct fiemap { 18 __u64 fm_start; 19 __u64 fm_length; 20 __u32 fm_flags; 21 __u32 fm_mapped_extents; 22 __u32 fm_extent_count; 23 __u32 fm_reserved; 24 struct fiemap_extent fm_extents[0]; 25 }; 26 #define FIEMAP_MAX_OFFSET (~0ULL) 27 #define FIEMAP_FLAG_SYNC 0x00000001 28 #define FIEMAP_FLAG_XATTR 0x00000002 29 #define FIEMAP_FLAG_CACHE 0x00000004 30 #define FIEMAP_FLAGS_COMPAT (FIEMAP_FLAG_SYNC | FIEMAP_FLAG_XATTR) 31 #define FIEMAP_EXTENT_LAST 0x00000001 32 #define FIEMAP_EXTENT_UNKNOWN 0x00000002 33 #define FIEMAP_EXTENT_DELALLOC 0x00000004 34 #define FIEMAP_EXTENT_ENCODED 0x00000008 35 #define FIEMAP_EXTENT_DATA_ENCRYPTED 0x00000080 36 #define FIEMAP_EXTENT_NOT_ALIGNED 0x00000100 37 #define FIEMAP_EXTENT_DATA_INLINE 0x00000200 38 #define FIEMAP_EXTENT_DATA_TAIL 0x00000400 39 #define FIEMAP_EXTENT_UNWRITTEN 0x00000800 40 #define FIEMAP_EXTENT_MERGED 0x00001000 41 #define FIEMAP_EXTENT_SHARED 0x00002000 42 #endif 43