LS1028ARDB I2C eeprom: how to load the RCW and the bootloaders

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LS1028ARDB I2C eeprom: how to load the RCW and the bootloaders

2,026 Views
imuguruza
Contributor III

Hi, I would like to know how can I load in the I2C eeprom the RCW and the BLs in order to boot the board from this source.

I have found this thread: https://community.nxp.com/t5/QorIQ/LS1028-RCW-generation-to-boot-from-I2C-EEPROM-to-NOR-Flash/m-p/14..., but I got stucked too.

I would like to know which version of the BL2 I need to load, bl2_emmc, bl2_sd,... but in my Yocto compilation bl2_i2c does not appear.

Do I need to change something in order to generate this? Or it is not necessary?

Thanks,

imuguruza

0 Kudos
8 Replies

1,237 Views
imuguruza
Contributor III

Hi again,

It has been time since I have tried this but it does not work.

I have been checking the I2C signals in the connector J26. When I boot up the board, I only see one I2C command. This command is a write request to the 0x50 address. It has no ACK from the EEPROM:

i2c_eeprom.png

 

This means the I2C multiplexor is not well configured and it is not connecting to its bus 0, where the EEPROM is attached...

I believe the CPLD should configure this device in order to enable the path from the LS to the EEPROM.

 

Is there any workaround to make it work? Is this a known issue?

Thanks,

imuguruza

0 Kudos

1,983 Views
imuguruza
Contributor III

Hi,

Thanks for your support.

It looks like when I execute:

=> i2c write 0xa0000000 0x50 0x400.2 0x13431

The processor gets hung up, so I am not sure if the bl2 binary is properly flahsed in the eeprom...

I have written the size in hex format in the i2c write command. Once it looks it has finished, I have changed the boot switch but nothing was printed in the serial session...

 

I have another question, is it required to reflash the fip? In my case, I would liketo use the nand as place to store the uboot/kernel/rtfs.

 

Thanks,

imuguruza

0 Kudos

1,917 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please try images in i2c_ls1028a.zip attached in https://community.nxp.com/t5/QorIQ/LS1028-RCW-generation-to-boot-from-I2C-EEPROM-to-NOR-Flash/m-p/14...

=> tftp 0xa0000000 rcw_1500_gpu600.bin

=> i2c write 0xa0000000 0x50 0.2 10c

=> tftp 0xa0000000 bl2.bin

=> i2c write 0xa0000000 0x50 0x400.2 9431

Please flash fip image at 0x100000 on the NAND flash.

0 Kudos

1,850 Views
imuguruza
Contributor III

Hi @yipingwang 

 

In the process of writing the bl2.bin, the board get freezed, and I believe that is not being loaded properly...
Here a capture:

error.PNG

Checkig the LS1028ARDB schematics, I think the pin sw_cfg_wp should be to '0' to allow eeprom writing:

 

switch.PNG

I have set that too, but the writing process freezes and after, once I change to boot option to eeprom, I don't see any printed character.

Any idea what could be wrong?

Regards,

imuguruza

0 Kudos

1,686 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please check whether you could write RCW image to i2c eeprom.

=> tftp 0xa0000000 nxa22585/ls1028ardb/rcw_1500_gpu600.bin
=> i2c write 0xa0000000 0x50 0.2 0x10c

=>reset

=> i2c read 0x50 0.2 0x10c 0xc0000000
=> md 0xc0000000
c0000000: aa55aa55 80100000 3c004010 00000030 U.U......@.<0...
c0000010: 00000000 00000000 00000000 018f0000 ................
c0000020: 0030c000 00000000 020031a0 00002580 ..0......1...%..
c0000030: 00000000 00003296 00000000 00000010 .....2..........
c0000040: 00000000 00000000 00000000 00000000 ................
c0000050: 00000000 00000000 00000000 00000000 ................
c0000060: 00000000 00000000 00000000 00000000 ................
c0000070: 200e705a 00000000 bb580000 00000000 Zp. ......X.....
c0000080: 00000000 00000000 458ca4b5 334008bc ...........E..@3
c0000090: 00000001 33400154 47474747 33400158 ....T.@3GGGGX.@3
c00000a0: 47474747 334008bc 00000000 335008bc GGGG..@3......P3
c00000b0: 00000001 33500154 47474747 335008bc ....T.P3GGGG..P3
c00000c0: 00000000 33400890 00800401 33500890 ......@3......P3
c00000d0: 00800401 33400098 00000000 33500098 ......@3......P3
c00000e0: 00000000 31e00900 00000004 31e00400 .......1.......1
c00000f0: 1800d000 8000000a 00000400 1800d000 ................
=>

0 Kudos

1,780 Views
imuguruza
Contributor III

ping @yipingwang 

0 Kudos

1,962 Views
imuguruza
Contributor III

ping @yipingwang , any idea what's going on?

Regards,

imuguruza

0 Kudos

2,002 Views
yipingwang
NXP TechSupport
NXP TechSupport

Here are the updated steps:

$ bitbake rcw -c cleansstate

$ bitbake rcw -c patch

Go to RCW source code folder, build_ls1028ardb/tmp/work/ls1028ardb-fsl-linux/rcw/git-r0/git/ls1028ardb/R_SQPP_0x85bb/, add the following commands at the end in rcw_1500_gpu600.rcw file
.pbi
write 0x01e00400,0x1800d000
blockcopy 0xa,0x400,0x1800d000,0x9435
.end

CCSR write command:
setting boot location pointer to 0x1800d000 in Boot location pointer low-order address (BOOTLOCPTRL) register present in DCFG.
block copy command:
blockcopy 0x0a,0x400,0x00100000,0x9400
Source : I2C EEPROM = 0xa
Source address: 0x400
Destination address: OCRAM (0x100000)
Block size : size of BL2 binary in bytes

 

$ bitbak rcw

$ bitbake atf -c cleansstate

$ bitbake atf

Get atf images bl2_flexspi_nor.pbl and fip_uboot.bin in build_ls1028ardb/tmp/deploy/images/ls1028ardb/atf/.

Programming EEPROM using I2C on U-Boot on LS1028ARDB
=> i2c probe
Valid chip addresses: 00 50 52 53 57 66 67 77 7C
=> i2c write 0xa0000000 0x50 0.2 0x11c
=> i2c read 0x50 0.2 0x114 0xc0000000
=> i2c write 0xa0000000 0x50 0x400.2 <size of bl2.bin>

0 Kudos