diff options
Diffstat (limited to 'drivers/md/bcache/util.c')
-rw-r--r-- | drivers/md/bcache/util.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/drivers/md/bcache/util.c b/drivers/md/bcache/util.c index 6198041f0ee2..74febd5230df 100644 --- a/drivers/md/bcache/util.c +++ b/drivers/md/bcache/util.c | |||
@@ -82,10 +82,9 @@ STRTO_H(strtoll, long long) | |||
82 | STRTO_H(strtoull, unsigned long long) | 82 | STRTO_H(strtoull, unsigned long long) |
83 | 83 | ||
84 | /** | 84 | /** |
85 | * bch_hprint() - formats @v to human readable string for sysfs. | 85 | * bch_hprint - formats @v to human readable string for sysfs. |
86 | * | 86 | * @buf: the (at least 8 byte) buffer to format the result into. |
87 | * @v - signed 64 bit integer | 87 | * @v: signed 64 bit integer |
88 | * @buf - the (at least 8 byte) buffer to format the result into. | ||
89 | * | 88 | * |
90 | * Returns the number of bytes used by format. | 89 | * Returns the number of bytes used by format. |
91 | */ | 90 | */ |
@@ -225,13 +224,12 @@ void bch_time_stats_update(struct time_stats *stats, uint64_t start_time) | |||
225 | } | 224 | } |
226 | 225 | ||
227 | /** | 226 | /** |
228 | * bch_next_delay() - increment @d by the amount of work done, and return how | 227 | * bch_next_delay() - update ratelimiting statistics and calculate next delay |
229 | * long to delay until the next time to do some work. | 228 | * @d: the struct bch_ratelimit to update |
230 | * | 229 | * @done: the amount of work done, in arbitrary units |
231 | * @d - the struct bch_ratelimit to update | ||
232 | * @done - the amount of work done, in arbitrary units | ||
233 | * | 230 | * |
234 | * Returns the amount of time to delay by, in jiffies | 231 | * Increment @d by the amount of work done, and return how long to delay in |
232 | * jiffies until the next time to do some work. | ||
235 | */ | 233 | */ |
236 | uint64_t bch_next_delay(struct bch_ratelimit *d, uint64_t done) | 234 | uint64_t bch_next_delay(struct bch_ratelimit *d, uint64_t done) |
237 | { | 235 | { |