sys/ztimer: add ztimer64_xtimer_compat complete xtimer replace module#17670
sys/ztimer: add ztimer64_xtimer_compat complete xtimer replace module#17670kaspar030 merged 3 commits intoRIOT-OS:masterfrom
Conversation
|
@leandrolanzieri do you mind taking a quick look I changed some of the xtimer/ztimer modelings, and I want to be sure I'm not re-introducing issues. |
4e6f9f7 to
28b6c93
Compare
sys/xtimer/Kconfig
Outdated
|
|
||
| # use timer peripheral unless ztimer compatibility module is used | ||
| select MODULE_PERIPH_TIMER if HAS_PERIPH_TIMER && !MODULE_XTIMER_ON_ZTIMER && !MODULE_ZTIMER_XTIMER_COMPAT | ||
| select MODULE_PERIPH_TIMER if HAS_PERIPH_TIMER |
There was a problem hiding this comment.
I think the idea of this was not to force the timer backend when compatibility is in place, leaving the option of the hardware to the Ztimer config. Why does this change?
There was a problem hiding this comment.
Hmmm let me revert it and remember why hahaha
There was a problem hiding this comment.
will split out in another commit if justfied
There was a problem hiding this comment.
Hmm well all green
There was a problem hiding this comment.
@leandrolanzieri does everything else Kconfig related look good to you?
sys/xtimer/Kconfig
Outdated
| depends on HAS_PERIPH_TIMER | ||
| depends on TEST_KCONFIG | ||
| select MODULE_PERIPH_TIMER if HAS_PERIPH_TIMER | ||
| # select MODULE_PERIPH_TIMER if HAS_PERIPH_TIMER |
There was a problem hiding this comment.
Should remove this line then
There was a problem hiding this comment.
The comment? yes, that means you still keep
select MODULE_PERIPH_TIMER if HAS_PERIPH_TIMER && !MODULE_XTIMER_ON_ZTIMER && !MODULE_ZTIMER_XTIMER_COMPAT
right?
There was a problem hiding this comment.
Yes, I meant removing the comments, ti was a note for myself when rebasing.
|
@kaspar030 could you give this one a look? IMO its missing only a rebase, squash, uncrustify the header file and this #17670 (comment) |
|
Maybe @kfessel wants to take a look as well |
|
I added as asked for a In a follow up what I'll do is enable |
So I'm modeling |
|
@kaspar030 @kfessel I'll split the event_timeout not supporting |
sys/include/ztimer64/xtimer_compat.h
Outdated
| return ztimer64_now(ZTIMER64_USEC); | ||
| } | ||
|
|
||
|
|
There was a problem hiding this comment.
some static test does not like that empty line
67a3e10 to
8555df0
Compare
|
somthing went wrong (event/timeout.c got added) |
8555df0 to
03cec76
Compare
ups wrong rebase, re-added |
|
Well all green |
kfessel
left a comment
There was a problem hiding this comment.
two nitpicks,
i think you can squash them right in and skip the murdock build
The ztimer64_xtimer_compat modules implements the whole xtimer api on top of ztimer64_usec
03cec76 to
46fe917
Compare
|
Squashed in both nitpicks @kfessel |
|
All green @kaspar030 @kfessel |
|
Thanks, @kaspar030 @kfessel! |
Contribution description
This PR makes
ztimer_xtimer_compatuseztimer64_usecimplementing allxtimerapi, with thisztimer64_useccan be used as a drop-in replacement forxtimer.Testing procedure
Issues/PRs references
Split from #17365