diff options
author | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2020-06-28 12:12:01 +0300 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2020-07-01 05:14:24 +0000 |
commit | 239abaf759dbade7feb2423d335df6a52f1f8930 (patch) | |
tree | f8e56e6433ad377243a4078bb9d690e8c59b1345 /src/southbridge/intel | |
parent | 6bed1c47f614143728cac64e6a7510230a7cfc28 (diff) | |
download | coreboot-239abaf759dbade7feb2423d335df6a52f1f8930.tar.xz |
ACPI GNVS: Replace uses of smm_get_gnvs()
Change-Id: I7b657750b10f98524f011f5254e533217fe94fd8
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/42849
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Diffstat (limited to 'src/southbridge/intel')
-rw-r--r-- | src/southbridge/intel/bd82x6x/smihandler.c | 8 | ||||
-rw-r--r-- | src/southbridge/intel/i82801gx/smihandler.c | 3 | ||||
-rw-r--r-- | src/southbridge/intel/i82801ix/smihandler.c | 9 | ||||
-rw-r--r-- | src/southbridge/intel/i82801jx/smihandler.c | 4 | ||||
-rw-r--r-- | src/southbridge/intel/ibexpeak/smihandler.c | 9 | ||||
-rw-r--r-- | src/southbridge/intel/lynxpoint/smihandler.c | 9 |
6 files changed, 6 insertions, 36 deletions
diff --git a/src/southbridge/intel/bd82x6x/smihandler.c b/src/southbridge/intel/bd82x6x/smihandler.c index b257fb69fb..8af14283c3 100644 --- a/src/southbridge/intel/bd82x6x/smihandler.c +++ b/src/southbridge/intel/bd82x6x/smihandler.c @@ -17,12 +17,6 @@ #include "pch.h" #include "nvs.h" -static struct global_nvs *gnvs; -struct global_nvs *smm_get_gnvs(void) -{ - return gnvs; -} - int southbridge_io_trap_handler(int smif) { switch (smif) { @@ -186,7 +180,7 @@ void southbridge_smi_monitor(void) void southbridge_smm_xhci_sleep(u8 slp_type) { - if (smm_get_gnvs()->xhci) + if (gnvs->xhci) xhci_sleep(slp_type); } diff --git a/src/southbridge/intel/i82801gx/smihandler.c b/src/southbridge/intel/i82801gx/smihandler.c index 1757872f2b..7aee63b457 100644 --- a/src/southbridge/intel/i82801gx/smihandler.c +++ b/src/southbridge/intel/i82801gx/smihandler.c @@ -21,9 +21,6 @@ u16 pmbase = DEFAULT_PMBASE; u8 smm_initialized = 0; -/* GNVS needs to be updated by an 0xEA PM Trap (B2) after it has been located by coreboot. */ -struct global_nvs *gnvs = (struct global_nvs *)0x0; - void southbridge_update_gnvs(u8 apm_cnt, int *smm_done) { gnvs = *(struct global_nvs **)0x500; diff --git a/src/southbridge/intel/i82801ix/smihandler.c b/src/southbridge/intel/i82801ix/smihandler.c index 070b7a60b8..c352e5d76c 100644 --- a/src/southbridge/intel/i82801ix/smihandler.c +++ b/src/southbridge/intel/i82801ix/smihandler.c @@ -9,10 +9,11 @@ #include "nvs.h" -/* GNVS needs to be updated by an 0xEA PM Trap (B2) after it has been located - * by coreboot. - */ -struct global_nvs *gnvs = (struct global_nvs *)0x0; +#if !CONFIG(SMM_TSEG) +/* For qemu/x86-q35 to build properly. */ +struct global_nvs *gnvs; +#endif + void *tcg = (void *)0x0; void *smi1 = (void *)0x0; diff --git a/src/southbridge/intel/i82801jx/smihandler.c b/src/southbridge/intel/i82801jx/smihandler.c index af242aaf19..b6161e9d81 100644 --- a/src/southbridge/intel/i82801jx/smihandler.c +++ b/src/southbridge/intel/i82801jx/smihandler.c @@ -15,10 +15,6 @@ u16 pmbase = DEFAULT_PMBASE; u8 smm_initialized = 0; -/* GNVS needs to be updated by an 0xEA PM Trap (B2) after it has been located - * by coreboot. - */ -struct global_nvs *gnvs = (struct global_nvs *)0x0; void *tcg = (void *)0x0; void *smi1 = (void *)0x0; diff --git a/src/southbridge/intel/ibexpeak/smihandler.c b/src/southbridge/intel/ibexpeak/smihandler.c index 2679351436..2bc31cf0cf 100644 --- a/src/southbridge/intel/ibexpeak/smihandler.c +++ b/src/southbridge/intel/ibexpeak/smihandler.c @@ -23,15 +23,6 @@ #include <southbridge/intel/common/gpio.h> #include <southbridge/intel/common/pmutil.h> -/* GNVS needs to be updated by an 0xEA PM Trap (B2) after it has been located - * by coreboot. - */ -static struct global_nvs *gnvs; -struct global_nvs *smm_get_gnvs(void) -{ - return gnvs; -} - int southbridge_io_trap_handler(int smif) { switch (smif) { diff --git a/src/southbridge/intel/lynxpoint/smihandler.c b/src/southbridge/intel/lynxpoint/smihandler.c index 0bc1e2a86f..6e14985307 100644 --- a/src/southbridge/intel/lynxpoint/smihandler.c +++ b/src/southbridge/intel/lynxpoint/smihandler.c @@ -21,15 +21,6 @@ static u8 smm_initialized = 0; -/* GNVS needs to be updated by an 0xEA PM Trap (B2) after it has been located - * by coreboot. - */ -static struct global_nvs *gnvs; -struct global_nvs *smm_get_gnvs(void) -{ - return gnvs; -} - int southbridge_io_trap_handler(int smif) { switch (smif) { |