[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <86802c440611042315m2c923fccmeec6b3fa1448780a@mail.gmail.com>
Date: Sat, 4 Nov 2006 23:15:57 -0800
From: "Yinghai Lu" <yinghai.lu@....com>
To: "Eric W. Biederman" <ebiederm@...ssion.com>
Cc: "Andi Kleen" <ak@...e.de>, Horms <horms@...ge.net.au>,
"Jan Kratochvil" <lace@...kratochvil.net>,
"H. Peter Anvin" <hpa@...or.com>,
"Magnus Damm" <magnus.damm@...il.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 32/33] x86_64: Relocatable kernel support
On 11/4/06, Eric W. Biederman <ebiederm@...ssion.com> wrote:
> If you are booting a vmlinux you read the ELF header. The ELF header
> only describes the native mode. Therefore no 32bit entry makes much sense.
>
Yes, but if you keep the startup_32 and it will be at 0x200000, and
startup_64 will be 0x200100. and entry point in ELF header is
0x200100.
by removing startup_32, startup_64 will be 0x200000. and entry point
in ehdr is 0x200000.
So I assume entry_point in elf_header could be used by 64bit
bootloader and phdr[1].p_addr could be used by 32bit boot loader.
YH
ELF Header:
Magic: 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00
Class: ELF64
Data: 2's complement, little endian
Version: 1 (current)
OS/ABI: UNIX - System V
ABI Version: 0
Type: EXEC (Executable file)
Machine: Advanced Micro Devices X86-64
Version: 0x1
Entry point address: 0x200100
Start of program headers: 64 (bytes into file)
Start of section headers: 7192496 (bytes into file)
Flags: 0x0
Size of this header: 64 (bytes)
Size of program headers: 56 (bytes)
Number of program headers: 5
Size of section headers: 64 (bytes)
Number of section headers: 42
Section header string table index: 39
Program Headers:
Type Offset VirtAddr PhysAddr
FileSiz MemSiz Flags Align
LOAD 0x0000000000100000 0xffffffff80200000 0x0000000000200000
0x000000000032f508 0x000000000032f508 R E 100000
LOAD 0x0000000000430000 0xffffffff80530000 0x0000000000530000
0x0000000000148ec8 0x0000000000148ec8 RWE 100000
LOAD 0x0000000000600000 0xffffffffff600000 0x0000000000679000
0x0000000000000c08 0x0000000000000c08 RWE 100000
LOAD 0x000000000067a000 0xffffffff8067a000 0x000000000067a000
0x000000000005dd68 0x00000000000e91c8 RWE 100000
NOTE 0x0000000000000000 0x0000000000000000 0x0000000000000000
0x0000000000000000 0x0000000000000000 R 8
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists