aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/md/bcache/request.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/md/bcache/request.h')
-rw-r--r--drivers/md/bcache/request.h43
1 files changed, 18 insertions, 25 deletions
diff --git a/drivers/md/bcache/request.h b/drivers/md/bcache/request.h
index 57dc4784f4f4..2cd65bf073c2 100644
--- a/drivers/md/bcache/request.h
+++ b/drivers/md/bcache/request.h
@@ -3,40 +3,33 @@
3 3
4#include <linux/cgroup.h> 4#include <linux/cgroup.h>
5 5
6struct search { 6struct data_insert_op {
7 /* Stack frame for bio_complete */
8 struct closure cl; 7 struct closure cl;
8 struct cache_set *c;
9 struct bio *bio;
9 10
10 struct bcache_device *d; 11 unsigned inode;
11 struct task_struct *task; 12 uint16_t write_point;
12 13 uint16_t write_prio;
13 struct bbio bio; 14 short error;
14 struct bio *orig_bio;
15 struct bio *cache_miss;
16 unsigned cache_bio_sectors;
17
18 unsigned recoverable:1;
19 unsigned unaligned_bvec:1;
20 15
21 unsigned write:1; 16 unsigned bypass:1;
22 unsigned writeback:1; 17 unsigned writeback:1;
18 unsigned flush_journal:1;
19 unsigned csum:1;
23 20
24 /* IO error returned to s->bio */ 21 unsigned replace:1;
25 short error; 22 unsigned replace_collision:1;
26 unsigned long start_time; 23
24 unsigned insert_data_done:1;
27 25
28 /* Anything past op->keys won't get zeroed in do_bio_hook */ 26 /* Anything past this point won't get zeroed in search_alloc() */
29 struct btree_op op; 27 struct keylist insert_keys;
28 BKEY_PADDED(replace_key);
30}; 29};
31 30
32void bch_cache_read_endio(struct bio *, int);
33unsigned bch_get_congested(struct cache_set *); 31unsigned bch_get_congested(struct cache_set *);
34void bch_insert_data(struct closure *cl); 32void bch_data_insert(struct closure *cl);
35void bch_btree_insert_async(struct closure *);
36void bch_cache_read_endio(struct bio *, int);
37
38void bch_open_buckets_free(struct cache_set *);
39int bch_open_buckets_alloc(struct cache_set *);
40 33
41void bch_cached_dev_request_init(struct cached_dev *dc); 34void bch_cached_dev_request_init(struct cached_dev *dc);
42void bch_flash_dev_request_init(struct bcache_device *d); 35void bch_flash_dev_request_init(struct bcache_device *d);