diff options
author | Nico Huber <nico.h@gmx.de> | 2021-07-12 18:11:58 +0200 |
---|---|---|
committer | Nick Vaccaro <nvaccaro@google.com> | 2021-08-19 18:16:04 +0000 |
commit | d5811378dc1f6dbf77cd93a01f9df61c6e218f26 (patch) | |
tree | aa1a151360a05dd9fe906631469d2efc635bae4a /src | |
parent | 6fcee7533c1a4036224339ae299e448e210ca78d (diff) |
acpi: Fill fadt->century based on Kconfig
Change-Id: I916f19e022633b316fbc0c6bf38bbd58228412be
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/56218
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Lance Zhao
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/acpi/acpi.c | 4 | ||||
-rw-r--r-- | src/soc/amd/picasso/acpi.c | 1 | ||||
-rw-r--r-- | src/soc/amd/stoneyridge/acpi.c | 1 | ||||
-rw-r--r-- | src/soc/intel/baytrail/fadt.c | 1 | ||||
-rw-r--r-- | src/soc/intel/braswell/fadt.c | 1 | ||||
-rw-r--r-- | src/soc/intel/broadwell/pch/fadt.c | 1 | ||||
-rw-r--r-- | src/soc/intel/denverton_ns/acpi.c | 1 | ||||
-rw-r--r-- | src/soc/intel/elkhartlake/acpi.c | 1 | ||||
-rw-r--r-- | src/soc/intel/skylake/fadt.c | 1 | ||||
-rw-r--r-- | src/soc/intel/xeon_sp/skx/soc_acpi.c | 1 | ||||
-rw-r--r-- | src/southbridge/amd/agesa/hudson/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/amd/cimx/sb800/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/amd/pi/hudson/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/bd82x6x/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/i82371eb/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/i82801dx/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/i82801gx/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/i82801ix/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/i82801jx/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/ibexpeak/fadt.c | 1 | ||||
-rw-r--r-- | src/southbridge/intel/lynxpoint/fadt.c | 1 |
21 files changed, 4 insertions, 20 deletions
diff --git a/src/acpi/acpi.c b/src/acpi/acpi.c index 5f9767e818..2e15ea9cc8 100644 --- a/src/acpi/acpi.c +++ b/src/acpi/acpi.c @@ -26,6 +26,7 @@ #include <types.h> #include <version.h> #include <commonlib/sort.h> +#include <pc80/mc146818rtc.h> static acpi_rsdp_t *valid_rsdp(acpi_rsdp_t *rsdp); @@ -1510,6 +1511,9 @@ void acpi_create_fadt(acpi_fadt_t *fadt, acpi_facs_t *facs, void *dsdt) fadt->preferred_pm_profile = acpi_get_preferred_pm_profile(); + if (CONFIG(USE_PC_CMOS_ALTCENTURY)) + fadt->century = RTC_CLK_ALTCENTURY; + arch_fill_fadt(fadt); acpi_fill_fadt(fadt); diff --git a/src/soc/amd/picasso/acpi.c b/src/soc/amd/picasso/acpi.c index eca3333277..99c1648f8a 100644 --- a/src/soc/amd/picasso/acpi.c +++ b/src/soc/amd/picasso/acpi.c @@ -94,7 +94,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* CLK_VAL bits 3:1 */ fadt->day_alrm = 0x0d; fadt->mon_alrm = 0; - fadt->century = 0x32; fadt->iapc_boot_arch = cfg->fadt_boot_arch; /* legacy free default */ fadt->res2 = 0; /* reserved, MUST be 0 ACPI 3.0 */ fadt->flags |= ACPI_FADT_WBINVD | /* See table 5-34 ACPI 6.3 spec */ diff --git a/src/soc/amd/stoneyridge/acpi.c b/src/soc/amd/stoneyridge/acpi.c index 16874adf5b..b2de89e016 100644 --- a/src/soc/amd/stoneyridge/acpi.c +++ b/src/soc/amd/stoneyridge/acpi.c @@ -86,7 +86,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* CLK_VAL bits 3:1 */ fadt->day_alrm = 0x0d; fadt->mon_alrm = 0; /* Not supported */ - fadt->century = 0x32; fadt->iapc_boot_arch = FADT_BOOT_ARCH; /* See table 5-10 */ fadt->res2 = 0; /* reserved, MUST be 0 ACPI 3.0 */ fadt->flags |= ACPI_FADT_WBINVD | /* See table 5-10 ACPI 3.0a spec */ diff --git a/src/soc/intel/baytrail/fadt.c b/src/soc/intel/baytrail/fadt.c index f78188ee28..395bdd37f2 100644 --- a/src/soc/intel/baytrail/fadt.c +++ b/src/soc/intel/baytrail/fadt.c @@ -36,7 +36,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | diff --git a/src/soc/intel/braswell/fadt.c b/src/soc/intel/braswell/fadt.c index f78188ee28..395bdd37f2 100644 --- a/src/soc/intel/braswell/fadt.c +++ b/src/soc/intel/braswell/fadt.c @@ -36,7 +36,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | diff --git a/src/soc/intel/broadwell/pch/fadt.c b/src/soc/intel/broadwell/pch/fadt.c index 52254a0f90..91924668cc 100644 --- a/src/soc/intel/broadwell/pch/fadt.c +++ b/src/soc/intel/broadwell/pch/fadt.c @@ -36,7 +36,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | diff --git a/src/soc/intel/denverton_ns/acpi.c b/src/soc/intel/denverton_ns/acpi.c index 921cbc9cf6..aa59aa8c81 100644 --- a/src/soc/intel/denverton_ns/acpi.c +++ b/src/soc/intel/denverton_ns/acpi.c @@ -111,7 +111,6 @@ void soc_fill_fadt(acpi_fadt_t *fadt) /* RTC Registers */ fadt->day_alrm = 0x0D; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | diff --git a/src/soc/intel/elkhartlake/acpi.c b/src/soc/intel/elkhartlake/acpi.c index 3a00c46a0c..22b8767f48 100644 --- a/src/soc/intel/elkhartlake/acpi.c +++ b/src/soc/intel/elkhartlake/acpi.c @@ -163,7 +163,6 @@ void soc_fill_fadt(acpi_fadt_t *fadt) fadt->p_lvl2_lat = ACPI_FADT_C2_NOT_SUPPORTED; fadt->p_lvl3_lat = ACPI_FADT_C3_NOT_SUPPORTED; fadt->duty_width = 0x3; /* CLK_VAL bits 3:1 */ - fadt->century = 0x32; if (config->s0ix_enable) fadt->flags |= ACPI_FADT_LOW_PWR_IDLE_S0; diff --git a/src/soc/intel/skylake/fadt.c b/src/soc/intel/skylake/fadt.c index 3e60216fba..b8eb9d02e5 100644 --- a/src/soc/intel/skylake/fadt.c +++ b/src/soc/intel/skylake/fadt.c @@ -40,7 +40,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_FREE; if (!CONFIG(NO_FADT_8042)) fadt->iapc_boot_arch |= ACPI_FADT_8042; diff --git a/src/soc/intel/xeon_sp/skx/soc_acpi.c b/src/soc/intel/xeon_sp/skx/soc_acpi.c index 1f1d058c81..41039eabdd 100644 --- a/src/soc/intel/xeon_sp/skx/soc_acpi.c +++ b/src/soc/intel/xeon_sp/skx/soc_acpi.c @@ -55,7 +55,6 @@ void soc_fill_fadt(acpi_fadt_t *fadt) /* RTC Registers */ fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; /* PM2 Control Registers */ diff --git a/src/southbridge/amd/agesa/hudson/fadt.c b/src/southbridge/amd/agesa/hudson/fadt.c index ba9e47d083..c9962be894 100644 --- a/src/southbridge/amd/agesa/hudson/fadt.c +++ b/src/southbridge/amd/agesa/hudson/fadt.c @@ -50,7 +50,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* CLK_VAL bits 3:1 */ fadt->day_alrm = 0; /* 0x7d these have to be */ fadt->mon_alrm = 0; /* 0x7e added to cmos.layout */ - fadt->century = 0; /* 0x7f to make rtc alarm work */ fadt->iapc_boot_arch = FADT_BOOT_ARCH; /* See table 5-10 */ fadt->res2 = 0; /* reserved, MUST be 0 ACPI 3.0 */ fadt->flags |= ACPI_FADT_WBINVD | /* See table 5-10 ACPI 3.0a spec */ diff --git a/src/southbridge/amd/cimx/sb800/fadt.c b/src/southbridge/amd/cimx/sb800/fadt.c index 9272194442..25600c081e 100644 --- a/src/southbridge/amd/cimx/sb800/fadt.c +++ b/src/southbridge/amd/cimx/sb800/fadt.c @@ -75,7 +75,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* CLK_VAL bits 3:1 */ fadt->day_alrm = 0; /* 0x7d these have to be */ fadt->mon_alrm = 0; /* 0x7e added to cmos.layout */ - fadt->century = 0; /* 0x7f to make rtc alarm work */ fadt->iapc_boot_arch = FADT_BOOT_ARCH; /* See table 5-10 */ fadt->res2 = 0; /* reserved, MUST be 0 ACPI 3.0 */ fadt->flags |= ACPI_FADT_WBINVD | /* See table 5-10 ACPI 3.0a spec */ diff --git a/src/southbridge/amd/pi/hudson/fadt.c b/src/southbridge/amd/pi/hudson/fadt.c index 0bb9a97f40..e2f3bbad7d 100644 --- a/src/southbridge/amd/pi/hudson/fadt.c +++ b/src/southbridge/amd/pi/hudson/fadt.c @@ -50,7 +50,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* CLK_VAL bits 3:1 */ fadt->day_alrm = 0; /* 0x7d these have to be */ fadt->mon_alrm = 0; /* 0x7e added to cmos.layout */ - fadt->century = 0; /* 0x7f to make rtc alarm work */ fadt->iapc_boot_arch = FADT_BOOT_ARCH; /* See table 5-10 */ fadt->res2 = 0; /* reserved, MUST be 0 ACPI 3.0 */ fadt->flags |= ACPI_FADT_WBINVD | /* See table 5-10 ACPI 3.0a spec */ diff --git a/src/southbridge/intel/bd82x6x/fadt.c b/src/southbridge/intel/bd82x6x/fadt.c index 77af4e89b5..c6f68775b6 100644 --- a/src/southbridge/intel/bd82x6x/fadt.c +++ b/src/southbridge/intel/bd82x6x/fadt.c @@ -39,7 +39,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | diff --git a/src/southbridge/intel/i82371eb/fadt.c b/src/southbridge/intel/i82371eb/fadt.c index 5aeff4ecc9..1d640f4e41 100644 --- a/src/southbridge/intel/i82371eb/fadt.c +++ b/src/southbridge/intel/i82371eb/fadt.c @@ -42,7 +42,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; /* this width is in bits */ fadt->day_alrm = 0x0d; /* rtc CMOS RAM offset */ fadt->mon_alrm = 0x0; /* not supported */ - fadt->century = 0x0; /* not supported */ /* * bit meaning * 0 1: We have user-visible legacy devices diff --git a/src/southbridge/intel/i82801dx/fadt.c b/src/southbridge/intel/i82801dx/fadt.c index 84ea73ad9c..9524b7d34f 100644 --- a/src/southbridge/intel/i82801dx/fadt.c +++ b/src/southbridge/intel/i82801dx/fadt.c @@ -44,7 +44,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | diff --git a/src/southbridge/intel/i82801gx/fadt.c b/src/southbridge/intel/i82801gx/fadt.c index 153ddea7e8..a59a586fbb 100644 --- a/src/southbridge/intel/i82801gx/fadt.c +++ b/src/southbridge/intel/i82801gx/fadt.c @@ -43,7 +43,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x32; fadt->iapc_boot_arch = ACPI_FADT_8042 | ACPI_FADT_LEGACY_DEVICES; fadt->flags |= (ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | ACPI_FADT_SLEEP_BUTTON | ACPI_FADT_S4_RTC_WAKE diff --git a/src/southbridge/intel/i82801ix/fadt.c b/src/southbridge/intel/i82801ix/fadt.c index 8a48f1b2a2..ec854966e5 100644 --- a/src/southbridge/intel/i82801ix/fadt.c +++ b/src/southbridge/intel/i82801ix/fadt.c @@ -36,7 +36,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 3; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x32; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_FREE; fadt->flags |= ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | ACPI_FADT_SLEEP_BUTTON | ACPI_FADT_S4_RTC_WAKE | diff --git a/src/southbridge/intel/i82801jx/fadt.c b/src/southbridge/intel/i82801jx/fadt.c index 377b4d28e5..6c5d1c76df 100644 --- a/src/southbridge/intel/i82801jx/fadt.c +++ b/src/southbridge/intel/i82801jx/fadt.c @@ -36,7 +36,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x32; fadt->iapc_boot_arch = ACPI_FADT_8042 | ACPI_FADT_LEGACY_DEVICES; fadt->flags |= (ACPI_FADT_WBINVD | ACPI_FADT_C1_SUPPORTED | ACPI_FADT_SLEEP_BUTTON | ACPI_FADT_S4_RTC_WAKE diff --git a/src/southbridge/intel/ibexpeak/fadt.c b/src/southbridge/intel/ibexpeak/fadt.c index 40c8bdc57b..7f2254167c 100644 --- a/src/southbridge/intel/ibexpeak/fadt.c +++ b/src/southbridge/intel/ibexpeak/fadt.c @@ -39,7 +39,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x32; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | diff --git a/src/southbridge/intel/lynxpoint/fadt.c b/src/southbridge/intel/lynxpoint/fadt.c index abf56ca6fd..0d078997e5 100644 --- a/src/southbridge/intel/lynxpoint/fadt.c +++ b/src/southbridge/intel/lynxpoint/fadt.c @@ -51,7 +51,6 @@ void acpi_fill_fadt(acpi_fadt_t *fadt) fadt->duty_width = 0; fadt->day_alrm = 0xd; fadt->mon_alrm = 0x00; - fadt->century = 0x00; fadt->iapc_boot_arch = ACPI_FADT_LEGACY_DEVICES | ACPI_FADT_8042; fadt->flags |= ACPI_FADT_WBINVD | |