summaryrefslogtreecommitdiff
path: root/arch/x86/include/asm/realmode.h
diff options
context:
space:
mode:
authorJarkko Sakkinen <jarkko.sakkinen@intel.com>2012-05-08 22:22:43 +0400
committerH. Peter Anvin <hpa@linux.intel.com>2012-05-08 22:48:45 +0400
commitf37240f16bec91f15ce564515f70a6ca9715ce96 (patch)
treed1e98241650bfed0d87f60e3e71a8ad716782f6d /arch/x86/include/asm/realmode.h
parentc4845474a01f699966272536e8416222e3f2d2cb (diff)
downloadlinux-f37240f16bec91f15ce564515f70a6ca9715ce96.tar.xz
x86, realmode: header for trampoline code
Added header for trampoline code that can be used to supply input data to it. This makes interface between real mode code and kernel cleaner and simpler. Replaced two confusing pointers to level4 pgt in trampoline_64.S with a single pointer to the beginning of the page table. Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@intel.com> Link: http://lkml.kernel.org/r/1336501366-28617-21-git-send-email-jarkko.sakkinen@intel.com Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'arch/x86/include/asm/realmode.h')
-rw-r--r--arch/x86/include/asm/realmode.h32
1 files changed, 20 insertions, 12 deletions
diff --git a/arch/x86/include/asm/realmode.h b/arch/x86/include/asm/realmode.h
index d3ae49f4c3ef..1421eed1c8e8 100644
--- a/arch/x86/include/asm/realmode.h
+++ b/arch/x86/include/asm/realmode.h
@@ -8,25 +8,33 @@
struct real_mode_header {
u32 text_start;
u32 ro_end;
- /* reboot */
-#ifdef CONFIG_X86_32
- u32 machine_real_restart_asm;
-#endif
/* SMP trampoline */
- u32 trampoline_data;
+ u32 trampoline_start;
u32 trampoline_status;
-#ifdef CONFIG_X86_32
- u32 startup_32_smp;
- u32 boot_gdt;
-#else
- u32 startup_64_smp;
- u32 level3_ident_pgt;
- u32 level3_kernel_pgt;
+ u32 trampoline_header;
+#ifdef CONFIG_X86_64
+ u32 trampoline_pgd;
#endif
+ /* ACPI S3 wakeup */
#ifdef CONFIG_ACPI_SLEEP
u32 wakeup_start;
u32 wakeup_header;
#endif
+ /* APM/BIOS reboot */
+#ifdef CONFIG_X86_32
+ u32 machine_real_restart_asm;
+#endif
+} __attribute__((__packed__));
+
+/* This must match data at trampoline_32/64.S */
+struct trampoline_header {
+#ifdef CONFIG_X86_32
+ u32 start;
+ u16 gdt_limit;
+ u32 gdt_base;
+#else
+ u64 start;
+#endif
} __attribute__((__packed__));
extern struct real_mode_header *real_mode_header;