]> git.baikalelectronics.ru Git - kernel.git/commit
dm mpath: only use ktime_get_ns() in historical selector
authorKhazhismel Kumykov <khazhy@google.com>
Mon, 11 Apr 2022 22:03:35 +0000 (15:03 -0700)
committerMike Snitzer <snitzer@kernel.org>
Wed, 13 Apr 2022 17:22:16 +0000 (13:22 -0400)
commitfd9f2bcac7bb139a7d92ebdbf16f8e65d01376cc
tree5854511d1b2d3cac9dadf05b2a8d4393b5cdf147
parentdac017807aba95ca107aa15d7e4e5ad4529e2605
dm mpath: only use ktime_get_ns() in historical selector

Mixing sched_clock() and ktime_get_ns() usage will give bad results.

Switch hst_select_path() from using sched_clock() to ktime_get_ns().
Also rename path_service_time()'s 'sched_now' variable to 'now'.

Fixes: df856fcc7cb6 ("dm mpath: add Historical Service Time Path Selector")
Signed-off-by: Khazhismel Kumykov <khazhy@google.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
drivers/md/dm-ps-historical-service-time.c