Kyösti Mälkki has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/cimx/sb800/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801ix/i82801ix.c M src/southbridge/intel/i82801jx/i82801jx.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 26 files changed, 36 insertions(+), 31 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/41910/1
diff --git a/src/include/acpi/acpi.h b/src/include/acpi/acpi.h index ea80e3b..544e2c5 100644 --- a/src/include/acpi/acpi.h +++ b/src/include/acpi/acpi.h @@ -1011,6 +1011,11 @@ /* Read and clear GPE status */ int acpi_get_gpe(int gpe);
+static inline int permanent_smi_handler(void) +{ + return CONFIG(HAVE_SMI_HANDLER); +} + static inline int acpi_s3_resume_allowed(void) { return CONFIG(HAVE_ACPI_RESUME); diff --git a/src/mainboard/aopen/dxplplusu/fadt.c b/src/mainboard/aopen/dxplplusu/fadt.c index 339c243..ad522c4 100644 --- a/src/mainboard/aopen/dxplplusu/fadt.c +++ b/src/mainboard/aopen/dxplplusu/fadt.c @@ -38,7 +38,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = ACPI_ENABLE; fadt->acpi_disable = ACPI_DISABLE; diff --git a/src/mainboard/emulation/qemu-q35/acpi_tables.c b/src/mainboard/emulation/qemu-q35/acpi_tables.c index 4236257..9bf58a6 100644 --- a/src/mainboard/emulation/qemu-q35/acpi_tables.c +++ b/src/mainboard/emulation/qemu-q35/acpi_tables.c @@ -43,7 +43,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { /* Do not advertise SMI even if installed. */ fadt->smi_cmd = 0; fadt->acpi_enable = 0; diff --git a/src/mainboard/lenovo/t400/fadt.c b/src/mainboard/lenovo/t400/fadt.c index d15b9b3..257fb41 100644 --- a/src/mainboard/lenovo/t400/fadt.c +++ b/src/mainboard/lenovo/t400/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/mainboard/lenovo/x200/fadt.c b/src/mainboard/lenovo/x200/fadt.c index d15b9b3..257fb41 100644 --- a/src/mainboard/lenovo/x200/fadt.c +++ b/src/mainboard/lenovo/x200/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/mainboard/roda/rk9/fadt.c b/src/mainboard/roda/rk9/fadt.c index 102865d..5127545 100644 --- a/src/mainboard/roda/rk9/fadt.c +++ b/src/mainboard/roda/rk9/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/amd/picasso/acpi.c b/src/soc/amd/picasso/acpi.c index d5a890b..817ec51 100644 --- a/src/soc/amd/picasso/acpi.c +++ b/src/soc/amd/picasso/acpi.c @@ -107,7 +107,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/amd/stoneyridge/acpi.c b/src/soc/amd/stoneyridge/acpi.c index 47d12bf..a7caa93 100644 --- a/src/soc/amd/stoneyridge/acpi.c +++ b/src/soc/amd/stoneyridge/acpi.c @@ -79,7 +79,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/baytrail/acpi.c b/src/soc/intel/baytrail/acpi.c index 66263e6..f9eb500 100644 --- a/src/soc/intel/baytrail/acpi.c +++ b/src/soc/intel/baytrail/acpi.c @@ -129,7 +129,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/braswell/acpi.c b/src/soc/intel/braswell/acpi.c index 4e3795e..e6790a7 100644 --- a/src/soc/intel/braswell/acpi.c +++ b/src/soc/intel/braswell/acpi.c @@ -133,7 +133,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/broadwell/acpi.c b/src/soc/intel/broadwell/acpi.c index 9df7dee..081b08a 100644 --- a/src/soc/intel/broadwell/acpi.c +++ b/src/soc/intel/broadwell/acpi.c @@ -185,7 +185,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/common/block/acpi/acpi.c b/src/soc/intel/common/block/acpi/acpi.c index c4a0698..bda2399 100644 --- a/src/soc/intel/common/block/acpi/acpi.c +++ b/src/soc/intel/common/block/acpi/acpi.c @@ -101,7 +101,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/skylake/acpi.c b/src/soc/intel/skylake/acpi.c index 34aed02..bdfacd3 100644 --- a/src/soc/intel/skylake/acpi.c +++ b/src/soc/intel/skylake/acpi.c @@ -226,7 +226,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/xeon_sp/cpx/acpi.c b/src/soc/intel/xeon_sp/cpx/acpi.c index d6d847b..b090d12 100644 --- a/src/soc/intel/xeon_sp/cpx/acpi.c +++ b/src/soc/intel/xeon_sp/cpx/acpi.c @@ -148,7 +148,7 @@
fadt->x_gpe1_blk.space_id = 1;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/xeon_sp/skx/acpi.c b/src/soc/intel/xeon_sp/skx/acpi.c index 9818508..374275b 100644 --- a/src/soc/intel/xeon_sp/skx/acpi.c +++ b/src/soc/intel/xeon_sp/skx/acpi.c @@ -339,7 +339,7 @@ fadt->sci_int = acpi_sci_irq();
/* TODO: enabled SMM mode switch when SMM handlers are set up. */ - if (0 && CONFIG(HAVE_SMI_HANDLER)) { + if (0 && permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/amd/agesa/hudson/fadt.c b/src/southbridge/amd/agesa/hudson/fadt.c index 660598a..a328a88 100644 --- a/src/southbridge/amd/agesa/hudson/fadt.c +++ b/src/southbridge/amd/agesa/hudson/fadt.c @@ -57,7 +57,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* HUDSON - IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/amd/cimx/sb800/fadt.c b/src/southbridge/amd/cimx/sb800/fadt.c index e836cfb..bd0ec9c 100644 --- a/src/southbridge/amd/cimx/sb800/fadt.c +++ b/src/southbridge/amd/cimx/sb800/fadt.c @@ -62,7 +62,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* HUDSON 1 - IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/amd/pi/hudson/fadt.c b/src/southbridge/amd/pi/hudson/fadt.c index 100cfb6..686b669 100644 --- a/src/southbridge/amd/pi/hudson/fadt.c +++ b/src/southbridge/amd/pi/hudson/fadt.c @@ -49,7 +49,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* HUDSON - IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/intel/bd82x6x/lpc.c b/src/southbridge/intel/bd82x6x/lpc.c index 45215f1..d939429 100644 --- a/src/southbridge/intel/bd82x6x/lpc.c +++ b/src/southbridge/intel/bd82x6x/lpc.c @@ -698,7 +698,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; @@ -836,7 +836,7 @@ spi_finalize_ops();
/* Call SMM finalize() handlers before resume */ - if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { if (CONFIG(INTEL_CHIPSET_LOCKDOWN) || acpi_is_wakeup_s3()) { outb(APM_CNT_FINALIZE, APM_CNT); diff --git a/src/southbridge/intel/i82371eb/fadt.c b/src/southbridge/intel/i82371eb/fadt.c index 26a1856..583a9ed 100644 --- a/src/southbridge/intel/i82371eb/fadt.c +++ b/src/southbridge/intel/i82371eb/fadt.c @@ -36,7 +36,7 @@ fadt->preferred_pm_profile = 0; /* unspecified */ fadt->sci_int = 9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/intel/i82801gx/lpc.c b/src/southbridge/intel/i82801gx/lpc.c index 86c3e58..d4aef55 100644 --- a/src/southbridge/intel/i82801gx/lpc.c +++ b/src/southbridge/intel/i82801gx/lpc.c @@ -522,7 +522,7 @@ fadt->reserved = 0; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/i82801ix/i82801ix.c b/src/southbridge/intel/i82801ix/i82801ix.c index b2b55ce..5e5e667 100644 --- a/src/southbridge/intel/i82801ix/i82801ix.c +++ b/src/southbridge/intel/i82801ix/i82801ix.c @@ -204,9 +204,9 @@ i82801ix_hide_functions();
/* Reset watchdog timer. */ -#if !CONFIG(HAVE_SMI_HANDLER) - outw(0x0008, DEFAULT_TCOBASE + 0x12); /* Set higher timer value. */ -#endif + if (!permanent_smi_handler()) + outw(0x0008, DEFAULT_TCOBASE + 0x12); /* Set higher timer value. */ + outw(0x0000, DEFAULT_TCOBASE + 0x00); /* Update timer. */ }
diff --git a/src/southbridge/intel/i82801jx/i82801jx.c b/src/southbridge/intel/i82801jx/i82801jx.c index b4ffcfa..7c6371b 100644 --- a/src/southbridge/intel/i82801jx/i82801jx.c +++ b/src/southbridge/intel/i82801jx/i82801jx.c @@ -203,9 +203,9 @@ i82801jx_hide_functions();
/* Reset watchdog timer. */ -#if !CONFIG(HAVE_SMI_HANDLER) - outw(0x0008, DEFAULT_TCOBASE + 0x12); /* Set higher timer value. */ -#endif + if (!permanent_smi_handler()) + outw(0x0008, DEFAULT_TCOBASE + 0x12); /* Set higher timer value. */ + outw(0x0000, DEFAULT_TCOBASE + 0x00); /* Update timer. */ }
diff --git a/src/southbridge/intel/i82801jx/lpc.c b/src/southbridge/intel/i82801jx/lpc.c index b3aeda2..7a1b24b 100644 --- a/src/southbridge/intel/i82801jx/lpc.c +++ b/src/southbridge/intel/i82801jx/lpc.c @@ -533,7 +533,7 @@ fadt->reserved = 0; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/ibexpeak/lpc.c b/src/southbridge/intel/ibexpeak/lpc.c index 1209f9b..c64f6b4 100644 --- a/src/southbridge/intel/ibexpeak/lpc.c +++ b/src/southbridge/intel/ibexpeak/lpc.c @@ -592,7 +592,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; @@ -729,7 +729,7 @@ spi_finalize_ops();
/* Call SMM finalize() handlers before resume */ - if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { if (CONFIG(INTEL_CHIPSET_LOCKDOWN) || acpi_is_wakeup_s3()) { outb(APM_CNT_FINALIZE, APM_CNT); diff --git a/src/southbridge/intel/lynxpoint/lpc.c b/src/southbridge/intel/lynxpoint/lpc.c index da744bf..1d75555 100644 --- a/src/southbridge/intel/lynxpoint/lpc.c +++ b/src/southbridge/intel/lynxpoint/lpc.c @@ -741,7 +741,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE;
Hello build bot (Jenkins), Alexander Couzens, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/41910
to look at the new patch set (#2).
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/cimx/sb800/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801ix/i82801ix.c M src/southbridge/intel/i82801jx/i82801jx.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 26 files changed, 36 insertions(+), 31 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/41910/2
Hello build bot (Jenkins), Alexander Couzens, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/41910
to look at the new patch set (#3).
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/cimx/sb800/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801ix/i82801ix.c M src/southbridge/intel/i82801jx/i82801jx.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 26 files changed, 36 insertions(+), 31 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/41910/3
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 3:
(1 comment)
Some hunks are not about the FADT advertisement. Which makes it hard to assess which cases of `if(CONFIG(HAVE_SMI_HANDLER))` should be updated with this patch and which shouldn't. For instance, there are several instances that were not updated in amd chipset code that configure the APM_CNT port. Will they be updated later? Do they need an update at all?
https://review.coreboot.org/c/coreboot/+/41910/3/src/include/acpi/acpi.h File src/include/acpi/acpi.h:
https://review.coreboot.org/c/coreboot/+/41910/3/src/include/acpi/acpi.h@101... PS3, Line 1014: static inline int permanent_smi_handler(void) A comment would be nice, what defines a "permanent" handler.
Hello build bot (Jenkins), Nico Huber, Alexander Couzens, Aaron Durbin, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/41910
to look at the new patch set (#4).
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed. There has been some experiments to delay SMM installation to OS, yet there are new platforms that allow some configuration access only to be done inside SMM.
Splitting static HAVE_SMI_HANDLER variable helps to manage cases where SMM might be both installed and cleared prior to entering payload.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801ix/i82801ix.c M src/southbridge/intel/i82801jx/i82801jx.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 25 files changed, 37 insertions(+), 30 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/41910/4
Kyösti Mälkki has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 4:
(4 comments)
Patch Set 3:
(1 comment)
Some hunks are not about the FADT advertisement. Which makes it hard to assess which cases of `if(CONFIG(HAVE_SMI_HANDLER))` should be updated with this patch and which shouldn't. For instance, there are several instances that were not updated in amd chipset code that configure the APM_CNT port. Will they be updated later? Do they need an update at all?
Thanks, there are indeed some hunks here I am not so sure about. I will make this change only touch FADT advertisement, maybe move to CB:36828 for further discussion?
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/bd82x... File src/southbridge/intel/bd82x6x/lpc.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/bd82x... PS4, Line 839: if (permanent_smi_handler()) { Might be a mistake here.
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... File src/southbridge/intel/i82801ix/i82801ix.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... PS4, Line 207: if (!permanent_smi_handler()) Need to figure out the logic in the original work.
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... File src/southbridge/intel/i82801jx/i82801jx.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... PS4, Line 206: if (!permanent_smi_handler()) Need to figure out the logic in the original work.
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/ibexp... File src/southbridge/intel/ibexpeak/lpc.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/ibexp... PS4, Line 732: if (permanent_smi_handler()) { Might be a mistake here.
Hello build bot (Jenkins), Nico Huber, Alexander Couzens, Aaron Durbin, Patrick Rudolph,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/41910
to look at the new patch set (#5).
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed. There has been some experiments to delay SMM installation to OS, yet there are new platforms that allow some configuration access only to be done inside SMM.
Splitting static HAVE_SMI_HANDLER variable helps to manage cases where SMM might be both installed and cleared prior to entering payload.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 23 files changed, 29 insertions(+), 22 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/41910/5
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 5: Code-Review+2
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 5:
(1 comment)
https://review.coreboot.org/c/coreboot/+/41910/3/src/include/acpi/acpi.h File src/include/acpi/acpi.h:
https://review.coreboot.org/c/coreboot/+/41910/3/src/include/acpi/acpi.h@101... PS3, Line 1014: static inline int permanent_smi_handler(void)
A comment would be nice, what defines a "permanent" handler.
Done
Kyösti Mälkki has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 5:
(4 comments)
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/bd82x... File src/southbridge/intel/bd82x6x/lpc.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/bd82x... PS4, Line 839: if (permanent_smi_handler()) {
Might be a mistake here.
CB:41971
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... File src/southbridge/intel/i82801ix/i82801ix.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... PS4, Line 207: if (!permanent_smi_handler())
Need to figure out the logic in the original work.
CB:41970
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... File src/southbridge/intel/i82801jx/i82801jx.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/i8280... PS4, Line 206: if (!permanent_smi_handler())
Need to figure out the logic in the original work.
CB:41970
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/ibexp... File src/southbridge/intel/ibexpeak/lpc.c:
https://review.coreboot.org/c/coreboot/+/41910/4/src/southbridge/intel/ibexp... PS4, Line 732: if (permanent_smi_handler()) {
Might be a mistake here.
CB:41971
Aaron Durbin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 5: Code-Review+2
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
Patch Set 5: Code-Review+2
Patrick Georgi has submitted this change. ( https://review.coreboot.org/c/coreboot/+/41910 )
Change subject: arch/x86: Declare permanent_smi_handler() ......................................................................
arch/x86: Declare permanent_smi_handler()
Advertising SMI triggers in FADT is only valid if we exit with SMI installed. There has been some experiments to delay SMM installation to OS, yet there are new platforms that allow some configuration access only to be done inside SMM.
Splitting static HAVE_SMI_HANDLER variable helps to manage cases where SMM might be both installed and cleared prior to entering payload.
Change-Id: Iad92c4a180524e15199633693446a087787ad3a2 Signed-off-by: Kyösti Mälkki kyosti.malkki@gmail.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/41910 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Nico Huber nico.h@gmx.de Reviewed-by: Aaron Durbin adurbin@chromium.org Reviewed-by: Angel Pons th3fanbus@gmail.com --- M src/include/acpi/acpi.h M src/mainboard/aopen/dxplplusu/fadt.c M src/mainboard/emulation/qemu-q35/acpi_tables.c M src/mainboard/lenovo/t400/fadt.c M src/mainboard/lenovo/x200/fadt.c M src/mainboard/roda/rk9/fadt.c M src/soc/amd/picasso/acpi.c M src/soc/amd/stoneyridge/acpi.c M src/soc/intel/baytrail/acpi.c M src/soc/intel/braswell/acpi.c M src/soc/intel/broadwell/acpi.c M src/soc/intel/common/block/acpi/acpi.c M src/soc/intel/skylake/acpi.c M src/soc/intel/xeon_sp/cpx/acpi.c M src/soc/intel/xeon_sp/skx/acpi.c M src/southbridge/amd/agesa/hudson/fadt.c M src/southbridge/amd/pi/hudson/fadt.c M src/southbridge/intel/bd82x6x/lpc.c M src/southbridge/intel/i82371eb/fadt.c M src/southbridge/intel/i82801gx/lpc.c M src/southbridge/intel/i82801jx/lpc.c M src/southbridge/intel/ibexpeak/lpc.c M src/southbridge/intel/lynxpoint/lpc.c 23 files changed, 29 insertions(+), 22 deletions(-)
Approvals: build bot (Jenkins): Verified Nico Huber: Looks good to me, approved Aaron Durbin: Looks good to me, approved Angel Pons: Looks good to me, approved
diff --git a/src/include/acpi/acpi.h b/src/include/acpi/acpi.h index ba056c0..e6c18c2 100644 --- a/src/include/acpi/acpi.h +++ b/src/include/acpi/acpi.h @@ -1019,6 +1019,13 @@ /* Read and clear GPE status */ int acpi_get_gpe(int gpe);
+/* Once we enter payload, is SMI handler installed and capable of + responding to APM_CNT Advanced Power Management Control commands. */ +static inline int permanent_smi_handler(void) +{ + return CONFIG(HAVE_SMI_HANDLER); +} + static inline int acpi_s3_resume_allowed(void) { return CONFIG(HAVE_ACPI_RESUME); diff --git a/src/mainboard/aopen/dxplplusu/fadt.c b/src/mainboard/aopen/dxplplusu/fadt.c index 339c243..ad522c4 100644 --- a/src/mainboard/aopen/dxplplusu/fadt.c +++ b/src/mainboard/aopen/dxplplusu/fadt.c @@ -38,7 +38,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = ACPI_ENABLE; fadt->acpi_disable = ACPI_DISABLE; diff --git a/src/mainboard/emulation/qemu-q35/acpi_tables.c b/src/mainboard/emulation/qemu-q35/acpi_tables.c index 4236257..9bf58a6 100644 --- a/src/mainboard/emulation/qemu-q35/acpi_tables.c +++ b/src/mainboard/emulation/qemu-q35/acpi_tables.c @@ -43,7 +43,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { /* Do not advertise SMI even if installed. */ fadt->smi_cmd = 0; fadt->acpi_enable = 0; diff --git a/src/mainboard/lenovo/t400/fadt.c b/src/mainboard/lenovo/t400/fadt.c index d15b9b3..257fb41 100644 --- a/src/mainboard/lenovo/t400/fadt.c +++ b/src/mainboard/lenovo/t400/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/mainboard/lenovo/x200/fadt.c b/src/mainboard/lenovo/x200/fadt.c index d15b9b3..257fb41 100644 --- a/src/mainboard/lenovo/x200/fadt.c +++ b/src/mainboard/lenovo/x200/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/mainboard/roda/rk9/fadt.c b/src/mainboard/roda/rk9/fadt.c index 102865d..5127545 100644 --- a/src/mainboard/roda/rk9/fadt.c +++ b/src/mainboard/roda/rk9/fadt.c @@ -26,7 +26,7 @@ fadt->preferred_pm_profile = PM_MOBILE; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/amd/picasso/acpi.c b/src/soc/amd/picasso/acpi.c index d5a890b..817ec51 100644 --- a/src/soc/amd/picasso/acpi.c +++ b/src/soc/amd/picasso/acpi.c @@ -107,7 +107,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/amd/stoneyridge/acpi.c b/src/soc/amd/stoneyridge/acpi.c index 47d12bf..a7caa93 100644 --- a/src/soc/amd/stoneyridge/acpi.c +++ b/src/soc/amd/stoneyridge/acpi.c @@ -79,7 +79,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/baytrail/acpi.c b/src/soc/intel/baytrail/acpi.c index 66263e6..f9eb500 100644 --- a/src/soc/intel/baytrail/acpi.c +++ b/src/soc/intel/baytrail/acpi.c @@ -129,7 +129,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/braswell/acpi.c b/src/soc/intel/braswell/acpi.c index 4e3795e..e6790a7 100644 --- a/src/soc/intel/braswell/acpi.c +++ b/src/soc/intel/braswell/acpi.c @@ -133,7 +133,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/broadwell/acpi.c b/src/soc/intel/broadwell/acpi.c index 9df7dee..081b08a 100644 --- a/src/soc/intel/broadwell/acpi.c +++ b/src/soc/intel/broadwell/acpi.c @@ -185,7 +185,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/common/block/acpi/acpi.c b/src/soc/intel/common/block/acpi/acpi.c index c4a0698..bda2399 100644 --- a/src/soc/intel/common/block/acpi/acpi.c +++ b/src/soc/intel/common/block/acpi/acpi.c @@ -101,7 +101,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/skylake/acpi.c b/src/soc/intel/skylake/acpi.c index 34aed02..bdfacd3 100644 --- a/src/soc/intel/skylake/acpi.c +++ b/src/soc/intel/skylake/acpi.c @@ -226,7 +226,7 @@
fadt->sci_int = acpi_sci_irq();
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/xeon_sp/cpx/acpi.c b/src/soc/intel/xeon_sp/cpx/acpi.c index d6d847b..b090d12 100644 --- a/src/soc/intel/xeon_sp/cpx/acpi.c +++ b/src/soc/intel/xeon_sp/cpx/acpi.c @@ -148,7 +148,7 @@
fadt->x_gpe1_blk.space_id = 1;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/soc/intel/xeon_sp/skx/acpi.c b/src/soc/intel/xeon_sp/skx/acpi.c index 9cb36b8..f5d4e7a 100644 --- a/src/soc/intel/xeon_sp/skx/acpi.c +++ b/src/soc/intel/xeon_sp/skx/acpi.c @@ -340,7 +340,7 @@ fadt->sci_int = acpi_sci_irq();
/* TODO: enabled SMM mode switch when SMM handlers are set up. */ - if (0 && CONFIG(HAVE_SMI_HANDLER)) { + if (0 && permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/amd/agesa/hudson/fadt.c b/src/southbridge/amd/agesa/hudson/fadt.c index 660598a..a328a88 100644 --- a/src/southbridge/amd/agesa/hudson/fadt.c +++ b/src/southbridge/amd/agesa/hudson/fadt.c @@ -57,7 +57,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* HUDSON - IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/amd/pi/hudson/fadt.c b/src/southbridge/amd/pi/hudson/fadt.c index 100cfb6..686b669 100644 --- a/src/southbridge/amd/pi/hudson/fadt.c +++ b/src/southbridge/amd/pi/hudson/fadt.c @@ -49,7 +49,7 @@ fadt->preferred_pm_profile = FADT_PM_PROFILE; fadt->sci_int = 9; /* HUDSON - IRQ 09 - ACPI SCI */
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = ACPI_SMI_CTL_PORT; fadt->acpi_enable = ACPI_SMI_CMD_ENABLE; fadt->acpi_disable = ACPI_SMI_CMD_DISABLE; diff --git a/src/southbridge/intel/bd82x6x/lpc.c b/src/southbridge/intel/bd82x6x/lpc.c index 45215f1..0f1d33e 100644 --- a/src/southbridge/intel/bd82x6x/lpc.c +++ b/src/southbridge/intel/bd82x6x/lpc.c @@ -698,7 +698,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/i82371eb/fadt.c b/src/southbridge/intel/i82371eb/fadt.c index 09e027f..66781be 100644 --- a/src/southbridge/intel/i82371eb/fadt.c +++ b/src/southbridge/intel/i82371eb/fadt.c @@ -36,7 +36,7 @@ fadt->preferred_pm_profile = 0; /* unspecified */ fadt->sci_int = 9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { /* TODO: SMI handler is not implemented. */ fadt->smi_cmd = 0x00; } diff --git a/src/southbridge/intel/i82801gx/lpc.c b/src/southbridge/intel/i82801gx/lpc.c index 86c3e58..d4aef55 100644 --- a/src/southbridge/intel/i82801gx/lpc.c +++ b/src/southbridge/intel/i82801gx/lpc.c @@ -522,7 +522,7 @@ fadt->reserved = 0; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/i82801jx/lpc.c b/src/southbridge/intel/i82801jx/lpc.c index b3aeda2..7a1b24b 100644 --- a/src/southbridge/intel/i82801jx/lpc.c +++ b/src/southbridge/intel/i82801jx/lpc.c @@ -533,7 +533,7 @@ fadt->reserved = 0; fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/ibexpeak/lpc.c b/src/southbridge/intel/ibexpeak/lpc.c index 1209f9b..742b86d 100644 --- a/src/southbridge/intel/ibexpeak/lpc.c +++ b/src/southbridge/intel/ibexpeak/lpc.c @@ -592,7 +592,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE; diff --git a/src/southbridge/intel/lynxpoint/lpc.c b/src/southbridge/intel/lynxpoint/lpc.c index da744bf..1d75555 100644 --- a/src/southbridge/intel/lynxpoint/lpc.c +++ b/src/southbridge/intel/lynxpoint/lpc.c @@ -741,7 +741,7 @@
fadt->sci_int = 0x9;
- if (CONFIG(HAVE_SMI_HANDLER)) { + if (permanent_smi_handler()) { fadt->smi_cmd = APM_CNT; fadt->acpi_enable = APM_CNT_ACPI_ENABLE; fadt->acpi_disable = APM_CNT_ACPI_DISABLE;