Networking: Need to set the IPv6 EtherType on outgoing IPv6 packets

This commit is contained in:
Gregory Nutt 2015-01-23 09:30:50 -06:00
parent c77426e550
commit b51c00c8d7
2 changed files with 7 additions and 0 deletions

View File

@ -218,6 +218,10 @@ void icmpv6_input(FAR struct net_driver_s *dev)
memcpy(eth->dest, eth->src, ETHER_ADDR_LEN);
memcpy(eth->src, dev->d_mac.ether_addr_octet, ETHER_ADDR_LEN);
/* Set the IPv6 Ethernet type */
eth->type = HTONS(ETHTYPE_IP6);
}
#endif
}

View File

@ -186,6 +186,9 @@ void icmpv6_solicit(FAR struct net_driver_s *dev,
memcpy(eth->src, dev->d_mac.ether_addr_octet, ETHER_ADDR_LEN);
/* Set the IPv6 Ethernet type */
eth->type = HTONS(ETHTYPE_IP6);
#if 0
/* No additional neighbor lookup is required on this packet.
* REVISIT: It is inappropriate to set this bit if we get here