aboutsummaryrefslogtreecommitdiffstats
path: root/block/cfq.h
diff options
context:
space:
mode:
Diffstat (limited to 'block/cfq.h')
-rw-r--r--block/cfq.h96
1 files changed, 58 insertions, 38 deletions
diff --git a/block/cfq.h b/block/cfq.h
index 398760194e11..5584e1b63ca8 100644
--- a/block/cfq.h
+++ b/block/cfq.h
@@ -4,67 +4,79 @@
4 4
5#ifdef CONFIG_CFQ_GROUP_IOSCHED 5#ifdef CONFIG_CFQ_GROUP_IOSCHED
6static inline void cfq_blkiocg_update_io_add_stats(struct blkio_group *blkg, 6static inline void cfq_blkiocg_update_io_add_stats(struct blkio_group *blkg,
7 struct blkio_group *curr_blkg, bool direction, bool sync) 7 struct blkio_policy_type *pol,
8 struct blkio_group *curr_blkg,
9 bool direction, bool sync)
8{ 10{
9 blkiocg_update_io_add_stats(blkg, curr_blkg, direction, sync); 11 blkiocg_update_io_add_stats(blkg, pol, curr_blkg, direction, sync);
10} 12}
11 13
12static inline void cfq_blkiocg_update_dequeue_stats(struct blkio_group *blkg, 14static inline void cfq_blkiocg_update_dequeue_stats(struct blkio_group *blkg,
13 unsigned long dequeue) 15 struct blkio_policy_type *pol, unsigned long dequeue)
14{ 16{
15 blkiocg_update_dequeue_stats(blkg, dequeue); 17 blkiocg_update_dequeue_stats(blkg, pol, dequeue);
16} 18}
17 19
18static inline void cfq_blkiocg_update_timeslice_used(struct blkio_group *blkg, 20static inline void cfq_blkiocg_update_timeslice_used(struct blkio_group *blkg,
19 unsigned long time, unsigned long unaccounted_time) 21 struct blkio_policy_type *pol, unsigned long time,
22 unsigned long unaccounted_time)
20{ 23{
21 blkiocg_update_timeslice_used(blkg, time, unaccounted_time); 24 blkiocg_update_timeslice_used(blkg, pol, time, unaccounted_time);
22} 25}
23 26
24static inline void cfq_blkiocg_set_start_empty_time(struct blkio_group *blkg) 27static inline void cfq_blkiocg_set_start_empty_time(struct blkio_group *blkg,
28 struct blkio_policy_type *pol)
25{ 29{
26 blkiocg_set_start_empty_time(blkg); 30 blkiocg_set_start_empty_time(blkg, pol);
27} 31}
28 32
29static inline void cfq_blkiocg_update_io_remove_stats(struct blkio_group *blkg, 33static inline void cfq_blkiocg_update_io_remove_stats(struct blkio_group *blkg,
30 bool direction, bool sync) 34 struct blkio_policy_type *pol, bool direction,
35 bool sync)
31{ 36{
32 blkiocg_update_io_remove_stats(blkg, direction, sync); 37 blkiocg_update_io_remove_stats(blkg, pol, direction, sync);
33} 38}
34 39
35static inline void cfq_blkiocg_update_io_merged_stats(struct blkio_group *blkg, 40static inline void cfq_blkiocg_update_io_merged_stats(struct blkio_group *blkg,
36 bool direction, bool sync) 41 struct blkio_policy_type *pol, bool direction,
42 bool sync)
37{ 43{
38 blkiocg_update_io_merged_stats(blkg, direction, sync); 44 blkiocg_update_io_merged_stats(blkg, pol, direction, sync);
39} 45}
40 46
41static inline void cfq_blkiocg_update_idle_time_stats(struct blkio_group *blkg) 47static inline void cfq_blkiocg_update_idle_time_stats(struct blkio_group *blkg,
48 struct blkio_policy_type *pol)
42{ 49{
43 blkiocg_update_idle_time_stats(blkg); 50 blkiocg_update_idle_time_stats(blkg, pol);
44} 51}
45 52
46static inline void 53static inline void
47cfq_blkiocg_update_avg_queue_size_stats(struct blkio_group *blkg) 54cfq_blkiocg_update_avg_queue_size_stats(struct blkio_group *blkg,
55 struct blkio_policy_type *pol)
48{ 56{
49 blkiocg_update_avg_queue_size_stats(blkg); 57 blkiocg_update_avg_queue_size_stats(blkg, pol);
50} 58}
51 59
52static inline void 60static inline void
53cfq_blkiocg_update_set_idle_time_stats(struct blkio_group *blkg) 61cfq_blkiocg_update_set_idle_time_stats(struct blkio_group *blkg,
62 struct blkio_policy_type *pol)
54{ 63{
55 blkiocg_update_set_idle_time_stats(blkg); 64 blkiocg_update_set_idle_time_stats(blkg, pol);
56} 65}
57 66
58static inline void cfq_blkiocg_update_dispatch_stats(struct blkio_group *blkg, 67static inline void cfq_blkiocg_update_dispatch_stats(struct blkio_group *blkg,
59 uint64_t bytes, bool direction, bool sync) 68 struct blkio_policy_type *pol, uint64_t bytes,
69 bool direction, bool sync)
60{ 70{
61 blkiocg_update_dispatch_stats(blkg, bytes, direction, sync); 71 blkiocg_update_dispatch_stats(blkg, pol, bytes, direction, sync);
62} 72}
63 73
64static inline void cfq_blkiocg_update_completion_stats(struct blkio_group *blkg, uint64_t start_time, uint64_t io_start_time, bool direction, bool sync) 74static inline void cfq_blkiocg_update_completion_stats(struct blkio_group *blkg,
75 struct blkio_policy_type *pol, uint64_t start_time,
76 uint64_t io_start_time, bool direction, bool sync)
65{ 77{
66 blkiocg_update_completion_stats(blkg, start_time, io_start_time, 78 blkiocg_update_completion_stats(blkg, pol, start_time, io_start_time,
67 direction, sync); 79 direction, sync);
68} 80}
69 81
70static inline int cfq_blkiocg_del_blkio_group(struct blkio_group *blkg) 82static inline int cfq_blkiocg_del_blkio_group(struct blkio_group *blkg)
@@ -74,30 +86,38 @@ static inline int cfq_blkiocg_del_blkio_group(struct blkio_group *blkg)
74 86
75#else /* CFQ_GROUP_IOSCHED */ 87#else /* CFQ_GROUP_IOSCHED */
76static inline void cfq_blkiocg_update_io_add_stats(struct blkio_group *blkg, 88static inline void cfq_blkiocg_update_io_add_stats(struct blkio_group *blkg,
77 struct blkio_group *curr_blkg, bool direction, bool sync) {} 89 struct blkio_policy_type *pol,
78 90 struct blkio_group *curr_blkg, bool direction,
91 bool sync) { }
79static inline void cfq_blkiocg_update_dequeue_stats(struct blkio_group *blkg, 92static inline void cfq_blkiocg_update_dequeue_stats(struct blkio_group *blkg,
80 unsigned long dequeue) {} 93 struct blkio_policy_type *pol, unsigned long dequeue) { }
81
82static inline void cfq_blkiocg_update_timeslice_used(struct blkio_group *blkg, 94static inline void cfq_blkiocg_update_timeslice_used(struct blkio_group *blkg,
83 unsigned long time, unsigned long unaccounted_time) {} 95 struct blkio_policy_type *pol, unsigned long time,
84static inline void cfq_blkiocg_set_start_empty_time(struct blkio_group *blkg) {} 96 unsigned long unaccounted_time) { }
97static inline void cfq_blkiocg_set_start_empty_time(struct blkio_group *blkg,
98 struct blkio_policy_type *pol) { }
85static inline void cfq_blkiocg_update_io_remove_stats(struct blkio_group *blkg, 99static inline void cfq_blkiocg_update_io_remove_stats(struct blkio_group *blkg,
86 bool direction, bool sync) {} 100 struct blkio_policy_type *pol, bool direction,
101 bool sync) { }
87static inline void cfq_blkiocg_update_io_merged_stats(struct blkio_group *blkg, 102static inline void cfq_blkiocg_update_io_merged_stats(struct blkio_group *blkg,
88 bool direction, bool sync) {} 103 struct blkio_policy_type *pol, bool direction,
89static inline void cfq_blkiocg_update_idle_time_stats(struct blkio_group *blkg) 104 bool sync) { }
90{ 105static inline void cfq_blkiocg_update_idle_time_stats(struct blkio_group *blkg,
91} 106 struct blkio_policy_type *pol) { }
92static inline void 107static inline void
93cfq_blkiocg_update_avg_queue_size_stats(struct blkio_group *blkg) {} 108cfq_blkiocg_update_avg_queue_size_stats(struct blkio_group *blkg,
109 struct blkio_policy_type *pol) { }
94 110
95static inline void 111static inline void
96cfq_blkiocg_update_set_idle_time_stats(struct blkio_group *blkg) {} 112cfq_blkiocg_update_set_idle_time_stats(struct blkio_group *blkg,
113 struct blkio_policy_type *pol) { }
97 114
98static inline void cfq_blkiocg_update_dispatch_stats(struct blkio_group *blkg, 115static inline void cfq_blkiocg_update_dispatch_stats(struct blkio_group *blkg,
99 uint64_t bytes, bool direction, bool sync) {} 116 struct blkio_policy_type *pol, uint64_t bytes,
100static inline void cfq_blkiocg_update_completion_stats(struct blkio_group *blkg, uint64_t start_time, uint64_t io_start_time, bool direction, bool sync) {} 117 bool direction, bool sync) { }
118static inline void cfq_blkiocg_update_completion_stats(struct blkio_group *blkg,
119 struct blkio_policy_type *pol, uint64_t start_time,
120 uint64_t io_start_time, bool direction, bool sync) { }
101 121
102static inline int cfq_blkiocg_del_blkio_group(struct blkio_group *blkg) 122static inline int cfq_blkiocg_del_blkio_group(struct blkio_group *blkg)
103{ 123{