diff options
Diffstat (limited to 'block/blk.h')
-rw-r--r-- | block/blk.h | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/block/blk.h b/block/blk.h index 3ee94358b43d..24fcaeeaf620 100644 --- a/block/blk.h +++ b/block/blk.h | |||
@@ -70,6 +70,10 @@ void blk_queue_congestion_threshold(struct request_queue *q); | |||
70 | 70 | ||
71 | int blk_dev_init(void); | 71 | int blk_dev_init(void); |
72 | 72 | ||
73 | void elv_quisce_start(struct request_queue *q); | ||
74 | void elv_quisce_end(struct request_queue *q); | ||
75 | |||
76 | |||
73 | /* | 77 | /* |
74 | * Return the threshold (number of used requests) at which the queue is | 78 | * Return the threshold (number of used requests) at which the queue is |
75 | * considered to be congested. It include a little hysteresis to keep the | 79 | * considered to be congested. It include a little hysteresis to keep the |
@@ -108,12 +112,14 @@ static inline int blk_cpu_to_group(int cpu) | |||
108 | #endif | 112 | #endif |
109 | } | 113 | } |
110 | 114 | ||
111 | static inline int blk_do_io_stat(struct request_queue *q) | 115 | static inline int blk_do_io_stat(struct request *rq) |
112 | { | 116 | { |
113 | if (q) | 117 | struct gendisk *disk = rq->rq_disk; |
114 | return blk_queue_io_stat(q); | ||
115 | 118 | ||
116 | return 0; | 119 | if (!disk || !disk->queue) |
120 | return 0; | ||
121 | |||
122 | return blk_queue_io_stat(disk->queue) && (rq->cmd_flags & REQ_ELVPRIV); | ||
117 | } | 123 | } |
118 | 124 | ||
119 | #endif | 125 | #endif |