diff options
author | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2019-11-23 07:23:40 +0200 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2020-06-06 09:23:45 +0000 |
commit | 2e270ae2974463c86711b400a7abcb36d1b2e67d (patch) | |
tree | 1f1615432d73a488a901c324d7512cb01c3a49a8 | |
parent | 9145ce2149a4e78e142e8074e601d45c3c2430e8 (diff) |
mb/emulation/qemu-q35: Control SMI related FADT entries
If running on older (like before 2.4.0) version of QEMU there is
no SMI support, so never advertise SMI in FADT for the emulation.
Behaviour if ACPI daemon tries to raise SMI under these conditions
is unknown.
Change-Id: I170058793798648c6713de1530d89ec2ac53e39a
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/41907
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
-rw-r--r-- | src/mainboard/emulation/qemu-q35/acpi_tables.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/mainboard/emulation/qemu-q35/acpi_tables.c b/src/mainboard/emulation/qemu-q35/acpi_tables.c index b9e76a93ed..423625711b 100644 --- a/src/mainboard/emulation/qemu-q35/acpi_tables.c +++ b/src/mainboard/emulation/qemu-q35/acpi_tables.c @@ -42,11 +42,13 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt) fadt->reserved = 0x00; fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9; - fadt->smi_cmd = 0; - fadt->acpi_enable = 0; - fadt->acpi_disable = 0; - fadt->s4bios_req = 0x0; - fadt->pstate_cnt = 0; + + if (CONFIG(HAVE_SMI_HANDLER)) { + /* Do not advertise SMI even if installed. */ + fadt->smi_cmd = 0; + fadt->acpi_enable = 0; + fadt->acpi_disable = 0; + } fadt->pm1a_evt_blk = pmbase; fadt->pm1b_evt_blk = 0x0; @@ -65,7 +67,6 @@ void acpi_create_fadt(acpi_fadt_t * fadt, acpi_facs_t * facs, void *dsdt) fadt->gpe0_blk_len = 16; fadt->gpe1_blk_len = 0; fadt->gpe1_base = 0; - fadt->cst_cnt = 0; fadt->p_lvl2_lat = 1; fadt->p_lvl3_lat = 0x39; fadt->flush_size = 0; |