diff --git a/os/rt/src/chschd.c b/os/rt/src/chschd.c index 322491ce7..540b1c296 100644 --- a/os/rt/src/chschd.c +++ b/os/rt/src/chschd.c @@ -582,7 +582,7 @@ void chSchDoReschedule(void) { #if CH_CFG_TIME_QUANTUM > 0 /* If CH_CFG_TIME_QUANTUM is enabled then there are two different scenarios to handle on preemption: time quantum elapsed or not.*/ - if (currp->ticks == (tslices_t)0) { + if (otp->ticks == (tslices_t)0) { /* The thread consumed its time quantum so it is enqueued behind threads with same priority level, however, it acquires a new time quantum.*/ diff --git a/readme.txt b/readme.txt index 4b58e96f2..cc41e540b 100644 --- a/readme.txt +++ b/readme.txt @@ -74,6 +74,8 @@ ***************************************************************************** *** 20.3.2 *** +- FIX: Schedule anomaly when CH_CFG_TIME_QUANTUM is greater than zero + (bug #1105). - FIX: Fixed Virtual Timers corner case (bug #1104). - FIX: Fixed GCC6 problem breaks Cortex-M0 port (bug #985). - FIX: Fixed a wrong management of the SPI TX buffer in the ADUCM port