Commit 8ca8b1e1 authored by Wang Qing's avatar Wang Qing Committed by Mike Snitzer

dm thin: use time_is_before_jiffies instead of open coding it

Use time_is_before_jiffies() to improve code readability.
Signed-off-by: default avatarWang Qing <wangqing@vivo.com>
Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>
parent 6fc51504
......@@ -161,7 +161,7 @@ static void throttle_work_start(struct throttle *t)
static void throttle_work_update(struct throttle *t)
{
if (!t->throttle_applied && jiffies > t->threshold) {
if (!t->throttle_applied && time_is_before_jiffies(t->threshold)) {
down_write(&t->lock);
t->throttle_applied = true;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment