Raspberry Pi 3b Plus USB-Ethernet lan78xx_eth address not set

Hello,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting I am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still the same error.
However on Raspberry Pi 3B, I don't see this error and "current eth" is set to "smsc95xx_eth" and "ethaddr" is also available.
Can anyone please let me know the issue with Raspberry Pi 3b plus?
Thanks in advance.

Hi,
On Sat, 24 Feb 2024 at 01:56, Sourabh Hegde Ramu hrsourabh1107@gmail.com wrote:
Hello,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting I am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still the same error.
However on Raspberry Pi 3B, I don't see this error and "current eth" is set to "smsc95xx_eth" and "ethaddr" is also available.
Can anyone please let me know the issue with Raspberry Pi 3b plus?
Thanks in advance.
Can you set the MAC address in boot environment?
# setenv ethaddr 00:14:05:42:03:BB # saveenv
It should update the mac address for LAN75xx printenv should display the mac address
Thanks -Anand

Hi Anand,
Thanks for the update.
Yes, I can set it manually. But this should be done by u-boot, right? Is there any reason why this is not happening on Pi 3b plus? I have other Raspberry Pi (4 & 3b) and they are working fine.
Also, is this MAC address for LAN75xx or LAN78xx? The error message shows lan78xx_eth.
On Sun, Feb 25, 2024, 06:50 Anand Moon linux.amoon@gmail.com wrote:
Hi,
On Sat, 24 Feb 2024 at 01:56, Sourabh Hegde Ramu hrsourabh1107@gmail.com wrote:
Hello,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting
I
am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still
the
same error.
However on Raspberry Pi 3B, I don't see this error and "current eth" is
set
to "smsc95xx_eth" and "ethaddr" is also available.
Can anyone please let me know the issue with Raspberry Pi 3b plus?
Thanks in advance.
Can you set the MAC address in boot environment?
# setenv ethaddr 00:14:05:42:03:BB # saveenv
It should update the mac address for LAN75xx printenv should display the mac address
Thanks -Anand

Hi,
On Sun, 25 Feb 2024 at 12:25, Sourabh Hegde Ramu hrsourabh1107@gmail.com wrote:
Hi Anand,
Thanks for the update.
Yes, I can set it manually. But this should be done by u-boot, right? Is there any reason why this is not happening on Pi 3b plus? I have other Raspberry Pi (4 & 3b) and they are working fine.
Also, is this MAC address for LAN75xx or LAN78xx? The error message shows lan78xx_eth.
Most of the ethernet controllers get the MAC address via EPROM. or they used some logic to set the MAC address. check CONFIG_NET_RANDOM_ETHADDR this flag is needed for your device.
Thanks -Anand
On Sun, Feb 25, 2024, 06:50 Anand Moon linux.amoon@gmail.com wrote:
Hi,
On Sat, 24 Feb 2024 at 01:56, Sourabh Hegde Ramu hrsourabh1107@gmail.com wrote:
Hello,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting I am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still the same error.
However on Raspberry Pi 3B, I don't see this error and "current eth" is set to "smsc95xx_eth" and "ethaddr" is also available.
Can anyone please let me know the issue with Raspberry Pi 3b plus?
Thanks in advance.
Can you set the MAC address in boot environment?
# setenv ethaddr 00:14:05:42:03:BB # saveenv
It should update the mac address for LAN75xx printenv should display the mac address
Thanks -Anand

Hi,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting I am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
The ethernet address is set by the ethaddr variable, it can be viewed by running printenv. That is then set to the ethernet0 alias in the device tree.
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still the same error.
I believe the driver for the USB network interface on the 3B+ is the USB_ETHER_LAN78XX driver,
However on Raspberry Pi 3B, I don't see this error and "current eth" is set to "smsc95xx_eth" and "ethaddr" is also available.
Do you mean it's set at U-Boot stage or when you boot into Linux?
Peter

Hi Peter,
USB_ETHER_LAN78XX is already enabled in the defconfig for Pi 3b plus. But the eth_get_ethaddr is returning null https://github.com/u-boot/u-boot/blob/1a66a7768af7e8106c2cd93a19f4013877fb85...
Do you know why this is not handled?
On Sun, Feb 25, 2024, 14:49 Peter Robinson pbrobinson@gmail.com wrote:
Hi,
I have a Raspberry Pi 3B Plus which I want to integrate with U-boot (v2023.10) .
I am using rpi_3_32b_defconfig to generate u-boot.bin. But while booting
I
am getting below error
Loading Environment from FAT... Unable to read "uboot.env" from mmc0:1... In: serial,usbkbd Out: serial,vidconsole Err: serial,vidconsole Net: No ethernet found. starting USB... Bus usb@7e980000: USB DWC2 scanning bus usb@7e980000 for devices... Error: lan78xx_eth address not set. 3 USB Device(s) found scanning usb for storage devices... 0 Storage Device(s) found Hit any key to stop autoboot: 0
In the "bdinfo", "current eth" is not set
The ethernet address is set by the ethaddr variable, it can be viewed by running printenv. That is then set to the ethernet0 alias in the device tree.
U-Boot> bdinfo boot_params = 0x00000100 DRAM bank = 0x00000000 -> start = 0x00000000 -> size = 0x3b400000 flashstart = 0x00000000 flashsize = 0x00000000 flashoffset = 0x00000000 baudrate = 115200 bps relocaddr = 0x3b360000 reloc off = 0x3b358000 Build = 32-bit current eth = unknown eth-1addr = (not set) IP addr = <NULL>
I also enabled LAN75xx in menuconfig and re-compiled u-boot. But still
the
same error.
I believe the driver for the USB network interface on the 3B+ is the USB_ETHER_LAN78XX driver,
However on Raspberry Pi 3B, I don't see this error and "current eth" is
set
to "smsc95xx_eth" and "ethaddr" is also available.
Do you mean it's set at U-Boot stage or when you boot into Linux?
Peter
participants (3)
-
Anand Moon
-
Peter Robinson
-
Sourabh Hegde Ramu