diff options
author | Adrian Bunk <bunk@stusta.de> | 2006-01-09 23:54:52 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-10 11:02:03 -0500 |
commit | 9979ead5d1eb23191a00453559927c5abf9087e2 (patch) | |
tree | 50741cf0f7d99c0cc395c4549eef725335edafa6 | |
parent | f346f4b373aa320fb0337a3b504e3fb5344abc0b (diff) |
[PATCH] fs/hfsplus/: remove the hfsplus_inode_check() debug function
This patch removes the hfsplus_inode_check() debug function.
It also removes the now obsolete last_inode_cnt and inode_cnt from struct
hfsplus_sb_info.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r-- | fs/hfsplus/hfsplus_fs.h | 3 | ||||
-rw-r--r-- | fs/hfsplus/inode.c | 10 | ||||
-rw-r--r-- | fs/hfsplus/super.c | 19 |
3 files changed, 0 insertions, 32 deletions
diff --git a/fs/hfsplus/hfsplus_fs.h b/fs/hfsplus/hfsplus_fs.h index df16fcbff3fb..0fa1ab6250bf 100644 --- a/fs/hfsplus/hfsplus_fs.h +++ b/fs/hfsplus/hfsplus_fs.h | |||
@@ -143,9 +143,6 @@ struct hfsplus_sb_info { | |||
143 | 143 | ||
144 | unsigned long flags; | 144 | unsigned long flags; |
145 | 145 | ||
146 | atomic_t inode_cnt; | ||
147 | u32 last_inode_cnt; | ||
148 | |||
149 | struct hlist_head rsrc_inodes; | 146 | struct hlist_head rsrc_inodes; |
150 | }; | 147 | }; |
151 | 148 | ||
diff --git a/fs/hfsplus/inode.c b/fs/hfsplus/inode.c index 983bcd02ac1c..7acff6c5464f 100644 --- a/fs/hfsplus/inode.c +++ b/fs/hfsplus/inode.c | |||
@@ -182,11 +182,6 @@ static struct dentry *hfsplus_file_lookup(struct inode *dir, struct dentry *dent | |||
182 | igrab(dir); | 182 | igrab(dir); |
183 | hlist_add_head(&inode->i_hash, &HFSPLUS_SB(sb).rsrc_inodes); | 183 | hlist_add_head(&inode->i_hash, &HFSPLUS_SB(sb).rsrc_inodes); |
184 | mark_inode_dirty(inode); | 184 | mark_inode_dirty(inode); |
185 | { | ||
186 | void hfsplus_inode_check(struct super_block *sb); | ||
187 | atomic_inc(&HFSPLUS_SB(sb).inode_cnt); | ||
188 | hfsplus_inode_check(sb); | ||
189 | } | ||
190 | out: | 185 | out: |
191 | d_add(dentry, inode); | 186 | d_add(dentry, inode); |
192 | return NULL; | 187 | return NULL; |
@@ -317,11 +312,6 @@ struct inode *hfsplus_new_inode(struct super_block *sb, int mode) | |||
317 | if (!inode) | 312 | if (!inode) |
318 | return NULL; | 313 | return NULL; |
319 | 314 | ||
320 | { | ||
321 | void hfsplus_inode_check(struct super_block *sb); | ||
322 | atomic_inc(&HFSPLUS_SB(sb).inode_cnt); | ||
323 | hfsplus_inode_check(sb); | ||
324 | } | ||
325 | inode->i_ino = HFSPLUS_SB(sb).next_cnid++; | 315 | inode->i_ino = HFSPLUS_SB(sb).next_cnid++; |
326 | inode->i_mode = mode; | 316 | inode->i_mode = mode; |
327 | inode->i_uid = current->fsuid; | 317 | inode->i_uid = current->fsuid; |
diff --git a/fs/hfsplus/super.c b/fs/hfsplus/super.c index 6daaf7c755a6..d791780def50 100644 --- a/fs/hfsplus/super.c +++ b/fs/hfsplus/super.c | |||
@@ -22,29 +22,12 @@ static void hfsplus_destroy_inode(struct inode *inode); | |||
22 | 22 | ||
23 | #include "hfsplus_fs.h" | 23 | #include "hfsplus_fs.h" |
24 | 24 | ||
25 | void hfsplus_inode_check(struct super_block *sb) | ||
26 | { | ||
27 | #if 0 | ||
28 | u32 cnt = atomic_read(&HFSPLUS_SB(sb).inode_cnt); | ||
29 | u32 last_cnt = HFSPLUS_SB(sb).last_inode_cnt; | ||
30 | |||
31 | if (cnt <= (last_cnt / 2) || | ||
32 | cnt >= (last_cnt * 2)) { | ||
33 | HFSPLUS_SB(sb).last_inode_cnt = cnt; | ||
34 | printk("inode_check: %u,%u,%u\n", cnt, last_cnt, | ||
35 | HFSPLUS_SB(sb).cat_tree ? HFSPLUS_SB(sb).cat_tree->node_hash_cnt : 0); | ||
36 | } | ||
37 | #endif | ||
38 | } | ||
39 | |||
40 | static void hfsplus_read_inode(struct inode *inode) | 25 | static void hfsplus_read_inode(struct inode *inode) |
41 | { | 26 | { |
42 | struct hfs_find_data fd; | 27 | struct hfs_find_data fd; |
43 | struct hfsplus_vh *vhdr; | 28 | struct hfsplus_vh *vhdr; |
44 | int err; | 29 | int err; |
45 | 30 | ||
46 | atomic_inc(&HFSPLUS_SB(inode->i_sb).inode_cnt); | ||
47 | hfsplus_inode_check(inode->i_sb); | ||
48 | INIT_LIST_HEAD(&HFSPLUS_I(inode).open_dir_list); | 31 | INIT_LIST_HEAD(&HFSPLUS_I(inode).open_dir_list); |
49 | init_MUTEX(&HFSPLUS_I(inode).extents_lock); | 32 | init_MUTEX(&HFSPLUS_I(inode).extents_lock); |
50 | HFSPLUS_I(inode).flags = 0; | 33 | HFSPLUS_I(inode).flags = 0; |
@@ -155,12 +138,10 @@ static int hfsplus_write_inode(struct inode *inode, int unused) | |||
155 | static void hfsplus_clear_inode(struct inode *inode) | 138 | static void hfsplus_clear_inode(struct inode *inode) |
156 | { | 139 | { |
157 | dprint(DBG_INODE, "hfsplus_clear_inode: %lu\n", inode->i_ino); | 140 | dprint(DBG_INODE, "hfsplus_clear_inode: %lu\n", inode->i_ino); |
158 | atomic_dec(&HFSPLUS_SB(inode->i_sb).inode_cnt); | ||
159 | if (HFSPLUS_IS_RSRC(inode)) { | 141 | if (HFSPLUS_IS_RSRC(inode)) { |
160 | HFSPLUS_I(HFSPLUS_I(inode).rsrc_inode).rsrc_inode = NULL; | 142 | HFSPLUS_I(HFSPLUS_I(inode).rsrc_inode).rsrc_inode = NULL; |
161 | iput(HFSPLUS_I(inode).rsrc_inode); | 143 | iput(HFSPLUS_I(inode).rsrc_inode); |
162 | } | 144 | } |
163 | hfsplus_inode_check(inode->i_sb); | ||
164 | } | 145 | } |
165 | 146 | ||
166 | static void hfsplus_write_super(struct super_block *sb) | 147 | static void hfsplus_write_super(struct super_block *sb) |