summaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi/zfcp_erp.c
diff options
context:
space:
mode:
author <jejb@titanic.il.steeleye.com>2005-04-10 23:04:28 -0500
committerJames Bottomley <jejb@titanic>2005-04-18 12:34:41 -0500
commit6f71d9bc025b02a8cbc2be83b0226a7043a507a5 (patch)
tree01caefa8cdcb986b0a698c640a6a59d89e69db62 /drivers/s390/scsi/zfcp_erp.c
parentf4c2c15b930b23edaa633b09fe3f4c01b4ecce9f (diff)
zfcp: add point-2-point support
From: Andreas Herrmann <aherrman@de.ibm.com> This patch mainly introduces support for point-2-point topology. From: Heiko Carstens <heiko.carstens@de.ibm.com> From: Maxim Shchetynin <maxim@de.ibm.com> From: Andreas Herrmann <aherrman@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/s390/scsi/zfcp_erp.c')
-rw-r--r--drivers/s390/scsi/zfcp_erp.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/drivers/s390/scsi/zfcp_erp.c b/drivers/s390/scsi/zfcp_erp.c
index cfc0d8c588d..53ebc1cdfe2 100644
--- a/drivers/s390/scsi/zfcp_erp.c
+++ b/drivers/s390/scsi/zfcp_erp.c
@@ -2568,6 +2568,23 @@ zfcp_erp_port_strategy_open_common(struct zfcp_erp_action *erp_action)
case ZFCP_ERP_STEP_UNINITIALIZED:
case ZFCP_ERP_STEP_PHYS_PORT_CLOSING:
case ZFCP_ERP_STEP_PORT_CLOSING:
+ if (adapter->fc_topology == FSF_TOPO_P2P) {
+ if (port->wwpn != adapter->peer_wwpn) {
+ ZFCP_LOG_NORMAL("Failed to open port 0x%016Lx "
+ "on adapter %s.\nPeer WWPN "
+ "0x%016Lx does not match\n",
+ port->wwpn,
+ zfcp_get_busid_by_adapter(adapter),
+ adapter->peer_wwpn);
+ zfcp_erp_port_failed(port);
+ retval = ZFCP_ERP_FAILED;
+ break;
+ }
+ port->d_id = adapter->peer_d_id;
+ atomic_set_mask(ZFCP_STATUS_PORT_DID_DID, &port->status);
+ retval = zfcp_erp_port_strategy_open_port(erp_action);
+ break;
+ }
if (!(adapter->nameserver_port)) {
retval = zfcp_nameserver_enqueue(adapter);
if (retval != 0) {
@@ -3516,8 +3533,9 @@ zfcp_erp_adapter_access_changed(struct zfcp_adapter *adapter)
debug_text_event(adapter->erp_dbf, 3, "a_access_unblock");
debug_event(adapter->erp_dbf, 3, &adapter->name, 8);
- zfcp_erp_port_access_changed(adapter->nameserver_port);
read_lock_irqsave(&zfcp_data.config_lock, flags);
+ if (adapter->nameserver_port)
+ zfcp_erp_port_access_changed(adapter->nameserver_port);
list_for_each_entry(port, &adapter->port_list_head, list)
if (port != adapter->nameserver_port)
zfcp_erp_port_access_changed(port);