Re: [PATCH v5 00/36] ACPI PCI Hotplug support on ARM
Hi Michael, On 7/7/25 7:53 PM, Michael S. Tsirkin wrote: > On Mon, Jul 07, 2025 at 07:09:34PM +0200, Eric Auger wrote: >> Hi, >> >> On 7/3/25 2:35 PM, Eric Auger wrote: >>> This series enables ACPI PCI hotplug/hotunplug on ARM. >>> It is not enabled by default and ACPI PCI hotplug can >>> be selected by setting: >>> >>> -global acpi-ged.acpi-pci-hotplug-with-bridge-support=on >>> >>> Expected benefits should be similar to those listed in [1], >>> ie. removal of some racy behaviors, improved latencies. >>> >>> The infrastructure used in x86 is heavily reused and a >>> huge part of the series consists in moving code from >>> hw/i386/acpi-build.c to a generic place and slightly >>> adapting it to make it usable on ARM. The DSDT table is >>> augmented to support ACPI PCI hotplug elements. >>> >>> On ARM we use use a GED event to notify the OS about >>> hotplug events. >> gentle ping on this series. I was hoping that this could target 10.1 but >> I ackowledge this is a big series to review and I am already very >> grateful to all reviewers. >> >> At least patches 1-15 have collected R-bs including Igor's ones. They >> can be seen as code move/reshuffle/cleanup and does not bring any >> functionality. I think patches 16-19 also belong to prerequisite and >> fixes and are easy to parse. >> So if we could at least have patches 1-19 merged in 10.1, this would >> alleviate the rebase efforts for next respins if any. >> >> Of course I have not totally lost all hopes to get this in in 10.1 ;-) >> and I will be able to diligently respin upon comments. >> >> Thanks >> >> Eric > > If no one objects, I can queue this. OK with ARM maintainers? > I think the only comment I have is shorter/cropped commit logs for the blobs, > that Jonathan already pointed out. > Want to respin doing that? Sure I will respin today with that change and grabbing latest R-bs from Jonathan. Thanks Eric > > >>> Best Regards >>> >>> Eric >>> >>> This series can be found at: >>> https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v5 >>> >>> previous series: >>> https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v4 >>> >>> History: >>> v4 -> v5: >>> - Collected Jonathan's R-bs (many thanks!) >>> - fixed the tests/qtest/bios-tables-test issue by >>> creating a variant for the viot test >>> - use the 3 phase reset API >>> - fixed qom-test failures that were due to unconditionnal >>> fetches of the GED property >>> >>> v3 -> v4: >>> - toook into account all comments on v3 >>> - static acpi-index is now supported unconditionally >>> from acpi pcihp option. See indiviual patches. >>> - I hit a problem with ref block generation at >>> [19/32] tests/qtest/bios-tables-test: Update ARM DSDT reference >>> blobs: despite I regenerate the blobs, I get some errors. >>> >>> v2 -> v3: >>> - lot of changes taking into account various feedbacks >>> (many thanks to all reviewers). Please refer to >>> individual patches for details. Main changes: >>> - no more machine option, acpi pci hp is not set by >>> default. >>> - removal of 2 unused variables in the osc method >>> - introduction of GED property to set the bus >>> - rework of the init/reset sequence >>> - fix virtio-mem-pci hotplug regression >>> >>> v1 -> v2: >>> - collected a bunch of R-bs from Gustavo (many thanks!) >>> - Fixed the breakage of bios-tables-test in TCG mode by >>> incorporating Gustavo's patches (part of >>> [PATCH 0/5] ACPI tests for PCI Hotplug on ARM >>> >>> https://lore.kernel.org/all/[email protected]/) >>> - Tweeked the dsdt aml changes to avoid any dsdt blob difference when >>> acpi-pcihp is off. >>> >>> RFC -> v1: >>> - First 3 trivial patches were pulled separately >>> - Fix of the register region size (0x18), ie. ACPI_PCIHP_SIZE >>> - addition of aml_pci_edsm which was not called in RFC >>> - acpi-index feature is now fixed. vms->bus was not set on >>> acpi_pcihp_init. The init sequence is still hacky though. Suggestions >>> are welcome. >>> >>> [1] [PATCH v6 0/6] Use ACPI PCI hot-plug for Q35 >>> https://lore.kernel.org/all/[email protected]/ >>> >>> >>> Eric Auger (32): >>> hw/i386/acpi-build: Make aml_pci_device_dsm() static >>> hw/acpi: Rename and move build_x86_acpi_pci_hotplug to pcihp >>> hw/pci-host/gpex-acpi: Add native_pci_hotplug arg to >>> acpi_dsdt_add_pci_osc >>> hw/pci-host/gpex-acpi: Split host bridge OSC and DSM generation >>> hw/acpi/ged: Add a acpi-pci-hotplug-with-bridge-support property >>> hw/pci-host/gpex-acpi: Use GED acpi pcihp property >>> hw/i386/acpi-build: Turn build_q35_osc_method into a generic method >>> hw/pci-host/gpex-acpi: Use build_pci_host_bridge_osc_method >>> tests/qtest/bios-tables-test: Update DSDT blobs after GPEX _OSC change >>> hw/i386/acpi-build: Introduce build_append_pcihp_resources() helper >>> hw/acpi/pcihp: Add an AmlRegionSpace arg to build_acpi_pci_hotplug >>> hw/i386/acpi-build: Move
Re: [PATCH v5 00/36] ACPI PCI Hotplug support on ARM
On Mon, 7 Jul 2025 at 18:53, Michael S. Tsirkin wrote: > > On Mon, Jul 07, 2025 at 07:09:34PM +0200, Eric Auger wrote: > > Hi, > > > > On 7/3/25 2:35 PM, Eric Auger wrote: > > > This series enables ACPI PCI hotplug/hotunplug on ARM. > > > It is not enabled by default and ACPI PCI hotplug can > > > be selected by setting: > > > > > > -global acpi-ged.acpi-pci-hotplug-with-bridge-support=on > > > > > > Expected benefits should be similar to those listed in [1], > > > ie. removal of some racy behaviors, improved latencies. > > > > > > The infrastructure used in x86 is heavily reused and a > > > huge part of the series consists in moving code from > > > hw/i386/acpi-build.c to a generic place and slightly > > > adapting it to make it usable on ARM. The DSDT table is > > > augmented to support ACPI PCI hotplug elements. > > > > > > On ARM we use use a GED event to notify the OS about > > > hotplug events. > > > > gentle ping on this series. I was hoping that this could target 10.1 but > > I ackowledge this is a big series to review and I am already very > > grateful to all reviewers. > > > > At least patches 1-15 have collected R-bs including Igor's ones. They > > can be seen as code move/reshuffle/cleanup and does not bring any > > functionality. I think patches 16-19 also belong to prerequisite and > > fixes and are easy to parse. > > So if we could at least have patches 1-19 merged in 10.1, this would > > alleviate the rebase efforts for next respins if any. > > > > Of course I have not totally lost all hopes to get this in in 10.1 ;-) > > and I will be able to diligently respin upon comments. > If no one objects, I can queue this. OK with ARM maintainers? Judging by the diffstat this doesn't really touch the arm stuff specifically, so if reviewers who are familiar with hotplug and ACPI are happy that this is the correct way to do PCI hotplug for Arm and have reviewed it then I'm fine with going via the ACPI tree for whatever subset of patches you think are ready to go in. thanks -- PMM
Re: [PATCH v5 00/36] ACPI PCI Hotplug support on ARM
On Mon, Jul 07, 2025 at 07:09:34PM +0200, Eric Auger wrote: > Hi, > > On 7/3/25 2:35 PM, Eric Auger wrote: > > This series enables ACPI PCI hotplug/hotunplug on ARM. > > It is not enabled by default and ACPI PCI hotplug can > > be selected by setting: > > > > -global acpi-ged.acpi-pci-hotplug-with-bridge-support=on > > > > Expected benefits should be similar to those listed in [1], > > ie. removal of some racy behaviors, improved latencies. > > > > The infrastructure used in x86 is heavily reused and a > > huge part of the series consists in moving code from > > hw/i386/acpi-build.c to a generic place and slightly > > adapting it to make it usable on ARM. The DSDT table is > > augmented to support ACPI PCI hotplug elements. > > > > On ARM we use use a GED event to notify the OS about > > hotplug events. > > gentle ping on this series. I was hoping that this could target 10.1 but > I ackowledge this is a big series to review and I am already very > grateful to all reviewers. > > At least patches 1-15 have collected R-bs including Igor's ones. They > can be seen as code move/reshuffle/cleanup and does not bring any > functionality. I think patches 16-19 also belong to prerequisite and > fixes and are easy to parse. > So if we could at least have patches 1-19 merged in 10.1, this would > alleviate the rebase efforts for next respins if any. > > Of course I have not totally lost all hopes to get this in in 10.1 ;-) > and I will be able to diligently respin upon comments. > > Thanks > > Eric If no one objects, I can queue this. OK with ARM maintainers? I think the only comment I have is shorter/cropped commit logs for the blobs, that Jonathan already pointed out. Want to respin doing that? > > > > Best Regards > > > > Eric > > > > This series can be found at: > > https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v5 > > > > previous series: > > https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v4 > > > > History: > > v4 -> v5: > > - Collected Jonathan's R-bs (many thanks!) > > - fixed the tests/qtest/bios-tables-test issue by > > creating a variant for the viot test > > - use the 3 phase reset API > > - fixed qom-test failures that were due to unconditionnal > > fetches of the GED property > > > > v3 -> v4: > > - toook into account all comments on v3 > > - static acpi-index is now supported unconditionally > > from acpi pcihp option. See indiviual patches. > > - I hit a problem with ref block generation at > > [19/32] tests/qtest/bios-tables-test: Update ARM DSDT reference > > blobs: despite I regenerate the blobs, I get some errors. > > > > v2 -> v3: > > - lot of changes taking into account various feedbacks > > (many thanks to all reviewers). Please refer to > > individual patches for details. Main changes: > > - no more machine option, acpi pci hp is not set by > > default. > > - removal of 2 unused variables in the osc method > > - introduction of GED property to set the bus > > - rework of the init/reset sequence > > - fix virtio-mem-pci hotplug regression > > > > v1 -> v2: > > - collected a bunch of R-bs from Gustavo (many thanks!) > > - Fixed the breakage of bios-tables-test in TCG mode by > > incorporating Gustavo's patches (part of > > [PATCH 0/5] ACPI tests for PCI Hotplug on ARM > > > > https://lore.kernel.org/all/[email protected]/) > > - Tweeked the dsdt aml changes to avoid any dsdt blob difference when > > acpi-pcihp is off. > > > > RFC -> v1: > > - First 3 trivial patches were pulled separately > > - Fix of the register region size (0x18), ie. ACPI_PCIHP_SIZE > > - addition of aml_pci_edsm which was not called in RFC > > - acpi-index feature is now fixed. vms->bus was not set on > > acpi_pcihp_init. The init sequence is still hacky though. Suggestions > > are welcome. > > > > [1] [PATCH v6 0/6] Use ACPI PCI hot-plug for Q35 > > https://lore.kernel.org/all/[email protected]/ > > > > > > Eric Auger (32): > > hw/i386/acpi-build: Make aml_pci_device_dsm() static > > hw/acpi: Rename and move build_x86_acpi_pci_hotplug to pcihp > > hw/pci-host/gpex-acpi: Add native_pci_hotplug arg to > > acpi_dsdt_add_pci_osc > > hw/pci-host/gpex-acpi: Split host bridge OSC and DSM generation > > hw/acpi/ged: Add a acpi-pci-hotplug-with-bridge-support property > > hw/pci-host/gpex-acpi: Use GED acpi pcihp property > > hw/i386/acpi-build: Turn build_q35_osc_method into a generic method > > hw/pci-host/gpex-acpi: Use build_pci_host_bridge_osc_method > > tests/qtest/bios-tables-test: Update DSDT blobs after GPEX _OSC change > > hw/i386/acpi-build: Introduce build_append_pcihp_resources() helper > > hw/acpi/pcihp: Add an AmlRegionSpace arg to build_acpi_pci_hotplug > > hw/i386/acpi-build: Move build_append_notification_callback to pcihp > > hw/i386/acpi-build: Move build_append_pci_bus_devices/pcihp_slots to > > pcihp > > hw/i386/acpi-build: Use AcpiPciHpState::root in
Re: [PATCH v5 00/36] ACPI PCI Hotplug support on ARM
Hi, On 7/3/25 2:35 PM, Eric Auger wrote: > This series enables ACPI PCI hotplug/hotunplug on ARM. > It is not enabled by default and ACPI PCI hotplug can > be selected by setting: > > -global acpi-ged.acpi-pci-hotplug-with-bridge-support=on > > Expected benefits should be similar to those listed in [1], > ie. removal of some racy behaviors, improved latencies. > > The infrastructure used in x86 is heavily reused and a > huge part of the series consists in moving code from > hw/i386/acpi-build.c to a generic place and slightly > adapting it to make it usable on ARM. The DSDT table is > augmented to support ACPI PCI hotplug elements. > > On ARM we use use a GED event to notify the OS about > hotplug events. gentle ping on this series. I was hoping that this could target 10.1 but I ackowledge this is a big series to review and I am already very grateful to all reviewers. At least patches 1-15 have collected R-bs including Igor's ones. They can be seen as code move/reshuffle/cleanup and does not bring any functionality. I think patches 16-19 also belong to prerequisite and fixes and are easy to parse. So if we could at least have patches 1-19 merged in 10.1, this would alleviate the rebase efforts for next respins if any. Of course I have not totally lost all hopes to get this in in 10.1 ;-) and I will be able to diligently respin upon comments. Thanks Eric > > Best Regards > > Eric > > This series can be found at: > https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v5 > > previous series: > https://github.com/eauger/qemu/tree/arm-acpi-pcihp-v4 > > History: > v4 -> v5: > - Collected Jonathan's R-bs (many thanks!) > - fixed the tests/qtest/bios-tables-test issue by > creating a variant for the viot test > - use the 3 phase reset API > - fixed qom-test failures that were due to unconditionnal > fetches of the GED property > > v3 -> v4: > - toook into account all comments on v3 > - static acpi-index is now supported unconditionally > from acpi pcihp option. See indiviual patches. > - I hit a problem with ref block generation at > [19/32] tests/qtest/bios-tables-test: Update ARM DSDT reference > blobs: despite I regenerate the blobs, I get some errors. > > v2 -> v3: > - lot of changes taking into account various feedbacks > (many thanks to all reviewers). Please refer to > individual patches for details. Main changes: > - no more machine option, acpi pci hp is not set by > default. > - removal of 2 unused variables in the osc method > - introduction of GED property to set the bus > - rework of the init/reset sequence > - fix virtio-mem-pci hotplug regression > > v1 -> v2: > - collected a bunch of R-bs from Gustavo (many thanks!) > - Fixed the breakage of bios-tables-test in TCG mode by > incorporating Gustavo's patches (part of > [PATCH 0/5] ACPI tests for PCI Hotplug on ARM > > https://lore.kernel.org/all/[email protected]/) > - Tweeked the dsdt aml changes to avoid any dsdt blob difference when > acpi-pcihp is off. > > RFC -> v1: > - First 3 trivial patches were pulled separately > - Fix of the register region size (0x18), ie. ACPI_PCIHP_SIZE > - addition of aml_pci_edsm which was not called in RFC > - acpi-index feature is now fixed. vms->bus was not set on > acpi_pcihp_init. The init sequence is still hacky though. Suggestions > are welcome. > > [1] [PATCH v6 0/6] Use ACPI PCI hot-plug for Q35 > https://lore.kernel.org/all/[email protected]/ > > > Eric Auger (32): > hw/i386/acpi-build: Make aml_pci_device_dsm() static > hw/acpi: Rename and move build_x86_acpi_pci_hotplug to pcihp > hw/pci-host/gpex-acpi: Add native_pci_hotplug arg to > acpi_dsdt_add_pci_osc > hw/pci-host/gpex-acpi: Split host bridge OSC and DSM generation > hw/acpi/ged: Add a acpi-pci-hotplug-with-bridge-support property > hw/pci-host/gpex-acpi: Use GED acpi pcihp property > hw/i386/acpi-build: Turn build_q35_osc_method into a generic method > hw/pci-host/gpex-acpi: Use build_pci_host_bridge_osc_method > tests/qtest/bios-tables-test: Update DSDT blobs after GPEX _OSC change > hw/i386/acpi-build: Introduce build_append_pcihp_resources() helper > hw/acpi/pcihp: Add an AmlRegionSpace arg to build_acpi_pci_hotplug > hw/i386/acpi-build: Move build_append_notification_callback to pcihp > hw/i386/acpi-build: Move build_append_pci_bus_devices/pcihp_slots to > pcihp > hw/i386/acpi-build: Use AcpiPciHpState::root in acpi_set_pci_info > hw/i386/acpi-build: Move aml_pci_edsm to a generic place > qtest/bios-tables-test: Prepare for fixing the aarch64 viot test > qtest/bios-tables-test: Add a variant to the aarch64 viot test > qtest/bios-tables-test: Generate DSDT.viot > hw/arm/virt-acpi-build: Let non hotplug ports support static > acpi-index > tests/qtest/bios-tables-test: Update ARM DSDT reference blobs > hw/arm/virt-acpi-build: Modify the DSDT ACPI table to enable ACPI PCI > hotplug >
