Commit 8be9b102 authored by Adam Wujek's avatar Adam Wujek 💬

userspace/wrsw_hal: reduce a load of HAL

Fix the bug introduced by a commit:
291a32c7 userspace/wrsw_hal: use get_monotonic_* instead of clock_gettime

get_monotonic_tics() return a value in us resolution, so to get ms it has to be
divided by 1000, not multiplied.
Signed-off-by: Adam Wujek's avatarAdam Wujek <adam.wujek@cern.ch>
parent dfcea15f
......@@ -261,7 +261,7 @@ int main(int argc, char *argv[])
hal_update_wripc(25 /* max ms delay */);
t2 = get_monotonic_tics();
delay_ms = (t2 - t1) * 1000;
delay_ms = (t2 - t1) / 1000;
if (delay_ms < PORT_FAN_MS_PERIOD)
continue;
......
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