diff options
author | Felix Held <felix-coreboot@felixheld.de> | 2023-03-09 19:29:16 +0100 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2023-03-10 21:26:12 +0000 |
commit | 65c4b8652de6d621dbc466b706d61c856db348d9 (patch) | |
tree | c1b9e0da258471777407fa33f64f238700b7e8aa /src/soc | |
parent | 2c9821898554eb139193ab6342dd0c2221160e9c (diff) |
soc/amd/common/block/psp/psp_smm: use raw MSR data
Since mst_t is a union of the struct containing the lower and higher 32
bits and the raw 64 bit value, there's no need to convert the lower and
higher 32 bits into a 64 bit value and we can just use the 64 bit raw
value.
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I5923df84f0eb3a28ba6eda4a06c7421f4459e560
Reviewed-on: https://review.coreboot.org/c/coreboot/+/73638
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Martin Roth <martin.roth@amd.corp-partner.google.com>
Reviewed-by: Fred Reitberger <reitbergerfred@gmail.com>
Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/soc')
-rw-r--r-- | src/soc/amd/common/block/psp/psp_smm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/soc/amd/common/block/psp/psp_smm.c b/src/soc/amd/common/block/psp/psp_smm.c index 95c3e4ef1b..49e48e3d48 100644 --- a/src/soc/amd/common/block/psp/psp_smm.c +++ b/src/soc/amd/common/block/psp/psp_smm.c @@ -51,10 +51,10 @@ int psp_notify_smm(void) }; msr = rdmsr(SMM_ADDR_MSR); - buffer.req.smm_base = ((uint64_t)msr.hi << 32) | msr.lo; + buffer.req.smm_base = msr.raw; msr = rdmsr(SMM_MASK_MSR); msr.lo &= 0xffff0000; /* mask SMM_TSEG_VALID and reserved bits */ - buffer.req.smm_mask = ((uint64_t)msr.hi << 32) | msr.lo; + buffer.req.smm_mask = msr.raw; soc_fill_smm_trig_info(&buffer.req.smm_trig_info); #if (CONFIG(SOC_AMD_COMMON_BLOCK_PSP_GEN2)) |