Ian Goodacre Posted 20 hours ago Posted 20 hours ago I have a NanoPi R2S Plus. If I boot the FriendlyElec Debian image both network ports work: LAN and WAN. If I boot the Armbian NanoPi R2S image, it boots OK and the LAN port works but the WAN port does not work. I believe the WAN port does not work because the NanoPi R2S has an RTL8211E chip but the NanoPi R2S Plus has an RTL8211F chip. I found some notes about problems with network on other boards that had the same change of chip (e.g. radxa RockpiE) and the device tree changes required to accommodate the new chip. So I tried to patch armbian/build to make the same changes for the NanoPi R2S Plus. I am not familiar with armbian/build or device trees. None the less, I seem to have made some progress. My latest image attempts to bring up the WAN port. It gets an IP address from dhcp server. But then it tries to get various files by TFTP and fails. It has no server IP and I have no TFTP server running. Part of the console logs: Quote scanning bus usb@ff5d0000 for devices... 1 USB Device(s) found scanning bus usb@ff580000 for devices... 1 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Device 0: unknown device Speed: 1000, full duplex BOOTP broadcast 1 DHCP client bound to address 192.168.1.156 (74 ms) *** ERROR: `serverip' not set Cannot autoload with TFTPGET missing environment variable: pxeuuid Retrieving file: pxelinux.cfg/01-72-bf-ff-86-49-5f Speed: 1000, full duplex *** ERROR: `serverip' not set Retrieving file: pxelinux.cfg/C0A8019C Speed: 1000, full duplex *** ERROR: `serverip' not set Retrieving file: pxelinux.cfg/C0A8019 ... Retrieving file: pxelinux.cfg/default Speed: 1000, full duplex *** ERROR: `serverip' not set Config file not found Speed: 1000, full duplex BOOTP broadcast 1 DHCP client bound to address 192.168.1.156 (71 ms) *** ERROR: `serverip' not set Cannot autoload with TFTPGET Speed: 1000, full duplex BOOTP broadcast 1 DHCP client bound to address 192.168.1.156 (73 ms) *** ERROR: `serverip' not set Cannot autoload with TFTPGET => Now I am lost. I don't understand why it is trying to load files by TFTPGET. Maybe I have something wrong in the device tree so it is loading an incorrect device driver. There is the line 'Device 0: unknown device'. The first file it attempts to retrieve appears to have the MAC address of the LAN port in the filename. It continues trying to load various files then fails and presents a prompt: '=> ' Can anyone give me pointers to where to look / what to read to understand what is going on? Is that a u-boot prompt? Any pointers would be much appreciated and, again, this is all new to me - I am blundering about in my ignorance. 0 Quote
Werner Posted 17 hours ago Posted 17 hours ago Hi The logs you provided (besides that they're incomplete) are from u-boot and have nothing to do with OS level. it might be possible that u-boot supports the 2nd NIC but it is broken in kernel. Could be a device tree issue, could also be something else. I suggest to try the available kernel branches (legacy, current, edge) first to check if one of them works properly. You can use armbian-config to switch between kernels or swap sdcards with written Armbian images with various kernels beneath on. @jock has some insights in some older rockchips I think? 0 Quote
Ian Goodacre Posted 17 hours ago Author Posted 17 hours ago Thanks Werner. I have found some of the log message text in the u-boot source code. As you suggest, it seems to be stuck in u-boot and not getting to a Linux kernel at all. I'm guessing BOOTP is a fallback in case it can't find an image to load on any storage. 'scanning usb for storage devices... 0 Storage Device(s) found' doesn't look good. It should be booting from the SD card. It did, before I messed with the device tree. I think u-boot cannot find any image to load so it presents a prompt ('=> ') and waits for a command to tell it what to load. I will have to capture the whole log and see what other clues I can find. At the moment, I only have a bit of cut-and-paste of the end of it. I guess I broke the device tree so it can't find the image to load on the SD card. I really need to learn how to inspect the device tree generated by armbian/build when the system doesn't boot. I guess it's in the image somewhere. I'm hobbled by my ignorance but learn a little each day 😉 0 Quote
jock Posted 13 hours ago Posted 13 hours ago @Ian Goodacre yes I confirm you broke the dtb, and for that reason u-boot does not take the kernel from sdcard anymore, then tries other boot options (USB, PXE). You should recover the device tree to let linux boot again. Funnily enough, u-boot is able to pick up an IP address from DHCP 😅 This is the merge request where I fixed the Gigabit LAN port on RockPi-E, I understand that you already read about the merge request, perhaps the problem is similar to yours. BTW, the phy chip should be automatically recognized by the kernel code because each chip exposes some ID that can be picked up by the driver, so you should not worry about. If you still have issues, post the link returned by armbianmonitor -u or at least the dmesg log. 0 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.