This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
JFFS2: endless loop in jffs2_kill_fragtree
- From: Mike Jastrebtsoff <jam2000 at pisem dot net>
- To: ecos-discuss at sources dot redhat dot com
- Date: Wed, 28 Jul 2004 12:53:13 +0700
- Subject: [ECOS] JFFS2: endless loop in jffs2_kill_fragtree
- Reply-to: Michael Jastrebtsoff <jam2000 at pisem dot net>
Hello, All
After several operations of opening/creating files on JFFS2
fd = open("...", O_TRUNC|O_CREAT|O_RDWR);
enters the endless cycle in
jffs2_do_clear_inode(...)->jffs2_kill_fragtree(...) -> endless loop!
nodelist.c:
...
void jffs2_kill_fragtree(struct rb_root *root, struct jffs2_sb_info *c)
{
...
while(frag) {
if (frag->rb.rb_left) {
D2(printk(KERN_DEBUG "Going left from frag (%p) %d-%d\n",
frag, frag->ofs, frag->ofs+frag->size));
frag = frag_left(frag);
continue;
}
if (frag->rb.rb_right) {
D2(printk(KERN_DEBUG "Going right from frag (%p) %d-%d\n",
frag, frag->ofs, frag->ofs+frag->size));
frag = frag_right(frag);
continue;
}
...
}
After several cycles "frag" pointer becomes a trash (smth. like frag == 0xbc010001)
I am using EB55 board, GCC 3.3.3, ecos from CVS.
I've tested the memory, flash is ok.
Any ideas?
--
Regards,
Mike
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss