[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL v2 54/58] acpi: fadt: add hw-reduced sleep register support
From: |
Michael S. Tsirkin |
Subject: |
[PULL v2 54/58] acpi: fadt: add hw-reduced sleep register support |
Date: |
Fri, 12 Jun 2020 10:53:00 -0400 |
From: Gerd Hoffmann <kraxel@redhat.com>
Add fields to struct AcpiFadtData and update build_fadt() to properly
generate sleep register entries.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Message-Id: <20200520132003.9492-9-kraxel@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
include/hw/acpi/acpi-defs.h | 2 ++
hw/acpi/aml-build.c | 4 ++--
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/include/hw/acpi/acpi-defs.h b/include/hw/acpi/acpi-defs.h
index c13327fa78..3be9ab5049 100644
--- a/include/hw/acpi/acpi-defs.h
+++ b/include/hw/acpi/acpi-defs.h
@@ -88,6 +88,8 @@ typedef struct AcpiFadtData {
struct AcpiGenericAddress pm_tmr; /* PM_TMR_BLK */
struct AcpiGenericAddress gpe0_blk; /* GPE0_BLK */
struct AcpiGenericAddress reset_reg; /* RESET_REG */
+ struct AcpiGenericAddress sleep_ctl; /* SLEEP_CONTROL_REG */
+ struct AcpiGenericAddress sleep_sts; /* SLEEP_STATUS_REG */
uint8_t reset_val; /* RESET_VALUE */
uint8_t rev; /* Revision */
uint32_t flags; /* Flags */
diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c
index d24e9e6c3a..2cb7b991ef 100644
--- a/hw/acpi/aml-build.c
+++ b/hw/acpi/aml-build.c
@@ -1866,9 +1866,9 @@ void build_fadt(GArray *tbl, BIOSLinker *linker, const
AcpiFadtData *f,
}
/* SLEEP_CONTROL_REG */
- build_append_gas(tbl, AML_AS_SYSTEM_MEMORY, 0 , 0, 0, 0);
+ build_append_gas_from_struct(tbl, &f->sleep_ctl);
/* SLEEP_STATUS_REG */
- build_append_gas(tbl, AML_AS_SYSTEM_MEMORY, 0 , 0, 0, 0);
+ build_append_gas_from_struct(tbl, &f->sleep_sts);
/* TODO: extra fields need to be added to support revisions above rev5 */
assert(f->rev == 5);
--
MST
- [PULL v2 42/58] Support ram slot configuration in libvhost-user, (continued)
- [PULL v2 42/58] Support ram slot configuration in libvhost-user, Michael S. Tsirkin, 2020/06/12
- [PULL v2 43/58] Support adding individual regions in libvhost-user, Michael S. Tsirkin, 2020/06/12
- [PULL v2 44/58] Support individual region unmap in libvhost-user, Michael S. Tsirkin, 2020/06/12
- [PULL v2 45/58] Lift max ram slots limit in libvhost-user, Michael S. Tsirkin, 2020/06/12
- [PULL v2 46/58] libvhost-user: advertise vring features, Michael S. Tsirkin, 2020/06/12
- [PULL v2 47/58] hw/pci: Fix crash when running QEMU with "-nic model=rocker", Michael S. Tsirkin, 2020/06/12
- [PULL v2 51/58] acpi: make build_madt() more generic., Michael S. Tsirkin, 2020/06/12
- [PULL v2 55/58] acpi: ged: rename event memory region, Michael S. Tsirkin, 2020/06/12
- [PULL v2 52/58] acpi: create acpi-common.c and move madt code, Michael S. Tsirkin, 2020/06/12
- [PULL v2 53/58] acpi: madt: skip pci override on pci-less systems., Michael S. Tsirkin, 2020/06/12
- [PULL v2 54/58] acpi: fadt: add hw-reduced sleep register support,
Michael S. Tsirkin <=
- [PULL v2 57/58] pci: Display PCI IRQ pin in "info pci", Michael S. Tsirkin, 2020/06/12
- [PULL v2 56/58] Fix parameter type in vhost migration log path, Michael S. Tsirkin, 2020/06/12
- [PULL v2 31/58] hw/pci/pci_bridge: Correct pci_bridge_io memory region size, Michael S. Tsirkin, 2020/06/12
- [PULL v2 05/58] qtest: allow DSDT acpi table changes, Michael S. Tsirkin, 2020/06/12
- [PULL v2 04/58] tests/acpi: update expected SRAT files, Michael S. Tsirkin, 2020/06/12
- [PULL v2 02/58] diffs-allowed: add the SRAT AML to diffs-allowed, Michael S. Tsirkin, 2020/06/12
- [PULL v2 18/58] tests/acpi: Add void tables for Q35/TPM-TIS bios-tables-test, Michael S. Tsirkin, 2020/06/12
- [PULL v2 25/58] virtio-balloon: Implement support for page poison reporting feature, Michael S. Tsirkin, 2020/06/12
- [PULL v2 14/58] acpi: Convert build_tpm2() to build_append* API, Michael S. Tsirkin, 2020/06/12
- [PULL v2 32/58] hw/pci/pci_bridge: Use the IEC binary prefix definitions, Michael S. Tsirkin, 2020/06/12