diff options
author | Swen Schillig <swen@vnet.ibm.com> | 2008-12-19 10:56:53 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-12-29 12:24:35 -0500 |
commit | 1d3aab084a2b4d6c60c8478b3ddf5dd9391f6a32 (patch) | |
tree | 885fb4c2a72f885fb4a6b4c331ca706193357904 /drivers/s390 | |
parent | 27c3f0a6e4521ba0ff6e76da54969f0bf430f53a (diff) |
[SCSI] zfcp: register with SCSI layer on ccw registration
Synchronize the registration and de-registration with the SCSI layer
at CCW registration, de-registration. Before we registered with the
SCSI layer on adapter activation. This way the reg and de-reg process
is in balance.
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')
-rw-r--r-- | drivers/s390/scsi/zfcp_aux.c | 3 | ||||
-rw-r--r-- | drivers/s390/scsi/zfcp_ccw.c | 6 |
2 files changed, 2 insertions, 7 deletions
diff --git a/drivers/s390/scsi/zfcp_aux.c b/drivers/s390/scsi/zfcp_aux.c index e529b55b3ce9..f0f49feaa34f 100644 --- a/drivers/s390/scsi/zfcp_aux.c +++ b/drivers/s390/scsi/zfcp_aux.c | |||
@@ -534,7 +534,8 @@ int zfcp_adapter_enqueue(struct ccw_device *ccw_device) | |||
534 | 534 | ||
535 | zfcp_fc_nameserver_init(adapter); | 535 | zfcp_fc_nameserver_init(adapter); |
536 | 536 | ||
537 | return 0; | 537 | if (!zfcp_adapter_scsi_register(adapter)) |
538 | return 0; | ||
538 | 539 | ||
539 | sysfs_failed: | 540 | sysfs_failed: |
540 | zfcp_adapter_debug_unregister(adapter); | 541 | zfcp_adapter_debug_unregister(adapter); |
diff --git a/drivers/s390/scsi/zfcp_ccw.c b/drivers/s390/scsi/zfcp_ccw.c index 728147131e1d..285881f07648 100644 --- a/drivers/s390/scsi/zfcp_ccw.c +++ b/drivers/s390/scsi/zfcp_ccw.c | |||
@@ -106,10 +106,6 @@ static int zfcp_ccw_set_online(struct ccw_device *ccw_device) | |||
106 | if (retval) | 106 | if (retval) |
107 | goto out; | 107 | goto out; |
108 | 108 | ||
109 | retval = zfcp_adapter_scsi_register(adapter); | ||
110 | if (retval) | ||
111 | goto out_scsi_register; | ||
112 | |||
113 | /* initialize request counter */ | 109 | /* initialize request counter */ |
114 | BUG_ON(!zfcp_reqlist_isempty(adapter)); | 110 | BUG_ON(!zfcp_reqlist_isempty(adapter)); |
115 | adapter->req_no = 0; | 111 | adapter->req_no = 0; |
@@ -123,8 +119,6 @@ static int zfcp_ccw_set_online(struct ccw_device *ccw_device) | |||
123 | flush_work(&adapter->scan_work); | 119 | flush_work(&adapter->scan_work); |
124 | return 0; | 120 | return 0; |
125 | 121 | ||
126 | out_scsi_register: | ||
127 | zfcp_erp_thread_kill(adapter); | ||
128 | out: | 122 | out: |
129 | up(&zfcp_data.config_sema); | 123 | up(&zfcp_data.config_sema); |
130 | return retval; | 124 | return retval; |