From: Zhao Liu Date: Thu, 8 Jan 2026 03:30:30 +0000 (+0800) Subject: docs/specs/acpi_cpu_hotplug: Remove legacy cpu hotplug descriptions X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cd531feb36c84d5f596445eb0cd2a25296d6de1a;p=thirdparty%2Fqemu.git docs/specs/acpi_cpu_hotplug: Remove legacy cpu hotplug descriptions Legacy cpu hotplug has been removed totally and machines start with modern cpu hotplug interface directly. Therefore, update the documentation to describe current QEMU cpu hotplug logic. Reviewed-by: Igor Mammedov Signed-off-by: Zhao Liu Link: https://lore.kernel.org/r/20260108033051.777361-7-zhao1.liu@intel.com Signed-off-by: Paolo Bonzini --- diff --git a/docs/specs/acpi_cpu_hotplug.rst b/docs/specs/acpi_cpu_hotplug.rst index 351057c967..f496781000 100644 --- a/docs/specs/acpi_cpu_hotplug.rst +++ b/docs/specs/acpi_cpu_hotplug.rst @@ -8,22 +8,6 @@ ACPI BIOS GPE.2 handler is dedicated for notifying OS about CPU hot-add and hot-remove events. -Legacy ACPI CPU hotplug interface registers -------------------------------------------- - -CPU present bitmap for: - -- ICH9-LPC (IO port 0x0cd8-0xcf7, 1-byte access) -- PIIX-PM (IO port 0xaf00-0xaf1f, 1-byte access) -- One bit per CPU. Bit position reflects corresponding CPU APIC ID. Read-only. -- The first DWORD in bitmap is used in write mode to switch from legacy - to modern CPU hotplug interface, write 0 into it to do switch. - -QEMU sets corresponding CPU bit on hot-add event and issues SCI -with GPE.2 event set. CPU present map is read by ACPI BIOS GPE.2 handler -to notify OS about CPU hot-add events. CPU hot-remove isn't supported. - - Modern ACPI CPU hotplug interface registers ------------------------------------------- @@ -189,20 +173,14 @@ Typical usecases (x86) Detecting and enabling modern CPU hotplug interface ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -QEMU starts with legacy CPU hotplug interface enabled. Detecting and -switching to modern interface is based on the 2 legacy CPU hotplug features: - -#. Writes into CPU bitmap are ignored. -#. CPU bitmap always has bit #0 set, corresponding to boot CPU. - -Use following steps to detect and enable modern CPU hotplug interface: +QEMU starts with modern CPU hotplug interface enabled. Use following steps to +detect modern CPU hotplug interface: -#. Store 0x0 to the 'CPU selector' register, attempting to switch to modern mode #. Store 0x0 to the 'CPU selector' register, to ensure valid selector value #. Store 0x0 to the 'Command field' register #. Read the 'Command data 2' register. If read value is 0x0, the modern interface is enabled. - Otherwise legacy or no CPU hotplug interface available + Otherwise no CPU hotplug interface available Get a cpu with pending event ^^^^^^^^^^^^^^^^^^^^^^^^^^^^