1d7140351SOtavio SalvadorU-Boot for the Congatec QMX6 boards 29b75bad0SSARTRE Leo 39b75bad0SSARTRE LeoThis file contains information for the port of U-Boot to the Congatec 4d7140351SOtavio SalvadorQMX6 boards. 59b75bad0SSARTRE Leo 6*a187559eSBin Meng1. Building U-Boot 7d7140351SOtavio Salvador------------------ 8d7140351SOtavio Salvador 9*a187559eSBin Meng- Build U-Boot for Congatec QMX6 boards: 10d7140351SOtavio Salvador 11d7140351SOtavio Salvador$ make mrproper 12d7140351SOtavio Salvador$ make cgtqmx6eval_defconfig 13d7140351SOtavio Salvador$ make 14d7140351SOtavio Salvador 15d7140351SOtavio SalvadorThis will generate the following binaries: 16d7140351SOtavio Salvador 17d7140351SOtavio Salvador- SPL 18d7140351SOtavio Salvador- u-boot.img 19d7140351SOtavio Salvador 20*a187559eSBin Meng2. Flashing U-Boot in the SPI NOR 219b75bad0SSARTRE Leo--------------------------------- 229b75bad0SSARTRE Leo 23d7140351SOtavio SalvadorCopy SPL and u-boot.img to the exported TFTP directory of the 24d7140351SOtavio Salvadorhost PC (/tftpboot , for example). 259b75bad0SSARTRE Leo 26d7140351SOtavio Salvador=> sf probe 279b75bad0SSARTRE Leo 28b5e7c1e7SOtavio Salvador=> setenv serverip <server_ip_address> 29b5e7c1e7SOtavio Salvador 30b5e7c1e7SOtavio Salvador=> setenv ipaddr <board_ip_address> 31b5e7c1e7SOtavio Salvador 32d7140351SOtavio Salvador=> tftp 0x12000000 SPL 339b75bad0SSARTRE Leo 34d7140351SOtavio Salvador=> sf erase 0x0 0x10000 359b75bad0SSARTRE Leo 36b5e7c1e7SOtavio Salvador=> sf write 0x12000000 0x400 0x10000 379b75bad0SSARTRE Leo 38d7140351SOtavio Salvador=> tftp 0x12000000 u-boot.img 39d7140351SOtavio Salvador 40d7140351SOtavio Salvador=> sf erase 0x10000 0x70000 41d7140351SOtavio Salvador 42d7140351SOtavio Salvador=> sf write 0x12000000 0x10000 0x70000 43d7140351SOtavio Salvador 44*a187559eSBin MengReboot the board and the new U-Boot should come up. 45d7140351SOtavio Salvador 46d7140351SOtavio Salvador3. Booting from the SD card 47d7140351SOtavio Salvador--------------------------- 48d7140351SOtavio Salvador 49d7140351SOtavio Salvador- Flash the SPL image into the SD card: 50d7140351SOtavio Salvador 51d7140351SOtavio Salvadorsudo dd if=SPL of=/dev/mmcblk0 bs=1k seek=1; sync 52d7140351SOtavio Salvador 53d7140351SOtavio Salvador- Flash the u-boot.img image into the SD card: 54d7140351SOtavio Salvador 55d7140351SOtavio Salvadorsudo dd if=u-boot.img of=/dev/mmcblk0 bs=1k seek=69; sync 56d7140351SOtavio Salvador 57d7140351SOtavio Salvador- Insert the SD card into the big slot. 58d7140351SOtavio Salvador 59d7140351SOtavio SalvadorThe boot medium of Congatec QMX6 boards is the SPI NOR flash, so boot 60d7140351SOtavio Salvadorthe board from SPI first. 61d7140351SOtavio Salvador 62d7140351SOtavio SalvadorIt is also possible to boot from the SD card slot by using the 'bmode' 63d7140351SOtavio Salvadorcommand: 64d7140351SOtavio Salvador 65d7140351SOtavio Salvador=> bmode esdhc4 66d7140351SOtavio Salvador 67*a187559eSBin MengAnd then the U-Boot from the big slot will boot. 68d7140351SOtavio Salvador 69*a187559eSBin MengNote: If the "bmode" command is not available from your pre-installed U-Boot, 70d7140351SOtavio Salvadorthese instruction will produce the same effect: 71d7140351SOtavio Salvador 72d7140351SOtavio Salvador=> mw.l 0x20d8040 0x3850 73d7140351SOtavio Salvador=> mw.l 0x020d8044 0x10000000 74d7140351SOtavio Salvador=> reset 75