aboutsummaryrefslogtreecommitdiff
path: root/src/soc/intel/baytrail/smihandler.c
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2021-03-16 19:02:26 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2021-06-14 19:45:56 +0000
commit4bd9187dadaf4f3be5a1776d98d1f79cdfb23de8 (patch)
treecadad49316ba0b6e77d9304a5505dcede8860ea5 /src/soc/intel/baytrail/smihandler.c
parent3dc1792f1df9a9cd982bb63d3b29cc16c08bd7f6 (diff)
ACPI: Refactor use of global and device NVS
After ChromeOS NVS was moved to a separate allocation and the use of multiple OperationRegions, maintaining the fixed offsets is not necessary. Use actual structure size for OperationRegions, but align the allocations to 8 bytes or sizeof(uint64_t). Change-Id: I9c73b7c44d234af42c571b23187b924ca2c3894a Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/51639 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src/soc/intel/baytrail/smihandler.c')
-rw-r--r--src/soc/intel/baytrail/smihandler.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/soc/intel/baytrail/smihandler.c b/src/soc/intel/baytrail/smihandler.c
index e48ddbacab..20e15902b1 100644
--- a/src/soc/intel/baytrail/smihandler.c
+++ b/src/soc/intel/baytrail/smihandler.c
@@ -20,8 +20,6 @@
#include <soc/nvs.h>
#include <soc/device_nvs.h>
-#include <vendorcode/google/chromeos/gnvs.h>
-
int southbridge_io_trap_handler(int smif)
{
switch (smif) {
@@ -210,7 +208,7 @@ static void southbridge_smi_gsmi(void)
void *acpi_get_device_nvs(void)
{
- return (u8 *)gnvs + GNVS_DEVICE_NVS_OFFSET;
+ return (u8 *)gnvs + ALIGN_UP(sizeof(struct global_nvs), sizeof(uint64_t));
}
/*