Can lx2160ardb run U-boot from memory?

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

Can lx2160ardb run U-boot from memory?

958 Views
shmulikhen
Contributor I

Hello,

I am currently evaluating lx2160ardb for a future product.

I have 2 main goals:

  1. Support more than 1 software version banks (preferably 2: current + previous/new)
  2. Avoid U-Boot upgrade in deployed units at all costs - dangerous step that may render a unit dead if something went wrong.

My main idea is to have 3 copies of U-Boot in FLASH:

  1. "Golden" U-Boot, residing in the default position, never upgraded, totally agnostic to version specific details - only needs to load and run one of the other copies based on some info in environment variables.
  2. Copy 1 - Also residing in flash, may be upgraded, related to the SW version in bank 1, needs to be aware of version specific information like root file system type and special kernel parameters.
  3. Copy 2 - Also residing in flash, may be upgraded, related to the SW version in bank 2, needs to be aware of version specific information like root file system type and special kernel parameters.

I have seen the same thing work in another NXP product that was powerpc based (t2081).

I got some pointers from our FAE, but they are also related to other powerpc based boards.

Is it possible in arm64 environment to have the first U-Boot load another copy of U-Boot to RAM and execute it there?

How do I go about implementing such a feature?

Thanks in advance,

Shmulik.

0 Kudos
Reply
2 Replies

812 Views
shmulikhen
Contributor I

Hello Yiping,

Thank you for getting back to me on this.

Unfortunately, I was not involved in implementing this feature on t2080 - it was by someone else in my previous work place, so I don't have access to the sources. I only saw how it works, not the internal details.

Also, in our design, there will be only 1 bank of QSPI flash, so all 3 images of u-boot and the RCW will have to reside on the same chip. The rest of the SW image will reside on eMMC.

When you say "the TEXT BASE addresses generated in u-boot binary image are mapped to QSPI flash" - does this mean that lx2160a executes code directly from flash? There is no copy of the code into some kind of internal SRAM?

In addition, where can I find out which addresses are mapped to flash and which are mapped to DDR?

From what I saw until now, the TEXT BASE address is not identical to the load address of the image - there is always some gap between where the image resides in memory and the actual entry point passed to the go command which I cannot understand.

Thanks again,

Shmulik.

0 Kudos
Reply

812 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Shmulik Hen,

By default, lx2160ardb boots from QSPI flash, the TEXT BASE addresses generated in u-boot binary image are mapped to QSPI flash.

You could modify the TEXT BASE address definition in ls2160ardb u-boot header file in u-boot source(include/configs) to map DDR memory, then rebuild this u-boot image and program it to bank 1 of QSPI flash as copy 1 u-boot. Then read copy 1 u-boot image from QSPI to DDR under the Golden U-Boot and use go command to execute copy 1 u-boot.

In addition, How did you implement this feature on T2080?


Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply