qemu-patch-raspberry4/include
Peter Maydell 32bd322a01 hw/timer/armv7m_systick: Rewrite to use ptimers
The armv7m systick timer is a 24-bit decrementing, wrap-on-zero,
clear-on-write counter. Our current implementation has various
bugs and dubious workarounds in it (for instance see
https://bugs.launchpad.net/qemu/+bug/1872237).

We have an implementation of a simple decrementing counter
and we put a lot of effort into making sure it handles the
interesting corner cases (like "spend a cycle at 0 before
reloading") -- ptimer.

Rewrite the systick timer to use a ptimer rather than
a raw QEMU timer.

Unfortunately this is a migration compatibility break,
which will affect all M-profile boards.

Among other bugs, this fixes
https://bugs.launchpad.net/qemu/+bug/1872237 :
now writes to SYST_CVR when the timer is enabled correctly
do nothing; when the timer is enabled via SYST_CSR.ENABLE,
the ptimer code will (because of POLICY_NO_IMMEDIATE_RELOAD)
arrange that after one timer tick the counter is reloaded
from SYST_RVR and then counts down from there, as the
architecture requires.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 20201015151829.14656-3-peter.maydell@linaro.org
2020-10-27 11:15:31 +00:00
..
authz qom: Remove module_obj_name parameter from OBJECT_DECLARE* macros 2020-09-18 14:12:32 -04:00
block block: Add bdrv_lock()/unlock() 2020-10-09 07:08:20 +02:00
chardev chardev/spice: simplify chardev setup 2020-10-15 11:14:40 +02:00
crypto qom: Remove module_obj_name parameter from OBJECT_DECLARE* macros 2020-09-18 14:12:32 -04:00
disas disas: Split out capstone code to disas/capstone.c 2020-10-03 04:25:14 -05:00
exec linux-user: Set PAGE_TARGET_1 for TARGET_PROT_BTI 2020-10-27 10:44:02 +00:00
fpu softfloat: Define comparison operations for bfloat16 2020-08-29 19:25:42 -07:00
hw hw/timer/armv7m_systick: Rewrite to use ptimers 2020-10-27 11:15:31 +00:00
io Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
libdecnumber include: Make headers more self-contained 2019-08-16 13:31:51 +02:00
migration migration/colo: Use ram_block_discard_disable() 2020-07-02 05:54:59 -04:00
monitor monitor: Make current monitor a per-coroutine property 2020-10-09 07:08:19 +02:00
net qom: fix objects with improper parent type 2020-10-12 11:50:22 -04:00
qapi qmp: Move dispatcher to a coroutine 2020-10-09 07:08:20 +02:00
qemu util/vhost-user-server: move header to include/ 2020-10-23 13:42:16 +01:00
qom qom: Add user_creatable_print_help_from_qdict() 2020-10-15 16:06:27 +02:00
scsi scsi-generic: Fix HM-zoned device scan 2020-09-30 19:09:20 +02:00
standard-headers linux headers: sync to 5.9-rc4 2020-09-29 02:14:29 -04:00
sysemu accel: move qtest CpusAccel functions to a common location 2020-10-24 07:23:19 +02:00
tcg tcg: Remove TCGOpDef.used 2020-10-08 05:57:32 -05:00
ui spice: wire up monitor in QemuSpiceOps. 2020-10-21 15:46:14 +02:00
user trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00
elf.h include/elf: Add defines related to GNU property notes for AArch64 2020-10-27 10:44:02 +00:00
glib-compat.h glib: bump min required glib library version to 2.48 2019-08-22 10:46:34 +01:00
qemu-common.h vl: relocate paths to data directories 2020-09-30 19:11:36 +02:00
qemu-io.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
trace-tcg.h trace: get rid of generated-events.h/generated-events.c 2016-10-12 09:54:52 +02:00