1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

sys/ztimer/xtimer_compat: fix bug introduced in #17690

This commit is contained in:
Karl Fessel 2022-02-25 13:20:23 +01:00
parent d895a29c79
commit eb87cb7d3a

View File

@ -142,16 +142,16 @@ static inline void xtimer_tsleep32(xtimer_ticks32_t ticks)
xtimer_usleep(xtimer_usec_from_ticks(ticks));
}
static inline uint64_t xtimer_tsleep64(xtimer_ticks64_t ticks)
static inline void xtimer_tsleep64(xtimer_ticks64_t ticks)
{
const uint32_t max_sleep = UINT32_MAX;
uint64_t time = xtimer_usec_from_ticks64(ticks);
while (time > max_sleep) {
xtimer_usleep(clock, max_sleep);
xtimer_usleep(max_sleep);
time -= max_sleep;
}
xtimer_usleep(clock, time);
xtimer_usleep(time);
}
static inline void xtimer_set(xtimer_t *timer, uint32_t offset)