public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: "Stephen M. Cameron" <scameron@beardog.cce.hp.com>
To: =james.bottomley@parallels.com
Cc: elliott@hp.com, stephenmcameron@gmail.com, hch@lst.de,
	linux-scsi@vger.kernel.org
Subject: [PATCH] scsi: break from queue depth adjusting loops when device found
Date: Thu, 03 Jul 2014 10:05:57 -0500	[thread overview]
Message-ID: <20140703150557.21608.37072.stgit@beardog.cce.hp.com> (raw)

From: Stephen M. Cameron <scameron@beardog.cce.hp.com>

Don't loop through all the devices even after
finding the one we're looking for

Signed-off-by: Stephen M. Cameron <scameron@beardog.cce.hp.com>
Reviewed-by: Robert Elliott <elliott@hp.com>
---
 drivers/scsi/scsi_error.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c
index cbe38e5..db8a488 100644
--- a/drivers/scsi/scsi_error.c
+++ b/drivers/scsi/scsi_error.c
@@ -635,6 +635,7 @@ static void scsi_handle_queue_ramp_up(struct scsi_device *sdev)
 		sht->change_queue_depth(tmp_sdev, tmp_sdev->queue_depth + 1,
 					SCSI_QDEPTH_RAMP_UP);
 		sdev->last_queue_ramp_up = jiffies;
+		break;
 	}
 }
 
@@ -657,6 +658,7 @@ static void scsi_handle_queue_full(struct scsi_device *sdev)
 		 */
 		sht->change_queue_depth(tmp_sdev, tmp_sdev->queue_depth - 1,
 					SCSI_QDEPTH_QFULL);
+		break;
 	}
 }
 


             reply	other threads:[~2014-07-03 15:06 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-03 15:05 Stephen M. Cameron [this message]
2014-07-03 15:25 ` [PATCH] scsi: break from queue depth adjusting loops when device found Douglas Gilbert
2014-07-03 17:11 ` Christoph Hellwig
2014-07-03 17:21   ` Mike Christie
2014-07-04 18:36     ` Douglas Gilbert
2014-07-04 10:53   ` Hannes Reinecke
2014-07-04 19:21     ` Elliott, Robert (Server Storage)
2014-07-06  9:49       ` Christoph Hellwig
2014-07-26 15:36       ` Christoph Hellwig
     [not found]         ` <CADzpL0Rn+x6N=v123EBej_iZhTwmjMYZ4deeTeRG7_sxgXU9PQ@mail.gmail.com>
2014-07-26 16:17           ` Christoph Hellwig
2014-07-27 15:36             ` Hannes Reinecke

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=20140703150557.21608.37072.stgit@beardog.cce.hp.com \
    --to=scameron@beardog.cce.hp.com \
    --cc==james.bottomley@parallels.com \
    --cc=elliott@hp.com \
    --cc=hch@lst.de \
    --cc=linux-scsi@vger.kernel.org \
    --cc=stephenmcameron@gmail.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