Add support for more IPv4 and IPv6 related macros in the LinuxKPI.
MFC after: 1 week Sponsored by: Mellanox Technologies
This commit is contained in:
parent
e336138c40
commit
303bd80ad5
@ -41,5 +41,7 @@
|
||||
|
||||
#define ipv4_is_zeronet(be) IN_ZERONET(ntohl(be))
|
||||
#define ipv4_is_loopback(be) IN_LOOPBACK(ntohl(be))
|
||||
#define ipv4_is_multicast(be) IN_MULTICAST(ntohl(be))
|
||||
#define ipv4_is_lbcast(be) ((be) == INADDR_BROADCAST)
|
||||
|
||||
#endif /* _LINUX_IN_H_ */
|
||||
|
@ -35,8 +35,12 @@
|
||||
#include <netinet/in.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
#define ipv6_addr_loopback IN6_IS_ADDR_LOOPBACK
|
||||
#define ipv6_addr_copy(dst, src) \
|
||||
#define IPV6_DEFAULT_HOPLIMIT 64
|
||||
|
||||
#define ipv6_addr_loopback(addr) IN6_IS_ADDR_LOOPBACK(addr)
|
||||
#define ipv6_addr_any(addr) IN6_IS_ADDR_UNSPECIFIED(addr)
|
||||
|
||||
#define ipv6_addr_copy(dst, src) \
|
||||
memcpy((dst), (src), sizeof(struct in6_addr))
|
||||
|
||||
static inline void
|
||||
|
Loading…
Reference in New Issue
Block a user