Skip to content

Commit 2385010

Browse files
YijingWangaxboe
authored andcommitted
bcache: remove unused parameter
Parameter bio is no longer used, clean it. Signed-off-by: Yijing Wang <wangyijing@huawei.com> Reviewed-by: Coly Li <colyli@suse.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent b41c9b0 commit 2385010

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

‎drivers/md/bcache/request.c‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,12 @@ struct kmem_cache *bch_search_cache;
2626

2727
static void bch_data_insert_start(struct closure *);
2828

29-
static unsigned cache_mode(struct cached_dev *dc, struct bio *bio)
29+
static unsigned cache_mode(struct cached_dev *dc)
3030
{
3131
return BDEV_CACHE_MODE(&dc->sb);
3232
}
3333

34-
static bool verify(struct cached_dev *dc, struct bio *bio)
34+
static bool verify(struct cached_dev *dc)
3535
{
3636
return dc->verify;
3737
}
@@ -369,7 +369,7 @@ static struct hlist_head *iohash(struct cached_dev *dc, uint64_t k)
369369
static bool check_should_bypass(struct cached_dev *dc, struct bio *bio)
370370
{
371371
struct cache_set *c = dc->disk.c;
372-
unsigned mode = cache_mode(dc, bio);
372+
unsigned mode = cache_mode(dc);
373373
unsigned sectors, congested = bch_get_congested(c);
374374
struct task_struct *task = current;
375375
struct io *i;
@@ -747,7 +747,7 @@ static void cached_dev_read_done(struct closure *cl)
747747
s->cache_miss = NULL;
748748
}
749749

750-
if (verify(dc, &s->bio.bio) && s->recoverable && !s->read_dirty_data)
750+
if (verify(dc) && s->recoverable && !s->read_dirty_data)
751751
bch_data_verify(dc, s->orig_bio);
752752

753753
bio_complete(s);
@@ -772,7 +772,7 @@ static void cached_dev_read_done_bh(struct closure *cl)
772772

773773
if (s->iop.status)
774774
continue_at_nobarrier(cl, cached_dev_read_error, bcache_wq);
775-
else if (s->iop.bio || verify(dc, &s->bio.bio))
775+
else if (s->iop.bio || verify(dc))
776776
continue_at_nobarrier(cl, cached_dev_read_done, bcache_wq);
777777
else
778778
continue_at_nobarrier(cl, cached_dev_bio_complete, NULL);
@@ -899,7 +899,7 @@ static void cached_dev_write(struct cached_dev *dc, struct search *s)
899899
s->iop.bypass = true;
900900

901901
if (should_writeback(dc, s->orig_bio,
902-
cache_mode(dc, bio),
902+
cache_mode(dc),
903903
s->iop.bypass)) {
904904
s->iop.bypass = false;
905905
s->iop.writeback = true;

0 commit comments

Comments
 (0)