From eb87cb7d3a0f850cef0f2c0865197457d4a2df61 Mon Sep 17 00:00:00 2001 From: Karl Fessel Date: Fri, 25 Feb 2022 13:20:23 +0100 Subject: [PATCH] sys/ztimer/xtimer_compat: fix bug introduced in #17690 --- sys/include/ztimer/xtimer_compat.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/include/ztimer/xtimer_compat.h b/sys/include/ztimer/xtimer_compat.h index c184b0adf4..6074886856 100644 --- a/sys/include/ztimer/xtimer_compat.h +++ b/sys/include/ztimer/xtimer_compat.h @@ -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)