aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/toolhead.py
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2017-02-14 22:15:51 -0500
committerKevin O'Connor <kevin@koconnor.net>2017-02-14 22:15:51 -0500
commitfec12030a9c63490ef357e71e2430133a64bbe34 (patch)
treeba7fb1db97b0709f5d5d6417f99b3f96bb14e24a /klippy/toolhead.py
parentbdfdf7ef55bca8e720eacdb479509fdd372cfcac (diff)
downloadkutter-fec12030a9c63490ef357e71e2430133a64bbe34.tar.gz
kutter-fec12030a9c63490ef357e71e2430133a64bbe34.tar.xz
kutter-fec12030a9c63490ef357e71e2430133a64bbe34.zip
sam3x8e/timer: Be careful of races in timer_set_next()
It's possible for sched_del_timer() to be called on a timer that fires just after sched_del_timer disables irqs but before the next timer is scheduled. In this case be sure to clear the irq pending status flag after scheduling the next timer so that a delayed irq doesn't cause the wrong timer to be run. For the same reason, make sure to check the irq pending status flag at the start of the timer irq. Also, as a safety check, make sure timer_set_next() isn't called from within the timer irq dispatch loop. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/toolhead.py')
0 files changed, 0 insertions, 0 deletions