initialize net_mode.if_type
cover initialize net_mode.if_type
A minor fix to efi networking.
When if_type is not set, it leads grub2's efi code to send a bogus arp request. This will then stall the progress of grub.
This was tested with grubaa64.efi from Redhat/Oracle linux 7u5.
The patch was tested against: 890e79f2b1c26c5ba1a86d179706348aec7feef7 (aka v2018.05)
Andrew Thomas (1):
initialize net_mode.if_type
lib/efi_loader/efi_net.c | 1 + 1 file changed, 1 insertion(+)
Signature · 1 line
1.8.3.1
PATCH 1/1 initialize net_mode.if_type
if_type is not correctly initialized
Failure to initialize if_type means that grub2/efinet sends a bogus arp request. It therefore gets no response. On Raspberry Pi 3B+ this leads to a pause at:
lan78xx_eth Waiting for PHY auto negotiation to complete....... done lan78xx_eth Waiting for PHY auto negotiation to complete....... done
--- lib/efi_loader/efi_net.c | 1 + 1 file changed, 1 insertion(+)
lib/efi_loader/efi_net.c +1 -0
@@ -361,6 +361,7 @@ efi_status_t efi_net_register(void)memcpy (netobj->net_mode.current_address.mac_addr,eth_get_ethaddr (),6 ); netobj->net_mode.hwaddr_size =ARP_HLEN ; netobj->net_mode.max_packet_size =PKTSIZE ; + netobj->net_mode.if_type =ARP_ETHER ; netobj->pxe.mode = &netobj->pxe_mode;if (dhcp_ack)
Signature · 1 line
1.8.3.1
PATCH 1/1 initialize net_mode.if_type
Quoted 10 lines · Andrew Thomas
if_typeis not correctly initializedFailure to initialize
if_typemeans that grub2/efinet sends a bogus arp request. It therefore gets no response. On Raspberry Pi 3B+ this leads to a pause at:
lan78xx_ethWaiting for PHY auto negotiation to complete....... donelan78xx_ethWaiting for PHY auto negotiation to complete....... doneSigned-off-by Andrew Thomas <[email protected]>
In the future, please Cc me (network maintainer).
Quoted 23 lines
--- lib/efi_loader/efi_net.c | 1 + 1 file changed, 1 insertion(+)lib/efi_loader/efi_net.c +1
-1@@ -361,6 +361,7 @@ efi_status_t efi_net_register(void)memcpy (netobj->net_mode.current_address.mac_addr,eth_get_ethaddr (),6 ); netobj->net_mode.hwaddr_size =ARP_HLEN ; netobj->net_mode.max_packet_size =PKTSIZE ; + netobj->net_mode.if_type =ARP_ETHER ; netobj->pxe.mode = &netobj->pxe_mode;if (dhcp_ack) --1.8.3.1
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
https://lists.denx.de/listinfo/u-boot
Hi andrew,
https://patchwork.ozlabs.org/patch/932997/ was applied to http://git.denx.de/?p=u-boot/u-boot-net.git
Thanks!
-Joe