Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(583)

Side by Side Diff: fusl/include/netinet/icmp6.h

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 #ifndef _NETINET_ICMP6_H 1 #ifndef _NETINET_ICMP6_H
2 #define _NETINET_ICMP6_H 2 #define _NETINET_ICMP6_H
3 3
4 #ifdef __cplusplus 4 #ifdef __cplusplus
5 extern "C" { 5 extern "C" {
6 #endif 6 #endif
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string.h> 9 #include <string.h>
10 #include <sys/types.h> 10 #include <sys/types.h>
11 #include <netinet/in.h> 11 #include <netinet/in.h>
12 12
13 #define ICMP6_FILTER 1 13 #define ICMP6_FILTER 1
14 14
15 #define ICMP6_FILTER_BLOCK» » 1 15 #define ICMP6_FILTER_BLOCK 1
16 #define ICMP6_FILTER_PASS» » 2 16 #define ICMP6_FILTER_PASS 2
17 #define ICMP6_FILTER_BLOCKOTHERS» 3 17 #define ICMP6_FILTER_BLOCKOTHERS 3
18 #define ICMP6_FILTER_PASSONLY» » 4 18 #define ICMP6_FILTER_PASSONLY 4
19 19
20 struct icmp6_filter { 20 struct icmp6_filter {
21 » uint32_t icmp6_filt[8]; 21 uint32_t icmp6_filt[8];
22 }; 22 };
23 23
24 struct icmp6_hdr { 24 struct icmp6_hdr {
25 » uint8_t icmp6_type; 25 uint8_t icmp6_type;
26 » uint8_t icmp6_code; 26 uint8_t icmp6_code;
27 » uint16_t icmp6_cksum; 27 uint16_t icmp6_cksum;
28 » union { 28 union {
29 » » uint32_t icmp6_un_data32[1]; 29 uint32_t icmp6_un_data32[1];
30 » » uint16_t icmp6_un_data16[2]; 30 uint16_t icmp6_un_data16[2];
31 » » uint8_t icmp6_un_data8[4]; 31 uint8_t icmp6_un_data8[4];
32 » } icmp6_dataun; 32 } icmp6_dataun;
33 }; 33 };
34 34
35 #define icmp6_data32 icmp6_dataun.icmp6_un_data32 35 #define icmp6_data32 icmp6_dataun.icmp6_un_data32
36 #define icmp6_data16 icmp6_dataun.icmp6_un_data16 36 #define icmp6_data16 icmp6_dataun.icmp6_un_data16
37 #define icmp6_data8 icmp6_dataun.icmp6_un_data8 37 #define icmp6_data8 icmp6_dataun.icmp6_un_data8
38 #define icmp6_pptr icmp6_data32[0] 38 #define icmp6_pptr icmp6_data32[0]
39 #define icmp6_mtu icmp6_data32[0] 39 #define icmp6_mtu icmp6_data32[0]
40 #define icmp6_id icmp6_data16[0] 40 #define icmp6_id icmp6_data16[0]
41 #define icmp6_seq icmp6_data16[1] 41 #define icmp6_seq icmp6_data16[1]
42 #define icmp6_maxdelay icmp6_data16[0] 42 #define icmp6_maxdelay icmp6_data16[0]
43 43
44 #define ICMP6_DST_UNREACH 1 44 #define ICMP6_DST_UNREACH 1
45 #define ICMP6_PACKET_TOO_BIG 2 45 #define ICMP6_PACKET_TOO_BIG 2
46 #define ICMP6_TIME_EXCEEDED 3 46 #define ICMP6_TIME_EXCEEDED 3
47 #define ICMP6_PARAM_PROB 4 47 #define ICMP6_PARAM_PROB 4
48 48
49 #define ICMP6_INFOMSG_MASK 0x80 49 #define ICMP6_INFOMSG_MASK 0x80
50 50
51 #define ICMP6_ECHO_REQUEST 128 51 #define ICMP6_ECHO_REQUEST 128
52 #define ICMP6_ECHO_REPLY 129 52 #define ICMP6_ECHO_REPLY 129
53 #define MLD_LISTENER_QUERY 130 53 #define MLD_LISTENER_QUERY 130
54 #define MLD_LISTENER_REPORT 131 54 #define MLD_LISTENER_REPORT 131
55 #define MLD_LISTENER_REDUCTION 132 55 #define MLD_LISTENER_REDUCTION 132
56 56
57 #define ICMP6_DST_UNREACH_NOROUTE 0 57 #define ICMP6_DST_UNREACH_NOROUTE 0
58 #define ICMP6_DST_UNREACH_ADMIN 1 58 #define ICMP6_DST_UNREACH_ADMIN 1
59 #define ICMP6_DST_UNREACH_BEYONDSCOPE 2 59 #define ICMP6_DST_UNREACH_BEYONDSCOPE 2
60 #define ICMP6_DST_UNREACH_ADDR 3 60 #define ICMP6_DST_UNREACH_ADDR 3
61 #define ICMP6_DST_UNREACH_NOPORT 4 61 #define ICMP6_DST_UNREACH_NOPORT 4
62 62
63 #define ICMP6_TIME_EXCEED_TRANSIT 0 63 #define ICMP6_TIME_EXCEED_TRANSIT 0
64 #define ICMP6_TIME_EXCEED_REASSEMBLY 1 64 #define ICMP6_TIME_EXCEED_REASSEMBLY 1
65 65
66 #define ICMP6_PARAMPROB_HEADER 0 66 #define ICMP6_PARAMPROB_HEADER 0
67 #define ICMP6_PARAMPROB_NEXTHEADER 1 67 #define ICMP6_PARAMPROB_NEXTHEADER 1
68 #define ICMP6_PARAMPROB_OPTION 2 68 #define ICMP6_PARAMPROB_OPTION 2
69 69
70 #define ICMP6_FILTER_WILLPASS(type, filterp) \ 70 #define ICMP6_FILTER_WILLPASS(type, filterp) \
71 » ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) 71 ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type)&31))) == 0)
72 72
73 #define ICMP6_FILTER_WILLBLOCK(type, filterp) \ 73 #define ICMP6_FILTER_WILLBLOCK(type, filterp) \
74 » ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) 74 ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type)&31))) != 0)
75 75
76 #define ICMP6_FILTER_SETPASS(type, filterp) \ 76 #define ICMP6_FILTER_SETPASS(type, filterp) \
77 » ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) 77 ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type)&31))))
78 78
79 #define ICMP6_FILTER_SETBLOCK(type, filterp) \ 79 #define ICMP6_FILTER_SETBLOCK(type, filterp) \
80 » ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) 80 ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type)&31))))
81 81
82 #define ICMP6_FILTER_SETPASSALL(filterp) \ 82 #define ICMP6_FILTER_SETPASSALL(filterp) \
83 » memset (filterp, 0, sizeof (struct icmp6_filter)); 83 memset(filterp, 0, sizeof(struct icmp6_filter));
84 84
85 #define ICMP6_FILTER_SETBLOCKALL(filterp) \ 85 #define ICMP6_FILTER_SETBLOCKALL(filterp) \
86 » memset (filterp, 0xFF, sizeof (struct icmp6_filter)); 86 memset(filterp, 0xFF, sizeof(struct icmp6_filter));
87 87
88 #define ND_ROUTER_SOLICIT 133 88 #define ND_ROUTER_SOLICIT 133
89 #define ND_ROUTER_ADVERT 134 89 #define ND_ROUTER_ADVERT 134
90 #define ND_NEIGHBOR_SOLICIT 135 90 #define ND_NEIGHBOR_SOLICIT 135
91 #define ND_NEIGHBOR_ADVERT 136 91 #define ND_NEIGHBOR_ADVERT 136
92 #define ND_REDIRECT 137 92 #define ND_REDIRECT 137
93 93
94 struct nd_router_solicit { 94 struct nd_router_solicit {
95 » struct icmp6_hdr nd_rs_hdr; 95 struct icmp6_hdr nd_rs_hdr;
96 }; 96 };
97 97
98 #define nd_rs_type nd_rs_hdr.icmp6_type 98 #define nd_rs_type nd_rs_hdr.icmp6_type
99 #define nd_rs_code nd_rs_hdr.icmp6_code 99 #define nd_rs_code nd_rs_hdr.icmp6_code
100 #define nd_rs_cksum nd_rs_hdr.icmp6_cksum 100 #define nd_rs_cksum nd_rs_hdr.icmp6_cksum
101 #define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] 101 #define nd_rs_reserved nd_rs_hdr.icmp6_data32[0]
102 102
103 struct nd_router_advert { 103 struct nd_router_advert {
104 » struct icmp6_hdr nd_ra_hdr; 104 struct icmp6_hdr nd_ra_hdr;
105 » uint32_t nd_ra_reachable; 105 uint32_t nd_ra_reachable;
106 » uint32_t nd_ra_retransmit; 106 uint32_t nd_ra_retransmit;
107 }; 107 };
108 108
109 #define nd_ra_type nd_ra_hdr.icmp6_type 109 #define nd_ra_type nd_ra_hdr.icmp6_type
110 #define nd_ra_code nd_ra_hdr.icmp6_code 110 #define nd_ra_code nd_ra_hdr.icmp6_code
111 #define nd_ra_cksum nd_ra_hdr.icmp6_cksum 111 #define nd_ra_cksum nd_ra_hdr.icmp6_cksum
112 #define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] 112 #define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0]
113 #define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] 113 #define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1]
114 #define ND_RA_FLAG_MANAGED 0x80 114 #define ND_RA_FLAG_MANAGED 0x80
115 #define ND_RA_FLAG_OTHER 0x40 115 #define ND_RA_FLAG_OTHER 0x40
116 #define ND_RA_FLAG_HOME_AGENT 0x20 116 #define ND_RA_FLAG_HOME_AGENT 0x20
117 #define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] 117 #define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1]
118 118
119 struct nd_neighbor_solicit { 119 struct nd_neighbor_solicit {
120 » struct icmp6_hdr nd_ns_hdr; 120 struct icmp6_hdr nd_ns_hdr;
121 » struct in6_addr nd_ns_target; 121 struct in6_addr nd_ns_target;
122 }; 122 };
123 123
124 #define nd_ns_type nd_ns_hdr.icmp6_type 124 #define nd_ns_type nd_ns_hdr.icmp6_type
125 #define nd_ns_code nd_ns_hdr.icmp6_code 125 #define nd_ns_code nd_ns_hdr.icmp6_code
126 #define nd_ns_cksum nd_ns_hdr.icmp6_cksum 126 #define nd_ns_cksum nd_ns_hdr.icmp6_cksum
127 #define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] 127 #define nd_ns_reserved nd_ns_hdr.icmp6_data32[0]
128 128
129 struct nd_neighbor_advert { 129 struct nd_neighbor_advert {
130 » struct icmp6_hdr nd_na_hdr; 130 struct icmp6_hdr nd_na_hdr;
131 » struct in6_addr nd_na_target; 131 struct in6_addr nd_na_target;
132 }; 132 };
133 133
134 #define nd_na_type nd_na_hdr.icmp6_type 134 #define nd_na_type nd_na_hdr.icmp6_type
135 #define nd_na_code nd_na_hdr.icmp6_code 135 #define nd_na_code nd_na_hdr.icmp6_code
136 #define nd_na_cksum nd_na_hdr.icmp6_cksum 136 #define nd_na_cksum nd_na_hdr.icmp6_cksum
137 #define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] 137 #define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0]
138 #if __BYTE_ORDER == __BIG_ENDIAN 138 #if __BYTE_ORDER == __BIG_ENDIAN
139 #define ND_NA_FLAG_ROUTER 0x80000000 139 #define ND_NA_FLAG_ROUTER 0x80000000
140 #define ND_NA_FLAG_SOLICITED 0x40000000 140 #define ND_NA_FLAG_SOLICITED 0x40000000
141 #define ND_NA_FLAG_OVERRIDE 0x20000000 141 #define ND_NA_FLAG_OVERRIDE 0x20000000
142 #else 142 #else
143 #define ND_NA_FLAG_ROUTER 0x00000080 143 #define ND_NA_FLAG_ROUTER 0x00000080
144 #define ND_NA_FLAG_SOLICITED 0x00000040 144 #define ND_NA_FLAG_SOLICITED 0x00000040
145 #define ND_NA_FLAG_OVERRIDE 0x00000020 145 #define ND_NA_FLAG_OVERRIDE 0x00000020
146 #endif 146 #endif
147 147
148 struct nd_redirect { 148 struct nd_redirect {
149 » struct icmp6_hdr nd_rd_hdr; 149 struct icmp6_hdr nd_rd_hdr;
150 » struct in6_addr nd_rd_target; 150 struct in6_addr nd_rd_target;
151 » struct in6_addr nd_rd_dst; 151 struct in6_addr nd_rd_dst;
152 }; 152 };
153 153
154 #define nd_rd_type nd_rd_hdr.icmp6_type 154 #define nd_rd_type nd_rd_hdr.icmp6_type
155 #define nd_rd_code nd_rd_hdr.icmp6_code 155 #define nd_rd_code nd_rd_hdr.icmp6_code
156 #define nd_rd_cksum nd_rd_hdr.icmp6_cksum 156 #define nd_rd_cksum nd_rd_hdr.icmp6_cksum
157 #define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] 157 #define nd_rd_reserved nd_rd_hdr.icmp6_data32[0]
158 158
159 struct nd_opt_hdr { 159 struct nd_opt_hdr {
160 » uint8_t nd_opt_type; 160 uint8_t nd_opt_type;
161 » uint8_t nd_opt_len; 161 uint8_t nd_opt_len;
162 }; 162 };
163 163
164 #define ND_OPT_SOURCE_LINKADDR» » 1 164 #define ND_OPT_SOURCE_LINKADDR 1
165 #define ND_OPT_TARGET_LINKADDR» » 2 165 #define ND_OPT_TARGET_LINKADDR 2
166 #define ND_OPT_PREFIX_INFORMATION» 3 166 #define ND_OPT_PREFIX_INFORMATION 3
167 #define ND_OPT_REDIRECTED_HEADER» 4 167 #define ND_OPT_REDIRECTED_HEADER 4
168 #define ND_OPT_MTU» » » 5 168 #define ND_OPT_MTU 5
169 #define ND_OPT_RTR_ADV_INTERVAL»» 7 169 #define ND_OPT_RTR_ADV_INTERVAL 7
170 #define ND_OPT_HOME_AGENT_INFO» » 8 170 #define ND_OPT_HOME_AGENT_INFO 8
171 171
172 struct nd_opt_prefix_info { 172 struct nd_opt_prefix_info {
173 » uint8_t nd_opt_pi_type; 173 uint8_t nd_opt_pi_type;
174 » uint8_t nd_opt_pi_len; 174 uint8_t nd_opt_pi_len;
175 » uint8_t nd_opt_pi_prefix_len; 175 uint8_t nd_opt_pi_prefix_len;
176 » uint8_t nd_opt_pi_flags_reserved; 176 uint8_t nd_opt_pi_flags_reserved;
177 » uint32_t nd_opt_pi_valid_time; 177 uint32_t nd_opt_pi_valid_time;
178 » uint32_t nd_opt_pi_preferred_time; 178 uint32_t nd_opt_pi_preferred_time;
179 » uint32_t nd_opt_pi_reserved2; 179 uint32_t nd_opt_pi_reserved2;
180 » struct in6_addr nd_opt_pi_prefix; 180 struct in6_addr nd_opt_pi_prefix;
181 }; 181 };
182 182
183 #define ND_OPT_PI_FLAG_ONLINK» 0x80 183 #define ND_OPT_PI_FLAG_ONLINK 0x80
184 #define ND_OPT_PI_FLAG_AUTO» 0x40 184 #define ND_OPT_PI_FLAG_AUTO 0x40
185 #define ND_OPT_PI_FLAG_RADDR» 0x20 185 #define ND_OPT_PI_FLAG_RADDR 0x20
186 186
187 struct nd_opt_rd_hdr { 187 struct nd_opt_rd_hdr {
188 » uint8_t nd_opt_rh_type; 188 uint8_t nd_opt_rh_type;
189 » uint8_t nd_opt_rh_len; 189 uint8_t nd_opt_rh_len;
190 » uint16_t nd_opt_rh_reserved1; 190 uint16_t nd_opt_rh_reserved1;
191 » uint32_t nd_opt_rh_reserved2; 191 uint32_t nd_opt_rh_reserved2;
192 }; 192 };
193 193
194 struct nd_opt_mtu { 194 struct nd_opt_mtu {
195 » uint8_t nd_opt_mtu_type; 195 uint8_t nd_opt_mtu_type;
196 » uint8_t nd_opt_mtu_len; 196 uint8_t nd_opt_mtu_len;
197 » uint16_t nd_opt_mtu_reserved; 197 uint16_t nd_opt_mtu_reserved;
198 » uint32_t nd_opt_mtu_mtu; 198 uint32_t nd_opt_mtu_mtu;
199 }; 199 };
200 200
201 struct mld_hdr { 201 struct mld_hdr {
202 » struct icmp6_hdr mld_icmp6_hdr; 202 struct icmp6_hdr mld_icmp6_hdr;
203 » struct in6_addr mld_addr; 203 struct in6_addr mld_addr;
204 }; 204 };
205 205
206 #define mld_type mld_icmp6_hdr.icmp6_type 206 #define mld_type mld_icmp6_hdr.icmp6_type
207 #define mld_code mld_icmp6_hdr.icmp6_code 207 #define mld_code mld_icmp6_hdr.icmp6_code
208 #define mld_cksum mld_icmp6_hdr.icmp6_cksum 208 #define mld_cksum mld_icmp6_hdr.icmp6_cksum
209 #define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] 209 #define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0]
210 #define mld_reserved mld_icmp6_hdr.icmp6_data16[1] 210 #define mld_reserved mld_icmp6_hdr.icmp6_data16[1]
211 211
212 #define ICMP6_ROUTER_RENUMBERING 138 212 #define ICMP6_ROUTER_RENUMBERING 138
213 213
214 struct icmp6_router_renum { 214 struct icmp6_router_renum {
215 » struct icmp6_hdr rr_hdr; 215 struct icmp6_hdr rr_hdr;
216 » uint8_t rr_segnum; 216 uint8_t rr_segnum;
217 » uint8_t rr_flags; 217 uint8_t rr_flags;
218 » uint16_t rr_maxdelay; 218 uint16_t rr_maxdelay;
219 » uint32_t rr_reserved; 219 uint32_t rr_reserved;
220 }; 220 };
221 221
222 #define rr_type»» rr_hdr.icmp6_type 222 #define rr_type rr_hdr.icmp6_type
223 #define rr_code rr_hdr.icmp6_code 223 #define rr_code rr_hdr.icmp6_code
224 #define rr_cksum rr_hdr.icmp6_cksum 224 #define rr_cksum rr_hdr.icmp6_cksum
225 #define rr_seqnum rr_hdr.icmp6_data32[0] 225 #define rr_seqnum rr_hdr.icmp6_data32[0]
226 226
227 #define ICMP6_RR_FLAGS_TEST 0x80 227 #define ICMP6_RR_FLAGS_TEST 0x80
228 #define ICMP6_RR_FLAGS_REQRESULT 0x40 228 #define ICMP6_RR_FLAGS_REQRESULT 0x40
229 #define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 229 #define ICMP6_RR_FLAGS_FORCEAPPLY 0x20
230 #define ICMP6_RR_FLAGS_SPECSITE 0x10 230 #define ICMP6_RR_FLAGS_SPECSITE 0x10
231 #define ICMP6_RR_FLAGS_PREVDONE 0x08 231 #define ICMP6_RR_FLAGS_PREVDONE 0x08
232 232
233 struct rr_pco_match { 233 struct rr_pco_match {
234 » uint8_t rpm_code; 234 uint8_t rpm_code;
235 » uint8_t rpm_len; 235 uint8_t rpm_len;
236 » uint8_t rpm_ordinal; 236 uint8_t rpm_ordinal;
237 » uint8_t rpm_matchlen; 237 uint8_t rpm_matchlen;
238 » uint8_t rpm_minlen; 238 uint8_t rpm_minlen;
239 » uint8_t rpm_maxlen; 239 uint8_t rpm_maxlen;
240 » uint16_t rpm_reserved; 240 uint16_t rpm_reserved;
241 » struct in6_addr rpm_prefix; 241 struct in6_addr rpm_prefix;
242 }; 242 };
243 243
244 #define RPM_PCO_ADD 1 244 #define RPM_PCO_ADD 1
245 #define RPM_PCO_CHANGE 2 245 #define RPM_PCO_CHANGE 2
246 #define RPM_PCO_SETGLOBAL 3 246 #define RPM_PCO_SETGLOBAL 3
247 247
248 struct rr_pco_use { 248 struct rr_pco_use {
249 » uint8_t rpu_uselen; 249 uint8_t rpu_uselen;
250 » uint8_t rpu_keeplen; 250 uint8_t rpu_keeplen;
251 » uint8_t rpu_ramask; 251 uint8_t rpu_ramask;
252 » uint8_t rpu_raflags; 252 uint8_t rpu_raflags;
253 » uint32_t rpu_vltime; 253 uint32_t rpu_vltime;
254 » uint32_t rpu_pltime; 254 uint32_t rpu_pltime;
255 » uint32_t rpu_flags; 255 uint32_t rpu_flags;
256 » struct in6_addr rpu_prefix; 256 struct in6_addr rpu_prefix;
257 }; 257 };
258 258
259 #define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 259 #define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20
260 #define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 260 #define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10
261 261
262 #if __BYTE_ORDER == __BIG_ENDIAN 262 #if __BYTE_ORDER == __BIG_ENDIAN
263 #define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80000000 263 #define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80000000
264 #define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40000000 264 #define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40000000
265 #else 265 #else
266 #define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 266 #define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80
267 #define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 267 #define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40
268 #endif 268 #endif
269 269
270 struct rr_result { 270 struct rr_result {
271 » uint16_t rrr_flags; 271 uint16_t rrr_flags;
272 » uint8_t rrr_ordinal; 272 uint8_t rrr_ordinal;
273 » uint8_t rrr_matchedlen; 273 uint8_t rrr_matchedlen;
274 » uint32_t rrr_ifid; 274 uint32_t rrr_ifid;
275 » struct in6_addr rrr_prefix; 275 struct in6_addr rrr_prefix;
276 }; 276 };
277 277
278 #if __BYTE_ORDER == __BIG_ENDIAN 278 #if __BYTE_ORDER == __BIG_ENDIAN
279 #define ICMP6_RR_RESULT_FLAGS_OOB 0x0002 279 #define ICMP6_RR_RESULT_FLAGS_OOB 0x0002
280 #define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0001 280 #define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0001
281 #else 281 #else
282 #define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 282 #define ICMP6_RR_RESULT_FLAGS_OOB 0x0200
283 #define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 283 #define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100
284 #endif 284 #endif
285 285
286 struct nd_opt_adv_interval { 286 struct nd_opt_adv_interval {
287 » uint8_t nd_opt_adv_interval_type; 287 uint8_t nd_opt_adv_interval_type;
288 » uint8_t nd_opt_adv_interval_len; 288 uint8_t nd_opt_adv_interval_len;
289 » uint16_t nd_opt_adv_interval_reserved; 289 uint16_t nd_opt_adv_interval_reserved;
290 » uint32_t nd_opt_adv_interval_ival; 290 uint32_t nd_opt_adv_interval_ival;
291 }; 291 };
292 292
293 struct nd_opt_home_agent_info { 293 struct nd_opt_home_agent_info {
294 » uint8_t nd_opt_home_agent_info_type; 294 uint8_t nd_opt_home_agent_info_type;
295 » uint8_t nd_opt_home_agent_info_len; 295 uint8_t nd_opt_home_agent_info_len;
296 » uint16_t nd_opt_home_agent_info_reserved; 296 uint16_t nd_opt_home_agent_info_reserved;
297 » uint16_t nd_opt_home_agent_info_preference; 297 uint16_t nd_opt_home_agent_info_preference;
298 » uint16_t nd_opt_home_agent_info_lifetime; 298 uint16_t nd_opt_home_agent_info_lifetime;
299 }; 299 };
300 300
301 #ifdef __cplusplus 301 #ifdef __cplusplus
302 } 302 }
303 #endif 303 #endif
304 304
305 #endif 305 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698