Building and Installing Linux uImage on the NXP i.MX RT1170 EVK Board Print


This note explains how to install a bootable Linux image to the SD Card of the NXP i.MX RT1170 EVK board. Having installed a Linux image to the SD Card, you would be able to boot Linux on the target automatically on any power up or reset cycle.

Instructions of how to build the sample Linux image (rootfs.uImage) from the Emcraft software distribution is described in Building Linux.

To install the sample Linux image (rootfs.uImage) from the Emcraft software distribution just follow the instructions:

  1. Make sure that SD Card is formatted.
  2. Remove SD Card from the NXP i.MX RT1170 EVK board, and plug it into PC.
  3. Find out a /dev/sdX device the system has assigned to your SD Card:
  4. $ dmesg | tail
    sd 1:0:0:0: [sdb] 31116288 512-byte logical blocks: (15.9GB/14.8 GiB)
    sd 1:0:0:0: [sdb] Cache data unavailable
    sd 1:0:0:0: [sdb] Assuming drive cache: write through
    sd 1:0:0:0: [sdb] Cache data unavailable
    sd 1:0:0:0: [sdb] Assuming drive cache: write through
    sdb: sdb1

  5. Mount the first partition of the SD Card, and copy rootfs.uImage file:
  6. $ sudo mount /dev/sdb1 /mnt
    $ cp rootfs.uImage /mnt

  7. Umount, and safely remove the SD Card:
  8. $ sudo umount /mnt
    $ sync

  9. Insert the SD Card back to the SD Card holder on the NXP i.MX RT1170 EVK board. Power on the EVK board. Connect to the serial console, and make sure that Linux boot up to console:
  10. U-Boot SPL 2023.04 (Sep 01 2023 - 17:34:47 +0000) Trying to boot from MMC1 U-Boot 2023.04 (Sep 01 2023 - 17:34:47 +0000) Model: NXP imxrt1170-evk board DRAM: 960 KiB (effective 64.9 MiB) Core: 72 devices, 15 uclasses, devicetree: separate MMC: FSL_SDHC: 0 Loading Environment from MMC... OK In: serial@4007c000 Out: serial@4007c000 Err: serial@4007c000 Net: eth0: ethernet@40424000 Hit any key to stop autoboot: 0 8489874 bytes read in 756 ms (10.7 MiB/s) ## Booting kernel from Legacy Image at 80007fc0 ... Image Name: Linux-6.1.22 Image Type: ARM Linux Multi-File Image (uncompressed) Data Size: 8489810 Bytes = 8.1 MiB Load Address: 80008000 Entry Point: 80008001 Contents: Image 0: 8480224 Bytes = 8.1 MiB Image 1: 9574 Bytes = 9.3 KiB Verifying Checksum ... OK ## Flattened Device Tree from multi component Image at 80007FC0 Booting using the fdt at 0x8081e5ec Working FDT set to 8081e5ec Loading Multi-File Image Loading Device Tree to 2032a000, end 2032f565 ... OK Working FDT set to 2032a000 Starting kernel ... Booting Linux on physical CPU 0x0 Linux version 6.1.22 (sasha@workbench.emcraft.com) (arm-none-eabi-gcc (GNU Arm Embedded Toolchain 10.3-2021.10) 10.3.1 20210824 (release), GNU ld (GNU Arm Embedded Toolchain 10.3-2021.10) 2.36.1.20210621) #2 Fri Sep 1 14:20:49 UTC 2023 CPU: ARMv7-M [411fc272] revision 2 (ARMv7M), cr=00000000 CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache OF: fdt: Machine model: NXP IMXRT1170 EVK board ..... Run /init as init process [72] Jan 01 00:00:01 Running in background / # mmc0: host does not support reading read-only switch, assuming write-enable mmc0: new high speed SDHC card at address 59b4 mmcblk0: mmc0:59b4 USD 7.39 GiB mmcblk0: p1 Micrel KSZ8081 or KSZ8091 40424000.ethernet-1:02: attached PHY driver (mii_bus:phy_addr=40424000.ethernet-1:02, irq=POLL) fec 40424000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off / # ls bin hello.ko lib proc sys var dev httpd linuxrc root tmp etc init mnt sbin usr / #