metalsvm/link64.ld
Stefan Lankes 227cc19890 add alpha version of x64 support
New features:
- support of kernel tasks in 64bit mode
- support of LwIP in 64bit mode

Missing features in 64bit mode
- user-level support
- APIC support => SMP support

To create a 64bit version of the MetalSVM kernel, the compiler flags “-m64 -mno-red-zone” and the assembler flags “-felf64” has to be used. Please use qemu-system-x86_64 as test platform.

Notice, metalsvm.elf is a 32bit ELF file. However, it contains (beside the startup code) only 64bit code. This is required because GRUB doesn’t boot 64bit ELF kernels. Therefore, for disassembling via objdump the flag  “-M x86-64” has to be used.
2012-06-10 08:05:24 +02:00

29 lines
496 B
Text

OUTPUT_FORMAT("elf64-x86-64")
OUTPUT_ARCH("i386:x86-64")
ENTRY(start)
phys = 0x000000100000;
SECTIONS
{
kernel_start = phys;
.mboot phys : AT(ADDR(.mboot)) {
*(.mboot)
*(.kmsg)
}
.text ALIGN(4096) : AT(ADDR(.text)) {
*(.text)
}
.rodata ALIGN(4096) : AT(ADDR(.rodata)) {
*(.rodata)
*(.rodata.*)
}
.data ALIGN(4096) : AT(ADDR(.data)) {
*(.data)
}
.bss ALIGN(4096) : AT(ADDR(.bss)) {
bss_start = .;
*(.bss)
}
bss_end = .;
kernel_end = .;
}