1dbd38004SZixuan Wang #ifndef _X86_ASM_SETUP_H_ 2dbd38004SZixuan Wang #define _X86_ASM_SETUP_H_ 3dbd38004SZixuan Wang 47e33895dSPaolo Bonzini unsigned long setup_tss(u8 *stacktop); 5dbd38004SZixuan Wang 6ad5fb883SZixuan Wang #ifdef TARGET_EFI 7ad5fb883SZixuan Wang #include "x86/apic.h" 8ad5fb883SZixuan Wang #include "x86/smp.h" 9*1ae9072eSZixuan Wang #include "efi.h" 10ad5fb883SZixuan Wang 11*1ae9072eSZixuan Wang /* 12*1ae9072eSZixuan Wang * efi_bootinfo_t: stores EFI-related machine info retrieved by 13*1ae9072eSZixuan Wang * setup_efi_pre_boot(), and is then used by setup_efi(). setup_efi() cannot 14*1ae9072eSZixuan Wang * retrieve this info as it is called after ExitBootServices and thus some EFI 15*1ae9072eSZixuan Wang * resources are not available. 16*1ae9072eSZixuan Wang */ 17*1ae9072eSZixuan Wang typedef struct { 18*1ae9072eSZixuan Wang phys_addr_t free_mem_start; 19*1ae9072eSZixuan Wang phys_addr_t free_mem_size; 20*1ae9072eSZixuan Wang } efi_bootinfo_t; 21*1ae9072eSZixuan Wang 22*1ae9072eSZixuan Wang void setup_efi_bootinfo(efi_bootinfo_t *efi_bootinfo); 23*1ae9072eSZixuan Wang void setup_efi(efi_bootinfo_t *efi_bootinfo); 24*1ae9072eSZixuan Wang efi_status_t setup_efi_pre_boot(unsigned long *mapkey, efi_bootinfo_t *efi_bootinfo); 25ad5fb883SZixuan Wang #endif /* TARGET_EFI */ 26ad5fb883SZixuan Wang 27dbd38004SZixuan Wang #endif /* _X86_ASM_SETUP_H_ */ 28