building RaspPi Images

Warner Losh imp at bsdimp.com
Mon Feb 11 03:49:28 UTC 2013


On Feb 10, 2013, at 5:39 PM, Tim Kientzle wrote:

> On Feb 10, 2013, at 6:56 AM, Warner Losh wrote:
>> 
>> Right, we're doing it wrong. Or rather, we're using the standalone interface when we should be using the linux interface.
> 
> So you think that ubldr should startup like a Linux kernel?
> That's an interesting idea…  Hmmmm…..

If it isn't getting the FDT via the alternate interface, then yes.

>> The stand alone interface should, in theory, provide us with the DTB, but the code that is in ubldr doesn't seem to be reliably getitng this image.
> 
> I don't think anyone has spent time on this.  We've
> just been focused on "making it work" and the compiled-in
> DTB does work for any single board.

Ah, that makes sense. I just know the theory, not the practice.  I haven't had time for armv6 stuff...

>> uboot is supposed pass dtb to us. We're using the self-hosted interface, rather than the linux interface, to boot. uboot is supposed to have a jump table that we find and use to get the dtb from it, but that code seems to not be working reliably.
> 
> The interface works (I've spent a fair few hours fixing it),
> but I don't think anyone has tried getting the DTB from it.

We should try...

> Any ideas for addressing the load-address problem?
> E.g., RPi has initial RAM mapped starting at address 0
> and BeagleBone starts with RAM mapped to 0x80000000.
> Right now, that means we can't even share ubldr across
> those two systems because it has to be linked differently.

I'm unsure how Linux deals with it...  I'm guessing that if we can turn on the vm translation early enough, then this won't matter...

>> uboot gives linux images the DTB w/o any problem today, but you have to run mkimage to get the image file to load into uboot for that to work.
> 
> Actually, the statement above isn't quite right for RPi.
> Linux on RPi doesn't use U-Boot.

Well, all Linux kernels require DTBs today, although some compile it into the image...

> So we're currently
> using:
> 
> RPi boot loader => U-Boot => ubldr => kernel.
> 
> The RPi boot loader does load the FDT and will pass
> it to a Linux kernel, but I don't think U-Boot implements
> that part of the linux kernel startup (which is why ubldr
> on RPi looks at a particular address in RAM to get
> the FDT from the RPi boot loader).

Ah, it implements the standard interface. That should be an option, since it is relatively easy to do.

Maybe I should give in and get a RPi :)

Warner



More information about the freebsd-arm mailing list