All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chris Webb <chris@arachsys.com>
To: James Bottomley <James.Bottomley@suse.de>
Cc: linux-scsi@vger.kernel.org
Subject: Re: oops during scsi scanning disk setup
Date: Sat, 5 Sep 2009 17:45:51 +0100	[thread overview]
Message-ID: <20090905164551.GH8710@arachsys.com> (raw)
In-Reply-To: <20090822155037.GB28586@arachsys.com>

Chris Webb <chris@arachsys.com> writes:

> James Bottomley <James.Bottomley@suse.de> writes:
> 
> > Actually, if that works, I'll have the above backported as well.
> 
> Hi James. That's much better; thanks! I certainly can't provoke any problems
> with it in a VM, although I couldn't really reproduce the problem with the
> original kernel in a test environment either. I'll push it to our clusters
> and see how things go over the next week or so.

We've been running with this for a couple of weeks now, and I haven't seen the
crash repeat itself. That said, I applied this on top to see if I could detect
the race:

diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
--- a/drivers/scsi/sd.c
+++ b/drivers/scsi/sd.c
@@ -1936,6 +1936,8 @@
 
 	sd_printk(KERN_NOTICE, sdkp, "Attached SCSI %sdisk\n",
 	          sdp->removable ? "removable " : "");
+	if (atomic_read(&sdkp->dev.kobj.kref.refcount) < 2)
+		sd_printk(KERN_WARNING, sdkp, "Attempted to release device before sd_probe_async complete\n");
 	put_device(&sdkp->dev);
 }

and it hasn't triggered at all, so I wonder whether we've just not hit the bug again.

Best wishes,

Chris.

      reply	other threads:[~2009-09-05 16:50 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-20 18:05 oops during scsi scanning disk setup Chris Webb
2009-08-20 20:01 ` Matthew Wilcox
2009-08-20 20:10   ` Yinghai Lu
2009-08-21  4:26     ` Arjan van de Ven
2009-08-20 22:26 ` James Bottomley
2009-08-21  8:16   ` Chris Webb
2009-08-21  8:33     ` Chris Webb
2009-08-21  9:23       ` Chris Webb
2009-08-21 14:00         ` James Bottomley
2009-08-21 14:51           ` Chris Webb
2009-08-21 15:47             ` James Bottomley
2009-08-21 22:59               ` Chris Webb
2009-08-21 23:39                 ` James Bottomley
2009-08-22 11:55               ` Chris Webb
2009-08-22 14:56                 ` James Bottomley
2009-08-22 15:50                   ` Chris Webb
2009-09-05 16:45                     ` Chris Webb [this message]

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=20090905164551.GH8710@arachsys.com \
    --to=chris@arachsys.com \
    --cc=James.Bottomley@suse.de \
    --cc=linux-scsi@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.