Commit d0d856e8 authored by Randy Dunlap's avatar Randy Dunlap Committed by Linus Torvalds

[PATCH] ext4: clean up comments in ext4-extents patch

Signed-off-by: default avatarRandy Dunlap <rdunlap@xenotime.net>
Signed-off-by: default avatarDave Kleikamp <shaggy@austin.ibm.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 471d4011
This diff is collapsed.
...@@ -22,29 +22,29 @@ ...@@ -22,29 +22,29 @@
#include <linux/ext4_fs.h> #include <linux/ext4_fs.h>
/* /*
* with AGRESSIVE_TEST defined capacity of index/leaf blocks * With AGRESSIVE_TEST defined, the capacity of index/leaf blocks
* become very little, so index split, in-depth growing and * becomes very small, so index split, in-depth growing and
* other hard changes happens much more often * other hard changes happen much more often.
* this is for debug purposes only * This is for debug purposes only.
*/ */
#define AGRESSIVE_TEST_ #define AGRESSIVE_TEST_
/* /*
* with EXTENTS_STATS defined number of blocks and extents * With EXTENTS_STATS defined, the number of blocks and extents
* are collected in truncate path. they'll be showed at * are collected in the truncate path. They'll be shown at
* umount time * umount time.
*/ */
#define EXTENTS_STATS__ #define EXTENTS_STATS__
/* /*
* if CHECK_BINSEARCH defined, then results of binary search * If CHECK_BINSEARCH is defined, then the results of the binary search
* will be checked by linear search * will also be checked by linear search.
*/ */
#define CHECK_BINSEARCH__ #define CHECK_BINSEARCH__
/* /*
* if EXT_DEBUG is defined you can use 'extdebug' mount option * If EXT_DEBUG is defined you can use the 'extdebug' mount option
* to get lots of info what's going on * to get lots of info about what's going on.
*/ */
#define EXT_DEBUG__ #define EXT_DEBUG__
#ifdef EXT_DEBUG #ifdef EXT_DEBUG
...@@ -54,58 +54,58 @@ ...@@ -54,58 +54,58 @@
#endif #endif
/* /*
* if EXT_STATS is defined then stats numbers are collected * If EXT_STATS is defined then stats numbers are collected.
* these number will be displayed at umount time * These number will be displayed at umount time.
*/ */
#define EXT_STATS_ #define EXT_STATS_
/* /*
* ext4_inode has i_block array (60 bytes total) * ext4_inode has i_block array (60 bytes total).
* first 12 bytes store ext4_extent_header * The first 12 bytes store ext4_extent_header;
* the remain stores array of ext4_extent * the remainder stores an array of ext4_extent.
*/ */
/* /*
* this is extent on-disk structure * This is the extent on-disk structure.
* it's used at the bottom of the tree * It's used at the bottom of the tree.
*/ */
struct ext4_extent { struct ext4_extent {
__le32 ee_block; /* first logical block extent covers */ __le32 ee_block; /* first logical block extent covers */
__le16 ee_len; /* number of blocks covered by extent */ __le16 ee_len; /* number of blocks covered by extent */
__le16 ee_start_hi; /* high 16 bits of physical block */ __le16 ee_start_hi; /* high 16 bits of physical block */
__le32 ee_start; /* low 32 bigs of physical block */ __le32 ee_start; /* low 32 bits of physical block */
}; };
/* /*
* this is index on-disk structure * This is index on-disk structure.
* it's used at all the levels, but the bottom * It's used at all the levels except the bottom.
*/ */
struct ext4_extent_idx { struct ext4_extent_idx {
__le32 ei_block; /* index covers logical blocks from 'block' */ __le32 ei_block; /* index covers logical blocks from 'block' */
__le32 ei_leaf; /* pointer to the physical block of the next * __le32 ei_leaf; /* pointer to the physical block of the next *
* level. leaf or next index could bet here */ * level. leaf or next index could be there */
__le16 ei_leaf_hi; /* high 16 bits of physical block */ __le16 ei_leaf_hi; /* high 16 bits of physical block */
__u16 ei_unused; __u16 ei_unused;
}; };
/* /*
* each block (leaves and indexes), even inode-stored has header * Each block (leaves and indexes), even inode-stored has header.
*/ */
struct ext4_extent_header { struct ext4_extent_header {
__le16 eh_magic; /* probably will support different formats */ __le16 eh_magic; /* probably will support different formats */
__le16 eh_entries; /* number of valid entries */ __le16 eh_entries; /* number of valid entries */
__le16 eh_max; /* capacity of store in entries */ __le16 eh_max; /* capacity of store in entries */
__le16 eh_depth; /* has tree real underlaying blocks? */ __le16 eh_depth; /* has tree real underlying blocks? */
__le32 eh_generation; /* generation of the tree */ __le32 eh_generation; /* generation of the tree */
}; };
#define EXT4_EXT_MAGIC cpu_to_le16(0xf30a) #define EXT4_EXT_MAGIC cpu_to_le16(0xf30a)
/* /*
* array of ext4_ext_path contains path to some extent * Array of ext4_ext_path contains path to some extent.
* creation/lookup routines use it for traversal/splitting/etc * Creation/lookup routines use it for traversal/splitting/etc.
* truncate uses it to simulate recursive walking * Truncate uses it to simulate recursive walking.
*/ */
struct ext4_ext_path { struct ext4_ext_path {
ext4_fsblk_t p_block; ext4_fsblk_t p_block;
......
...@@ -28,8 +28,8 @@ ...@@ -28,8 +28,8 @@
* indirection blocks, the group and superblock summaries, and the data * indirection blocks, the group and superblock summaries, and the data
* block to complete the transaction. * block to complete the transaction.
* *
* For extents-enabled fs we may have to allocate and modify upto * For extents-enabled fs we may have to allocate and modify up to
* 5 levels of tree + root which is stored in inode. */ * 5 levels of tree + root which are stored in the inode. */
#define EXT4_SINGLEDATA_TRANS_BLOCKS(sb) \ #define EXT4_SINGLEDATA_TRANS_BLOCKS(sb) \
(EXT4_HAS_INCOMPAT_FEATURE(sb, EXT4_FEATURE_INCOMPAT_EXTENTS) \ (EXT4_HAS_INCOMPAT_FEATURE(sb, EXT4_FEATURE_INCOMPAT_EXTENTS) \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment