PERFORCE change 180105 for review
Zheng Liu
lz at FreeBSD.org
Tue Jun 22 11:33:11 UTC 2010
http://p4web.freebsd.org/@@180105?ac=10
Change 180105 by lz at gnehzuil-freebsd on 2010/06/22 11:32:20
Add three data structures into ext2_extents.h.
Affected files ...
.. //depot/projects/soc2010/ext4fs/src/sys/fs/ext2fs/ext2_extents.h#2 edit
Differences ...
==== //depot/projects/soc2010/ext4fs/src/sys/fs/ext2fs/ext2_extents.h#2 (text+ko) ====
@@ -28,4 +28,37 @@
#ifndef _FS_EXT2FS_EXT2_EXTENTS_H_
#define _FS_EXT2FS_EXT2_EXTENTS_H_
+#define EXT4_EXT_MAGIC 0xf30a
+
+/*
+ * ext4 file system extent on disk
+ */
+struct ext4_extent {
+ u_int32_t e_blk; /* first logical block */
+ u_int16_t e_len; /* number of blocks */
+ u_int16_t e_start_hi; /* high 16 bits of physical block */
+ u_int32_t e_start_lo; /* low 32 bits of physical block */
+};
+
+/*
+ * extent index on disk
+ */
+struct ext4_extent_index {
+ u_int32_t ei_blk; /* indexes logical blocks */
+ u_int32_t ei_leaf_lo; /* pointes to physical block of the next level */
+ u_int16_t ei_leaf_hi; /* high 16 bits of physical block */
+ u_int16_t ei_unused;
+};
+
+/*
+ * extent tree header
+ */
+struct ext4_extent_header {
+ u_int16_t eh_magic; /* magic number: 0xf30a */
+ u_int16_t eh_ecount; /* number of valid entries */
+ u_int16_t eh_max; /* capacity of store in entries */
+ u_int16_t eh_depth; /* the depth of extent tree */
+ u_int32_t eh_gen; /* generation of extent tree */
+};
+
#endif /* !_FS_EXT2FS_EXT2_EXTENTS_H_ */
More information about the p4-projects
mailing list