aboutsummaryrefslogtreecommitdiff
path: root/scripts/qapi
diff options
context:
space:
mode:
authorJonathan Cameron <Jonathan.Cameron@huawei.com>2025-07-03 11:41:07 +0100
committerPeter Maydell <peter.maydell@linaro.org>2025-07-08 20:27:09 +0100
commit584f722eb3ab4896ce9e3913c49f4f22e8b51f2b (patch)
tree468fdcedd07437e37d429c8925e89e95f0544d70 /scripts/qapi
parent35566583d86e167b617f0b55e485fc4ef1ae5dc3 (diff)
downloadqemu-584f722eb3ab4896ce9e3913c49f4f22e8b51f2b.zip
qemu-584f722eb3ab4896ce9e3913c49f4f22e8b51f2b.tar.gz
qemu-584f722eb3ab4896ce9e3913c49f4f22e8b51f2b.tar.bz2
hw/cxl: Make the CXL fixed memory windows devices.
Previously these somewhat device like structures were tracked using a list in the CXLState in each machine. This is proving restrictive in a few cases where we need to iterate through these without being aware of the machine type. Just make them sysbus devices. Restrict them to not user created as they need to be visible to early stages of machine init given effects on the memory map. This change both simplifies state tracking and enables features needed for performance optimization and hotness tracking by making it possible to retrieve the fixed memory window on actions elsewhere in the topology. In some cases the ordering of the Fixed Memory Windows matters. For those utility functions provide a GSList sorted by the window index. This ensures that we get consistency across: - ordering in the command line - ordering of the host PA ranges - ordering of ACPI CEDT structures describing the CFMWS. Other aspects don't have this constraint. For those direct iteration of the underlying hash structures is fine. In the setup path for the memory map in pc_memory_init() split the operations into two calls. The first, cxl_fmws_set_mmemap(), loops over fixed memory windows in order and assigns their addresses. The second, cxl_fmws_update_mmio() actually sets up the mmio for each window. This is obviously less efficient than a single loop but this split design is needed to put the logic in two different places in the arm64 support and it is not a hot enough path to justify an x86 only implementation. Reviewed-by: Li Zhijian <lizhijian@fujitsu.com> Tested-by: Li Zhijian <lizhijian@fujitsu.com> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Tested-by: Itaru Kitayama <itaru.kitayama@fujitsu.com> Message-id: 20250703104110.992379-3-Jonathan.Cameron@huawei.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'scripts/qapi')
0 files changed, 0 insertions, 0 deletions