diff options
Diffstat (limited to 'arch/x86/boot/compressed/efi_stub_64.S')
| -rw-r--r-- | arch/x86/boot/compressed/efi_stub_64.S | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/arch/x86/boot/compressed/efi_stub_64.S b/arch/x86/boot/compressed/efi_stub_64.S index cedc60de86eb..7ff3632806b1 100644 --- a/arch/x86/boot/compressed/efi_stub_64.S +++ b/arch/x86/boot/compressed/efi_stub_64.S | |||
| @@ -1 +1,30 @@ | |||
| 1 | #include <asm/segment.h> | ||
| 2 | #include <asm/msr.h> | ||
| 3 | #include <asm/processor-flags.h> | ||
| 4 | |||
| 1 | #include "../../platform/efi/efi_stub_64.S" | 5 | #include "../../platform/efi/efi_stub_64.S" |
| 6 | |||
| 7 | #ifdef CONFIG_EFI_MIXED | ||
| 8 | .code64 | ||
| 9 | .text | ||
| 10 | ENTRY(efi64_thunk) | ||
| 11 | push %rbp | ||
| 12 | push %rbx | ||
| 13 | |||
| 14 | subq $16, %rsp | ||
| 15 | leaq efi_exit32(%rip), %rax | ||
| 16 | movl %eax, 8(%rsp) | ||
| 17 | leaq efi_gdt64(%rip), %rax | ||
| 18 | movl %eax, 4(%rsp) | ||
| 19 | movl %eax, 2(%rax) /* Fixup the gdt base address */ | ||
| 20 | leaq efi32_boot_gdt(%rip), %rax | ||
| 21 | movl %eax, (%rsp) | ||
| 22 | |||
| 23 | call __efi64_thunk | ||
| 24 | |||
| 25 | addq $16, %rsp | ||
| 26 | pop %rbx | ||
| 27 | pop %rbp | ||
| 28 | ret | ||
| 29 | ENDPROC(efi64_thunk) | ||
| 30 | #endif /* CONFIG_EFI_MIXED */ | ||
