diff options
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-core.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index 54e442ba44aa..b5776c1fd52a 100644 --- a/block/blk-core.c +++ b/block/blk-core.c | |||
@@ -1885,7 +1885,7 @@ static int blk_end_io(struct request *rq, int error, unsigned int nr_bytes, | |||
1885 | struct request_queue *q = rq->q; | 1885 | struct request_queue *q = rq->q; |
1886 | unsigned long flags = 0UL; | 1886 | unsigned long flags = 0UL; |
1887 | 1887 | ||
1888 | if (blk_fs_request(rq) || blk_pc_request(rq)) { | 1888 | if (bio_has_data(rq->bio)) { |
1889 | if (__end_that_request_first(rq, error, nr_bytes)) | 1889 | if (__end_that_request_first(rq, error, nr_bytes)) |
1890 | return 1; | 1890 | return 1; |
1891 | 1891 | ||
@@ -1943,10 +1943,9 @@ EXPORT_SYMBOL_GPL(blk_end_request); | |||
1943 | **/ | 1943 | **/ |
1944 | int __blk_end_request(struct request *rq, int error, unsigned int nr_bytes) | 1944 | int __blk_end_request(struct request *rq, int error, unsigned int nr_bytes) |
1945 | { | 1945 | { |
1946 | if (blk_fs_request(rq) || blk_pc_request(rq)) { | 1946 | if (bio_has_data(rq->bio) && |
1947 | if (__end_that_request_first(rq, error, nr_bytes)) | 1947 | __end_that_request_first(rq, error, nr_bytes)) |
1948 | return 1; | 1948 | return 1; |
1949 | } | ||
1950 | 1949 | ||
1951 | add_disk_randomness(rq->rq_disk); | 1950 | add_disk_randomness(rq->rq_disk); |
1952 | 1951 | ||