• Christof Schmitt's avatar
    [SCSI] zfcp: Register SCSI devices after successful fc_remote_port_add · 5a7de559
    Christof Schmitt authored
    When the successful return of an adisc is the final step to set the
    port online, the registration of SCSI devices might be omitted. SCSI
    devices that have been removed before (due to a short dev_loss_tmo
    setting) might not be attached again.
    
    The problem is that the registration of SCSI devices is done only
    after erp has finished. The correct place would be after the call to
    fc_remote_port_add to mimick the scan in the FC transport class.
    
    Change the registration of SCSI devices to be triggered after the
    fc_remote_port_add call. For the initial inquiry command to succeed,
    the unit must also be open. If the unit reopen is still pending, the
    inquiry command to the LUN will be deferred with DID_IMM_RETRY, so
    there is no harm from this approach.
    Reviewed-by: default avatarSwen Schillig <swen@vnet.ibm.com>
    Signed-off-by: default avatarChristof Schmitt <christof.schmitt@de.ibm.com>
    Signed-off-by: default avatarJames Bottomley <James.Bottomley@suse.de>
    5a7de559
zfcp_ext.h 8.12 KB