]> git.ipfire.org Git - thirdparty/kernel/stable.git/blame - drivers/md/bcache/request.h
Merge tag 'kvm-x86-generic-6.8' of https://github.com/kvm-x86/linux into HEAD
[thirdparty/kernel/stable.git] / drivers / md / bcache / request.h
CommitLineData
b2441318 1/* SPDX-License-Identifier: GPL-2.0 */
cafe5635
KO
2#ifndef _BCACHE_REQUEST_H_
3#define _BCACHE_REQUEST_H_
4
220bb38c 5struct data_insert_op {
cafe5635 6 struct closure cl;
c18536a7 7 struct cache_set *c;
220bb38c 8 struct bio *bio;
da415a09 9 struct workqueue_struct *wq;
cafe5635 10
6f10f7d1 11 unsigned int inode;
2599b53b 12 uint16_t write_point;
220bb38c 13 uint16_t write_prio;
4e4cbee9 14 blk_status_t status;
c18536a7 15
a5ae4300
KO
16 union {
17 uint16_t flags;
c18536a7 18
a5ae4300 19 struct {
6f10f7d1
CL
20 unsigned int bypass:1;
21 unsigned int writeback:1;
22 unsigned int flush_journal:1;
23 unsigned int csum:1;
cafe5635 24
6f10f7d1
CL
25 unsigned int replace:1;
26 unsigned int replace_collision:1;
a5ae4300 27
6f10f7d1 28 unsigned int insert_data_done:1;
a5ae4300
KO
29 };
30 };
0b93207a 31
0b93207a 32 struct keylist insert_keys;
1b207d80 33 BKEY_PADDED(replace_key);
cafe5635
KO
34};
35
3a394727 36unsigned int bch_get_congested(const struct cache_set *c);
d4e3b928 37CLOSURE_CALLBACK(bch_data_insert);
cafe5635 38
cafe5635 39void bch_cached_dev_request_init(struct cached_dev *dc);
3e08773c 40void cached_dev_submit_bio(struct bio *bio);
ff27668c 41
cafe5635 42void bch_flash_dev_request_init(struct bcache_device *d);
3e08773c 43void flash_dev_submit_bio(struct bio *bio);
cafe5635 44
3fd3c5c0 45extern struct kmem_cache *bch_search_cache;
cafe5635 46
cafe5635 47#endif /* _BCACHE_REQUEST_H_ */