Spear machines currently have only the possibility to boot from NOR while an interesting alternative exist: booting from USB. For this, the BootROM will enumerate an USB device and wait for a RAM driver (likely, the SPL). It will load the driver in SRAM and jump to it. Once the initialization done, the SPL must return back into the BootROM so that another enumeration occurs allowing the user to upload the full Bootloader (eg. U-Boot). The BootROM will finally load the file in RAM and jump into it.
Most of the patches are cleanups and preparation work to ease the reading of the main assembly file. The last patch is a fallback on USB Boot if the NOR is empty or corrupted. Of course if USB boot has not been enabled, nothing will happen. Tested on a custom board featuring a SPEAr600. Hope this change will find users! Thanks, Miquèl Miquel Raynal (12): spl: Fix typo in kernel doc arm: spear: Drop useless board_init_r call arm: spear: Call the SPL 'SPL', not 'Xloader' arm: spear: Drop false comment arm: spear: Fix the main comment in start.S arm: spear: Purely cosmetic changes in start.S arm: spear: Use PUSH/POP mnemonics when relevant arm: spear: Reference the link register with LR instead of R14 arm: spear: Simplify start.S organization arm: spear: Support returning to BootROM arm: spear: Do not link the _main branch arm: spear: Return to BootROM if failing to boot from the main device arch/arm/cpu/arm926ejs/spear/spl.c | 47 +++++++++++++++++++++-- arch/arm/cpu/arm926ejs/spear/start.S | 56 +++++++++++----------------- common/spl/spl.c | 2 +- 3 files changed, 66 insertions(+), 39 deletions(-) -- 2.19.1 _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot