[U-Boot] u-boot for SPEAr1310

Hello!
Is there git tree with u-boot for SPEAr1310 somewhere? I only seen patches from 2010... Is there easy way to flash resulting u-boot using BDI?
Thanks, Pavel

Hi Pavel,
(Added Amit to Cc).
On Thursday 23 February 2012 15:17:19 Pavel Machek wrote:
Is there git tree with u-boot for SPEAr1310 somewhere? I only seen patches from 2010...
Here a link to the ST git repository:
git://stlinux.com/spear/u-boot.git
Most branches are not based on current mainline U-Boot version though. ST people might have a better overview here.
Please note that there is currently ongoing effort to port much of this repository into mainline. From ST and from myself. Stay tuned. The list should see some updates quite soon...
Please don't hesitate if you have any specific questions.
Is there easy way to flash resulting u-boot using BDI?
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM. SPEAr600 uses XLoader as SPL. I ported U-Boot SPL for SPEAr600 though, completely obsoleting XLoader. Patches are not quite ready for the list though.
Best regards, Stefan
-- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office@denx.de

Hi Pavel,
(Added Amit to Cc).
On Thursday 23 February 2012 15:17:19 Pavel Machek wrote:
Is there git tree with u-boot for SPEAr1310 somewhere? I only seen patches from 2010...
Here a link to the ST git repository:
git://stlinux.com/spear/u-boot.git
Most branches are not based on current mainline U-Boot version though. ST people might have a better overview here.
Please note that there is currently ongoing effort to port much of this repository into mainline. From ST and from myself. Stay tuned. The list should see some updates quite soon...
Please don't hesitate if you have any specific questions.
Is there easy way to flash resulting u-boot using BDI?
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM.
I believe the spear600 is totally different from 1300. But, simple:
reset halt ; load ... ; go ...
combo should work I believe. In case you're loading some U-Boot SPL, it's very good idea to put an "asm volatile("x : b x");" line into the SPL to make the CPU loop instead of try loading uboot. Since if the CPU is looping, you can break it with BDI, if it isn't looping and jumps to some garbage, it usually ends in undefined state and bootrom might further tamper with the CPU configuration.
M
SPEAr600 uses XLoader as SPL. I ported U-Boot SPL for SPEAr600 though, completely obsoleting XLoader. Patches are not quite ready for the list though.
Best regards, Stefan
-- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office@denx.de _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot

On Thursday 23 February 2012 15:49:02 Marek Vasut wrote:
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM.
I believe the spear600 is totally different from 1300. But, simple:
reset halt ; load ... ; go ...
combo should work I believe. In case you're loading some U-Boot SPL, it's very good idea to put an "asm volatile("x : b x");" line into the SPL to make the CPU loop instead of try loading uboot. Since if the CPU is looping, you can break it with BDI, if it isn't looping and jumps to some garbage, it usually ends in undefined state and bootrom might further tamper with the CPU configuration.
Yes, good point. But a "STARTUP RESET ;no code is executed after reset" seems to solve this problem as well. At least for me on SPEAr600. I know. Since I broke my SPL from time to time. ;)
Best regards, Stefan
-- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office@denx.de

On Thursday 23 February 2012 15:49:02 Marek Vasut wrote:
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM.
I believe the spear600 is totally different from 1300. But, simple:
reset halt ; load ... ; go ...
combo should work I believe. In case you're loading some U-Boot SPL, it's very good idea to put an "asm volatile("x : b x");" line into the SPL to make the CPU loop instead of try loading uboot. Since if the CPU is looping, you can break it with BDI, if it isn't looping and jumps to some garbage, it usually ends in undefined state and bootrom might further tamper with the CPU configuration.
Yes, good point. But a "STARTUP RESET ;no code is executed after reset" seems to solve this problem as well. At least for me on SPEAr600. I know. Since I broke my SPL from time to time. ;)
Ah that's good idea indeed, though sometimes you might want to break the execution after the BootROM, since bootrom might be doing some mandatory chip init.
M
Best regards, Stefan
-- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office@denx.de

Hi!
On Thu 2012-02-23 15:49:02, Marek Vasut wrote:
On Thursday 23 February 2012 15:17:19 Pavel Machek wrote:
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM.
I believe the spear600 is totally different from 1300. But, simple:
reset halt ; load ... ; go ...
combo should work I believe. In case you're loading some U-Boot SPL, it's very
I have a problem here: "reset halt" does not reset the board; probably some kind of BDI problem. I tried playing with BDI config, but was not successful.
I tried to load u-boot from u-boot using:
u-boot> tftp 0x00700000 192.168.1.1:/spear1310eval/u-boot.bin
Using mii0 device TFTP from server 192.168.1.1; our IP address is 192.168.20.47 Filename '/spear1310eval/u-boot.bin'. Load address: 0x700000 Loading: ############## done Bytes transferred = 193032 (2f208 hex) u-boot> go 0x00700000 ## Starting application at 0x00700000 ...
U-Boot 2010.03-lsp-3.0-rc7 (Sep 15 2011 - 13:52:19) SPEAr-emlix-CCLite-BSP-0.11
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
Any ideas? Pavel

Hi Pavel,
On Friday 24 February 2012 19:16:46 Pavel Machek wrote:
I have a problem here: "reset halt" does not reset the board; probably some kind of BDI problem. I tried playing with BDI config, but was not successful.
I tried to load u-boot from u-boot using:
u-boot> tftp 0x00700000 192.168.1.1:/spear1310eval/u-boot.bin
Using mii0 device TFTP from server 192.168.1.1; our IP address is 192.168.20.47 Filename '/spear1310eval/u-boot.bin'. Load address: 0x700000 Loading: ############## done Bytes transferred = 193032 (2f208 hex) u-boot> go 0x00700000 ## Starting application at 0x00700000 ...
U-Boot 2010.03-lsp-3.0-rc7 (Sep 15 2011 - 13:52:19) SPEAr-emlix-CCLite-BSP-0.11
Not bad so far. :)
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
A few thoughts: - Is this the original (installed in flash) image or different one? - If it is a new image, did you try booting the original U-Boot version this way as well? - Are the load and start addresses ok? Did you check this with the original images (iminfo)?
Sorry, no more time mow. Into the weekend... ;)
Cheers, Stefan

Hello Pavel,
Not bad so far. :)
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
Yes, the u-boot resets itself. This is a workaround of a known problem The code lies at arch/arm/cpu/arm_cortexa8/spear13xx/cpu.c search for config_spear1300_issue_101435.
It can be disabled during development
Regards Vipin

Hi!
On Thu 2012-02-23 15:49:02, Marek Vasut wrote:
On Thursday 23 February 2012 15:17:19 Pavel Machek wrote:
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM.
I believe the spear600 is totally different from 1300. But, simple:
reset halt ; load ... ; go ...
combo should work I believe. In case you're loading some U-Boot SPL,
it's very
I have a problem here: "reset halt" does not reset the board; probably some kind of BDI problem. I tried playing with BDI config, but was not successful.
I tried to load u-boot from u-boot using:
u-boot> tftp 0x00700000 192.168.1.1:/spear1310eval/u-boot.bin
Using mii0 device TFTP from server 192.168.1.1; our IP address is 192.168.20.47 Filename '/spear1310eval/u-boot.bin'. Load address: 0x700000 Loading: ############## done Bytes transferred = 193032 (2f208 hex) u-boot> go 0x00700000 ## Starting application at 0x00700000 ...
U-Boot 2010.03-lsp-3.0-rc7 (Sep 15 2011 - 13:52:19) SPEAr-emlix-CCLite-BSP-0.11
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
Well yea, loading uboot from uboot isn't supported.
Any ideas? Pavel

On Friday 24 February 2012 19:37:45 Marek Vasut wrote:
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
Well yea, loading uboot from uboot isn't supported.
Not officially, yes. But for U-Boot images that are loaded via SPL into already configured SDRAM it might work. At least it does for me on SPEAr600:
U-Boot 2011.12-00388-g0166e9b (Feb 24 2012 - 15:28:17)-SPEAr
CPU: SPEAr600 I2C: ready DRAM: 128 MiB WARNING: Caches not enabled Flash: 512 KiB NAND: 128 MiB Net: mii0 Hit SPACE in 3 seconds to stop autoboot. x500> tftp 800040 x500/u-boot.bin Waiting for PHY auto negotiation to complete... done ENET Speed is 1000 Mbps - FULL duplex connection Using mii0 device TFTP from server 10.0.0.152; our IP address is 10.0.0.246 Filename 'x500/u-boot.bin'. Load address: 0x800040 Loading: ######################### done Bytes transferred = 364352 (58f40 hex) x500> go 800040 ## Starting application at 0x00800040 ...
U-Boot 2011.12-00388-g0166e9b (Feb 24 2012 - 19:43:40)-SPEAr
CPU: SPEAr600 I2C: ready DRAM: 128 MiB WARNING: Caches not enabled Flash: 512 KiB NAND: 128 MiB Net: mii0 Hit SPACE in 3 seconds to stop autoboot. x500>
Important it the load and start address of course.
Now I'm really off for the weekend! Stefan

Hi!
On Fri 2012-02-24 19:46:50, Stefan Roese wrote:
On Friday 24 February 2012 19:37:45 Marek Vasut wrote:
...it started something. According to gdb it looks like "new" u-boot executes briefly, but fails in C code while processing intialization, and it seems that "old" u-boot takes over. (Some kind of failure and board resets itself?).
Well yea, loading uboot from uboot isn't supported.
Not officially, yes. But for U-Boot images that are loaded via SPL into already configured SDRAM it might work. At least it does for me on SPEAr600:
U-Boot 2011.12-00388-g0166e9b (Feb 24 2012 - 15:28:17)-SPEAr
Just... I got it working after all the help on the list. Thanks for the hints! Pavel

On 2/23/2012 8:12 PM, Stefan Roese wrote:
Hi Pavel,
Hello Pavel,
(Added Amit to Cc).
On Thursday 23 February 2012 15:17:19 Pavel Machek wrote:
Is there git tree with u-boot for SPEAr1310 somewhere? I only seen patches from 2010...
Here a link to the ST git repository:
git://stlinux.com/spear/u-boot.git
Most branches are not based on current mainline U-Boot version though. ST people might have a better overview here.
Please note that there is currently ongoing effort to port much of this repository into mainline. From ST and from myself. Stay tuned. The list should see some updates quite soon...
Please don't hesitate if you have any specific questions.
Is there easy way to flash resulting u-boot using BDI?
My experience is mostly SPEAr600 only right now. Not sure if there are bigger differences between those SoC's in the BootROM. SPEAr600 uses XLoader as SPL.
The case is same with spear1310. It needs an Xloader to boot. The differences are a dual core CortexA9 CPU and more peripherals.
The uboot present at "git://stlinux.com/spear/u-boot.git" supports spear1310.
Please have a look and revert back if you have any doubt
I ported U-Boot SPL for SPEAr600 though, completely obsoleting XLoader. Patches are not quite ready for the list though.
Thanks Stefan. I have been thinking of doing the same for a long time now.
Regards Vipin'
Best regards, Stefan
-- DENX Software Engineering GmbH, MD: Wolfgang Denk& Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office@denx.de .
participants (4)
-
Marek Vasut
-
Pavel Machek
-
Stefan Roese
-
Vipin Kumar