linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Patrick Mansfield <patmans@us.ibm.com>
To: Steven Dake <sdake@mvista.com>
Cc: linux-scsi@vger.kernel.org
Subject: Re: [PATCH] [RFC] Advanced TCA SCSI Disk Hotswap
Date: Thu, 24 Oct 2002 15:32:40 -0700	[thread overview]
Message-ID: <20021024153240.A18890@eng2.beaverton.ibm.com> (raw)
In-Reply-To: <3DB7436E.9060100@mvista.com>; from sdake@mvista.com on Wed, Oct 23, 2002 at 05:48:46PM -0700

On Wed, Oct 23, 2002 at 05:48:46PM -0700, Steven Dake wrote:
> linux-scsi,
> 
> 

> diff -uNr linux-2.5.44-qla/drivers/scsi/scsi_error.c linux-2.5.44-scsi-hotswap/drivers/scsi/scsi_error.c
> --- linux-2.5.44-qla/drivers/scsi/scsi_error.c	Fri Oct 18 21:01:07 2002
> +++ linux-2.5.44-scsi-hotswap/drivers/scsi/scsi_error.c	Wed Oct 23 11:48:20 2002

> @@ -962,6 +970,8 @@
>  
>  	SCSI_LOG_ERROR_RECOVERY(3, printk("%s: Trying BDR\n", __FUNCTION__));
>  
> +	spin_lock (&shost->host_queue_lock);
> +
>  	for (sdev = shost->host_queue; sdev; sdev = sdev->next) {
>  		for (scmd = sc_todo; scmd; scmd = scmd->bh_next)
>  			if ((scmd->device == sdev) &&
> @@ -985,6 +995,7 @@
>  							scsi_eh_finish_cmd(scmd, shost);
>  					}
>  	}
> +	spin_unlock (&shost->host_queue_lock);
>  
>  	return shost->host_failed;
>  }

The bus device reset functions are allowed sleep, so you cannot hold a lock
while calling them.

-- Patrick Mansfield

  parent reply	other threads:[~2002-10-24 22:32 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-24  0:48 [PATCH] [RFC] Advanced TCA SCSI Disk Hotswap Steven Dake
2002-10-24 14:25 ` James Bottomley
2002-10-24 19:40   ` Steven Dake
2002-10-24 20:02     ` James Bottomley
2002-10-24 20:45       ` Steven Dake
2002-10-24 21:05         ` Randy.Dunlap
2002-10-24 21:48           ` Steven Dake
2002-10-24 23:00           ` Scott Murray
2002-10-24 23:22             ` Greg KH
2002-10-24 23:48               ` Steven Dake
2002-10-25  0:20                 ` Jeff Garzik
2002-10-25 10:04                 ` Alan Cox
2002-10-25  0:18               ` Scott Murray
2002-10-24 23:42         ` James Bottomley
2002-10-24 23:52           ` Jeff Garzik
2002-10-27 15:08             ` Rob Landley
2002-10-27 20:25               ` Randy.Dunlap
2002-10-24 22:58       ` Mike Anderson
2002-10-24 22:32 ` Patrick Mansfield [this message]
2002-10-24 22:36 ` Mike Anderson
2002-10-24 22:47   ` Steven Dake

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=20021024153240.A18890@eng2.beaverton.ibm.com \
    --to=patmans@us.ibm.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=sdake@mvista.com \
    /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).