2.4: kernel BUG at inode.c:334!

From: Marcelo Tosatti
Date: Fri Mar 26 2004 - 14:03:11 EST


On Fri, Mar 26, 2004 at 04:40:00PM +0100, Fredrik Steen wrote:
> On [040326 16:20] Marcelo Tosatti <marcelo.tosatti@xxxxxxxxxxxx> wrote:
> > On Thu, Mar 25, 2004 at 09:32:22AM -0800, Martin J. Bligh wrote:
> > > http://bugme.osdl.org/show_bug.cgi?id=2367
> >
> > This is the second bug report of "BUG at inode.c:334" I have seen.
> > The other one reported by Mika Fischer.
> >
> > Its indeed not valid for I_LOCK or I_FREEING inode's to be on the
> > superblock dirty list. I cannot see how this is happening.
> >
> > Martin, Mika, can you please apply the attached patch and rerun the tests?
> >
> > It might give a bit more clue. Thanks.
> >
> > --- fs/inode.c.orig 2004-03-26 12:30:01.961087616 -0300
> [...]
>
> I ran the patch and got this:
> inode->i_istate:f
> Kernel BUG at inode.c:340!
> [...]

Hi Fredik,

It seems Trond already figured it out, we are erroneously moving
locked inodes to the dirty list. He attached the following patch in
the bugzilla to fix the problem. Can you please give it a try?

--- linux-2.4.26-up/fs/inode.c.orig 2004-03-19 17:12:46.000000000 -0500
+++ linux-2.4.26-up/fs/inode.c 2004-03-26 13:01:23.000000000 -0500
@@ -319,7 +319,8 @@ void refile_inode(struct inode *inode)
if (!inode)
return;
spin_lock(&inode_lock);
- __refile_inode(inode);
+ if (!(inode->i_state & I_LOCK))
+ __refile_inode(inode);
spin_unlock(&inode_lock);
}



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/