Skip to content

Commit

Permalink
[SCSI] zfcp: register with SCSI layer on ccw registration
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Swen Schillig authored and James Bottomley committed Dec 29, 2008
1 parent 27c3f0a commit 1d3aab0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
3 changes: 2 additions & 1 deletion drivers/s390/scsi/zfcp_aux.c
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,8 @@ int zfcp_adapter_enqueue(struct ccw_device *ccw_device)

zfcp_fc_nameserver_init(adapter);

return 0;
if (!zfcp_adapter_scsi_register(adapter))
return 0;

sysfs_failed:
zfcp_adapter_debug_unregister(adapter);
Expand Down
6 changes: 0 additions & 6 deletions drivers/s390/scsi/zfcp_ccw.c
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,6 @@ static int zfcp_ccw_set_online(struct ccw_device *ccw_device)
if (retval)
goto out;

retval = zfcp_adapter_scsi_register(adapter);
if (retval)
goto out_scsi_register;

/* initialize request counter */
BUG_ON(!zfcp_reqlist_isempty(adapter));
adapter->req_no = 0;
Expand All @@ -123,8 +119,6 @@ static int zfcp_ccw_set_online(struct ccw_device *ccw_device)
flush_work(&adapter->scan_work);
return 0;

out_scsi_register:
zfcp_erp_thread_kill(adapter);
out:
up(&zfcp_data.config_sema);
return retval;
Expand Down

0 comments on commit 1d3aab0

Please sign in to comment.