drv_hrt: inline hrt_elapsed_time

GCC did not do that.
This commit is contained in:
Beat Küng
2019-01-25 07:53:37 +01:00
parent 2ffb49b734
commit 74a3c378b2
5 changed files with 4 additions and 47 deletions
-13
View File
@@ -198,19 +198,6 @@ hrt_abstime ts_to_abstime(const struct timespec *ts)
return result;
}
/*
* Compute the delta between a timestamp taken in the past
* and now.
*
* This function is safe to use even if the timestamp is updated
* by an interrupt during execution.
*/
hrt_abstime hrt_elapsed_time(const hrt_abstime *then)
{
hrt_abstime delta = hrt_absolute_time() - *then;
return delta;
}
/*
* Compute the delta between a timestamp taken in the past
* and now.