Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 95783
b: refs/heads/master
c: 82fe26b
h: refs/heads/master
i:
  95781: 1fe033a
  95779: bbd700f
  95775: 95b0238
v: v3
  • Loading branch information
Pete Zaitcev authored and Greg Kroah-Hartman committed May 2, 2008
1 parent fbf6f57 commit 96464ce
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2c51ae70ede5a90d8ccb67d965c1b4e20fc4e110
refs/heads/master: 82fe26ba7a21d9bcc77e6142c941683eede32940
9 changes: 4 additions & 5 deletions trunk/drivers/block/ub.c
Original file line number Diff line number Diff line change
Expand Up @@ -792,10 +792,6 @@ static void ub_rw_cmd_done(struct ub_dev *sc, struct ub_scsi_cmd *cmd)
scsi_status = 0;
} else {
if (cmd->act_len != cmd->len) {
if ((cmd->key == MEDIUM_ERROR ||
cmd->key == UNIT_ATTENTION) &&
ub_rw_cmd_retry(sc, lun, urq, cmd) == 0)
return;
scsi_status = SAM_STAT_CHECK_CONDITION;
} else {
scsi_status = 0;
Expand All @@ -811,7 +807,10 @@ static void ub_rw_cmd_done(struct ub_dev *sc, struct ub_scsi_cmd *cmd)
else
scsi_status = DID_ERROR << 16;
} else {
if (cmd->error == -EIO) {
if (cmd->error == -EIO &&
(cmd->key == 0 ||
cmd->key == MEDIUM_ERROR ||
cmd->key == UNIT_ATTENTION)) {
if (ub_rw_cmd_retry(sc, lun, urq, cmd) == 0)
return;
}
Expand Down

0 comments on commit 96464ce

Please sign in to comment.