aboutsummaryrefslogtreecommitdiff
path: root/src/arch/x86/gdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch/x86/gdt.c')
-rw-r--r--src/arch/x86/gdt.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/arch/x86/gdt.c b/src/arch/x86/gdt.c
index 982b8ae9d2..f662edda3a 100644
--- a/src/arch/x86/gdt.c
+++ b/src/arch/x86/gdt.c
@@ -38,6 +38,10 @@ static void move_gdt(int is_recovery)
u16 num_gdt_bytes = (uintptr_t)&gdt_end - (uintptr_t)&gdt;
struct gdtarg gdtarg;
+ /* ramstage is already in high memory. No need to use a new gdt. */
+ if (IS_ENABLED(CONFIG_RELOCATABLE_RAMSTAGE))
+ return;
+
newgdt = cbmem_find(CBMEM_ID_GDT);
if (!newgdt) {
newgdt = cbmem_add(CBMEM_ID_GDT, ALIGN(num_gdt_bytes, 512));