diff options
Diffstat (limited to 'include/linux/iocontext.h')
-rw-r--r-- | include/linux/iocontext.h | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/include/linux/iocontext.h b/include/linux/iocontext.h index b2eee896dcb..7cbace3e14f 100644 --- a/include/linux/iocontext.h +++ b/include/linux/iocontext.h | |||
@@ -1,14 +1,14 @@ | |||
1 | #ifndef IOCONTEXT_H | 1 | #ifndef IOCONTEXT_H |
2 | #define IOCONTEXT_H | 2 | #define IOCONTEXT_H |
3 | 3 | ||
4 | #include <linux/bitmap.h> | ||
4 | #include <linux/radix-tree.h> | 5 | #include <linux/radix-tree.h> |
5 | #include <linux/rcupdate.h> | 6 | #include <linux/rcupdate.h> |
6 | 7 | ||
7 | struct cfq_queue; | ||
8 | struct cfq_io_context { | 8 | struct cfq_io_context { |
9 | void *key; | 9 | void *key; |
10 | 10 | ||
11 | struct cfq_queue *cfqq[2]; | 11 | void *cfqq[2]; |
12 | 12 | ||
13 | struct io_context *ioc; | 13 | struct io_context *ioc; |
14 | 14 | ||
@@ -28,6 +28,16 @@ struct cfq_io_context { | |||
28 | }; | 28 | }; |
29 | 29 | ||
30 | /* | 30 | /* |
31 | * Indexes into the ioprio_changed bitmap. A bit set indicates that | ||
32 | * the corresponding I/O scheduler needs to see a ioprio update. | ||
33 | */ | ||
34 | enum { | ||
35 | IOC_CFQ_IOPRIO_CHANGED, | ||
36 | IOC_BFQ_IOPRIO_CHANGED, | ||
37 | IOC_IOPRIO_CHANGED_BITS | ||
38 | }; | ||
39 | |||
40 | /* | ||
31 | * I/O subsystem state of the associated processes. It is refcounted | 41 | * I/O subsystem state of the associated processes. It is refcounted |
32 | * and kmalloc'ed. These could be shared between processes. | 42 | * and kmalloc'ed. These could be shared between processes. |
33 | */ | 43 | */ |
@@ -39,7 +49,7 @@ struct io_context { | |||
39 | spinlock_t lock; | 49 | spinlock_t lock; |
40 | 50 | ||
41 | unsigned short ioprio; | 51 | unsigned short ioprio; |
42 | unsigned short ioprio_changed; | 52 | DECLARE_BITMAP(ioprio_changed, IOC_IOPRIO_CHANGED_BITS); |
43 | 53 | ||
44 | #if defined(CONFIG_BLK_CGROUP) || defined(CONFIG_BLK_CGROUP_MODULE) | 54 | #if defined(CONFIG_BLK_CGROUP) || defined(CONFIG_BLK_CGROUP_MODULE) |
45 | unsigned short cgroup_changed; | 55 | unsigned short cgroup_changed; |
@@ -53,6 +63,8 @@ struct io_context { | |||
53 | 63 | ||
54 | struct radix_tree_root radix_root; | 64 | struct radix_tree_root radix_root; |
55 | struct hlist_head cic_list; | 65 | struct hlist_head cic_list; |
66 | struct radix_tree_root bfq_radix_root; | ||
67 | struct hlist_head bfq_cic_list; | ||
56 | void __rcu *ioc_data; | 68 | void __rcu *ioc_data; |
57 | }; | 69 | }; |
58 | 70 | ||