From: Jan Kara <jack@suse.cz>
To: Nick Piggin <npiggin@suse.de>
Cc: linux-fsdevel@vger.kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
"Jorge Boncompte [DTI2]" <jorge@dti2.net>,
Adrian Hunter <ext-adrian.hunter@nokia.com>,
stable@kernel.org
Subject: Re: [patch] fs: avoid I_NEW inodes
Date: Wed, 11 Mar 2009 13:22:52 +0100 [thread overview]
Message-ID: <20090311122251.GA24590@duck.suse.cz> (raw)
In-Reply-To: <20090311023429.GC16561@wotan.suse.de>
On Wed 11-03-09 03:34:30, Nick Piggin wrote:
> On Tue, Mar 10, 2009 at 05:03:21PM +0100, Jan Kara wrote:
> > > Index: linux-2.6/fs/drop_caches.c
> > > ===================================================================
> > > --- linux-2.6.orig/fs/drop_caches.c
> > > +++ linux-2.6/fs/drop_caches.c
> > > @@ -18,7 +18,7 @@ static void drop_pagecache_sb(struct sup
> > >
> > > spin_lock(&inode_lock);
> > > list_for_each_entry(inode, &sb->s_inodes, i_sb_list) {
> > > - if (inode->i_state & (I_FREEING|I_WILL_FREE))
> > > + if (inode->i_state & (I_FREEING|I_WILL_FREE|I_NEW))
> > > continue;
> > > if (inode->i_mapping->nrpages == 0)
> > > continue;
> > > Index: linux-2.6/fs/inode.c
> > > ===================================================================
> > > --- linux-2.6.orig/fs/inode.c
> > > +++ linux-2.6/fs/inode.c
> > > @@ -356,6 +356,8 @@ static int invalidate_list(struct list_h
> > > if (tmp == head)
> > > break;
> > > inode = list_entry(tmp, struct inode, i_sb_list);
> > > + if (inode->i_state & I_NEW)
> > > + continue;
> > If somebody is setting up inodes at this point, we are in serious
> > trouble I think. So WARN_ON would be more appropriate I think.
>
> Really? Hmm, this is also called via flush_disk which seems like it
> can operate under a mounted filesystem?
Ah, I was not following calls far enough. You're right.
Honza
--
Jan Kara <jack@suse.cz>
SUSE Labs, CR
next prev parent reply other threads:[~2009-03-11 12:22 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-05 6:45 [patch] fs: new inode i_state corruption fix Nick Piggin
2009-03-05 10:00 ` Jan Kara
2009-03-05 10:16 ` Nick Piggin
2009-03-05 11:12 ` Jan Kara
2009-03-10 13:41 ` [patch] fs: avoid I_NEW inodes Nick Piggin
2009-03-10 16:03 ` Jan Kara
2009-03-11 2:34 ` Nick Piggin
2009-03-11 12:22 ` Jan Kara [this message]
2009-03-11 3:29 ` Nick Piggin
2009-03-11 12:24 ` Jan Kara
2009-03-11 12:57 ` Nick Piggin
2009-03-11 20:19 ` Andrew Morton
2009-03-12 3:09 ` Nick Piggin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090311122251.GA24590@duck.suse.cz \
--to=jack@suse.cz \
--cc=akpm@linux-foundation.org \
--cc=ext-adrian.hunter@nokia.com \
--cc=jorge@dti2.net \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=npiggin@suse.de \
--cc=stable@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).