linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marcelo Tosatti <marcelo.tosatti@cyclades.com>
To: Chris Caputo <ccaputo@alt.net>
Cc: "Velupula, Prakash" <prakash.velupula@hp.com>,
	Albert Chu <chu11@llnl.gov>,
	David Woodhouse <dwmw2@infradead.org>,
	Al Viro <viro@parcelfarce.linux.theplanet.co.uk>,
	linux-fsdevel@vger.kernel.org, lwoodman@redhat.com
Subject: Re: RE: oops in 2.4.25 prune_icache() called from kswapd
Date: Tue, 26 Jul 2005 08:01:32 -0300	[thread overview]
Message-ID: <20050726110132.GE28003@dmt.cnet> (raw)
In-Reply-To: <Pine.LNX.4.63.0506192304210.3095@nacho.alt.net>


FYI

commit cc54d1333e409f714aa9c7db63f7f9ed07cc57a9
tree f301f581dd4389028f8b2588940d456904e552f1
parent 2e8f68c45925123d33d476ce369b570bd989dd9a
author Larry Woodman <lwoodman@redhat.com> Fri, 15 Jul 2005 11:32:08 -0400
committer Marcelo Tosatti <marcelo@dmt.cnet> Tue, 26 Jul 2005 07:52:46 -0300

    [PATCH] workaround inode cache (prune_icache/__refile_inode) SMP races

    Over the past couple of weeks we have seen two races in the inode cache
    code. The first is between [dispose_list()] and __refile_inode() and the
    second is between prune_icache() and truncate_inodes(). I posted both of
    these patches but wanted to make sure they got properly reviewed and
    included in RHEL3-U6.

--- a/fs/inode.c
+++ b/fs/inode.c
@@ -297,7 +297,7 @@ static inline void __refile_inode(struct
 {
        struct list_head *to;

-       if (inode->i_state & I_FREEING)
+       if (inode->i_state & (I_FREEING|I_CLEAR))
                return;
        if (list_empty(&inode->i_hash))
                return;
@@ -634,7 +634,9 @@ void clear_inode(struct inode *inode)
                cdput(inode->i_cdev);
                inode->i_cdev = NULL;
        }
+       spin_lock(&inode_lock);
        inode->i_state = I_CLEAR;
+       spin_unlock(&inode_lock);
 }

 /*


On Sun, Jun 19, 2005 at 11:07:44PM +0000, Chris Caputo wrote:
> My basic repro method was:
> 
> --
> 0) start irqbalance
> 1) run loop_dbench, which is the following dbench script which uses
>    client_plain.txt:
> 
>    #!/bin/sh
> 
>    while [ 1 ]
>    do
>         date
>         dbench 2
> 2) wait for oops
> --
> 
> I think I was using dbench-2.1:
> 
>   http://samba.org/ftp/tridge/dbench/dbench-2.1.tar.gz
> 
> In my case irqbalance was key.  If I didn't run it I never got the 
> problem.  I think irqbalance just did a good job of exasperating a race 
> condition in some way.

  reply	other threads:[~2005-07-26 23:35 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-06-19 22:51 RE: oops in 2.4.25 prune_icache() called from kswapd Velupula, Prakash
2005-06-19 23:07 ` Chris Caputo
2005-07-26 11:01   ` Marcelo Tosatti [this message]
     [not found] <390de35bed.35bed390de@llnl.gov>
2005-06-18 19:45 ` Marcelo Tosatti
2005-06-19  1:11   ` Chris Caputo
2005-06-18 20:33     ` Marcelo Tosatti

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=20050726110132.GE28003@dmt.cnet \
    --to=marcelo.tosatti@cyclades.com \
    --cc=ccaputo@alt.net \
    --cc=chu11@llnl.gov \
    --cc=dwmw2@infradead.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=lwoodman@redhat.com \
    --cc=prakash.velupula@hp.com \
    --cc=viro@parcelfarce.linux.theplanet.co.uk \
    /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).