summaryrefslogtreecommitdiffstats
path: root/drivers/message/fusion
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2005-10-19 20:01:17 +0200
committerJames Bottomley <jejb@mulgrave.(none)>2005-10-28 19:06:45 -0500
commitac01bbbd3b7ebfca64357aed12cf476b16abe3ce (patch)
treee0ab34ebdabb88f31a0b06321df5c7ff7122455a /drivers/message/fusion
parent80d904c43b11105c16395b240078ccc2f7ac6074 (diff)
downloadkernel-crypto-ac01bbbd3b7ebfca64357aed12cf476b16abe3ce.tar.gz
kernel-crypto-ac01bbbd3b7ebfca64357aed12cf476b16abe3ce.tar.xz
kernel-crypto-ac01bbbd3b7ebfca64357aed12cf476b16abe3ce.zip
[SCSI] sas: add flag for locally attached PHYs
Add a flag to mark a PHY as attached to the HBA as opposed to beeing on an expander. This is needed because various features are only supported on those. This is a crude hack, the proper fix would be to use different classes for host-attached vs expander phys. I'm looking into that. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/message/fusion')
-rw-r--r--drivers/message/fusion/mptsas.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/drivers/message/fusion/mptsas.c b/drivers/message/fusion/mptsas.c
index 6512027bc69..dcdf0380be8 100644
--- a/drivers/message/fusion/mptsas.c
+++ b/drivers/message/fusion/mptsas.c
@@ -760,7 +760,7 @@ mptsas_parse_device_info(struct sas_identify *identify,
}
static int mptsas_probe_one_phy(struct device *dev,
- struct mptsas_phyinfo *phy_info, int index)
+ struct mptsas_phyinfo *phy_info, int index, int local)
{
struct sas_phy *port;
int error;
@@ -853,6 +853,9 @@ static int mptsas_probe_one_phy(struct device *dev,
break;
}
+ if (local)
+ port->local_attached = 1;
+
error = sas_phy_add(port);
if (error) {
sas_phy_free(port);
@@ -918,7 +921,7 @@ mptsas_probe_hba_phys(MPT_ADAPTER *ioc, int *index)
}
mptsas_probe_one_phy(&ioc->sh->shost_gendev,
- &port_info->phy_info[i], *index);
+ &port_info->phy_info[i], *index, 1);
(*index)++;
}
@@ -989,7 +992,8 @@ mptsas_probe_expander_phys(MPT_ADAPTER *ioc, u32 *handle, int *index)
}
}
- mptsas_probe_one_phy(parent, &port_info->phy_info[i], *index);
+ mptsas_probe_one_phy(parent, &port_info->phy_info[i],
+ *index, 0);
(*index)++;
}