From: adilger Date: Wed, 19 Jun 2002 18:41:35 +0000 (+0000) Subject: Remove debugging from htree patch, sync with branch. X-Git-Tag: v1_7_100~5503 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=5251c2def55226d288013eb331e1535abf8f04e8;p=fs%2Flustre-release.git Remove debugging from htree patch, sync with branch. --- diff --git a/lustre/extN/htree-ext3-2.4.18.diff b/lustre/extN/htree-ext3-2.4.18.diff index 284dc78..0579601 100644 --- a/lustre/extN/htree-ext3-2.4.18.diff +++ b/lustre/extN/htree-ext3-2.4.18.diff @@ -132,10 +132,10 @@ + +struct dx_root +{ -+ struct fake_dirent fake1; -+ char dot1[4]; -+ struct fake_dirent fake2; -+ char dot2[4]; ++ struct fake_dirent dot; ++ char dot_name[4]; ++ struct fake_dirent dotdot; ++ char dotdot_name[4]; + struct dx_root_info + { + le_u32 reserved_zero; @@ -237,13 +237,14 @@ + +static inline unsigned dx_root_limit (struct inode *dir, unsigned infosize) +{ -+ unsigned entry_space = dir->i_sb->s_blocksize - 24 - infosize; ++ unsigned entry_space = dir->i_sb->s_blocksize - EXT3_DIR_REC_LEN(1) - ++ EXT3_DIR_REC_LEN(2) - infosize; + return 0? 20: entry_space / sizeof(struct dx_entry); +} + +static inline unsigned dx_node_limit (struct inode *dir) +{ -+ unsigned entry_space = dir->i_sb->s_blocksize - sizeof(struct fake_dirent); ++ unsigned entry_space = dir->i_sb->s_blocksize - EXT3_DIR_REC_LEN(0); + return 0? 22: entry_space / sizeof(struct dx_entry); +} + @@ -259,7 +260,6 @@ + hash1 = hash0; + hash0 = hash; + } -+ return 80; /* FIXME: for test only */ + return hash0; +} + @@ -1036,7 +1036,7 @@ + de = de2; + de->rec_len = cpu_to_le16(data1 + blocksize - (char *) de); + /* Initialize the root; the dot dirents already exist */ -+ de = (ext3_dirent *) (&root->fake2); ++ de = (ext3_dirent *) (&root->dotdot); + de->rec_len = cpu_to_le16(blocksize - EXT3_DIR_REC_LEN(2)); + memset (&root->info, 0, sizeof(root->info)); + root->info.info_length = sizeof(root->info);