diff options
author | Krishna Gudipati <kgudipat@brocade.com> | 2010-03-05 22:38:17 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-03-07 02:42:04 -0500 |
commit | 25e2934c26f5efaea156c9fda4457d01a8bb44e1 (patch) | |
tree | 85329bd822e098c0a1b5fa1a29b4fc4fb4000f4d /drivers/scsi/bfa/fdmi.c | |
parent | ca8b4327e405820966971236224db0e0724b5673 (diff) |
[SCSI] bfa: FCS and include file changes.
MS module did not invoke fdmi offline in all cases,
call fdmi offline when ms module receives a port offline,
so that fdmi offline is from one place in the ms module.
Make changes to handle 10G speed in the conversion routine.
Replaced the usage of bfa_adapter_attr_s struct with specific API's.
Signed-off-by: Krishna Gudipati <kgudipat@brocade.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/bfa/fdmi.c')
-rw-r--r-- | drivers/scsi/bfa/fdmi.c | 33 |
1 files changed, 10 insertions, 23 deletions
diff --git a/drivers/scsi/bfa/fdmi.c b/drivers/scsi/bfa/fdmi.c index 2c9e7132a368..8f17076d1a87 100644 --- a/drivers/scsi/bfa/fdmi.c +++ b/drivers/scsi/bfa/fdmi.c | |||
@@ -1114,36 +1114,23 @@ bfa_fcs_fdmi_get_hbaattr(struct bfa_fcs_port_fdmi_s *fdmi, | |||
1114 | { | 1114 | { |
1115 | struct bfa_fcs_port_s *port = fdmi->ms->port; | 1115 | struct bfa_fcs_port_s *port = fdmi->ms->port; |
1116 | struct bfa_fcs_driver_info_s *driver_info = &port->fcs->driver_info; | 1116 | struct bfa_fcs_driver_info_s *driver_info = &port->fcs->driver_info; |
1117 | struct bfa_adapter_attr_s adapter_attr; | ||
1118 | 1117 | ||
1119 | bfa_os_memset(hba_attr, 0, sizeof(struct bfa_fcs_fdmi_hba_attr_s)); | 1118 | bfa_os_memset(hba_attr, 0, sizeof(struct bfa_fcs_fdmi_hba_attr_s)); |
1120 | bfa_os_memset(&adapter_attr, 0, sizeof(struct bfa_adapter_attr_s)); | ||
1121 | 1119 | ||
1122 | bfa_ioc_get_adapter_attr(&port->fcs->bfa->ioc, &adapter_attr); | 1120 | bfa_ioc_get_adapter_manufacturer(&port->fcs->bfa->ioc, |
1123 | 1121 | hba_attr->manufacturer); | |
1124 | strncpy(hba_attr->manufacturer, adapter_attr.manufacturer, | 1122 | bfa_ioc_get_adapter_serial_num(&port->fcs->bfa->ioc, |
1125 | sizeof(adapter_attr.manufacturer)); | 1123 | hba_attr->serial_num); |
1126 | 1124 | bfa_ioc_get_adapter_model(&port->fcs->bfa->ioc, hba_attr->model); | |
1127 | strncpy(hba_attr->serial_num, adapter_attr.serial_num, | 1125 | bfa_ioc_get_adapter_model(&port->fcs->bfa->ioc, hba_attr->model_desc); |
1128 | sizeof(adapter_attr.serial_num)); | 1126 | bfa_ioc_get_pci_chip_rev(&port->fcs->bfa->ioc, hba_attr->hw_version); |
1129 | 1127 | bfa_ioc_get_adapter_optrom_ver(&port->fcs->bfa->ioc, | |
1130 | strncpy(hba_attr->model, adapter_attr.model, sizeof(hba_attr->model)); | 1128 | hba_attr->option_rom_ver); |
1131 | 1129 | bfa_ioc_get_adapter_fw_ver(&port->fcs->bfa->ioc, hba_attr->fw_version); | |
1132 | strncpy(hba_attr->model_desc, adapter_attr.model_descr, | ||
1133 | sizeof(hba_attr->model_desc)); | ||
1134 | |||
1135 | strncpy(hba_attr->hw_version, adapter_attr.hw_ver, | ||
1136 | sizeof(hba_attr->hw_version)); | ||
1137 | 1130 | ||
1138 | strncpy(hba_attr->driver_version, (char *)driver_info->version, | 1131 | strncpy(hba_attr->driver_version, (char *)driver_info->version, |
1139 | sizeof(hba_attr->driver_version)); | 1132 | sizeof(hba_attr->driver_version)); |
1140 | 1133 | ||
1141 | strncpy(hba_attr->option_rom_ver, adapter_attr.optrom_ver, | ||
1142 | sizeof(hba_attr->option_rom_ver)); | ||
1143 | |||
1144 | strncpy(hba_attr->fw_version, adapter_attr.fw_ver, | ||
1145 | sizeof(hba_attr->fw_version)); | ||
1146 | |||
1147 | strncpy(hba_attr->os_name, driver_info->host_os_name, | 1134 | strncpy(hba_attr->os_name, driver_info->host_os_name, |
1148 | sizeof(hba_attr->os_name)); | 1135 | sizeof(hba_attr->os_name)); |
1149 | 1136 | ||