diff options
Diffstat (limited to 'src/cpu')
-rw-r--r-- | src/cpu/amd/mtrr/amd_earlymtrr.c | 6 | ||||
-rw-r--r-- | src/cpu/x86/mtrr/earlymtrr.c | 15 |
2 files changed, 9 insertions, 12 deletions
diff --git a/src/cpu/amd/mtrr/amd_earlymtrr.c b/src/cpu/amd/mtrr/amd_earlymtrr.c index 6ade525110..81b4a80a84 100644 --- a/src/cpu/amd/mtrr/amd_earlymtrr.c +++ b/src/cpu/amd/mtrr/amd_earlymtrr.c @@ -42,12 +42,6 @@ static void do_amd_early_mtrr_init(const unsigned long *mtrr_msrs) wrmsr(TOP_MEM, msr); #if defined(CONFIG_XIP_ROM_SIZE) -#if defined(CONFIG_TINY_BOOTBLOCK) && CONFIG_TINY_BOOTBLOCK -extern unsigned long AUTO_XIP_ROM_BASE; -#define REAL_XIP_ROM_BASE AUTO_XIP_ROM_BASE -#else -#define REAL_XIP_ROM_BASE CONFIG_XIP_ROM_BASE -#endif /* enable write through caching so we can do execute in place * on the flash rom. */ diff --git a/src/cpu/x86/mtrr/earlymtrr.c b/src/cpu/x86/mtrr/earlymtrr.c index 150091e7a8..af9d56871a 100644 --- a/src/cpu/x86/mtrr/earlymtrr.c +++ b/src/cpu/x86/mtrr/earlymtrr.c @@ -26,6 +26,15 @@ # error "CONFIG_RAMTOP must be a power of 2" #endif +#if defined(CONFIG_XIP_ROM_SIZE) +# if defined(CONFIG_TINY_BOOTBLOCK) && CONFIG_TINY_BOOTBLOCK + extern unsigned long AUTO_XIP_ROM_BASE; +# define REAL_XIP_ROM_BASE AUTO_XIP_ROM_BASE +# else +# define REAL_XIP_ROM_BASE CONFIG_XIP_ROM_BASE +# endif +#endif + static void disable_var_mtrr(unsigned reg) { /* The invalid bit is kept in the mask so we simply @@ -100,12 +109,6 @@ static void do_early_mtrr_init(const unsigned long *mtrr_msrs) } #if defined(CONFIG_XIP_ROM_SIZE) -#if defined(CONFIG_TINY_BOOTBLOCK) && CONFIG_TINY_BOOTBLOCK -extern unsigned long AUTO_XIP_ROM_BASE; -#define REAL_XIP_ROM_BASE AUTO_XIP_ROM_BASE -#else -#define REAL_XIP_ROM_BASE CONFIG_XIP_ROM_BASE -#endif /* enable write through caching so we can do execute in place * on the flash rom. */ |