]> err.no Git - linux-2.6/commitdiff
[SCSI] zfcp: fix: avoid race between fc_remote_port_add and scsi_add_device
authorAndreas Herrmann <aherrman@de.ibm.com>
Sat, 11 Feb 2006 00:43:55 +0000 (01:43 +0100)
committer <jejb@mulgrave.il.steeleye.com> <>
Sun, 12 Feb 2006 17:12:38 +0000 (11:12 -0600)
Flush workqueue of a scsi host after a remote port for that host
is registered at the fc transport class. Otherwise immediate
registration of a scsi device on that host is racy.

Signed-off-by: Andreas Herrmann <aherrman@de.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
drivers/s390/scsi/zfcp_erp.c

index 8ed6fcb41653a83dd12976408bbf06602ef666c8..e3c4bdd29a60805ee36c8d24b54966ab71c43b01 100644 (file)
@@ -3415,6 +3415,8 @@ zfcp_erp_action_cleanup(int action, struct zfcp_adapter *adapter,
                                                "(adapter %s, wwpn=0x%016Lx)\n",
                                                zfcp_get_busid_by_port(port),
                                                port->wwpn);
+                       else
+                               scsi_flush_work(adapter->scsi_host);
                }
                zfcp_port_put(port);
                break;