diff options
author | Angel Pons <th3fanbus@gmail.com> | 2020-10-13 13:43:07 +0200 |
---|---|---|
committer | Angel Pons <th3fanbus@gmail.com> | 2020-10-23 14:45:31 +0000 |
commit | e3fd00f9e8a65ddb9c54622fd095c252c5c36cf8 (patch) | |
tree | 6130abfd86c5b2d823979fb756db72e9719f7d4d | |
parent | 0263e0ff65d50a616e1ae04ab0837c0d90118d19 (diff) |
soc/intel/broadwell: Guard MCHBAR macro parameters
Add brackets around the parameters to avoid operation order problems.
Tested with BUILD_TIMELESS=1, Purism Librem 13 v1 remains identical.
Change-Id: I6efbe70d2bb3ad776a2566365afa66afab51584e
Signed-off-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/46336
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Nico Huber <nico.h@gmx.de>
-rw-r--r-- | src/soc/intel/broadwell/include/soc/systemagent.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/soc/intel/broadwell/include/soc/systemagent.h b/src/soc/intel/broadwell/include/soc/systemagent.h index c2c5cc8ada..f81d5a00b2 100644 --- a/src/soc/intel/broadwell/include/soc/systemagent.h +++ b/src/soc/intel/broadwell/include/soc/systemagent.h @@ -80,9 +80,9 @@ /* MCHBAR */ -#define MCHBAR8(x) *((volatile u8 *)(MCH_BASE_ADDRESS + x)) -#define MCHBAR16(x) *((volatile u16 *)(MCH_BASE_ADDRESS + x)) -#define MCHBAR32(x) *((volatile u32 *)(MCH_BASE_ADDRESS + x)) +#define MCHBAR8(x) *((volatile u8 *)(MCH_BASE_ADDRESS + (x))) +#define MCHBAR16(x) *((volatile u16 *)(MCH_BASE_ADDRESS + (x))) +#define MCHBAR32(x) *((volatile u32 *)(MCH_BASE_ADDRESS + (x))) #define MCHBAR_PEI_VERSION 0x5034 #define BIOS_RESET_CPL 0x5da8 |