diff options
author | Krishna Gudipati <kgudipat@brocade.com> | 2010-12-13 19:23:27 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-12-21 13:37:17 -0500 |
commit | 15821f05b78dbeb2f897d1d22576449103a4d8d5 (patch) | |
tree | d71a92b42ceba66e2cd33d5494b05f378cae0476 /drivers/scsi/bfa/bfa_fcs_lport.c | |
parent | b704495c6707013806d1b66507a967896e2b4a7c (diff) |
[SCSI] bfa: io tag handling and minor bug fix.
Fix iotag handling:
1) Update and check io tag for retry case.
2) Clearing upper 3 bits in io tag when an IO completes.
The 3 upper bits in io tags are used for counting FCP exchange retry.
Un-cleared bits will cause firmware to access invalid memory when the
same io tag is used for an IO to a target that doesn't support FCP
exchange retry.
3) Only check the effective bits when validating an iotag.
Other minor fixes:
1) Added trace to get FC header type with assert of unhandled packet received.
Ignore the type FC_TYPE_FC_FSS (FC_XS).
2) Fixed the adapter info display check - to check for fcmode flag even.
Signed-off-by: Krishna Gudipati <kgudipat@brocade.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/bfa/bfa_fcs_lport.c')
-rw-r--r-- | drivers/scsi/bfa/bfa_fcs_lport.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/scsi/bfa/bfa_fcs_lport.c b/drivers/scsi/bfa/bfa_fcs_lport.c index 4f2e4e095d67..eb804980cde9 100644 --- a/drivers/scsi/bfa/bfa_fcs_lport.c +++ b/drivers/scsi/bfa/bfa_fcs_lport.c | |||
@@ -604,6 +604,7 @@ bfa_fcs_lport_uf_recv(struct bfa_fcs_lport_s *lport, | |||
604 | struct fc_els_cmd_s *els_cmd = (struct fc_els_cmd_s *) (fchs + 1); | 604 | struct fc_els_cmd_s *els_cmd = (struct fc_els_cmd_s *) (fchs + 1); |
605 | 605 | ||
606 | bfa_stats(lport, uf_recvs); | 606 | bfa_stats(lport, uf_recvs); |
607 | bfa_trc(lport->fcs, fchs->type); | ||
607 | 608 | ||
608 | if (!bfa_fcs_lport_is_online(lport)) { | 609 | if (!bfa_fcs_lport_is_online(lport)) { |
609 | bfa_stats(lport, uf_recv_drops); | 610 | bfa_stats(lport, uf_recv_drops); |
@@ -663,8 +664,11 @@ bfa_fcs_lport_uf_recv(struct bfa_fcs_lport_s *lport, | |||
663 | * Only handles ELS frames for now. | 664 | * Only handles ELS frames for now. |
664 | */ | 665 | */ |
665 | if (fchs->type != FC_TYPE_ELS) { | 666 | if (fchs->type != FC_TYPE_ELS) { |
666 | bfa_trc(lport->fcs, fchs->type); | 667 | bfa_trc(lport->fcs, fchs->s_id); |
667 | bfa_assert(0); | 668 | bfa_trc(lport->fcs, fchs->d_id); |
669 | /* ignore type FC_TYPE_FC_FSS */ | ||
670 | if (fchs->type != FC_TYPE_FC_FSS) | ||
671 | bfa_sm_fault(lport->fcs, fchs->type); | ||
668 | return; | 672 | return; |
669 | } | 673 | } |
670 | 674 | ||