incubator-nuttx/sched/clock
Xiang Xiao 6d69439f58 Call xxx_timer_initialize from clock subsystem
Call xxx_timer_initialize from clock subsystem to make timer ready for use as soon as possiblei and revert the workaround:

commit 0863e771a9
Author: Gregory Nutt <gnutt@nuttx.org>
Date:   Fri Apr 26 07:24:57 2019 -0600

    Revert "sched/clock/clock_initialize.c:  clock_inittime() needs to be done with CONFIG_SCHED_TICKLESS and clock_initialize should skip clock_inittime() for external RTC case since the RTC isn't ready yet."

    This reverts commit 2bc709d4b9.

    Commit 2bc709d4b9 was intended to handle the case where up_timer_gettime may not start from zero case.  However, this change has the side-effect of breaking every implementation of tickless mode:  After this change the tickless timer structures are used before they are initialized in clock_inittime().  Initialization happens later when up_initialize is called() when arm_timer_initialize().

    Since the tickless mode timer is very special, one solution might be to

    1. Rename xxx_timer_initialize to up_timer_initialize
    2  Move up_timer_initialize to include/nuttx/arch.h
    3.  Call it from clock subsystem instead up_initialize

    Basically, this change make timer initialization almost same as rtc initialization(up_rtc_initialize).

    For now, however, we just need to revert the change.
2020-02-08 07:40:06 -06:00
..
Make.defs syscall: clock_systimer() is no longer a system call. It has been replaced with the equivalent, standard interface clock() as the system call. 2018-06-16 12:50:28 -06:00
clock.c sched/clock/clock.c: Correct a comment as noted in Issue 175. 2019-10-17 12:24:19 -06:00
clock.h sched/clock/ timekeeping: Use clock_basetime() to initialize g_clock_wall_time to get the best initial RTC value and initialize g_clock_last_counter too since the hardware may not start counting from zero. 2018-11-12 07:00:41 -06:00
clock_abstime2ticks.c Elimate use of the non-standard type systime_t and replace it the equivalent, standard type clock_t 2018-06-16 12:16:13 -06:00
clock_dow.c tools/nxstyle.c: Fix logic that detects if an operator is correctly delimited with spaces. sched/: Various changes because sched/ C files were used as Guinea Pigs to test nstyle.c. 2019-03-01 10:50:02 -06:00
clock_getres.c tools/nxstyle.c: Fix a rare false alarm that could occur if a variable or function name begins with the sub-string 'union' or 'struct'. misc fixes under fs/ and sched/ from application of current version of nxstyle. 2019-12-01 13:01:16 -06:00
clock_gettime.c sched/clock/: Don't call up_timer_gettime in clock_gettime and clock_systimer to ensure the return value from them consistent with clock_systimespec 2018-11-12 06:52:56 -06:00
clock_initialize.c Call xxx_timer_initialize from clock subsystem 2020-02-08 07:40:06 -06:00
clock_settime.c Fix wait loop and void cast (#24) 2020-01-02 10:54:43 -06:00
clock_systimer.c Fix wait loop and void cast (#24) 2020-01-02 10:54:43 -06:00
clock_systimespec.c Merged in jgraef-linetco/nuttx/fix-32bit-timer-overflow (pull request #1055) 2019-10-21 12:23:02 +00:00
clock_ticks2time.c Elimate use of the non-standard type systime_t and replace it the equivalent, standard type clock_t 2018-06-16 12:16:13 -06:00
clock_time2ticks.c Elimate use of the non-standard type systime_t and replace it the equivalent, standard type clock_t 2018-06-16 12:16:13 -06:00
clock_timekeeping.c tools/nxstyle.c: Add automatic detection of line width based on examining 2020-01-12 13:07:54 -03:00
clock_timekeeping.h ched/clock/: Remove g_monotonic_basetime and g_clock_monotonic_time since we don't need ensure monotonic time start from zero as state here: http://pubs.opengroup.org/onlinepubs/009696899/functions/clock_getres.html 2018-11-12 06:50:37 -06:00
clock_timespec_add.c Fix typos and some incorrect comments 2020-01-20 09:32:36 -03:00
clock_timespec_subtract.c Fix typos and some incorrect comments 2020-01-20 09:32:36 -03:00