]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[SCSI] zfcp: Fix handling for boxed port after physical close
authorChristof Schmitt <christof.schmitt@de.ibm.com>
Mon, 10 Mar 2008 15:18:54 +0000 (16:18 +0100)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Mon, 7 Apr 2008 17:15:44 +0000 (12:15 -0500)
When a FSF physical close returns the status boxed, this means that
another system already closed the port. For our system this is the
same status as in the good path, we have to send the normal close. So,
set the status for the boxed response to the same as for the good
status.

Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com>
Signed-off-by: Martin Peschke <mp3@de.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
drivers/s390/scsi/zfcp_fsf.c

index 0dff05840ee2e1ffcdb222cdb3805c01054fbd65..2ed3c7b48882bc3f06f2b2cfe3407529ab1905c8 100644 (file)
@@ -2968,6 +2968,13 @@ zfcp_fsf_close_physical_port_handler(struct zfcp_fsf_req *fsf_req)
                zfcp_erp_port_boxed(port);
                fsf_req->status |= ZFCP_STATUS_FSFREQ_ERROR |
                        ZFCP_STATUS_FSFREQ_RETRY;
+
+               /* can't use generic zfcp_erp_modify_port_status because
+                * ZFCP_STATUS_COMMON_OPEN must not be reset for the port */
+               atomic_clear_mask(ZFCP_STATUS_PORT_PHYS_OPEN, &port->status);
+               list_for_each_entry(unit, &port->unit_list_head, list)
+                       atomic_clear_mask(ZFCP_STATUS_COMMON_OPEN,
+                                         &unit->status);
                break;
 
        case FSF_ADAPTER_STATUS_AVAILABLE: