block: change ->make_request_fn() and users to return a queue cookie
No functional changes in this patch, but it prepares us for returning a more useful cookie related to the IO that was queued up. Signed-off-by: Jens Axboe <axboe@fb.com> Acked-by: Christoph Hellwig <hch@lst.de> Acked-by: Keith Busch <keith.busch@intel.com>
This commit is contained in:
@@ -958,7 +958,8 @@ static void cached_dev_nodata(struct closure *cl)
|
||||
|
||||
/* Cached devices - read & write stuff */
|
||||
|
||||
static void cached_dev_make_request(struct request_queue *q, struct bio *bio)
|
||||
static blk_qc_t cached_dev_make_request(struct request_queue *q,
|
||||
struct bio *bio)
|
||||
{
|
||||
struct search *s;
|
||||
struct bcache_device *d = bio->bi_bdev->bd_disk->private_data;
|
||||
@@ -997,6 +998,8 @@ static void cached_dev_make_request(struct request_queue *q, struct bio *bio)
|
||||
else
|
||||
generic_make_request(bio);
|
||||
}
|
||||
|
||||
return BLK_QC_T_NONE;
|
||||
}
|
||||
|
||||
static int cached_dev_ioctl(struct bcache_device *d, fmode_t mode,
|
||||
@@ -1070,7 +1073,8 @@ static void flash_dev_nodata(struct closure *cl)
|
||||
continue_at(cl, search_free, NULL);
|
||||
}
|
||||
|
||||
static void flash_dev_make_request(struct request_queue *q, struct bio *bio)
|
||||
static blk_qc_t flash_dev_make_request(struct request_queue *q,
|
||||
struct bio *bio)
|
||||
{
|
||||
struct search *s;
|
||||
struct closure *cl;
|
||||
@@ -1093,7 +1097,7 @@ static void flash_dev_make_request(struct request_queue *q, struct bio *bio)
|
||||
continue_at_nobarrier(&s->cl,
|
||||
flash_dev_nodata,
|
||||
bcache_wq);
|
||||
return;
|
||||
return BLK_QC_T_NONE;
|
||||
} else if (rw) {
|
||||
bch_keybuf_check_overlapping(&s->iop.c->moving_gc_keys,
|
||||
&KEY(d->id, bio->bi_iter.bi_sector, 0),
|
||||
@@ -1109,6 +1113,7 @@ static void flash_dev_make_request(struct request_queue *q, struct bio *bio)
|
||||
}
|
||||
|
||||
continue_at(cl, search_free, NULL);
|
||||
return BLK_QC_T_NONE;
|
||||
}
|
||||
|
||||
static int flash_dev_ioctl(struct bcache_device *d, fmode_t mode,
|
||||
|
Reference in New Issue
Block a user