diff options
author | H. Peter Anvin <hpa@zytor.com> | 2012-05-18 16:26:53 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2012-05-18 16:26:53 -0700 |
commit | a965da4a4fa04471c68d0cbdc91deba61362a160 (patch) | |
tree | 88e6f3ca3cbdac441191ca260f57d83faa96f700 | |
parent | 06531db8ec5d58477d7083d3d8130e909206233f (diff) | |
download | syslinux-a965da4a4fa04471c68d0cbdc91deba61362a160.tar.gz syslinux-a965da4a4fa04471c68d0cbdc91deba61362a160.tar.xz syslinux-a965da4a4fa04471c68d0cbdc91deba61362a160.zip |
syslinux_boot_linux(): revert to text mode unless vga=current
When loading a Linux kernel, revert to text mode before invoking
unless vga=current.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r-- | com32/lib/syslinux/load_linux.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/com32/lib/syslinux/load_linux.c b/com32/lib/syslinux/load_linux.c index 45cd6965..e5fd3333 100644 --- a/com32/lib/syslinux/load_linux.c +++ b/com32/lib/syslinux/load_linux.c @@ -466,6 +466,17 @@ int syslinux_boot_linux(void *kernel_buf, size_t kernel_size, dprintf("Initial movelist:\n"); syslinux_dump_movelist(fraglist); + if (video_mode != 0x0f04) { + /* + * video_mode is not "current", so if we are in graphics mode we + * need to revert to text mode... + */ + dprintf("*** Calling vgaclearmode()...\n"); + vgaclearmode(); + } else { + dprintf("*** vga=current, not calling vgaclearmode()...\n"); + } + syslinux_shuffle_boot_rm(fraglist, mmap, 0, ®s); bail: |