qemu/hw/core
Peter Maydell f037f5b4b9 target/arm: Default to 1GHz cntfrq for 'max' and new CPUs
In previous versions of the Arm architecture, the frequency of the
generic timers as reported in CNTFRQ_EL0 could be any IMPDEF value,
and for QEMU we picked 62.5MHz, giving a timer tick period of 16ns.
In Armv8.6, the architecture standardized this frequency to 1GHz.

Because there is no ID register feature field that indicates whether
a CPU is v8.6 or that it ought to have this counter frequency, we
implement this by changing our default CNTFRQ value for all CPUs,
with exceptions for backwards compatibility:

 * CPU types which we already implement will retain the old
   default value. None of these are v8.6 CPUs, so this is
   architecturally OK.
 * CPUs used in versioned machine types with a version of 9.0
   or earlier will retain the old default value.

The upshot is that the only CPU type that changes is 'max'; but any
new type we add in future (whether v8.6 or not) will also get the new
1GHz default.

It remains the case that the machine model can override the default
value via the 'cntfrq' QOM property (regardless of the CPU type).

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-id: 20240426122913.3427983-5-peter.maydell@linaro.org
2024-04-30 15:14:15 +01:00
..
Kconfig hw/core: Only build guest-loader if libfdt is available 2021-03-17 07:17:46 +00:00
bus.c hw/core: Remove transitional infrastructure from BusClass 2024-02-02 13:51:57 +00:00
clock-vmstate.c hw/core: Constify VMState 2023-12-29 11:17:30 +11:00
clock.c hw/core/clock: allow clock_propagate on child clocks 2024-04-30 15:01:05 +01:00
cpu-common.c hw, target: Add ResetType argument to hold and exit phase methods 2024-04-25 10:21:06 +01:00
cpu-sysemu.c exec: Declare target_words_bigendian() in 'exec/tswap.h' 2024-04-26 17:03:05 +02:00
fw-path-provider.c
generic-loader.c exec: Declare target_words_bigendian() in 'exec/tswap.h' 2024-04-26 17:03:05 +02:00
gpio.c hw/qdev: Rename qdev_connect_gpio_out*() 'input_pin' parameter 2021-12-31 13:21:36 +01:00
guest-loader.c Mark remaining global TypeInfo instances as const 2022-02-21 13:30:20 +00:00
guest-loader.h hw/core: implement a guest-loader to support static hypervisor guests 2021-03-10 15:34:11 +00:00
hotplug.c
irq.c hw/irq: Declare QOM macros using OBJECT_DECLARE_SIMPLE_TYPE() 2023-02-27 13:27:05 +00:00
loader-fit.c hw/core/loader-fit: Fix missing ERRP_GUARD() for error_prepend() 2024-03-11 22:10:18 +01:00
loader.c hw/elf_ops: Rename elf_ops.h -> elf_ops.h.inc 2024-04-25 12:48:12 +02:00
machine-hmp-cmds.c hw/core: Introduce module-id as the topology subindex 2024-04-25 12:48:12 +02:00
machine-qmp-cmds.c qmp: add dump machine type compatibility properties 2024-04-25 10:12:40 +02:00
machine-smp.c hw/core/machine: Support modules in -smp 2024-04-25 12:48:12 +02:00
machine.c target/arm: Default to 1GHz cntfrq for 'max' and new CPUs 2024-04-30 15:14:15 +01:00
meson.build hw/core: Move system emulation files to system_ss 2024-04-18 11:17:27 +02:00
nmi.c hw/core: Improve error message when machine doesn't provide NMIs 2023-02-23 14:10:17 +01:00
null-machine.c Do not include sysemu/sysemu.h if it's not really necessary 2021-05-02 17:24:50 +02:00
numa.c virtio,pc,pci: features, cleanups, fixes 2024-03-13 15:11:53 +00:00
or-irq.c hw/core: Constify VMState 2023-12-29 11:17:30 +11:00
platform-bus.c nomaintainer: Fix Lesser GPL version number 2020-11-15 17:04:40 +01:00
ptimer.c hw/core: Constify VMState 2023-12-29 11:17:30 +11:00
qdev-clock.c Drop more useless casts from void * to pointer 2022-12-14 16:19:35 +01:00
qdev-fw.c
qdev-hotplug.c hw/core: Extract hotplug-related functions to qdev-hotplug.c 2021-11-01 19:44:11 +01:00
qdev-prop-internal.h qdev: Make qdev_propinfo_get_uint16() static 2020-12-15 10:02:07 -05:00
qdev-properties-system.c virtio,pc,pci: features, cleanups, fixes 2024-03-13 15:11:53 +00:00
qdev-properties.c qapi: Inline and remove QERR_PROPERTY_VALUE_BAD definition 2024-04-24 09:50:58 +02:00
qdev.c hw, target: Add ResetType argument to hold and exit phase methods 2024-04-25 10:21:06 +01:00
register.c hw/core/register: Add more 64-bit utilities 2021-09-01 11:59:12 +10:00
reset.c reset: Add RESET_TYPE_SNAPSHOT_LOAD 2024-04-25 10:21:59 +01:00
resetcontainer.c hw/core: Add ResetContainer which holds objects implementing Resettable 2024-02-27 13:01:42 +00:00
resettable.c reset: Add RESET_TYPE_SNAPSHOT_LOAD 2024-04-25 10:21:59 +01:00
split-irq.c
stream.c hw/core/stream: Rename StreamSlave as StreamSink 2020-12-10 12:15:04 -05:00
sysbus-fdt.c hw/core: Tidy up unnecessary casting away of const 2022-10-22 22:50:27 +02:00
sysbus.c hw/sysbus: Remove now unused sysbus_address_space() 2024-02-26 18:40:21 +01:00
trace-events trace-events: remove the remaining vcpu trace events 2023-06-01 11:05:05 -04:00
trace.h
uboot_image.h hw/core: Sync uboot_image.h from U-Boot v2022.01 2022-05-24 10:38:50 +10:00
vm-change-state-handler.c qdev: Add qdev_add_vm_change_state_handler_full() 2023-09-11 08:34:05 +02:00
vmstate-if.c