kernel: Move timeout_remaining API

_timeout_remaining_get() was a function on a struct _timeout, doing
iteration on the timeout list, but it was defined in timer.c (the
higher level abstraction).

Move it to where it belongs.  Also have it return ticks instead of ms
to conform to scheme in the rest of the timeout API.  And rename it to
a more standard zephyr name.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
This commit is contained in:
Andy Ross 2018-09-28 09:06:37 -07:00 committed by Anas Nashif
commit 52e444bc05
5 changed files with 35 additions and 31 deletions

View file

@ -220,8 +220,6 @@ struct _timeout {
_timeout_func_t func;
};
extern s32_t _timeout_remaining_get(struct _timeout *timeout);
/*
* Number of ticks for x seconds. NOTE: With MSEC() or USEC(),
* since it does an integer division, x must be greater or equal to