2008-03-21 07:23:19 -07:00
|
|
|
#include <linux/io.h>
|
|
|
|
|
|
|
|
#include <asm/trampoline.h>
|
|
|
|
|
2008-05-18 01:18:57 -07:00
|
|
|
/* ready for x86_64 and x86 */
|
2008-03-21 07:23:19 -07:00
|
|
|
unsigned char *trampoline_base = __va(TRAMPOLINE_BASE);
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Currently trivial. Write the real->protected mode
|
|
|
|
* bootstrap into the page concerned. The caller
|
|
|
|
* has made sure it's suitably aligned.
|
|
|
|
*/
|
|
|
|
unsigned long setup_trampoline(void)
|
|
|
|
{
|
|
|
|
memcpy(trampoline_base, trampoline_data,
|
|
|
|
trampoline_end - trampoline_data);
|
|
|
|
return virt_to_phys(trampoline_base);
|
|
|
|
}
|