diff options
author | James Bottomley | 2016-02-04 21:37:52 -0800 |
---|---|---|
committer | James Bottomley | 2016-02-04 21:37:52 -0800 |
commit | 12ffbbe94d8c0186daccc2e61d5ff87b15aa7bc6 (patch) | |
tree | b8fe38b24a2070d5b0cb2279f86e98b6dce98c46 /block/blk-core.c | |
parent | 6344a5cd3e8acf6e9823046cebd00b16faacdb1a (diff) | |
parent | 0fb5b1fb30fba3671dd5b1489d78e93e08d62e4e (diff) |
Merge remote-tracking branch 'mkp-scsi/4.5/scsi-fixes' into fixes
Diffstat (limited to 'block/blk-core.c')
-rw-r--r-- | block/blk-core.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index ab51685988c2..b83d29755b5a 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -2455,14 +2455,16 @@ struct request *blk_peek_request(struct request_queue *q) rq = NULL; break; - } else if (ret == BLKPREP_KILL) { + } else if (ret == BLKPREP_KILL || ret == BLKPREP_INVALID) { + int err = (ret == BLKPREP_INVALID) ? -EREMOTEIO : -EIO; + rq->cmd_flags |= REQ_QUIET; /* * Mark this request as started so we don't trigger * any debug logic in the end I/O path. */ blk_start_request(rq); - __blk_end_request_all(rq, -EIO); + __blk_end_request_all(rq, err); } else { printk(KERN_ERR "%s: bad return=%d\n", __func__, ret); break; |