aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jffs2/scan.c
diff options
context:
space:
mode:
authorKaiGai Kohei <kaigai@ak.jp.nec.com>2006-05-13 02:15:07 -0400
committerKaiGai Kohei <kaigai@ak.jp.nec.com>2006-05-13 02:15:07 -0400
commit8f2b6f49c656dd4597904f8c20661d6b73cdbbeb (patch)
tree7452e7d2fb9070181a943c104c409cac79abc991 /fs/jffs2/scan.c
parent8b0b339d46ca0105a9936e3caa3bac80b72de7a3 (diff)
[JFFS2][XATTR] Remove 'struct list_head ilist' from jffs2_inode_cache.
This patch can reduce 4-byte of memory usage per inode_cache. [4/10] jffs2-xattr-v5.1-04-remove_ilist_from_ic.patch Signed-off-by: KaiGai Kohei <kaigai@ak.jp.nec.com>
Diffstat (limited to 'fs/jffs2/scan.c')
-rw-r--r--fs/jffs2/scan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/jffs2/scan.c b/fs/jffs2/scan.c
index f09689e320fe..0a79fc921e9f 100644
--- a/fs/jffs2/scan.c
+++ b/fs/jffs2/scan.c
@@ -408,14 +408,15 @@ static int jffs2_scan_xref_node(struct jffs2_sb_info *c, struct jffs2_eraseblock
408 * ref->xid is used to store 32bit xid, xd is not used 408 * ref->xid is used to store 32bit xid, xd is not used
409 * ref->ino is used to store 32bit inode-number, ic is not used 409 * ref->ino is used to store 32bit inode-number, ic is not used
410 * Thoes variables are declared as union, thus using those 410 * Thoes variables are declared as union, thus using those
411 * are exclusive. In a similar way, ref->ilist is temporarily 411 * are exclusive. In a similar way, ref->next is temporarily
412 * used to chain all xattr_ref object. It's re-chained to 412 * used to chain all xattr_ref object. It's re-chained to
413 * jffs2_inode_cache in jffs2_build_xattr_subsystem() correctly. 413 * jffs2_inode_cache in jffs2_build_xattr_subsystem() correctly.
414 */ 414 */
415 ref->node = raw; 415 ref->node = raw;
416 ref->ino = je32_to_cpu(rr->ino); 416 ref->ino = je32_to_cpu(rr->ino);
417 ref->xid = je32_to_cpu(rr->xid); 417 ref->xid = je32_to_cpu(rr->xid);
418 list_add_tail(&ref->ilist, &c->xattr_temp); 418 ref->next = c->xref_temp;
419 c->xref_temp = ref;
419 420
420 raw->__totlen = PAD(je32_to_cpu(rr->totlen)); 421 raw->__totlen = PAD(je32_to_cpu(rr->totlen));
421 raw->flash_offset = ofs | REF_PRISTINE; 422 raw->flash_offset = ofs | REF_PRISTINE;
@@ -888,7 +889,6 @@ struct jffs2_inode_cache *jffs2_scan_make_ino_cache(struct jffs2_sb_info *c, uin
888 889
889 ic->ino = ino; 890 ic->ino = ino;
890 ic->nodes = (void *)ic; 891 ic->nodes = (void *)ic;
891 init_xattr_inode_cache(ic);
892 jffs2_add_ino_cache(c, ic); 892 jffs2_add_ino_cache(c, ic);
893 if (ino == 1) 893 if (ino == 1)
894 ic->nlink = 1; 894 ic->nlink = 1;