Commit 7676f83a authored by James Bottomley's avatar James Bottomley Committed by James Bottomley

[SCSI] scsi_transport_sas: don't scan a non-existent end device

Any end device that can't support any of the scanning protocols
shouldn't be scanned, so set its id to -1 to prevent
scsi_scan_target() being called for it.
Signed-off-by: default avatarJames Bottomley <James.Bottomley@SteelEye.com>
parent 3c0c25b9
...@@ -845,6 +845,8 @@ int sas_rphy_add(struct sas_rphy *rphy) ...@@ -845,6 +845,8 @@ int sas_rphy_add(struct sas_rphy *rphy)
(identify->target_port_protocols & (identify->target_port_protocols &
(SAS_PROTOCOL_SSP|SAS_PROTOCOL_STP|SAS_PROTOCOL_SATA))) (SAS_PROTOCOL_SSP|SAS_PROTOCOL_STP|SAS_PROTOCOL_SATA)))
rphy->scsi_target_id = sas_host->next_target_id++; rphy->scsi_target_id = sas_host->next_target_id++;
else if (identify->device_type == SAS_END_DEVICE)
rphy->scsi_target_id = -1;
mutex_unlock(&sas_host->lock); mutex_unlock(&sas_host->lock);
if (identify->device_type == SAS_END_DEVICE && if (identify->device_type == SAS_END_DEVICE &&
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment