提交 40dce4ee 编写于 作者: P Paolo Bonzini

scsi-disk: fix rerror/werror=ignore

rerror=ignore was returning true from scsi_handle_rw_error but the callers were not
calling scsi_req_complete when rerror=ignore returns true (this is the correct thing
to do when true is returned after executing a passthrough command).  Fix this by
calling it in scsi_handle_rw_error.
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
上级 e6aa5ba4
......@@ -473,10 +473,15 @@ static bool scsi_handle_rw_error(SCSIDiskReq *r, int error, bool acct_failed)
}
blk_error_action(s->qdev.conf.blk, action, is_read, error);
if (action == BLOCK_ERROR_ACTION_IGNORE) {
scsi_req_complete(&r->req, 0);
return true;
}
if (action == BLOCK_ERROR_ACTION_STOP) {
scsi_req_retry(&r->req);
}
return action != BLOCK_ERROR_ACTION_IGNORE;
return false;
}
static void scsi_write_complete_noio(SCSIDiskReq *r, int ret)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册