diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c index ec3ffb94807d..3d5236fa54dd 100644 --- a/arch/x86/xen/setup.c +++ b/arch/x86/xen/setup.c @@ -656,7 +656,7 @@ static void __init xen_e820_swap_entry_with_ram(struct e820_entry *swap_entry) /* Fill new entry (keep size and page offset). */ entry->type = swap_entry->type; entry->addr = entry_end - swap_size + - swap_addr - swap_entry->addr; + swap_entry->addr - swap_addr; entry->size = swap_entry->size; /* Convert old entry to RAM, align to pages. */