diff options
author | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2019-11-25 21:23:37 +0200 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2020-06-28 21:50:12 +0000 |
commit | 5b672d595411a50012d3d232db6d886818d44893 (patch) | |
tree | 06ead78b90df1ec04fe71c29f52068290821f115 /src/soc/amd/picasso | |
parent | b0ae42b5bb7fe7c9f6e8301bff8fbabe95294c62 (diff) |
soc/amd/common: Access ACPIMMIO via proper symbols
Using proper symbols for base addresses, it is possible to
only define the symbols for base addresses implemented for
the specific platform and executing stage.
Change-Id: Ib8599ee93bfb1c2d6d9b4accfca1ebbefe758e09
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/37324
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/soc/amd/picasso')
-rw-r--r-- | src/soc/amd/picasso/psp.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/soc/amd/picasso/psp.c b/src/soc/amd/picasso/psp.c index 02291393d1..e40d395637 100644 --- a/src/soc/amd/picasso/psp.c +++ b/src/soc/amd/picasso/psp.c @@ -3,7 +3,7 @@ #include <console/console.h> #include <cpu/x86/msr.h> #include <soc/smi.h> -#include <amdblocks/acpimmio_map.h> +#include <amdblocks/acpimmio.h> #include <amdblocks/psp.h> #define PSP_MAILBOX_OFFSET 0x10570 @@ -27,7 +27,7 @@ void soc_fill_smm_trig_info(struct smm_trigger_info *trig) if (!trig) return; - trig->address = 0xfed802a8; + trig->address = (uintptr_t)acpimmio_smi + SMI_REG_CONTROL2; trig->address_type = SMM_TRIGGER_MEM; trig->value_width = SMM_TRIGGER_DWORD; trig->value_and_mask = 0xfdffffff; @@ -39,19 +39,19 @@ void soc_fill_smm_reg_info(struct smm_register_info *reg) if (!reg) return; - reg->smi_enb.address = ACPIMMIO_SMI_BASE + SMI_REG_SMITRIG0; + reg->smi_enb.address = (uintptr_t)acpimmio_smi + SMI_REG_SMITRIG0; reg->smi_enb.address_type = SMM_TRIGGER_MEM; reg->smi_enb.value_width = SMM_TRIGGER_DWORD; reg->smi_enb.reg_bit_mask = SMITRG0_SMIENB; reg->smi_enb.expect_value = 0; - reg->eos.address = ACPIMMIO_SMI_BASE + SMI_REG_SMITRIG0; + reg->eos.address = (uintptr_t)acpimmio_smi + SMI_REG_SMITRIG0; reg->eos.address_type = SMM_TRIGGER_MEM; reg->eos.value_width = SMM_TRIGGER_DWORD; reg->eos.reg_bit_mask = SMITRG0_EOS; reg->eos.expect_value = SMITRG0_EOS; - reg->psp_smi_en.address = ACPIMMIO_SMI_BASE + SMI_REG_CONTROL0; + reg->psp_smi_en.address = (uintptr_t)acpimmio_smi + SMI_REG_CONTROL0; reg->psp_smi_en.address += sizeof(uint32_t) * SMITYPE_PSP / 16; reg->psp_smi_en.address_type = SMM_TRIGGER_MEM; reg->psp_smi_en.value_width = SMM_TRIGGER_DWORD; |