Skip to contentSkip to conversation

acpi: beginnings of piix acpi interface doc

PATCH In review Michael S. Tsirkin 2 participants 4 messages Mar 12, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 acpi: beginnings of piix acpi interface doc

Before we start tweaking and enhancing hardware, I think it makes sense to document what we currently have, to make sure we stay compatible.
This documents the hotplug interface for piix. Stubs for cpu hotplug, PM.

---
 docs/acpi.txt |   32 ++++++++++++++++++++++++++++++++
 1 files changed, 32 insertions(+), 0 deletions(-)
 create mode 100644 docs/acpi.txt
docs/acpi.txt new file +32 -0
new file mode 100644
index 0000000..4938d48
@@ -0,0 +1,32 @@
+QEMU exposes the following registers to guests,
+intended primarily for use by the ACPI interface.
+
+PCI Hotplug
+----
+
+Events use the standard GPE register:
+GPE  0xafe0 - an ACPI GPE register
+
+Hotplug events set GPE bit 1 (mask 0x2)
+
+The following registers are used for PCI hotplug.
+Each register is 32 bit (4 bytes) long, and has little endian format.
+Bits 0-31 in each register correspond to slots 0-31 on the root bus,
+respectively.
+
+UP   0xae00 - RO - Bit set by host on device insertion (note:existing implementations
+                   trigger device check event)
+DOWN 0xae04 - RO - Bit set by host on user eject request
+EJ0  0xae08 - WO - Bit set by guest removes all power to device
+RMV  0xae0c - RO - Bit set by host if slot supports hotplug
+                   (can not change while guest is up)
+
+
+Power management
+----
+TODO
+
+
+CPU hotplug
+----
+TODO
Signature · 1 line
1.7.9.111.gf3fb0
#1 lore raw
Quoted 6 lines · Michael S. Tsirkin

Before we start tweaking and enhancing hardware, I think it makes sense to document what we currently have, to make sure we stay compatible.
This documents the hotplug interface for piix. Stubs for cpu hotplug, PM.

We already have docs/specs/acpi_pci_hotplug.txt, no?

Quoted 46 lines
---
 docs/acpi.txt |   32 ++++++++++++++++++++++++++++++++
 1 files changed, 32 insertions(+), 0 deletions(-)
 create mode 100644 docs/acpi.txt
docs/acpi.txt new file +32 -0
new file mode 100644
index 0000000..4938d48
@@ -0,0 +1,32 @@
+QEMU exposes the following registers to guests,
+intended primarily for use by the ACPI interface.
+
+PCI Hotplug
+----
+
+Events use the standard GPE register:
+GPE  0xafe0 - an ACPI GPE register
+
+Hotplug events set GPE bit 1 (mask 0x2)
+
+The following registers are used for PCI hotplug.
+Each register is 32 bit (4 bytes) long, and has little endian format.
+Bits 0-31 in each register correspond to slots 0-31 on the root bus,
+respectively.
+
+UP   0xae00 - RO - Bit set by host on device insertion (note:existing implementations
+                   trigger device check event)
+DOWN 0xae04 - RO - Bit set by host on user eject request
+EJ0  0xae08 - WO - Bit set by guest removes all power to device
+RMV  0xae0c - RO - Bit set by host if slot supports hotplug
+                   (can not change while guest is up)
+
+
+Power management
+----
+TODO
+
+
+CPU hotplug
+----
+TODO
Signature · 1 line
1.7.9.111.gf3fb0

--
Gleb.

#2 lore raw
Quoted 8 lines · Gleb Natapov
Quoted 6 lines · Michael S. Tsirkin

Before we start tweaking and enhancing hardware, I think it makes sense to document what we currently have, to make sure we stay compatible.
This documents the hotplug interface for piix. Stubs for cpu hotplug, PM.

We already have docs/specs/acpi_pci_hotplug.txt, no?

Indeed. I didn't notice it.
Alex, so if you change this device you probably want to update the spec :)

Quoted 49 lines
Quoted 46 lines
---
 docs/acpi.txt |   32 ++++++++++++++++++++++++++++++++
 1 files changed, 32 insertions(+), 0 deletions(-)
 create mode 100644 docs/acpi.txt
docs/acpi.txt new file +32 -0
new file mode 100644
index 0000000..4938d48
@@ -0,0 +1,32 @@
+QEMU exposes the following registers to guests,
+intended primarily for use by the ACPI interface.
+
+PCI Hotplug
+----
+
+Events use the standard GPE register:
+GPE  0xafe0 - an ACPI GPE register
+
+Hotplug events set GPE bit 1 (mask 0x2)
+
+The following registers are used for PCI hotplug.
+Each register is 32 bit (4 bytes) long, and has little endian format.
+Bits 0-31 in each register correspond to slots 0-31 on the root bus,
+respectively.
+
+UP   0xae00 - RO - Bit set by host on device insertion (note:existing implementations
+                   trigger device check event)
+DOWN 0xae04 - RO - Bit set by host on user eject request
+EJ0  0xae08 - WO - Bit set by guest removes all power to device
+RMV  0xae0c - RO - Bit set by host if slot supports hotplug
+                   (can not change while guest is up)
+
+
+Power management
+----
+TODO
+
+
+CPU hotplug
+----
+TODO
Signature · 1 line
1.7.9.111.gf3fb0

--
Gleb.

#3 lore raw
Quoted 11 lines · Michael S. Tsirkin
Quoted 8 lines · Gleb Natapov
Quoted 6 lines · Michael S. Tsirkin

Before we start tweaking and enhancing hardware, I think it makes sense to document what we currently have, to make sure we stay compatible.
This documents the hotplug interface for piix. Stubs for cpu hotplug, PM.

We already have docs/specs/acpi_pci_hotplug.txt, no?

Indeed. I didn't notice it.

The commit that adds it has your SOB :)

--
Gleb.