From 2e4dfa0aac1ded1a85e6824851f7d68de504c50e Mon Sep 17 00:00:00 2001 From: Francisco Molina Date: Tue, 2 Nov 2021 15:31:04 +0100 Subject: [PATCH] sys/ztimer: don't default to rtc for ztimer_sec --- sys/ztimer/Kconfig | 2 -- sys/ztimer/Makefile.dep | 21 ++++----------------- 2 files changed, 4 insertions(+), 19 deletions(-) diff --git a/sys/ztimer/Kconfig b/sys/ztimer/Kconfig index 5078457b0c..c788ca8e49 100644 --- a/sys/ztimer/Kconfig +++ b/sys/ztimer/Kconfig @@ -74,8 +74,6 @@ config MODULE_ZTIMER_SEC choice bool "Backend" depends on MODULE_ZTIMER_SEC - default ZTIMER_SEC_BACKEND_RTC if !BOARD_NATIVE && \ - !HAVE_SHARED_PERIPH_RTT_PERIPH_RTC default ZTIMER_SEC_BACKEND_RTT config ZTIMER_SEC_BACKEND_TIMER diff --git a/sys/ztimer/Makefile.dep b/sys/ztimer/Makefile.dep index 787119a9d9..131efa2160 100644 --- a/sys/ztimer/Makefile.dep +++ b/sys/ztimer/Makefile.dep @@ -111,24 +111,11 @@ endif ifneq (,$(filter ztimer_sec,$(USEMODULE))) USEMODULE += ztimer - # try to use RTC unless we are on native, as it is based on xtimer it is - # actually buggy - ifeq (,$(filter native,$(BOARD))) - FEATURES_OPTIONAL += periph_rtc - endif + FEATURES_OPTIONAL += periph_rtt # HACK: see above - include $(RIOTMAKE)/features_check.inc.mk - ifneq (,$(filter periph_rtc,$(FEATURES_USED))) - USEMODULE += ztimer_periph_rtc + ifneq (,$(filter periph_rtt,$(FEATURES_USED))) + USEMODULE += ztimer_periph_rtt else - # if there is no RTC try to use RTT - FEATURES_OPTIONAL += periph_rtt - # HACK: see above - include $(RIOTMAKE)/features_check.inc.mk - ifneq (,$(filter periph_rtt,$(FEATURES_USED))) - USEMODULE += ztimer_periph_rtt - else - USEMODULE += ztimer_periph_timer - endif + USEMODULE += ztimer_periph_timer endif endif