diff options
author | Christoph Hellwig <hch@lst.de> | 2017-04-25 12:56:44 -0400 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2017-04-27 02:39:32 -0400 |
commit | 7569b90a228ed7dfdc1f92f2c98d7a1b041f22eb (patch) | |
tree | 17d65f82bf253ceedd1268f2fd9fa39c65669c30 | |
parent | 25d9baa47505ead1bcae7334991363c3bbfa1831 (diff) |
nvme-scsi: remove nvme_trans_security_protocol
This function just returns the same error code and sense data as
the default statement in the switch in the caller.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Keith Busch <keith.busch@intel.com>
-rw-r--r-- | drivers/nvme/host/scsi.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/nvme/host/scsi.c b/drivers/nvme/host/scsi.c index 988da610d6aa..1f7671e631dd 100644 --- a/drivers/nvme/host/scsi.c +++ b/drivers/nvme/host/scsi.c | |||
@@ -2138,15 +2138,6 @@ static int nvme_trans_request_sense(struct nvme_ns *ns, struct sg_io_hdr *hdr, | |||
2138 | return res; | 2138 | return res; |
2139 | } | 2139 | } |
2140 | 2140 | ||
2141 | static int nvme_trans_security_protocol(struct nvme_ns *ns, | ||
2142 | struct sg_io_hdr *hdr, | ||
2143 | u8 *cmd) | ||
2144 | { | ||
2145 | return nvme_trans_completion(hdr, SAM_STAT_CHECK_CONDITION, | ||
2146 | ILLEGAL_REQUEST, SCSI_ASC_ILLEGAL_COMMAND, | ||
2147 | SCSI_ASCQ_CAUSE_NOT_REPORTABLE); | ||
2148 | } | ||
2149 | |||
2150 | static int nvme_trans_synchronize_cache(struct nvme_ns *ns, | 2141 | static int nvme_trans_synchronize_cache(struct nvme_ns *ns, |
2151 | struct sg_io_hdr *hdr) | 2142 | struct sg_io_hdr *hdr) |
2152 | { | 2143 | { |
@@ -2414,10 +2405,6 @@ static int nvme_scsi_translate(struct nvme_ns *ns, struct sg_io_hdr *hdr) | |||
2414 | case REQUEST_SENSE: | 2405 | case REQUEST_SENSE: |
2415 | retcode = nvme_trans_request_sense(ns, hdr, cmd); | 2406 | retcode = nvme_trans_request_sense(ns, hdr, cmd); |
2416 | break; | 2407 | break; |
2417 | case SECURITY_PROTOCOL_IN: | ||
2418 | case SECURITY_PROTOCOL_OUT: | ||
2419 | retcode = nvme_trans_security_protocol(ns, hdr, cmd); | ||
2420 | break; | ||
2421 | case SYNCHRONIZE_CACHE: | 2408 | case SYNCHRONIZE_CACHE: |
2422 | retcode = nvme_trans_synchronize_cache(ns, hdr); | 2409 | retcode = nvme_trans_synchronize_cache(ns, hdr); |
2423 | break; | 2410 | break; |