Skip to contentSkip to conversation

Ext4 Punch Hole Support: Split Extents

PATCH Superseded Allison Henderson 1 participant 1 message Apr 19, 2011 ext4 file system

v5 of 7 Superseded Latest is v7 →

lore
Share & tools
lore
#0 lore raw

PATCH v5 2/6 Ext4 Punch Hole Support: Split Extents

The ext4_split_unwritten_extents routine has been modified to also handle initialized extents and renamed to ext4_ext_split_extents. This routine is used to split an extent that needs to be partially converted to an uninitialized extent.

---
:100644 100644 6c1f415... a256ba3... M fs/ext4/ext4.h
:100644 100644 0b186d9... 4d9f06d... M fs/ext4/extents.c

 fs/ext4/ext4.h    |    5 ++++
 fs/ext4/extents.c |   63 +++++++++++++++++++++++++++++++++++++++++-----------
 2 files changed, 54 insertions(+), 14 deletions(-)
fs/ext4/ext4.h +5 -0
index 6c1f415..a256ba3 100644
@@ -516,6 +516,11 @@ struct ext4_new_group_data {
 #define EXT4_GET_BLOCKS_PUNCH_OUT_EXT		0x0020
 
 /*
+ * Flags used by ext4_ext_split_extents
+ */
+#define EXT4_SPLIT_EXTENTS_UNWRITTEN	0x0001
+
+/*
  * Flags used by ext4_free_blocks
  */
 #define EXT4_FREE_BLOCKS_METADATA	0x0001
fs/ext4/extents.c +49 -14

147 lines not on this page · raw message

Signature · 1 line
1.7.1