Merged in masayuki2009/nuttx.nuttx/network_test (pull request #452)

ICMPv6: Support source link-layer address option in RA

Approved-by: Gregory Nutt <gnutt@nuttx.org>
This commit is contained in:
Masayuki Ishikawa 2017-08-08 12:33:21 +00:00 committed by Gregory Nutt
commit 7d4194686c

View File

@ -255,6 +255,14 @@ void icmpv6_input(FAR struct net_driver_s *dev)
for (ndx = 0; ndx + sizeof(struct icmpv6_prefixinfo_s) <= optlen; )
{
FAR struct icmpv6_srclladdr_s *sllopt =
(FAR struct icmpv6_srclladdr_s *)&options[ndx];
if (sllopt->opttype == 1 && sllopt->optlen == 1)
{
neighbor_add(icmp->srcipaddr, DEV_LLTYPE(dev), sllopt->srclladdr);
}
FAR struct icmpv6_prefixinfo_s *opt =
(FAR struct icmpv6_prefixinfo_s *)&options[ndx];