aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/scsi
diff options
context:
space:
mode:
authorSwen Schillig <swen@vnet.ibm.com>2008-10-01 06:42:23 -0400
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-10-03 13:11:55 -0400
commite4e9ba5d9313f362d2192fb7a2d35a3bfb714b1e (patch)
tree82e7319ec06da69956bb9a80b30b60cef79f2da7 /drivers/s390/scsi
parentb7f15f3c94196accac799727502ed88a029ae7ef (diff)
[SCSI] zfcp: prevent fc_remote_port_delete calls for unregistered rport
In case of an adapter reopen all rports have to be deleted from the environment. This should only happen for already registered rports otherwise fc_remote_port_delete is called with a NULL pointer. Signed-off-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')
-rw-r--r--drivers/s390/scsi/zfcp_erp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/s390/scsi/zfcp_erp.c b/drivers/s390/scsi/zfcp_erp.c
index f5ebeb7ca2be..8c117416d5ad 100644
--- a/drivers/s390/scsi/zfcp_erp.c
+++ b/drivers/s390/scsi/zfcp_erp.c
@@ -1236,6 +1236,8 @@ static void zfcp_erp_rports_del(struct zfcp_adapter *adapter)
1236{ 1236{
1237 struct zfcp_port *port; 1237 struct zfcp_port *port;
1238 list_for_each_entry(port, &adapter->port_list_head, list) { 1238 list_for_each_entry(port, &adapter->port_list_head, list) {
1239 if (!port->rport)
1240 continue;
1239 fc_remote_port_delete(port->rport); 1241 fc_remote_port_delete(port->rport);
1240 port->rport = NULL; 1242 port->rport = NULL;
1241 } 1243 }