[U-Boot] [PATCH v2 3/7] stm32: stm32f7: add spl build support

Robert Nelson robertcnelson at gmail.com
Thu Aug 10 18:36:36 UTC 2017


On Thu, Aug 10, 2017 at 1:10 PM, Vikas Manocha <vikas.manocha at st.com> wrote:
> One other point,
>
> On 08/10/2017 11:07 AM, Vikas Manocha wrote:
>> Hi Robert,
>>
>> On 08/10/2017 11:03 AM, Robert Nelson wrote:
>>> Hi Vikas,
>>>
>>> On Sun, May 28, 2017 at 2:55 PM, Vikas Manocha <vikas.manocha at st.com> wrote:
>>>> This commit supports booting from stm32 internal nor flash. spl U-Boot
>>>> initializes the sdram memory, copies next image (e.g. standard U-Boot)
>>>> to sdram & then jumps to entry point.
>>>>
>>>> Here are the flash memory addresses for U-Boot-spl & standard U-Boot:
>>>>         - spl U-Boot            : 0x0800_0000
>>>>         - standard U-Boot       : 0x0800_8000
>>>
>>> Is there another patchset missing on mainline for booting via spl?
>>
>> No, you just need to flash spl & next image at above mentioned addresses. By default spl expects kernel image.
>>
>> To boot u-boot, press keyboard character 'c'.
>> you might need to keep on pressing 'c' it for some time as the keyboard entry acceptance & detection window is very small.
>>
>> Cheers,
>> Vikas
>>
>>>
>>> on mainline with the stm32f746-disco board:
>>>
>>> U-Boot SPL 2017.09-rc1-00177-gd529124fdc (Aug 10 2017 - 12:33:35)
>>> Trying to boot from XIP
>>> Hard fault
>>> pc : 08008008    lr : 08000adb    xPSR : 21000000
>>> r12 : 2004f338   r3 : 00000005    r2 : 081c0000
>>> r1 : ffffff9a    r0 : 00000000
>>> Resetting CPU ...
>>>
>>> resetting ...
>>>
>>> I'm using openocd to program
>>>
>>> openocd -f board/stm32f7discovery.cfg \
>>>   -c "init" \
>>>   -c "reset init" \
>>>   -c "flash probe 0" \
>>>   -c "flash write_image erase ./spl/u-boot-spl.bin 0x08000000" \
>>>   -c "flash write_image erase ./u-boot.img 0x08008000" \
>
> it should be u-boot-dtb.bin.

Bingo!

Thanks Vikas!!

U-Boot SPL 2017.09-rc1-00177-gd529124fdc (Aug 10 2017 - 12:33:35)
Trying to boot from XIP


U-Boot 2017.09-rc1-00177-gd529124fdc (Aug 10 2017 - 12:33:35 -0500)

Model: STMicroelectronics STM32F746-DISCO board
DRAM:  8 MiB
Flash: 1 MiB
Using default environment

In:    serial at 40011000
Out:   serial at 40011000
Err:   serial at 40011000
usr button is at LOW LEVEL
Net:
Warning: ethernet at 40028000 (eth0) using random MAC address - 02:4a:de:c3:c8:80
eth0: ethernet at 40028000
Hit SPACE in 3 seconds to stop autoboot.
U-Boot >

Regards,

-- 
Robert Nelson
https://rcn-ee.com/


More information about the U-Boot mailing list