aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi/zfcp_erp.c
diff options
context:
space:
mode:
authorChristof Schmitt <christof.schmitt@de.ibm.com>2009-03-02 07:08:54 -0500
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2009-03-12 13:58:18 -0400
commita5b11dda12ed7e3a79180b10ad6209a40a02989f (patch)
tree57196bdb6f2c48a5e6f12a5d1129b57c1e393c3f /drivers/s390/scsi/zfcp_erp.c
parent77c019768f0607c36e25bec11ce3e1eabef09277 (diff)
[SCSI] zfcp: Remove some port flags
PORT_PHYS_CLOSING is only set and cleared, but not actually used for status checking. PORT_INVALID_WWPN is set when the GID_PN request does not return a d_id for a remote port, e.g. when a remote port has been unplugged. For this case, the d_id is zero. In the erp we can check the d_id and use the normal escalation procedure that gives up after three retries and remove the special case. PORT_NO_WWPN is unused: Each port in the remote port list has a valid wwpn. The WKA ports are now tracked outside the port list. Remove the PORT_NO_WWPN flag, since this is no longer set for any port. Acked-by: Swen Schillig <swen@vnet.ibm.com> Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/s390/scsi/zfcp_erp.c')
-rw-r--r--drivers/s390/scsi/zfcp_erp.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/drivers/s390/scsi/zfcp_erp.c b/drivers/s390/scsi/zfcp_erp.c
index 387a3af528ac..aed08e70aa96 100644
--- a/drivers/s390/scsi/zfcp_erp.c
+++ b/drivers/s390/scsi/zfcp_erp.c
@@ -777,10 +777,7 @@ static int zfcp_erp_port_forced_strategy_close(struct zfcp_erp_action *act)
777 777
778static void zfcp_erp_port_strategy_clearstati(struct zfcp_port *port) 778static void zfcp_erp_port_strategy_clearstati(struct zfcp_port *port)
779{ 779{
780 atomic_clear_mask(ZFCP_STATUS_COMMON_ACCESS_DENIED | 780 atomic_clear_mask(ZFCP_STATUS_COMMON_ACCESS_DENIED, &port->status);
781 ZFCP_STATUS_PORT_PHYS_CLOSING |
782 ZFCP_STATUS_PORT_INVALID_WWPN,
783 &port->status);
784} 781}
785 782
786static int zfcp_erp_port_forced_strategy(struct zfcp_erp_action *erp_action) 783static int zfcp_erp_port_forced_strategy(struct zfcp_erp_action *erp_action)
@@ -875,13 +872,8 @@ static int zfcp_erp_port_strategy_open_common(struct zfcp_erp_action *act)
875 return ZFCP_ERP_CONTINUES; 872 return ZFCP_ERP_CONTINUES;
876 } 873 }
877 case ZFCP_ERP_STEP_NAMESERVER_LOOKUP: 874 case ZFCP_ERP_STEP_NAMESERVER_LOOKUP:
878 if (!port->d_id) { 875 if (!port->d_id)
879 if (p_status & (ZFCP_STATUS_PORT_INVALID_WWPN)) {
880 zfcp_erp_port_failed(port, 26, NULL);
881 return ZFCP_ERP_EXIT;
882 }
883 return ZFCP_ERP_FAILED; 876 return ZFCP_ERP_FAILED;
884 }
885 return zfcp_erp_port_strategy_open_port(act); 877 return zfcp_erp_port_strategy_open_port(act);
886 878
887 case ZFCP_ERP_STEP_PORT_OPENING: 879 case ZFCP_ERP_STEP_PORT_OPENING:
@@ -1269,10 +1261,6 @@ static void zfcp_erp_action_cleanup(struct zfcp_erp_action *act, int result)
1269 1261
1270 case ZFCP_ERP_ACTION_REOPEN_PORT_FORCED: 1262 case ZFCP_ERP_ACTION_REOPEN_PORT_FORCED:
1271 case ZFCP_ERP_ACTION_REOPEN_PORT: 1263 case ZFCP_ERP_ACTION_REOPEN_PORT:
1272 if (atomic_read(&port->status) & ZFCP_STATUS_PORT_NO_WWPN) {
1273 zfcp_port_put(port);
1274 return;
1275 }
1276 if ((result == ZFCP_ERP_SUCCEEDED) && !port->rport) 1264 if ((result == ZFCP_ERP_SUCCEEDED) && !port->rport)
1277 zfcp_erp_rport_register(port); 1265 zfcp_erp_rport_register(port);
1278 if ((result != ZFCP_ERP_SUCCEEDED) && port->rport) { 1266 if ((result != ZFCP_ERP_SUCCEEDED) && port->rport) {