public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: linux-scsi@vger.kernel.org
Subject: [PATCH] scsi: Fix incorrect reporting of host protection capabilities
Date: Thu, 15 Oct 2009 14:46:13 -0400	[thread overview]
Message-ID: <yq18wfc8phm.fsf@sermon.lab.mkp.net> (raw)


The advent of DIF Type 2 devices exposed these missing break statements.

Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

---

diff --git a/include/scsi/scsi_host.h b/include/scsi/scsi_host.h
index 6e728b1..7220125 100644
--- a/include/scsi/scsi_host.h
+++ b/include/scsi/scsi_host.h
@@ -801,12 +801,15 @@ static inline unsigned int scsi_host_dif_capable(struct Scsi_Host *shost, unsign
 	case 1:
 		if (shost->prot_capabilities & SHOST_DIF_TYPE1_PROTECTION)
 			return target_type;
+		break;
 	case 2:
 		if (shost->prot_capabilities & SHOST_DIF_TYPE2_PROTECTION)
 			return target_type;
+		break;
 	case 3:
 		if (shost->prot_capabilities & SHOST_DIF_TYPE3_PROTECTION)
 			return target_type;
+		break;
 	}
 
 	return 0;

             reply	other threads:[~2009-10-15 18:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-15 18:46 Martin K. Petersen [this message]
2009-10-15 19:18 ` [PATCH] scsi: Fix incorrect reporting of host protection capabilities Matthew Wilcox
2009-10-30  2:32   ` Martin K. Petersen

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=yq18wfc8phm.fsf@sermon.lab.mkp.net \
    --to=martin.petersen@oracle.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox