[U-Boot] FEL mode broken since "sunxi: Move all boards to the driver-model"

Hi Hans,
Sorry for only just noticing this, but it looks like FEL mode doesn't work on my cubietruck since this commit. I get the SPL output:
U-Boot SPL 2015.04-00665-gb6006ba (Jun 26 2015 - 20:38:50) DRAM: 2048 MiB CPU: 912000000Hz, AXI/AHB/APB: 3/2/2
But then nothing.
Or have I missed some change in how I should be using it?
Later versions (with CONFIG_FEL gone) exhibit similar behaviour when using the new "spl fel" method too, so I got that memo at least...
u-boot-sunxi.git#next has the issue too.
Do you know what this is likely to be or shall I try and find some time to investigate?
Ian.

Hi,
On 26-06-15 21:50, Ian Campbell wrote:
Hi Hans,
Sorry for only just noticing this, but it looks like FEL mode doesn't work on my cubietruck since this commit. I get the SPL output:
U-Boot SPL 2015.04-00665-gb6006ba (Jun 26 2015 - 20:38:50) DRAM: 2048 MiB CPU: 912000000Hz, AXI/AHB/APB: 3/2/2
But then nothing.
Right, that is expected, all the "fel spl" command does is load the spl, you need to do something like this to fel boot:
sudo ~hans/bin/fel version echo Write SPL sudo ~hans/bin/fel spl u-boot-sunxi-with-spl.bin echo Exec SPL sudo ~hans/bin/fel exe 0x2000 sleep 0.5 echo Write u-boot sudo ~hans/bin/fel write 0x4a000000 u-boot-dtb.bin echo Exec u-boot sudo ~hans/bin/fel exe 0x4a000000
Are you doing that ? Also note that you now need to use u-boot-dtb.bin not u-boot.bin .
Or have I missed some change in how I should be using it?
Later versions (with CONFIG_FEL gone) exhibit similar behaviour when using the new "spl fel" method too, so I got that memo at least...
u-boot-sunxi.git#next has the issue too.
Do you know what this is likely to be
See above.
or shall I try and find some time to investigate?
If that is not it it would be greay if you can find some time to investigate this.
Regards,
Hans

On Sun, 2015-06-28 at 17:28 +0200, Hans de Goede wrote:
Hi,
On 26-06-15 21:50, Ian Campbell wrote:
Hi Hans,
Sorry for only just noticing this, but it looks like FEL mode doesn't work on my cubietruck since this commit. I get the SPL output:
U-Boot SPL 2015.04-00665-gb6006ba (Jun 26 2015 - 20:38:50) DRAM: 2048 MiB CPU: 912000000Hz, AXI/AHB/APB: 3/2/2
But then nothing.
Right, that is expected, all the "fel spl" command does is load the spl,
Ah, I had (naïvely?) expected that since it took u-boot-sunxi-with-spl.bin as an argument it would do the second half too.
I would have expected this to become necessary at with "sunxi: Support the FEL boot mode in the regular u-boot build" rather than at "sunxi: Move all boards to the driver-model".
Anyway, I'll try your suggested path tonight. I'm pretty certain that'll end up being it.
Also note that you now need to use u-boot-dtb.bin not u-boot.bin .
Noted, I probably would have got that wrong too, so thanks.
Ian.

Ian Campbell <ijc+uboot <at> hellion.org.uk> writes:
I would have expected this to become necessary at with "sunxi: Support the FEL boot mode in the regular u-boot build" rather than at "sunxi: Move all boards to the driver-model".
Anyway, I'll try your suggested path tonight. I'm pretty certain that'll end up being it.
Also note that you now need to use u-boot-dtb.bin not u-boot.bin .
Noted, I probably would have got that wrong too, so thanks.
Ian.
I've fooled myself on this too - and thought it to be a problem in the SPL -> main U-Boot transition. Of course I had not adapted my FEL script, and missed the u-boot-dtb.bin requirement.
After the necessary adjustments U-Boot (v2015.07-rc2) starts just fine via FEL. This should probably be improved in sunxi-tools, so the 'fel' utility gracefully handles both parts of the u-boot-sunxi-with-spl.bin.
Regards, B. Nortmann

On Sun, 2015-06-28 at 17:28 +0200, Hans de Goede wrote:
Right, that is expected, all the "fel spl" command does is load the spl, you need to do something like this to fel boot:
This worked, thanks. Couple of notes:
sudo ~hans/bin/fel version echo Write SPL sudo ~hans/bin/fel spl u-boot-sunxi-with-spl.bin
FWIW also works with spl/sunxi-spl.bin.
echo Exec SPL sudo ~hans/bin/fel exe 0x2000
Doesn't seem to be needed, it's done part of the above the above spl command.
sleep 0.5 echo Write u-boot sudo ~hans/bin/fel write 0x4a000000 u-boot-dtb.bin echo Exec u-boot sudo ~hans/bin/fel exe 0x4a000000
I think it ought to be possible to update the usb-boot script to use "fel spl" and relax the SPL size restriction in that script accordingly, I'll take a look.
Ian.

Hi Ian / Hans,
On 30 June 2015 at 01:33, Ian Campbell ijc+uboot@hellion.org.uk wrote:
On Sun, 2015-06-28 at 17:28 +0200, Hans de Goede wrote:
Right, that is expected, all the "fel spl" command does is load the spl, you need to do something like this to fel boot:
This worked, thanks. Couple of notes:
sudo ~hans/bin/fel version echo Write SPL sudo ~hans/bin/fel spl u-boot-sunxi-with-spl.bin
FWIW also works with spl/sunxi-spl.bin.
echo Exec SPL sudo ~hans/bin/fel exe 0x2000
Doesn't seem to be needed, it's done part of the above the above spl command.
sleep 0.5 echo Write u-boot sudo ~hans/bin/fel write 0x4a000000 u-boot-dtb.bin echo Exec u-boot sudo ~hans/bin/fel exe 0x4a000000
I think it ought to be possible to update the usb-boot script to use "fel spl" and relax the SPL size restriction in that script accordingly, I'll take a look.
Ian.
It would be nice to have a doc/README.sunxi or similar which describes how to use FEL and how to create a bootable SD card.
Regards, Simon
participants (4)
-
Bernhard Nortmann
-
Hans de Goede
-
Ian Campbell
-
Simon Glass