time: Proactive pull from FlashFloppy for 32-bit timebase update period

Make the period proportional to systick rate by updating the timebase
every 2^23 systicks. This will always be safe, no matter how high the
systick rate.
This commit is contained in:
Keir Fraser
2023-07-14 14:24:03 +01:00
parent ca7447ceac
commit ee02a86e80
2 changed files with 7 additions and 2 deletions

View File

@@ -14,6 +14,7 @@ typedef uint32_t time_t;
#define TIME_MHZ STK_MHZ
#define time_us(x) stk_us(x)
#define time_ms(x) stk_ms(x)
#define time_stk(x) (x)
#define time_sysclk(x) stk_sysclk(x)
#define sysclk_time(x) sysclk_stk(x)