summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/btrfs_inode.h
diff options
context:
space:
mode:
authorJosef Bacik2008-07-24 18:12:38 +0200
committerChris Mason2008-09-25 17:04:05 +0200
commitaec7477b3b0e8ec93f6d274f25ba40b0665134d4 (patch)
tree2f689681e2f1b48d1c42b2242e21cbf456ec4c55 /fs/btrfs/btrfs_inode.h
parentBtrfs: Fix the defragmention code and the block relocation code for data=ordered (diff)
downloadkernel-qcow2-linux-aec7477b3b0e8ec93f6d274f25ba40b0665134d4.tar.gz
kernel-qcow2-linux-aec7477b3b0e8ec93f6d274f25ba40b0665134d4.tar.xz
kernel-qcow2-linux-aec7477b3b0e8ec93f6d274f25ba40b0665134d4.zip
Btrfs: Implement new dir index format
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/btrfs_inode.h')
-rw-r--r--fs/btrfs/btrfs_inode.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/fs/btrfs/btrfs_inode.h b/fs/btrfs/btrfs_inode.h
index 3bf40591742a..b7bd60e4fdd7 100644
--- a/fs/btrfs/btrfs_inode.h
+++ b/fs/btrfs/btrfs_inode.h
@@ -43,6 +43,21 @@ struct btrfs_inode {
u64 delalloc_bytes;
u64 disk_i_size;
u32 flags;
+
+ /*
+ * if this is a directory then index_cnt is the counter for the index
+ * number for new files that are created
+ */
+ u64 index_cnt;
+
+ /*
+ * index holds the directory index for this inode on creation, so
+ * add_link can do what its supposed to. This isn't populated when the
+ * inode is read because there isn't really a reason to know this unless
+ * we are creating the directory index or deleting it, and deletion
+ * reads the index off of the inode reference at unlink time.
+ */
+ u64 index;
};
static inline struct btrfs_inode *BTRFS_I(struct inode *inode)