Lines Matching +full:address +full:- +full:1

4  * Generic IPv6 and IPv4 address definitions.
10 * SPDX-License-Identifier: Apache-2.0
45 #define PF_INET 1 /**< IP protocol family version 4. */
50 #define PF_LOCAL 6 /**< Inter-process communication */
51 #define PF_UNIX PF_LOCAL /**< Inter-process communication */
53 /* Address families. */
54 #define AF_UNSPEC PF_UNSPEC /**< Unspecified address family. */
60 #define AF_LOCAL PF_LOCAL /**< Inter-process communication */
61 #define AF_UNIX PF_UNIX /**< Inter-process communication */
65 IPPROTO_IP = 0, /**< IP protocol (pseudo-val for setsockopt() */
66 IPPROTO_ICMP = 1, /**< ICMP protocol */
89 SOCK_STREAM = 1, /**< Stream socket type */
94 /** @brief Convert 16-bit value from network to host byte order.
102 /** @brief Convert 32-bit value from network to host byte order.
110 /** @brief Convert 64-bit value from network to host byte order.
118 /** @brief Convert 16-bit value from host to network byte order.
126 /** @brief Convert 32-bit value from host to network byte order.
134 /** @brief Convert 64-bit value from host to network byte order.
142 /** IPv6 address struct */
145 uint8_t s6_addr[16]; /**< IPv6 address buffer */
151 /** Binary size of the IPv6 address */
154 /** IPv4 address struct */
157 uint8_t s4_addr[4]; /**< IPv4 address buffer */
159 uint32_t s4_addr32[1]; /**< In big endian */
164 /** Binary size of the IPv4 address */
167 /** Socket address family type */
170 /** Length of a socket address */
181 /** Socket address struct for IPv6. */
185 struct in6_addr sin6_addr; /**< IPv6 address */
189 /** Socket address struct for IPv4. */
193 struct in_addr sin_addr; /**< IPv4 address */
196 /** Socket address struct for packet socket. */
199 uint16_t sll_protocol; /**< Physical-layer protocol */
203 uint8_t sll_halen; /**< Length of address */
204 uint8_t sll_addr[8]; /**< Physical-layer address, big endian */
209 /** Socket address struct for IPv6 where address is a pointer */
213 struct in6_addr *sin6_addr; /**< IPv6 address */
217 /** Socket address struct for IPv4 where address is a pointer */
221 struct in_addr *sin_addr; /**< IPv4 address */
224 /** Socket address struct for packet socket where address is a pointer */
227 uint16_t sll_protocol; /**< Physical-layer protocol */
231 uint8_t sll_halen; /**< Length of address */
232 uint8_t *sll_addr; /**< Physical-layer address, big endian */
235 /** Socket address struct for unix socket where address is a pointer */
258 void *msg_name; /**< Optional socket address, big endian */
259 socklen_t msg_namelen; /**< Size of socket address */
271 int cmsg_type; /**< Protocol-specific type */
296 ((msghdr)->msg_controllen >= sizeof(struct cmsghdr) ? \
297 (struct cmsghdr *)((msghdr)->msg_control) : NULL)
307 (((uint8_t *)(cmsg) + ALIGN_H((cmsg)->cmsg_len) + \
309 (uint8_t *)((msghdr)->msg_control) + (msghdr)->msg_controllen) ? \
312 ALIGN_H((cmsg)->cmsg_len))))
347 #define PACKET_BROADCAST 1 /* To all */
355 #define ARPHRD_ETHER 1
409 sa_family_t sa_family; /**< Address family */
411 char data[NET_SOCKADDR_MAX_SIZE - sizeof(sa_family_t)];
419 char data[NET_SOCKADDR_PTR_MAX_SIZE - sizeof(sa_family_t)];
425 char data[NET_SOCKADDR_MAX_SIZE - sizeof(sa_family_t)];
428 /* Socket address struct for UNIX domain sockets */
431 char sun_path[NET_SOCKADDR_MAX_SIZE - sizeof(sa_family_t)];
442 /** A pointer to IPv6 any address (all values zero) */
445 /** A pointer to IPv6 loopback address (::1) */
450 /** IPv6 address initializer */
454 /** IPv6 loopback address initializer */
456 0, 0, 0, 0, 0, 0, 0, 0, 1 } } }
458 /** IPv4 any address */
461 /** IPv4 broadcast address */
464 /** IPv4 address initializer */
467 /** IPv6 loopback address initializer */
468 #define INADDR_LOOPBACK_INIT { { { 127, 0, 0, 1 } } }
470 /** Max length of the IPv4 address as a string. Defined by POSIX. */
472 /** Max length of the IPv6 address as a string. Takes into account possible
502 /** @brief Network packet priority settings described in IEEE 802.1Q Annex I.1 */
504 NET_PRIORITY_BK = 1, /**< Background (lowest) */
518 struct net_addr *remote_addr; /**< IPv6/IPv4 remote address */
519 struct net_addr *local_addr; /**< IPv6/IPv4 local address */
525 /** @brief What is the current state of the network address */
527 NET_ADDR_ANY_STATE = -1, /**< Default (invalid) address type */
528 NET_ADDR_TENTATIVE = 0, /**< Tentative address */
529 NET_ADDR_PREFERRED, /**< Preferred address */
530 NET_ADDR_DEPRECATED, /**< Deprecated address */
533 /** @brief How the network address is assigned to network interface */
537 /** Auto configured address */
539 /** Address is from DHCP */
541 /** Manually set address */
543 /** Manually set address which is overridable by DHCP */
665 #define NET_IPV6_FRAGH_OFFSET_MASK 0xfff8 /* Mask for the 13-bit Fragment Offset field */
666 #define NET_IPV4_FRAGH_OFFSET_MASK 0x1fff /* Mask for the 13-bit Fragment Offset field */
667 #define NET_IPV4_MORE_FRAG_MASK 0x2000 /* Mask for the 1-bit More Fragments field */
668 #define NET_IPV4_DO_NOT_FRAG_MASK 0x4000 /* Mask for the 1-bit Do Not Fragment field */
673 * @brief Check if the IPv6 address is a loopback address (::1).
675 * @param addr IPv6 address
677 * @return True if address is a loopback address, False otherwise.
681 return UNALIGNED_GET(&addr->s6_addr32[0]) == 0 && in net_ipv6_is_addr_loopback()
682 UNALIGNED_GET(&addr->s6_addr32[1]) == 0 && in net_ipv6_is_addr_loopback()
683 UNALIGNED_GET(&addr->s6_addr32[2]) == 0 && in net_ipv6_is_addr_loopback()
684 ntohl(UNALIGNED_GET(&addr->s6_addr32[3])) == 1; in net_ipv6_is_addr_loopback()
688 * @brief Check if the IPv6 address is a multicast address.
690 * @param addr IPv6 address
692 * @return True if address is multicast address, False otherwise.
696 return addr->s6_addr[0] == 0xFF; in net_ipv6_is_addr_mcast()
706 * @brief Check if IPv6 address is found in one of the network interfaces.
708 * @param addr IPv6 address
710 * @return True if address was found, False otherwise.
721 * @brief Check if IPv6 multicast address is found in one of the
724 * @param maddr Multicast IPv6 address
726 * @return True if address was found, False otherwise.
736 * @param addr1 First IPv6 address.
737 * @param addr2 Second IPv6 address.
746 uint8_t bits = 128 - length; in net_ipv6_is_prefix()
767 mask = (uint8_t)((0xff << (8 - remain)) ^ 0xff) << remain; in net_ipv6_is_prefix()
774 * @brief Get the IPv6 network address via the unicast address and the prefix mask.
776 * @param inaddr Unicast IPv6 address.
777 * @param outaddr Prefix masked IPv6 address (network address).
784 uint8_t bits = 128 - prefix_len; in net_ipv6_addr_prefix_mask()
800 mask = (uint8_t)((0xff << (8 - remain)) ^ 0xff) << remain; in net_ipv6_addr_prefix_mask()
805 * @brief Check if the IPv4 address is a loopback address (127.0.0.0/8).
807 * @param addr IPv4 address
809 * @return True if address is a loopback address, False otherwise.
813 return addr->s4_addr[0] == 127U; in net_ipv4_is_addr_loopback()
817 * @brief Check if the IPv4 address is unspecified (all bits zero)
819 * @param addr IPv4 address.
821 * @return True if the address is unspecified, false otherwise.
825 return UNALIGNED_GET(&addr->s_addr) == 0; in net_ipv4_is_addr_unspecified()
829 * @brief Check if the IPv4 address is a multicast address.
831 * @param addr IPv4 address
833 * @return True if address is multicast address, False otherwise.
837 return (ntohl(UNALIGNED_GET(&addr->s_addr)) & 0xF0000000) == 0xE0000000; in net_ipv4_is_addr_mcast()
841 * @brief Check if the given IPv4 address is a link local address.
843 * @param addr A valid pointer on an IPv4 address
849 return (ntohl(UNALIGNED_GET(&addr->s_addr)) & 0xFFFF0000) == 0xA9FE0000; in net_ipv4_is_ll_addr()
853 * @brief Check if the given IPv4 address is from a private address range.
857 * @param addr A valid pointer on an IPv4 address
865 masked_24 = ntohl(UNALIGNED_GET(&addr->s_addr)) & 0xFFFFFF00; in net_ipv4_is_private_addr()
881 * @brief Copy an IPv4 or IPv6 address
883 * @param dest Destination IP address.
884 * @param src Source IP address.
886 * @return Destination address.
892 * @brief Copy an IPv4 address raw buffer
894 * @param dest Destination IP address.
895 * @param src Source IP address.
904 * @brief Copy an IPv6 address raw buffer
906 * @param dest Destination IP address.
907 * @param src Source IP address.
918 * @param addr1 Pointer to IPv4 address.
919 * @param addr2 Pointer to IPv4 address.
926 return UNALIGNED_GET(&addr1->s_addr) == UNALIGNED_GET(&addr2->s_addr); in net_ipv4_addr_cmp()
930 * @brief Compare two raw IPv4 address buffers
932 * @param addr1 Pointer to IPv4 address buffer.
933 * @param addr2 Pointer to IPv4 address buffer.
947 * @param addr1 Pointer to IPv6 address.
948 * @param addr2 Pointer to IPv6 address.
959 * @brief Compare two raw IPv6 address buffers
961 * @param addr1 Pointer to IPv6 address buffer.
962 * @param addr2 Pointer to IPv6 address buffer.
974 * @brief Check if the given IPv6 address is a link local address.
976 * @param addr A valid pointer on an IPv6 address
982 return UNALIGNED_GET(&addr->s6_addr16[0]) == htons(0xFE80); in net_ipv6_is_ll_addr()
986 * @brief Check if the given IPv6 address is a site local address.
988 * @param addr A valid pointer on an IPv6 address
994 return UNALIGNED_GET(&addr->s6_addr16[0]) == htons(0xFEC0); in net_ipv6_is_sl_addr()
999 * @brief Check if the given IPv6 address is a unique local address.
1001 * @param addr A valid pointer on an IPv6 address
1007 return addr->s6_addr[0] == 0xFD; in net_ipv6_is_ula_addr()
1011 * @brief Check if the given IPv6 address is a global address.
1013 * @param addr A valid pointer on an IPv6 address
1019 return (addr->s6_addr[0] & 0xE0) == 0x20; in net_ipv6_is_global_addr()
1023 * @brief Check if the given IPv6 address is from a private/local address range.
1027 * @param addr A valid pointer on an IPv6 address
1035 masked_32 = ntohl(UNALIGNED_GET(&addr->s6_addr32[0])); in net_ipv6_is_private_addr()
1043 * @brief Return pointer to any (all bits zeros) IPv6 address.
1045 * @return Any IPv6 address.
1050 * @brief Return pointer to any (all bits zeros) IPv4 address.
1052 * @return Any IPv4 address.
1057 * @brief Return pointer to broadcast (all bits ones) IPv4 address.
1059 * @return Broadcast IPv4 address.
1068 * @brief Check if the given address belongs to same subnet that
1072 * @param addr IPv4 address
1074 * @return True if address is in same subnet, false otherwise.
1086 * @brief Check if the given IPv4 address is a broadcast address.
1089 * @param addr IPv4 address
1091 * @return True if address is a broadcast address, false otherwise.
1118 * @brief Check if the IPv4 address is assigned to any network interface
1121 * @param addr A valid pointer on an IPv4 address
1123 * @return True if IPv4 address is found in one of the network interfaces,
1139 * @brief Check if the IPv6 address is unspecified (all bits zero)
1141 * @param addr IPv6 address.
1143 * @return True if the address is unspecified, false otherwise.
1147 return UNALIGNED_GET(&addr->s6_addr32[0]) == 0 && in net_ipv6_is_addr_unspecified()
1148 UNALIGNED_GET(&addr->s6_addr32[1]) == 0 && in net_ipv6_is_addr_unspecified()
1149 UNALIGNED_GET(&addr->s6_addr32[2]) == 0 && in net_ipv6_is_addr_unspecified()
1150 UNALIGNED_GET(&addr->s6_addr32[3]) == 0; in net_ipv6_is_addr_unspecified()
1154 * @brief Check if the IPv6 address is solicited node multicast address
1155 * FF02:0:0:0:0:1:FFXX:XXXX defined in RFC 3513
1157 * @param addr IPv6 address.
1159 * @return True if the address is solicited node address, false otherwise.
1163 return UNALIGNED_GET(&addr->s6_addr32[0]) == htonl(0xff020000) && in net_ipv6_is_addr_solicited_node()
1164 UNALIGNED_GET(&addr->s6_addr32[1]) == 0x00000000 && in net_ipv6_is_addr_solicited_node()
1165 UNALIGNED_GET(&addr->s6_addr32[2]) == htonl(0x00000001) && in net_ipv6_is_addr_solicited_node()
1166 ((UNALIGNED_GET(&addr->s6_addr32[3]) & htonl(0xff000000)) == in net_ipv6_is_addr_solicited_node()
1171 * @brief Check if the IPv6 address is a given scope multicast
1172 * address (FFyx::).
1174 * @param addr IPv6 address
1177 * @return True if the address is in given scope multicast address,
1183 return (addr->s6_addr[0] == 0xff) && ((addr->s6_addr[1] & 0xF) == scope); in net_ipv6_is_addr_mcast_scope()
1189 * @param addr_1 IPv6 address 1
1190 * @param addr_2 IPv6 address 2
1198 return (addr_1->s6_addr[0] == 0xff) && (addr_2->s6_addr[0] == 0xff) && in net_ipv6_is_same_mcast_scope()
1199 (addr_1->s6_addr[1] == addr_2->s6_addr[1]); in net_ipv6_is_same_mcast_scope()
1203 * @brief Check if the IPv6 address is a global multicast address (FFxE::/16).
1205 * @param addr IPv6 address.
1207 * @return True if the address is global multicast address, false otherwise.
1215 * @brief Check if the IPv6 address is a interface scope multicast
1216 * address (FFx1::).
1218 * @param addr IPv6 address.
1220 * @return True if the address is a interface scope multicast address,
1229 * @brief Check if the IPv6 address is a link local scope multicast
1230 * address (FFx2::).
1232 * @param addr IPv6 address.
1234 * @return True if the address is a link local scope multicast address,
1243 * @brief Check if the IPv6 address is a mesh-local scope multicast
1244 * address (FFx3::).
1246 * @param addr IPv6 address.
1248 * @return True if the address is a mesh-local scope multicast address,
1257 * @brief Check if the IPv6 address is a site scope multicast
1258 * address (FFx5::).
1260 * @param addr IPv6 address.
1262 * @return True if the address is a site scope multicast address,
1271 * @brief Check if the IPv6 address is an organization scope multicast
1272 * address (FFx8::).
1274 * @param addr IPv6 address.
1276 * @return True if the address is an organization scope multicast address,
1285 * @brief Check if the IPv6 address belongs to certain multicast group
1287 * @param addr IPv6 address.
1288 * @param group Group id IPv6 address, the values must be in network
1291 * @return True if the IPv6 multicast address belongs to given multicast
1297 return UNALIGNED_GET(&addr->s6_addr16[1]) == group->s6_addr16[1] && in net_ipv6_is_addr_mcast_group()
1298 UNALIGNED_GET(&addr->s6_addr16[2]) == group->s6_addr16[2] && in net_ipv6_is_addr_mcast_group()
1299 UNALIGNED_GET(&addr->s6_addr16[3]) == group->s6_addr16[3] && in net_ipv6_is_addr_mcast_group()
1300 UNALIGNED_GET(&addr->s6_addr32[1]) == group->s6_addr32[1] && in net_ipv6_is_addr_mcast_group()
1301 UNALIGNED_GET(&addr->s6_addr32[2]) == group->s6_addr32[1] && in net_ipv6_is_addr_mcast_group()
1302 UNALIGNED_GET(&addr->s6_addr32[3]) == group->s6_addr32[3]; in net_ipv6_is_addr_mcast_group()
1306 * @brief Check if the IPv6 address belongs to the all nodes multicast group
1308 * @param addr IPv6 address
1310 * @return True if the IPv6 multicast address belongs to the all nodes multicast
1325 * @brief Check if the IPv6 address is a interface scope all nodes multicast
1326 * address (FF01::1).
1328 * @param addr IPv6 address.
1330 * @return True if the address is a interface scope all nodes multicast address,
1341 * @brief Check if the IPv6 address is a link local scope all nodes multicast
1342 * address (FF02::1).
1344 * @param addr IPv6 address.
1346 * @return True if the address is a link local scope all nodes multicast
1347 * address, false otherwise.
1357 * @brief Create solicited node IPv6 multicast address
1358 * FF02:0:0:0:0:1:FFXX:XXXX defined in RFC 3513
1360 * @param src IPv6 address.
1361 * @param dst IPv6 address.
1367 dst->s6_addr[0] = 0xFF; in net_ipv6_addr_create_solicited_node()
1368 dst->s6_addr[1] = 0x02; in net_ipv6_addr_create_solicited_node()
1369 UNALIGNED_PUT(0, &dst->s6_addr16[1]); in net_ipv6_addr_create_solicited_node()
1370 UNALIGNED_PUT(0, &dst->s6_addr16[2]); in net_ipv6_addr_create_solicited_node()
1371 UNALIGNED_PUT(0, &dst->s6_addr16[3]); in net_ipv6_addr_create_solicited_node()
1372 UNALIGNED_PUT(0, &dst->s6_addr16[4]); in net_ipv6_addr_create_solicited_node()
1373 dst->s6_addr[10] = 0U; in net_ipv6_addr_create_solicited_node()
1374 dst->s6_addr[11] = 0x01; in net_ipv6_addr_create_solicited_node()
1375 dst->s6_addr[12] = 0xFF; in net_ipv6_addr_create_solicited_node()
1376 dst->s6_addr[13] = src->s6_addr[13]; in net_ipv6_addr_create_solicited_node()
1377 UNALIGNED_PUT(UNALIGNED_GET(&src->s6_addr16[7]), &dst->s6_addr16[7]); in net_ipv6_addr_create_solicited_node()
1380 /** @brief Construct an IPv6 address from eight 16-bit words.
1382 * @param addr IPv6 address
1383 * @param addr0 16-bit word which is part of the address
1384 * @param addr1 16-bit word which is part of the address
1385 * @param addr2 16-bit word which is part of the address
1386 * @param addr3 16-bit word which is part of the address
1387 * @param addr4 16-bit word which is part of the address
1388 * @param addr5 16-bit word which is part of the address
1389 * @param addr6 16-bit word which is part of the address
1390 * @param addr7 16-bit word which is part of the address
1398 UNALIGNED_PUT(htons(addr0), &addr->s6_addr16[0]); in net_ipv6_addr_create()
1399 UNALIGNED_PUT(htons(addr1), &addr->s6_addr16[1]); in net_ipv6_addr_create()
1400 UNALIGNED_PUT(htons(addr2), &addr->s6_addr16[2]); in net_ipv6_addr_create()
1401 UNALIGNED_PUT(htons(addr3), &addr->s6_addr16[3]); in net_ipv6_addr_create()
1402 UNALIGNED_PUT(htons(addr4), &addr->s6_addr16[4]); in net_ipv6_addr_create()
1403 UNALIGNED_PUT(htons(addr5), &addr->s6_addr16[5]); in net_ipv6_addr_create()
1404 UNALIGNED_PUT(htons(addr6), &addr->s6_addr16[6]); in net_ipv6_addr_create()
1405 UNALIGNED_PUT(htons(addr7), &addr->s6_addr16[7]); in net_ipv6_addr_create()
1409 * @brief Create link local allnodes multicast IPv6 address
1411 * @param addr IPv6 address
1419 * @brief Create link local allrouters multicast IPv6 address
1421 * @param addr IPv6 address
1429 * @brief Create IPv4 mapped IPv6 address
1431 * @param addr4 IPv4 address
1432 * @param addr6 IPv6 address to be created
1438 ntohs(addr4->s4_addr16[0]), in net_ipv6_addr_create_v4_mapped()
1439 ntohs(addr4->s4_addr16[1])); in net_ipv6_addr_create_v4_mapped()
1443 * @brief Is the IPv6 address an IPv4 mapped one. The v4 mapped addresses
1446 * @param addr IPv6 address
1448 * @return True if IPv6 address is a IPv4 mapped address, False otherwise.
1452 if (UNALIGNED_GET(&addr->s6_addr32[0]) == 0 && in net_ipv6_addr_is_v4_mapped()
1453 UNALIGNED_GET(&addr->s6_addr32[1]) == 0 && in net_ipv6_addr_is_v4_mapped()
1454 UNALIGNED_GET(&addr->s6_addr16[5]) == 0xffff) { in net_ipv6_addr_is_v4_mapped()
1462 * @brief Generate IPv6 address using a prefix and interface identifier.
1463 * Interface identifier is either generated from EUI-64 (MAC) defined
1472 * @param dad_counter Duplicate Address Detection counter value, can be set to 0
1474 * @param addr IPv6 address
1475 * @param lladdr Link local address
1487 * @brief Create IPv6 address interface identifier.
1489 * @param addr IPv6 address
1490 * @param lladdr Link local address
1499 * @brief Check if given address is based on link layer address
1510 switch (lladdr->len) { in net_ipv6_addr_based_on_ll()
1512 if (!memcmp(&addr->s6_addr[14], lladdr->addr, lladdr->len) && in net_ipv6_addr_based_on_ll()
1513 addr->s6_addr[8] == 0U && in net_ipv6_addr_based_on_ll()
1514 addr->s6_addr[9] == 0U && in net_ipv6_addr_based_on_ll()
1515 addr->s6_addr[10] == 0U && in net_ipv6_addr_based_on_ll()
1516 addr->s6_addr[11] == 0xff && in net_ipv6_addr_based_on_ll()
1517 addr->s6_addr[12] == 0xfe) { in net_ipv6_addr_based_on_ll()
1523 if (lladdr->type == NET_LINK_ETHERNET) { in net_ipv6_addr_based_on_ll()
1524 if (!memcmp(&addr->s6_addr[9], &lladdr->addr[1], 2) && in net_ipv6_addr_based_on_ll()
1525 !memcmp(&addr->s6_addr[13], &lladdr->addr[3], 3) && in net_ipv6_addr_based_on_ll()
1526 addr->s6_addr[11] == 0xff && in net_ipv6_addr_based_on_ll()
1527 addr->s6_addr[12] == 0xfe && in net_ipv6_addr_based_on_ll()
1528 (addr->s6_addr[8] ^ 0x02) == lladdr->addr[0]) { in net_ipv6_addr_based_on_ll()
1535 if (!memcmp(&addr->s6_addr[9], &lladdr->addr[1], in net_ipv6_addr_based_on_ll()
1536 lladdr->len - 1) && in net_ipv6_addr_based_on_ll()
1537 (addr->s6_addr[8] ^ 0x02) == lladdr->addr[0]) { in net_ipv6_addr_based_on_ll()
1551 * @param addr Socket address
1553 * @return Pointer to IPv6 socket address
1564 * @param addr Socket address
1566 * @return Pointer to IPv4 socket address
1577 * @param addr Socket address
1579 * @return Pointer to IPv6 socket address
1591 * @param addr Socket address
1593 * @return Pointer to IPv4 socket address
1605 * @param addr Socket address
1607 * @return Pointer to linklayer socket address
1619 * @param addr Socket address
1621 * @return Pointer to CAN socket address
1630 * @brief Convert a string to IP address.
1632 * @param family IP address family (AF_INET or AF_INET6)
1633 * @param src IP address in a null terminated string
1645 * @brief Convert IP address to string form.
1647 * @param family IP address family (AF_INET or AF_INET6)
1650 * @param dst Buffer for IP address as a null terminated string
1659 * @brief Parse a string that contains either IPv4 or IPv6 address
1663 * @details Syntax of the IP address string:
1666 * [2001:db8::1]:8080
1673 * @param str String that contains the IP address.
1706 return (int32_t)(seq1 - seq2); in net_tcp_seq_cmp()
1801 * @brief Return network address family value as a string. This is only usable
1804 * @param family Network address family code
1806 * @return Network address family as a string, or NULL if family is unknown.
1829 return -ENOTSUP; in net_ipv6_pe_add_filter()
1847 return -ENOTSUP; in net_ipv6_pe_del_filter()