diff options
author | Vijaya Mohan Guvva <vmohan@brocade.com> | 2013-11-21 04:37:45 -0500 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2013-12-19 10:39:05 -0500 |
commit | 9781851f47a7fba2013f879f13cfdadfcdc879dc (patch) | |
tree | 74f6a828fe2d92f27033772e8808f1eb4477a761 | |
parent | da3e0bee18f7f36a63537219e18a03557a21a41b (diff) |
[SCSI] bfa: LUN discovery issue in direct attach mode
In direct attach mode, if port features like QoS/Trunk/FEC/CR are
enabled, driver can receive PLOGI from the target before firmware
notifies lport online to the driver. In case the lport is not yet online
and a PLOGI is received, send a reject to the peer port, instead of
dropping it on the floor.
Signed-off-by: Vijaya Mohan Guvva <vmohan@brocade.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
-rw-r--r-- | drivers/scsi/bfa/bfa_fcs_lport.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/scsi/bfa/bfa_fcs_lport.c b/drivers/scsi/bfa/bfa_fcs_lport.c index f5e4e61a0fd7..ff75ef891755 100644 --- a/drivers/scsi/bfa/bfa_fcs_lport.c +++ b/drivers/scsi/bfa/bfa_fcs_lport.c | |||
@@ -773,7 +773,20 @@ bfa_fcs_lport_uf_recv(struct bfa_fcs_lport_s *lport, | |||
773 | bfa_trc(lport->fcs, fchs->type); | 773 | bfa_trc(lport->fcs, fchs->type); |
774 | 774 | ||
775 | if (!bfa_fcs_lport_is_online(lport)) { | 775 | if (!bfa_fcs_lport_is_online(lport)) { |
776 | bfa_stats(lport, uf_recv_drops); | 776 | /* |
777 | * In direct attach topology, it is possible to get a PLOGI | ||
778 | * before the lport is online due to port feature | ||
779 | * (QoS/Trunk/FEC/CR), so send a rjt | ||
780 | */ | ||
781 | if ((fchs->type == FC_TYPE_ELS) && | ||
782 | (els_cmd->els_code == FC_ELS_PLOGI)) { | ||
783 | bfa_fcs_lport_send_ls_rjt(lport, fchs, | ||
784 | FC_LS_RJT_RSN_UNABLE_TO_PERF_CMD, | ||
785 | FC_LS_RJT_EXP_NO_ADDL_INFO); | ||
786 | bfa_stats(lport, plogi_rcvd); | ||
787 | } else | ||
788 | bfa_stats(lport, uf_recv_drops); | ||
789 | |||
777 | return; | 790 | return; |
778 | } | 791 | } |
779 | 792 | ||