Skip to content

Commit

Permalink
[SCSI] qla2xxx: Additional residual-count corrections during UNDERRUN…
Browse files Browse the repository at this point in the history
… handling.

Add additional tightening of residual-count handling (originally
from commit 6acf819) where the
driver should discard any lower SCSI-status during
firmware/transport residual-count mismatches.

Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
  • Loading branch information
Andrew Vasquez authored and James Bottomley committed Oct 3, 2008
1 parent cc3ef7b commit 2d13693
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions drivers/scsi/qla2xxx/qla_isr.c
Original file line number Diff line number Diff line change
Expand Up @@ -1060,8 +1060,9 @@ qla2x00_status_entry(scsi_qla_host_t *ha, void *pkt)
resid = resid_len;
/* Use F/W calculated residual length. */
if (IS_FWI2_CAPABLE(ha)) {
if (scsi_status & SS_RESIDUAL_UNDER &&
resid != fw_resid_len) {
if (!(scsi_status & SS_RESIDUAL_UNDER)) {
lscsi_status = 0;
} else if (resid != fw_resid_len) {
scsi_status &= ~SS_RESIDUAL_UNDER;
lscsi_status = 0;
}
Expand Down

0 comments on commit 2d13693

Please sign in to comment.