iMX6S boot from SD problem

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

iMX6S boot from SD problem

679 Views
dubravkomoravsk
Contributor I

We have a problem with the board we've developed.

What works well:

  • USB OTG works; downloading u-boot, initramfs and uimage to DDR memory works; all mentioned software and flashing SD card works
  • u-boot downloaded over USB starts, uimage downloaded over USB starts, everything works correctly
  • u-boot downloaded over USB can start uimage from SD card, uimage from SD card launches correctly and there are no issues with file system on SD

Booting from SD, however, doesn't seem to work at all. We believe all the boot configuration pins, gpios, voltages, etc to be set correctly. DCD initialization table must be good because boot and everything else work over USB. DDR stress tool reports no errors at all. Everything seems to work - except boot.

We've seen on the scope that there is about 80 ms of some activity on SD card pins at boot time, which roughly should be enough to read the entire u-boot. Afterwards, nothing happens/boot doesn't start, as far as we can say. A LED that is otherwise toggled in board_init(), remains unchanged; no printouts at all.

Partitions on SD card appear to be correct. The first four bytes at offset 0x400 match the four bytes at same offset in u-boot.bin. There is nothing particularly specific in ucl2.xml for our board. We've also tried toggling all the BOOT_CFG options that seemed even remotely relevant (... though there are many and we may have missed something).

We've checked power supplies, all seem good, POR goes high about 10 ms after all voltages become stable.

If we remove the SD card, CPU correctly goes into serial downloader mode.

Any hints what we could try?

Some additional, possibly relevant information. MMC flash behaves identically to SD card: everything apparently written correctly and readable, but boot won't start. SPI flash exhibits a different (related?) problem - kernel detects it not as 25P64 that we know it is, but instead non-jedec-25P05 with far smaller capacity, insufficient even for uboot.

Labels (2)
0 Kudos
2 Replies

456 Views
igorpadykov
NXP Employee
NXP Employee

Hi Dubravko

you can test SD port using basic read/write (better with oscilloscope checking

signals quality) with SDK (note one can run it with jtag) usdhc test

i.MX 6Series Platform SDK

Then you can run SDK from SD, check README.pdf

sect.5.5 "Using SD boot".

One can run SDK from iRAM

iRAM (OCRAM) i.MX6 SDK Application

Lastly, you can just try another SD card.

Best regards

chip

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

0 Kudos

456 Views
dubravkomoravsk
Contributor I

Thanks for the reply. The different SD card didn't help. We've got it working anyway - the problem were our leftover experimental settings in u-boot.lds, plus leftover settings from other files because ltib apparently doesn't rebuild all/required files no matter what is changed in build configuration.

  • -m selectype sometimes triggers rebuild when target board is changed, sometimes doesn't
  • -m clean doesn't clean temporary files
  • -m scbuild often won't rebuild something.c after included something.h was modified
  • --force to unconditionally rebuild everything doesn't work at all
  • somehow some software managed to force including something_mfg.h even though mfg firmware was turned off everywhere

:smileyhappy: Managed to get a satisfying build after cleaning and configuring and rebuilding many times and many debug printouts to figure out what was actually compiled with which option, plus grep through all the files to weed out some stubborn leftover old settings.

0 Kudos