Skip to content

Commit

Permalink
[SCSI] libfc: set seq_id for incoming sequence
Browse files Browse the repository at this point in the history
After the recent patch "fixes unnecessary seq id jump"
the SCST module fcst stopped working because multi-sequence
write data wasn't finding the sequence after the first frame.

Add back the setting of the seq_id when the first frame arrives.
Also fix indentation on two lines.

Signed-off-by: Joe Eykholt <jeykholt@cisco.com>
Signed-off-by: Robert Love <robert.w.love@intel.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
  • Loading branch information
Joe Eykholt authored and James Bottomley committed May 17, 2010
1 parent f1af620 commit b3667f9
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions drivers/scsi/libfc/fc_exch.c
Original file line number Diff line number Diff line change
Expand Up @@ -918,6 +918,7 @@ static enum fc_pf_rjt_reason fc_seq_lookup_recip(struct fc_lport *lport,
if (fc_sof_is_init(fr_sof(fp))) {
sp = &ep->seq;
sp->ssb_stat |= SSB_ST_RESP;
sp->id = fh->fh_seq_id;
} else {
sp = &ep->seq;
if (sp->id != fh->fh_seq_id) {
Expand Down Expand Up @@ -1322,11 +1323,12 @@ static void fc_exch_recv_seq_resp(struct fc_exch_mgr *mp, struct fc_frame *fp)
}
sof = fr_sof(fp);
sp = &ep->seq;
if (fc_sof_is_init(sof))
if (fc_sof_is_init(sof)) {
sp->ssb_stat |= SSB_ST_RESP;
else if (sp->id != fh->fh_seq_id) {
atomic_inc(&mp->stats.seq_not_found);
goto rel;
sp->id = fh->fh_seq_id;
} else if (sp->id != fh->fh_seq_id) {
atomic_inc(&mp->stats.seq_not_found);
goto rel;
}

f_ctl = ntoh24(fh->fh_f_ctl);
Expand Down

0 comments on commit b3667f9

Please sign in to comment.