NXP i.MXRT10XX: Running TCP/IP Stack in Linux

NXP i.MXRT10XX: Running TCP/IP Stack in Linux

With uClinux running on the i.MX RT10XX, you get the full Linux TCP/IP stack. Userspace POSIX APIs are provided by the uClibc library. Key user-space networking tools and utilities are available from the multi-call busybox. Additional tools and packages, such as for instance the SSH dropbear server, can be built specifically for uClinux. All in all, you have the powerful Linux TCP/IP stack at your disposal.

There is a full-functioning Ethernet device driver available in the kernel tree for the i.MX RT10XX. The device driver is linux/drivers/net/ethernet/freescale/fec.c configured in the kernel using the CONFIG_FEC build time option in Device Drivers -> Network device support -> Ethernet driver support -> Freescale devices -> FEC ethernet controller (of ColdFire and some i.MX CPUs).

For the run-time configuration of the kernel, Ethernet is enabled in rootfs.dts.IMXRT102X_NXPEVK or rootfs.dts.IMXRT105X_NXPEVK or rootfs.dts.IMXRT106X_NXPEVK in projects/rootfs as follows, for example:

 &fec { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_fec>; status = "okay"; assigned-clocks = <&clks IMXRT1050_CLK_ENET_REF>, <&clks IMXRT1050_CLK_PLL6_BYPASS>; assigned-clock-rates = <50000000>; assigned-clock-parents = <0>, <&clks IMXRT1050_CLK_PLL6>; clocks = <&clks IMXRT1050_CLK_ENET>, <&clks IMXRT1050_CLK_AHB_PODF>, <&clks IMXRT1050_CLK_ENET_REF>; clock-names = "ipg", "ahb", "enet_clk_ref"; fsl,ref-clk-dir = <&gpr 4 17 1>; phy-mode = "rmii"; phy-handle = <&ethphy0>; phy-reset-duration = <1>; phy-reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>; mdio { #address-cells = <1>; #size-cells = <0>; ethphy0: ethernet-phy@0 { reg = <2>; clocks = <&clks IMXRT1050_CLK_ENET_REF>; clock-names = "rmii-ref"; }; }; };

This will register a platform device for the i.MX RT10XX Ethernet controller with the Ethernet driver.

The Linux project provided by Emcraft in the distribution (refer to projects/rootfs) and installed on each shipping module and kit includes the TCP/IP stack and various network related capabilities. The following snapshot shows the full Linux bootsrap sequence from power-on to the Linux shell:

U-Boot SPL 2025.04 (Dec 05 2025 - 05:11:04 +0000) Trying to boot from MMC1 U-Boot 2025.04 (Dec 05 2025 - 05:11:04 +0000) DRAM: 32 MiB Core: 79 devices, 18 uclasses, devicetree: separate MMC: FSL_SDHC: 0 Loading Environment from MMC... Reading from MMC(0)... OK In: serial@40184000 Out: serial Err: serial Net: eth0: ethernet@402d8000 Hit any key to stop autoboot: 0 8823579 bytes read in 4860 ms (1.7 MiB/s) ## Booting kernel from Legacy Image at 80007fc0 ... Image Name: Linux-6.12.20 Image Type: ARM Linux Multi-File Image (uncompressed) Data Size: 8823515 Bytes = 8.4 MiB Load Address: 80008000 Entry Point: 80008001 Contents: Image 0: 8811684 Bytes = 8.4 MiB Image 1: 11819 Bytes = 11.5 KiB Verifying Checksum ... OK ## Flattened Device Tree from multi component Image at 80007FC0 Booting using the fdt at 0x8086f4b0 Working FDT set to 8086f4b0 Loading Multi-File Image to 80008000 Loading Device Tree to 81c71000, end 81c76e2a ... OK Working FDT set to 81c71000 Starting kernel ... Booting Linux on physical CPU 0x0 Linux version 6.12.20 (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 PREEMPT Fri Dec 5 05:05:12 UTC 2025 CPU: ARMv7-M [411fc271] revision 1 (ARMv7M), cr=00000000 CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache OF: fdt: Machine model: NXP IMXRT1050-evk board Zone ranges: Normal [mem 0x0000000080000000-0x0000000081ffffff] Movable zone start for each node Early memory node ranges node 0: [mem 0x0000000080000000-0x0000000081dfffff] node 0: [mem 0x0000000081e00000-0x0000000081ffffff] Initmem setup node 0 [mem 0x0000000080000000-0x0000000081ffffff] Reserved memory: created DMA memory pool at 0x81e00000, size 1 MiB OF: reserved mem: initialized node dmapool@81e00000, compatible id shared-dma-pool OF: reserved mem: 0x81e00000..0x81efffff (1024 KiB) nomap non-reusable dmapool@81e00000 OF: reserved mem: 0x81f00000..0x81ffffff (1024 KiB) nomap non-reusable memory@81f00000 Kernel command line: root=/dev/mmcblk0p2 rw rootwait ip=192.168.1.82:192.168.1.86:192.168.1.254:255.255.255.0::eth0:off Unknown kernel command line parameters "ip=192.168.1.82:192.168.1.86:192.168.1.254:255.255.255.0::eth0:off", will be passed to user space. Dentry cache hash table entries: 4096 (order: 2, 16384 bytes, linear) Inode-cache hash table entries: 2048 (order: 1, 8192 bytes, linear) Built 1 zonelists, mobility grouping on. Total pages: 8192 mem auto-init: stack:off, heap alloc:off, heap free:off SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1 Invalid parameters for execmem allocator, module loading will fail rcu: Preemptible hierarchical RCU implementation. rcu: RCU calculated value of scheduler-enlistment delay is 100 jiffies. NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16 rcu: srcu_init: Setting srcu_struct sizes based on contention. Switching to timer-based delay loop, resolution 333ns sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 715827882841ns clocksource: mxc_timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 637086815595 ns Console: colour dummy device 80x30 printk: legacy console [tty0] enabled Calibrating delay loop (skipped), value calculated using timer frequency.. 6.00 BogoMIPS (lpj=3000) pid_max: default: 32768 minimum: 301 Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) rcu: Hierarchical SRCU implementation. rcu: Max phase no-delay instances is 400. Memory: 21248K/32768K available (3784K kernel code, 221K rwdata, 1108K rodata, 3260K init, 125K bss, 11144K reserved, 0K cma-reserved) devtmpfs: initialized DMA: default coherent area is set clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 1911260446275000 ns futex hash table entries: 256 (order: -1, 3072 bytes, linear) pinctrl core: initialized pinctrl subsystem NET: Registered PF_NETLINK/PF_ROUTE protocol family imxrt1050-pinctrl 401f8000.pinctrl: initialized IMX pinctrl driver imxrt1050-pinctrl 400a8000.pinctrl-snvs: initialized IMX pinctrl driver gpio gpiochip0: Static allocation of GPIO base is deprecated, use dynamic allocation. gpio gpiochip1: Static allocation of GPIO base is deprecated, use dynamic allocation. gpio gpiochip2: Static allocation of GPIO base is deprecated, use dynamic allocation. gpio gpiochip3: Static allocation of GPIO base is deprecated, use dynamic allocation. gpio gpiochip4: Static allocation of GPIO base is deprecated, use dynamic allocation. SCSI subsystem initialized usbcore: registered new interface driver usbfs usbcore: registered new interface driver hub usbcore: registered new device driver usb pps_core: LinuxPPS API ver. 1 registered pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it> PTP clock support registered Bluetooth: Core ver 2.22 NET: Registered PF_BLUETOOTH protocol family Bluetooth: HCI device and connection manager initialized Bluetooth: HCI socket layer initialized Bluetooth: L2CAP socket layer initialized Bluetooth: SCO socket layer initialized clocksource: Switched to clocksource mxc_timer1 NET: Registered PF_INET protocol family IP idents hash table entries: 2048 (order: 2, 16384 bytes, linear) tcp_listen_portaddr_hash hash table entries: 1024 (order: 0, 4096 bytes, linear) Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear) TCP established hash table entries: 1024 (order: 0, 4096 bytes, linear) TCP bind hash table entries: 1024 (order: 1, 8192 bytes, linear) TCP: Hash tables configured (established 1024 bind 1024) UDP hash table entries: 256 (order: 0, 4096 bytes, linear) UDP-Lite hash table entries: 256 (order: 0, 4096 bytes, linear) NET: Registered PF_UNIX/PF_LOCAL protocol family RPC: Registered named UNIX socket transport module. RPC: Registered udp transport module. RPC: Registered tcp transport module. RPC: Registered tcp-with-tls transport module. RPC: Registered tcp NFSv4.1 backchannel transport module. Bus freq driver module loaded Initialise system trusted keyrings workingset: timestamp_bits=30 max_order=13 bucket_order=0 Key type asymmetric registered Asymmetric key parser 'x509' registered Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249) io scheduler mq-deadline registered io scheduler kyber registered io scheduler bfq registered 40184000.serial: ttyLP0 at MMIO 0x40184010 (irq = 187, base_baud = 1250000) is a FSL_LPUART fsl-lpuart 40184000.serial: Serial: Console lpuart rounded baud ratefrom 208333 to 115200 printk: legacy console [ttyLP0] enabled PPP generic driver version 2.4.2 PPP BSD Compression module registered PPP Deflate Compression module registered usbcore: registered new interface driver rt2800usb usbcore: registered new interface driver cdc_acm cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters usbcore: registered new interface driver uas usbcore: registered new interface driver usb-storage snvs_rtc 400d4000.snvs:snvs-rtc-lp: registered as rtc0 snvs_rtc 400d4000.snvs:snvs-rtc-lp: setting system clock to 1970-01-01T00:00:00 UTC (0) i2c_dev: i2c /dev entries driver usbcore: registered new interface driver btusb sdhci: Secure Digital Host Controller Interface driver sdhci: Copyright(c) Pierre Ossman sdhci-pltfm: SDHCI platform and OF driver helper usbcore: registered new interface driver usbhid usbhid: USB HID core driver NET: Registered PF_PACKET protocol family Bluetooth: RFCOMM TTY layer initialized Bluetooth: RFCOMM socket layer initialized Bluetooth: RFCOMM ver 1.11 ARMv7-M VFP coprocessor found VFP: Double precision floating points are supported mmc0: SDHCI controller on 402c0000.mmc [402c0000.mmc] using ADMA Loading compiled-in X.509 certificates mmc0: new high speed SDHC card at address 0001 mmcblk0: mmc0:0001 SD16G 14.5 GiB mmcblk0: p1 p2 mxs_phy 400d9000.usbphy: supply phy-3p0 not found, using dummy regulator mxs_phy 400da000.usbphy: supply phy-3p0 not found, using dummy regulator imx-lpi2c 403f0000.i2c: use pio mode ft5x0x_ts 0-0038: resolution: 479x271 input: ft5x0x_ts as /devices/virtual/input/input0 ft5x0x_ts 0-0038: fft5x0x_i2c_Read: i2c read error. [FTS] Firmware version = 0x0 ft5x0x_ts 0-0038: fft5x0x_i2c_Read: i2c read error. [FTS] report rate is 0Hz. ft5x0x_ts 0-0038: fft5x0x_i2c_Read: i2c read error. [FTS] touch threshold is 0. i2c i2c-0: LPI2C adapter registered mxsfb 402b8000.lcdif: supply lcd not found, using dummy regulator mxsfb 402b8000.lcdif: initialized ci_hdrc ci_hdrc.1: EHCI Host Controller ci_hdrc ci_hdrc.1: new USB bus registered, assigned bus number 1 ci_hdrc ci_hdrc.1: USB 2.0 started, EHCI 1.00 hub 1-0:1.0: USB hub found hub 1-0:1.0: 1 port detected input: gpio-keys as /devices/platform/gpio-keys/input/input1 cfg80211: Loading compiled-in X.509 certificates for regulatory database Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7' Loaded X.509 cert 'wens: 61c038651aabdcf94bd0ac7ff06c7248db18c600' clk: Disabling unused clocks platform regulatory.0: Direct firmware load for regulatory.db failed with error -2 PM: genpd: Disabling unused power domains cfg80211: failed to load regulatory.db Freeing unused kernel image (initmem) memory: 3260K This architecture does not have kernel memory protection. Run /init as init process [54] Jan 01 00:00:02 Running in background / # Micrel KSZ8081 or KSZ8091 402d8000.ethernet-1:02: attached PHY driver (mii_bus:phy_addr=402d8000.ethernet-1:02, irq=POLL) fec 402d8000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off random: crng init done / #

Let's test the TCP/IP stack on the i.MX RT10XX.

From the development host validate that the target is visible using ping:

$ ping -c 5 192.168.1.82 PING 192.168.1.82 (192.168.1.82) 56(84) bytes of data. 64 bytes from 192.168.1.82: icmp_seq=1 ttl=64 time=0.688 ms 64 bytes from 192.168.1.82: icmp_seq=2 ttl=64 time=0.382 ms 64 bytes from 192.168.1.82: icmp_seq=3 ttl=64 time=0.402 ms 64 bytes from 192.168.1.82: icmp_seq=4 ttl=64 time=0.412 ms 64 bytes from 192.168.1.82: icmp_seq=5 ttl=64 time=0.411 ms --- 192.168.1.82 ping statistics --- 5 packets transmitted, 5 received, 0% packet loss, time 4128ms rtt min/avg/max/mdev = 0.382/0.459/0.688/0.115 ms

ping the development host from the target:

/ # ping -c 5 192.168.1.86 PING 192.168.1.86 (192.168.1.86): 56 data bytes 64 bytes from 192.168.1.86: seq=0 ttl=64 time=0.734 ms 64 bytes from 192.168.1.86: seq=1 ttl=64 time=0.909 ms 64 bytes from 192.168.1.86: seq=2 ttl=64 time=0.823 ms 64 bytes from 192.168.1.86: seq=3 ttl=64 time=0.828 ms 64 bytes from 192.168.1.86: seq=4 ttl=64 time=0.814 ms --- 192.168.1.86 ping statistics --- 5 packets transmitted, 5 packets received, 0% packet loss round-trip min/avg/max = 0.734/0.821/0.909 ms

On the target, start the telnetd daemon to allow connections to the i.MX RT10XX:

 / # ps | grep telnetd 78 root 864 S telnetd 80 root 864 S grep telnetd / #

Connect to the target from the development host using telnet. The target is configured to accept the 123 password for root

$ telnet 192.168.1.82 Trying 192.168.1.82... Connected to 192.168.1.82. Escape character is '^]'. (none) login: root Password: / # ls bin etc httpd lib mnt root sbin tmp var dev hello.ko init linuxrc proc run sys usr / # exit Connection closed by foreign host. $

The dropbear SSH daemon starts automatically on the target. Verify that dropbear allows secure connections to the target:

/ # ps | grep dropbear 71 root 728 S dropbear -R 106 root 864 S grep dropbear / #

Connect to the target from the development host using ssh. The first connection takes several seconds to establish as the i.MX RT10XX runs computation-extensive key calculations. Again, enter 123 on the password prompt:

$ ssh root@192.168.1.82 The authenticity of host '192.168.1.82 (192.168.1.82)' can't be established. ED25519 key fingerprint is SHA256:/XK4PN+GGXJXs/F+wXhsv2T7sFJbu+Sx0bazmZZra54. This key is not known by any other names. Are you sure you want to continue connecting (yes/no/[fingerprint])? yes Warning: Permanently added '192.168.1.82' (ED25519) to the list of known hosts. root@192.168.1.82's password: / # ls bin etc httpd lib mnt root sbin tmp var dev hello.ko init linuxrc proc run sys usr / # exit Connection to 192.168.1.82 closed. $

On the target, enable access to the Internet by configuring a default gateway. Note also that the system makes use of the public name server provided by Google:

/ # cat /etc/resolv.conf # This configuration makes use of the Google public DNS server. # If you would like to use something else, replace with the IP # of your DNS server nameserver 8.8.8.8 / #

Use ntpd to synchronize the time on the target with the time provided by a public server:

/ # date Thu Jan 1 17:40:57 UTC 1970 / # ntpd -p 0.fedora.pool.ntp.org / # sleep 5; date Sat Dec 6 07:53:53 UTC 2025 / #

Use wget to download a file from a remote server:

/ # wget ftp://ftp.gnu.org/README Connecting to http://ftp.gnu.org (209.51.188.20:21) saving to 'README' README 100% |********************************| 2748 0:00:00 ETA 'README' saved / # cat README This is http://ftp.gnu.org , the FTP server of the the GNU project. ...

Mount a directory exported by a development host over NFS:

/ # mount -o nolock,rsize=1024 192.168.1.86:/srv/homes /mnt/nfs / # ls /mnt/nfs/ 512kB.host check_float.c linux-dp.c SimpleClass check_float_soft test SimpleClass.cc check_float_softfp test.encoded app eclipse-workspace uartboot.script app.c fs.jffs2 widgets_gui_demo busybox linux-dp / # cp /bin/busybox /mnt/nfs / # cp /mnt/nfs/busybox /tmp / # md5sum /bin/busybox /tmp/busybox aa40e58bd2e79cfd23692c58088e3386 /bin/busybox aa40e58bd2e79cfd23692c58088e3386 /tmp/busybox

Start the HTTP daemon:

/ # httpd -h /httpd/html/

From a local host, open a Web browser to the target and watch the demo web page provided by the target. The target shows the current time and date as well as the list of the currently running processes: