System: Do not return values in the past from GetHighResTimerValue. If an interrupt would occur between reading the timer LSB and MSB, it could result in incorrect results. E.g. when the timer is 1FFH before the interrupt and it is 280H after, the value returned would be 180H and time would run backwards. With this fix, if the MSB between two reads differs, it always returns 0 as the LSB which must have been true somewhere between the MSB reads.
1 files changed, 3 insertions(+), 2 deletions(-) M src/System.asm
M src/System.asm +3 -2