diff options
author | Pavel Machek <pavel@suse.cz> | 2008-04-10 17:28:10 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-04-17 11:41:37 -0400 |
commit | e44b7b7525ad9d43163ab5e60c784325419e0ea6 (patch) | |
tree | e2918917a97b4c9de4367e8778ed78afc762b9f8 /arch/x86/kernel/setup_32.c | |
parent | f49688d459c5eaa62db3597cbfd3cb13e361d415 (diff) |
x86: move suspend wakeup code to C
Move wakeup code to .c, so that video mode setting code can be shared
between boot and wakeup. Remove nasty assembly code in 64-bit case by
re-using trampoline code. Stack setup was fixed to clear high 16bits
of %esp, maybe that fixes some machines.
.c code sharing and morse code was done H. Peter Anvin, Sam Ravnborg
reviewed kbuild related stuff, and it seems okay to him. Rafael did
some cleanups.
[rjw:
* Made the patch stop breaking compilation on x86-32
* Added arch/x86/kernel/acpi/sleep.h
* Got rid of compiler warnings in arch/x86/kernel/acpi/sleep.c
* Fixed 32-bit compilation on x86-64 systems
* Added include/asm-x86/trampoline.h and fixed the non-SMP
compilation on 64-bit x86
* Removed arch/x86/kernel/acpi/sleep_32.c which was not used
* Fixed some breakage caused by the integration of smpboot.c done
under us in the meantime]
Signed-off-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/setup_32.c')
-rw-r--r-- | arch/x86/kernel/setup_32.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/x86/kernel/setup_32.c b/arch/x86/kernel/setup_32.c index 4b198d9d0de3..5b0bffb7fcc9 100644 --- a/arch/x86/kernel/setup_32.c +++ b/arch/x86/kernel/setup_32.c | |||
@@ -192,7 +192,7 @@ EXPORT_SYMBOL(ist_info); | |||
192 | extern void early_cpu_init(void); | 192 | extern void early_cpu_init(void); |
193 | extern int root_mountflags; | 193 | extern int root_mountflags; |
194 | 194 | ||
195 | unsigned long saved_videomode; | 195 | unsigned long saved_video_mode; |
196 | 196 | ||
197 | #define RAMDISK_IMAGE_START_MASK 0x07FF | 197 | #define RAMDISK_IMAGE_START_MASK 0x07FF |
198 | #define RAMDISK_PROMPT_FLAG 0x8000 | 198 | #define RAMDISK_PROMPT_FLAG 0x8000 |
@@ -763,7 +763,7 @@ void __init setup_arch(char **cmdline_p) | |||
763 | edid_info = boot_params.edid_info; | 763 | edid_info = boot_params.edid_info; |
764 | apm_info.bios = boot_params.apm_bios_info; | 764 | apm_info.bios = boot_params.apm_bios_info; |
765 | ist_info = boot_params.ist_info; | 765 | ist_info = boot_params.ist_info; |
766 | saved_videomode = boot_params.hdr.vid_mode; | 766 | saved_video_mode = boot_params.hdr.vid_mode; |
767 | if( boot_params.sys_desc_table.length != 0 ) { | 767 | if( boot_params.sys_desc_table.length != 0 ) { |
768 | set_mca_bus(boot_params.sys_desc_table.table[3] & 0x2); | 768 | set_mca_bus(boot_params.sys_desc_table.table[3] & 0x2); |
769 | machine_id = boot_params.sys_desc_table.table[0]; | 769 | machine_id = boot_params.sys_desc_table.table[0]; |