3 #include <asm/trampoline.h>
6 #if defined(CONFIG_X86_64) && defined(CONFIG_ACPI_SLEEP)
8 #define __trampinitdata
10 #define __trampinit __cpuinit
11 #define __trampinitdata __cpuinitdata
14 /* ready for x86_64 and x86 */
15 unsigned char *__trampinitdata trampoline_base
= __va(TRAMPOLINE_BASE
);
17 void __init
reserve_trampoline_memory(void)
21 * But first pinch a few for the stack/trampoline stuff
22 * FIXME: Don't need the extra page at 4K, but need to fix
23 * trampoline before removing it. (see the GDT stuff)
25 reserve_early(PAGE_SIZE
, PAGE_SIZE
+ PAGE_SIZE
, "EX TRAMPOLINE");
27 /* Has to be in very low memory so we can execute real-mode AP code. */
28 reserve_early(TRAMPOLINE_BASE
, TRAMPOLINE_BASE
+ TRAMPOLINE_SIZE
,
33 * Currently trivial. Write the real->protected mode
34 * bootstrap into the page concerned. The caller
35 * has made sure it's suitably aligned.
37 unsigned long __trampinit
setup_trampoline(void)
39 memcpy(trampoline_base
, trampoline_data
, TRAMPOLINE_SIZE
);
40 return virt_to_phys(trampoline_base
);