diff options
author | Christof Schmitt <christof.schmitt@de.ibm.com> | 2009-04-17 09:08:15 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2009-04-27 11:07:37 -0400 |
commit | 70932935b61ee3dcc5a419ec4c367feb2ff808e4 (patch) | |
tree | 67e0925b8a44b3e163e4da36ecff299ba9e842bf /drivers/s390/scsi/zfcp_aux.c | |
parent | 3869bb6e73f5f55ce16b13025726b0bfdf1f4aae (diff) |
[SCSI] zfcp: Fix oops when port disappears
The zfcp_port might have been removed, while the FC fast_io_fail timer
is still running and could trigger the terminate_rport_io callback.
Set the pointer to the zfcp_port to NULL and check accordingly
before using it.
Reviewed-by: Martin Petermann <martin@linux.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_aux.c')
-rw-r--r-- | drivers/s390/scsi/zfcp_aux.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/s390/scsi/zfcp_aux.c b/drivers/s390/scsi/zfcp_aux.c index a00d2bb9559c..3ac27ee47396 100644 --- a/drivers/s390/scsi/zfcp_aux.c +++ b/drivers/s390/scsi/zfcp_aux.c | |||
@@ -671,8 +671,7 @@ void zfcp_port_dequeue(struct zfcp_port *port) | |||
671 | list_del(&port->list); | 671 | list_del(&port->list); |
672 | write_unlock_irq(&zfcp_data.config_lock); | 672 | write_unlock_irq(&zfcp_data.config_lock); |
673 | if (port->rport) | 673 | if (port->rport) |
674 | fc_remote_port_delete(port->rport); | 674 | port->rport->dd_data = NULL; |
675 | port->rport = NULL; | ||
676 | zfcp_adapter_put(port->adapter); | 675 | zfcp_adapter_put(port->adapter); |
677 | sysfs_remove_group(&port->sysfs_device.kobj, &zfcp_sysfs_port_attrs); | 676 | sysfs_remove_group(&port->sysfs_device.kobj, &zfcp_sysfs_port_attrs); |
678 | device_unregister(&port->sysfs_device); | 677 | device_unregister(&port->sysfs_device); |