aboutsummaryrefslogtreecommitdiffstats
path: root/block/blk-wbt.h
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2016-11-28 11:22:47 -0500
committerJens Axboe <axboe@fb.com>2016-11-28 12:27:03 -0500
commit80e091d10e8bf7b801d634ea8870b9e907314424 (patch)
tree05d99a001b158de7e3f6f9eb119f28bb226b8bc2 /block/blk-wbt.h
parentfeffa5cc7b47f38210d4997ceb3fe30881d6c337 (diff)
blk-wbt: allow reset of default latency through sysfs
Allow a write of '-1' to reset the default latency target for a given device. This removes knowledge of the different default settings for rotational vs non-rotational from user space. Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/blk-wbt.h')
-rw-r--r--block/blk-wbt.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/block/blk-wbt.h b/block/blk-wbt.h
index 44dc2173dc1f..9dfc88ad7f30 100644
--- a/block/blk-wbt.h
+++ b/block/blk-wbt.h
@@ -110,6 +110,8 @@ void wbt_disable(struct rq_wb *);
110void wbt_set_queue_depth(struct rq_wb *, unsigned int); 110void wbt_set_queue_depth(struct rq_wb *, unsigned int);
111void wbt_set_write_cache(struct rq_wb *, bool); 111void wbt_set_write_cache(struct rq_wb *, bool);
112 112
113u64 wbt_default_latency_nsec(struct request_queue *);
114
113#else 115#else
114 116
115static inline void __wbt_done(struct rq_wb *rwb, enum wbt_flags flags) 117static inline void __wbt_done(struct rq_wb *rwb, enum wbt_flags flags)
@@ -148,6 +150,10 @@ static inline void wbt_set_queue_depth(struct rq_wb *rwb, unsigned int depth)
148static inline void wbt_set_write_cache(struct rq_wb *rwb, bool wc) 150static inline void wbt_set_write_cache(struct rq_wb *rwb, bool wc)
149{ 151{
150} 152}
153static inline u64 wbt_default_latency_nsec(struct request_queue *q)
154{
155 return 0;
156}
151 157
152#endif /* CONFIG_BLK_WBT */ 158#endif /* CONFIG_BLK_WBT */
153 159