aboutsummaryrefslogtreecommitdiffstats
path: root/unmodified_drivers/linux-2.6/platform-pci/panic-handler.c
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2008-02-01 11:16:37 +0000
committerKeir Fraser <keir.fraser@citrix.com>2008-02-01 11:16:37 +0000
commit042397126c8e75019b4c74483d7bfdff7f501a0a (patch)
treeb5a27ec4a9c2f680b34cb155ff0eddc72a11c4dd /unmodified_drivers/linux-2.6/platform-pci/panic-handler.c
parentbd03fbb90e6bfcbed2f71a4ef815840f86e66136 (diff)
downloadxen-042397126c8e75019b4c74483d7bfdff7f501a0a.tar.gz
xen-042397126c8e75019b4c74483d7bfdff7f501a0a.tar.bz2
xen-042397126c8e75019b4c74483d7bfdff7f501a0a.zip
Direct Linux boot: Support booting non-relocatable Linux kernels.
This patch introduces a hack to make non-relocatable kernels bootable too. Non-relocatable kernels absolutely want to run at 0x100000 and are not at all happy about being at 0x200000. Fortunately, thanks to crazy programs like LOADLIN, Linux has a couple of hooks in its boot process which can be used to play games. The 'code32_switch' hook is executed immediately following the switch to protected mode. So, this patch installs a hook at 0x200000+kernel_size. The hook is hand crafted assembly which sets up all the segments as needed, then essentially does memmove(0x100000,0x200000,kernel_size) and finally does an unconditional jmp to 0x100000. Amazingly this actually really does work. It has been successfully tested with RHEL-2.1 and Fedora Core 6 install kernels on i386, and Fedora Core 6 and 7 kernels on x86_64. Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'unmodified_drivers/linux-2.6/platform-pci/panic-handler.c')
0 files changed, 0 insertions, 0 deletions