diff options
author | David Woodhouse <dwmw2@infradead.org> | 2008-05-01 13:47:17 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@infradead.org> | 2008-05-01 13:47:17 -0400 |
commit | 27c72b040c0be8f3704ed0b6b84c12cbba24a7e8 (patch) | |
tree | 0b84847120e817465d517d21fa4653d958222567 /fs/jffs2/gc.c | |
parent | 1b690b48786229571e590dd22fe01ecc22a8746b (diff) |
[JFFS2] Track parent inode for directories (for NFS export)
To support NFS export, we need to know the parent inode of directories.
Rather than growing the jffs2_inode_cache structure, share space with
the nlink field -- which was always set to 1 for directories anyway.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Diffstat (limited to 'fs/jffs2/gc.c')
-rw-r--r-- | fs/jffs2/gc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/jffs2/gc.c b/fs/jffs2/gc.c index d4db0efeceaf..090c556ffed2 100644 --- a/fs/jffs2/gc.c +++ b/fs/jffs2/gc.c | |||
@@ -161,8 +161,8 @@ int jffs2_garbage_collect_pass(struct jffs2_sb_info *c) | |||
161 | continue; | 161 | continue; |
162 | } | 162 | } |
163 | 163 | ||
164 | if (!ic->nlink) { | 164 | if (!ic->pino_nlink) { |
165 | D1(printk(KERN_DEBUG "Skipping check of ino #%d with nlink zero\n", | 165 | D1(printk(KERN_DEBUG "Skipping check of ino #%d with nlink/pino zero\n", |
166 | ic->ino)); | 166 | ic->ino)); |
167 | spin_unlock(&c->inocache_lock); | 167 | spin_unlock(&c->inocache_lock); |
168 | jffs2_xattr_delete_inode(c, ic); | 168 | jffs2_xattr_delete_inode(c, ic); |
@@ -398,7 +398,7 @@ int jffs2_garbage_collect_pass(struct jffs2_sb_info *c) | |||
398 | it's vaguely possible. */ | 398 | it's vaguely possible. */ |
399 | 399 | ||
400 | inum = ic->ino; | 400 | inum = ic->ino; |
401 | nlink = ic->nlink; | 401 | nlink = ic->pino_nlink; |
402 | spin_unlock(&c->inocache_lock); | 402 | spin_unlock(&c->inocache_lock); |
403 | 403 | ||
404 | f = jffs2_gc_fetch_inode(c, inum, !nlink); | 404 | f = jffs2_gc_fetch_inode(c, inum, !nlink); |