Generating elf kernel ?
tiejun.chen at windriver.com
Fri Sep 17 11:58:41 EST 2010
Scott Wood wrote:
> On Thu, 16 Sep 2010 10:37:32 +0800
> "tiejun.chen" <tiejun.chen at windriver.com> wrote:
>> 1> can you load the Linux vmlinux directly to the physical address '0' on
>> current bootloader?
> That depends on what bootloader we're talking about -- I don't know
> what the original poster's custom loader can do. Obviously the
> bootloader itself would have to be executing from some other address
> (e.g. U-Boot runs from the top of RAM).
>> 2> additionally you have to find a way to pass dtb to the native vmlinux.
> Yes, of course. But that's a different issue. :-)
>> I believe the hypervisor can boot vmlinux directly. But your so-called vmlinux
>> should be guest OS. And the hypervisor will handle/assit TLB exception for the
>> guest OS on MMU. Right? So you can use the hypervisor to load vmlinux to any
>> physical address as you expect.
> I was just using our hypervisor as an example, since it has an ELF
> loader that can pass a device tree.
>> But the guest OS should not be same as the native Linux.
> The guest OS *is* the same as native Linux, as far as TLB handling is
Looks you means the TLB exception handler should be same between the native and
the guest OS. Right?
Here I assume we're talking about e500mc since as far as I know for Freescale
only e500mc is designed to support virtual machine based on ISA 2.0.6.
I also know all TLB exceptions can direct to the guest OS when we enable
EPCR[DTLBGS|ITLBGS|DSIGS|ISIGS]. But some TLB instructions (i.e. tlbwe )are the
privileged instructions. So the guest OS always trap into the hypervisor and
then the hypervisor should complete the real action with appropriate physical
address. And also the hypervisor can supervisor if the guest OS want to access
the invalid physical space.
So I don't think the guest OS is same as native Linux :)
More information about the Linuxppc-dev