Commit Graph

40 Commits (17b35f6ece14a22abcf7aee20d18dcea7314a0e9)

Author SHA1 Message Date
Joakim Nohlgård 63e91151cd xtimer: Add tick conversion 7 years ago
Joakim Nohlgård 4449ba4933 xtimer: Refactor xtimer_usleep_until and rename to xtimer_periodic_wakeup
Rewrote conditions for improved readability, and removed magic number 512
7 years ago
Joakim Nohlgård da8cd11816 xtimer: Move xtimer_spin_until into xtimer_core.c 7 years ago
Joakim Nohlgård 4fe674f746 xtimer: Add missing space 7 years ago
Joakim Nohlgård 7c70d3bc4f xtimer: Add Eistec copyright and author 7 years ago
Joakim Nohlgård 4d862955c2 xtimer: Rename XTIMER -> XTIMER_DEV 7 years ago
Joakim Nohlgård 2f832117f8 xtimer: prefix _lltimer_now, _lltimer_mask with _xtimer 7 years ago
Kaspar Schleiser 7718f114cb all: remove pointer casts for msg.content.ptr 7 years ago
Ian Martin 31c6bcc4d8 xtimer: return after xtimer_spin() when within an ISR 7 years ago
DipSwitch 0bb4748a94 core: Fix/refactor function naming in core/incude/irq.h 7 years ago
Kaspar Schleiser 9e3081849e sys: xtimer: fix some race conditions 7 years ago
Ian Martin 856c5e1539 s/XTIMER_RSHIFT/XTIMER_USEC_TO_TICKS/g
s/XTIMER_LSHIFT/XTIMER_TICKS_TO_USEC/g
7 years ago
Ian Martin f86c118594 xtimer: define XTIMER_RSHIFT() and XTIMER_LSHIFT() macros to avoid using XTIMER_SHIFT directly. 7 years ago
Hauke Petersen e9d79a37d6 sys/xtimer: adapted to timer API changes 7 years ago
malo 9b8fe52d5d xtimer: Fixed _add_timer_to_long_list since timer could be added at the wrong position.
Signed-off-by: malo <malo@25cmsquare.io>
7 years ago
malo 93eb56c612 xtimer: Fixed case when _xtimer_set_absolute called with target < now and target has _this_high_period .
Signed-off-by: malo <malo@25cmsquare.io>
7 years ago
Joakim Nohlgård df416c1b76 sys/xtimer: Update to match timer_init API changes 7 years ago
Kaspar Schleiser 2d1ad4b31e Merge pull request #4272 from OlegHahm/xtimer_msg_receive_timeout
xtimer: implement missing msg receive timeout
8 years ago
Oleg Hahm 0ddd6ec15e xtimer: implement xtimer_msg_receive_timeout 8 years ago
Kaspar Schleiser 2640277156 sys: xtimer: add posix sleep/usleep wrapper 8 years ago
Joakim Nohlgård d1b4e7a70b xtimer: Rename _xtimer_now() -> _lltimer_now()
This matches _lltimer_set() and _lltimer_mask()
8 years ago
Joakim Nohlgård d432bb42b0 xtimer: rename _mask -> _lltimer_mask 8 years ago
Joakim Nohlgård fb0322ee1b xtimer: Add spaces for readability 8 years ago
Joakim Nohlgård e8f33c2ca0 xtimer: Add parentheses to condition 8 years ago
Kaspar Schleiser 725473d9a6 sys: xtimer: make xtimer use div.h 8 years ago
Kaspar Schleiser c2f6417bea sys: xtimer: add another safeguard against setting a timer in the past 8 years ago
Joakim Nohlgård b365ab45cb sys/xtimer: Avoid race incrementing multiple periods in _timer_callback
On a fast CPU with a slow timer (e.g. XTIMER_SHIFT > 0) it is possible
that now == _xtimer_now() when spinning for the overflow. In the extreme
case When this happens _next_period() will be called more than once
until the timer overflows for real.

Fault observed in real life when running on a 32.768 kHz timer on a
~96 MHz clocked mulle (Kinetis K60, Cortex-M4). _next_period() was
called 9 times during the same ISR call before the 32 kHz timer
overflowed.
8 years ago
Joakim Nohlgård 983b299745 sys/xtimer: xtimer_set: Reduce scope on target variable 8 years ago
Joakim Nohlgård 7f254c6d12 sys/xtimer: rename _ms_to_sec -> _us_to_sec to reflect actual functionality
The function divides the argument by 1000000, (microsecond to seconds)
8 years ago
Joakim Nohlgård 75d0281ef3 xtimer-core: Use xtimer_now as reference time instead of future timer target 8 years ago
Oleg Hahm 38148c2d48 xtimer: initialize struct members
The xtimer_t struct members target and long_target are used in _is_set() function in xtimer_remove(), but will be uninitialized.
8 years ago
Kaspar Schleiser a719e7d61f sys: xtimer: some updates
- more robust underflow protection in xtimer_usleep_until()
- use relative target in xtimer_spin()
- honour reference in isr when spinning until timer target
- add XTIMER_BACKOFF to xtimer_spin_until() target when backing off in
  _timer_set_absolute()
- doxygen updates
8 years ago
Kaspar Schleiser 40812e722e sys: xtimer: use relative spin in absolute set functions 8 years ago
Kaspar Schleiser 48611c0572 sys: xtimer: avoid setting timers multiple times from within ISR 8 years ago
Kaspar Schleiser a0d78cf989 sys: xtimer: disable timer before shooting in isr handler 8 years ago
Kaspar Schleiser 691fe95546 sys: xtimer: use XTIMER_SHIFT in mask, add doxygen 8 years ago
Kaspar Schleiser cb0337d77e sys: xtimer: xtimer_set(): shoot directly if offset <= 1 8 years ago
Kaspar Schleiser e27ce2465f sys: xtimer: add xtimer_wakeup64 8 years ago
Kaspar Schleiser 383ada9349 sys: xtimer: always set long_target, even for short timers 8 years ago
Kaspar Schleiser 808a8bc899 sys: xtimer: introduce new timer subsystem 8 years ago