nano_timer: Make nano_timer_init call _nano_timeout_init

With the introduction of _nano_timeout_init it prefered to call it
to initialize the _nano_timeout fields properly.

Change-Id: I83e9c63f9bb2903c508264d1199d2c687c330ec8
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This commit is contained in:
Luiz Augusto von Dentz 2016-05-25 12:42:04 +03:00 committed by Anas Nashif
parent 10e33ff779
commit 4afb4e4150

View file

@ -22,14 +22,8 @@
void nano_timer_init(struct nano_timer *timer, void *data)
{
/* initialize timer in expired state */
timer->timeout_data.delta_ticks_from_prev = -1;
/* initialize to no object to wait on */
timer->timeout_data.wait_q = NULL;
/* initialize to no fiber waiting for the timer expire */
timer->timeout_data.tcs = NULL;
/* initialize timeout_data */
_nano_timeout_init(&timer->timeout_data);
/* nano_timer_test() returns NULL on timer that was not started */
timer->user_data = NULL;