Two independent STM32F405 fixes with qtests on netduinoplus2.
Patch 1 fixes the stm32f2xx timer periodic mode: period ARR + 1
including ARR == 0, CNT wrap, CNT freeze/preset across CEN via a new
stopped_cnt (VMState v2), and reset cancelling a pending timer event.
Patch 2 mirrors RCC oscillator-ready and system-clock status
(HSERDY=HSEON, PLLRDY=PLLON, SWS=SW) as an instantaneous simplified
model.
USART IDLE line detection is intentionally excluded here and will
follow as a separate series once baud-derived timing, VMState and a
dynamic qtest are in place.
Manuele Conti (2):
hw/timer/stm32f2xx_timer: fix periodic mode, CNT wrap and CEN handling
hw/misc/stm32_rcc: mirror oscillator ready and system clock status
MAINTAINERS | 1 +
hw/misc/stm32_rcc.c | 18 ++++
hw/timer/stm32f2xx_timer.c | 101 ++++++++++++++++----
include/hw/timer/stm32f2xx_timer.h | 7 ++
tests/qtest/meson.build | 5 +
tests/qtest/stm32f405-rcc-test.c | 57 ++++++++++++
tests/qtest/stm32f405-timer-test.c | 142 +++++++++++++++++++++++++++++
7 files changed, 312 insertions(+), 19 deletions(-)
create mode 100644 tests/qtest/stm32f405-rcc-test.c
create mode 100644 tests/qtest/stm32f405-timer-test.c
--
2.41.0