[U-Boot] Fw: FDT pointer value, passed by the PI firmware, is not set in u-boot

dh at synoia.com dh at synoia.com
Tue Sep 20 05:50:59 CEST 2016


I modified the current u-boot code to store r2 in rpi.c board_init, but only get a zero value from the register.

It could be one of three issues:
1. My use of the c asm statement  to store r2 is wrong (I've never done this before), assembler yes, c assembler no.
2. The compiler has consumed the value of r2 before getting to board_init
3. The pi firmware does not put the fdt value in r2.

asm statement to store r2 is asm("mov %%r2, %0" : "=r" (gd->bd->bpi_boot_parms) ); 

In order to use up Marco's ATAG and FDT code.

What the earliest place where I can store the input r2 value?
Hopefully, I'm putting the r2 value into gd->bd->bpi_boot_parms in board_init, but it appear it is zero at that point.

Should I restrict the compiler's use of r2? (I'm reluctant to limit the compiler in that manner)?

Suggestion would be welcome.

Thanks Duncan Hare

714 931 7952

   

   

   


More information about the U-Boot mailing list