MCPcopy Create free account
hub / github.com/F-Stack/f-stack / infiniband_ipv6_multicast_map

Function infiniband_ipv6_multicast_map

freebsd/net/if_infiniband.c:99–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97
98#ifdef INET6
99static inline void
100infiniband_ipv6_multicast_map(const struct in6_addr *addr,
101 const uint8_t *broadcast, uint8_t *buf)
102{
103 uint8_t scope;
104
105 scope = broadcast[5] & 0xF;
106
107 buf[0] = 0;
108 buf[1] = 0xff;
109 buf[2] = 0xff;
110 buf[3] = 0xff;
111 buf[4] = 0xff;
112 buf[5] = 0x10 | scope;
113 buf[6] = 0x60;
114 buf[7] = 0x1b;
115 buf[8] = broadcast[8];
116 buf[9] = broadcast[9];
117 memcpy(&buf[10], &addr->s6_addr[6], 10);
118}
119#endif
120
121/*

Callers 2

infiniband_resolve_addrFunction · 0.85
infiniband_resolvemultiFunction · 0.85

Calls 1

memcpyFunction · 0.50

Tested by

no test coverage detected