FreeBSD/Linux Kernel Cross Reference
sys/netiso/clnp.h
1 /* $NetBSD: clnp.h,v 1.18 2004/04/21 23:18:10 matt Exp $ */
2
3 /*-
4 * Copyright (c) 1991, 1993, 1994
5 * The Regents of the University of California. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions
9 * are met:
10 * 1. Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer.
12 * 2. Redistributions in binary form must reproduce the above copyright
13 * notice, this list of conditions and the following disclaimer in the
14 * documentation and/or other materials provided with the distribution.
15 * 3. Neither the name of the University nor the names of its contributors
16 * may be used to endorse or promote products derived from this software
17 * without specific prior written permission.
18 *
19 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
20 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
22 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
23 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
27 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
28 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29 * SUCH DAMAGE.
30 *
31 * @(#)clnp.h 8.2 (Berkeley) 4/16/94
32 */
33
34 /***********************************************************
35 Copyright IBM Corporation 1987
36
37 All Rights Reserved
38
39 Permission to use, copy, modify, and distribute this software and its
40 documentation for any purpose and without fee is hereby granted,
41 provided that the above copyright notice appear in all copies and that
42 both that copyright notice and this permission notice appear in
43 supporting documentation, and that the name of IBM not be
44 used in advertising or publicity pertaining to distribution of the
45 software without specific, written prior permission.
46
47 IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
48 ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
49 IBM BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
50 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
51 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
52 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
53 SOFTWARE.
54
55 ******************************************************************/
56
57 #ifndef _NETISO_CLNP_H
58 #define _NETISO_CLNP_H
59
60 /*
61 * ARGO Project, Computer Sciences Dept., University of Wisconsin - Madison
62 */
63
64 /* should be config option but cpp breaks with too many #defines */
65 #define DECBIT
66
67 /*
68 * Return true if the mbuf is a cluster mbuf
69 */
70 #define IS_CLUSTER(m) ((m)->m_flags & M_EXT)
71
72 /*
73 * Move the halfword into the two characters
74 */
75 #define HTOC(msb, lsb, hword)\
76 (msb) = (u_char)((hword) >> 8);\
77 (lsb) = (u_char)((hword) & 0xff)
78 /*
79 * Move the two charcters into the halfword
80 */
81 #define CTOH(msb, lsb, hword)\
82 (hword) = ((msb) << 8) | (lsb)
83
84 /*
85 * Return true if the checksum has been set - ie. the checksum is
86 * not zero
87 */
88 #define CKSUM_REQUIRED(clnp)\
89 (((clnp)->cnf_cksum_msb != 0) || ((clnp)->cnf_cksum_lsb != 0))
90
91 /*
92 * Fixed part of clnp header
93 */
94 struct clnp_fixed {
95 u_char cnf_proto_id; /* network layer protocol identifier */
96 u_char cnf_hdr_len; /* length indicator (octets) */
97 u_char cnf_vers; /* version/protocol identifier
98 * extension */
99 u_char cnf_ttl;/* lifetime (500 milliseconds) */
100 u_char cnf_type; /* type code */
101 /* Includes err_ok, more_segs, and seg_ok */
102 u_char cnf_seglen_msb; /* pdu segment length (octets) high
103 * byte */
104 u_char cnf_seglen_lsb; /* pdu segment length (octets) low
105 * byte */
106 u_char cnf_cksum_msb; /* checksum high byte */
107 u_char cnf_cksum_lsb; /* checksum low byte */
108 } __attribute__((packed));
109 #define CNF_TYPE 0x1f
110 #define CNF_ERR_OK 0x20
111 #define CNF_MORE_SEGS 0x40
112 #define CNF_SEG_OK 0x80
113
114 #define CLNP_CKSUM_OFF 0x07 /* offset of checksum */
115
116 #define clnl_fixed clnp_fixed
117
118 /*
119 * Segmentation part of clnp header
120 */
121 struct clnp_segment {
122 u_short cng_id; /* data unit identifier */
123 u_short cng_off;/* segment offset */
124 u_short cng_tot_len; /* total length */
125 };
126
127 /*
128 * Clnp fragment reassembly structures:
129 *
130 * All packets undergoing reassembly are linked together in
131 * clnp_fragl structures. Each clnp_fragl structure contains a
132 * pointer to the original clnp packet header, as well as a
133 * list of packet fragments. Each packet fragment
134 * is headed by a clnp_frag structure. This structure contains the
135 * offset of the first and last byte of the fragment, as well as
136 * a pointer to the data (an mbuf chain) of the fragment.
137 */
138
139 /*
140 * NOTE:
141 * The clnp_frag structure is stored in an mbuf immedately
142 * preceding the fragment data. Since there are words in
143 * this struct, it must be word aligned.
144 *
145 * NOTE:
146 * All the fragment code assumes that the entire clnp header is
147 * contained in the first mbuf.
148 */
149 struct clnp_frag {
150 u_int cfr_first; /* offset of first byte of this frag */
151 u_int cfr_last; /* offset of last byte of this frag */
152 u_int cfr_bytes; /* bytes to shave to get to data */
153 struct mbuf *cfr_data; /* ptr to data for this frag */
154 struct clnp_frag *cfr_next; /* next fragment in list */
155 };
156
157 struct clnp_fragl {
158 struct iso_addr cfl_src;/* source of the pkt */
159 struct iso_addr cfl_dst;/* destination of the pkt */
160 u_short cfl_id; /* id of the pkt */
161 u_char cfl_ttl;/* current ttl of pkt */
162 u_short cfl_last; /* offset of last byte of packet */
163 struct mbuf *cfl_orighdr; /* ptr to original header */
164 struct clnp_frag *cfl_frags; /* linked list of fragments for pkt */
165 struct clnp_fragl *cfl_next; /* next pkt being reassembled */
166 };
167
168 /*
169 * The following structure is used to index into an options section
170 * of a clnp datagram. These values can be used without worry that
171 * offset or length fields are invalid or too big, etc. That is,
172 * the consistancy of the options will be guaranteed before this
173 * structure is filled in. Any pointer (field ending in p) is
174 * actually the offset from the beginning of the mbuf the option
175 * is contained in. A value of NULL for any pointer
176 * means that the option is not present. The length any option
177 * does not include the option code or option length fields.
178 */
179 struct clnp_optidx {
180 u_short cni_securep; /* ptr to start of security option */
181 char cni_secure_len; /* length of entire security option */
182
183 u_short cni_srcrt_s; /* offset of start of src rt option */
184 u_short cni_srcrt_len; /* length of entire src rt option */
185
186 u_short cni_recrtp; /* ptr to beginning of recrt option */
187 char cni_recrt_len; /* length of entire recrt option */
188
189 char cni_priorp; /* ptr to priority option */
190
191 u_short cni_qos_formatp; /* ptr to format of qos
192 * option */
193 char cni_qos_len; /* length of entire qos option */
194
195 u_char cni_er_reason; /* reason from ER pdu option */
196
197 /* ESIS options */
198
199 u_short cni_esct; /* value from ISH ESCT option */
200
201 u_short cni_netmaskp; /* ptr to beginning of netmask option */
202 char cni_netmask_len; /* length of entire netmask
203 * option */
204
205 u_short cni_snpamaskp; /* ptr to start of snpamask option */
206 char cni_snpamask_len; /* length of entire snpamask
207 * option */
208
209 };
210
211 #define ER_INVALREAS 0xff /* code for invalid ER pdu discard reason */
212
213 /* given an mbuf and addr of option, return offset from data of mbuf */
214 #define CLNP_OPTTOOFF(m, opt) ((u_short) (opt - mtod(m, caddr_t)))
215
216 /* given an mbuf and offset of option, return address of option */
217 #define CLNP_OFFTOOPT(m, off) ((caddr_t) (mtod(m, caddr_t) + off))
218
219 /* return true iff src route is valid */
220 #define CLNPSRCRT_VALID(oidx) ((oidx) && (oidx->cni_srcrt_s))
221
222 /* return the offset field of the src rt */
223 #define CLNPSRCRT_OFF(oidx, options)\
224 (*((u_char *)(CLNP_OFFTOOPT(options, oidx->cni_srcrt_s) + 1)))
225
226 /* return the type field of the src rt */
227 #define CLNPSRCRT_TYPE(oidx, options)\
228 ((u_char)(*(CLNP_OFFTOOPT(options, oidx->cni_srcrt_s))))
229
230 /* return the length of the current address */
231 #define CLNPSRCRT_CLEN(oidx, options)\
232 ((u_char)(*(CLNP_OFFTOOPT(options, oidx->cni_srcrt_s) + CLNPSRCRT_OFF(oidx, options) - 1)))
233
234 /* return the address of the current address */
235 #define CLNPSRCRT_CADDR(oidx, options)\
236 ((caddr_t)(CLNP_OFFTOOPT(options, oidx->cni_srcrt_s) + CLNPSRCRT_OFF(oidx, options)))
237
238 /*
239 * return true if the src route has run out of routes this is true if the
240 * offset of next route is greater than the end of the rt
241 */
242 #define CLNPSRCRT_TERM(oidx, options)\
243 (CLNPSRCRT_OFF(oidx, options) > oidx->cni_srcrt_len)
244
245 /*
246 * Options a user can set/get
247 */
248 #define CLNPOPT_FLAGS 0x01 /* flags: seg permitted, no er xmit, etc */
249 #define CLNPOPT_OPTS 0x02 /* datagram options */
250
251 /*
252 * Values for particular datagram options
253 */
254 #define CLNPOVAL_PAD 0xcc /* padding */
255 #define CLNPOVAL_SECURE 0xc5 /* security */
256 #define CLNPOVAL_SRCRT 0xc8 /* source routing */
257 #define CLNPOVAL_RECRT 0xcb /* record route */
258 #define CLNPOVAL_QOS 0xc3 /* quality of service */
259 #define CLNPOVAL_PRIOR 0xcd /* priority */
260 #define CLNPOVAL_ERREAS 0xc1 /* ER PDU ONLY: reason for discard */
261
262 #define CLNPOVAL_SRCSPEC 0x40 /* source address specific */
263 #define CLNPOVAL_DSTSPEC 0x80 /* destination address specific */
264 #define CLNPOVAL_GLOBAL 0xc0 /* globally unique */
265
266 /* Globally Unique QOS */
267 #define CLNPOVAL_SEQUENCING 0x10 /* sequencing preferred */
268 #define CLNPOVAL_CONGESTED 0x08 /* congestion experienced */
269 #define CLNPOVAL_LOWDELAY 0x04 /* low transit delay */
270
271 #define CLNPOVAL_PARTRT 0x00 /* partial source routing */
272 #define CLNPOVAL_COMPRT 0x01 /* complete source routing */
273
274 /*
275 * Clnp flags used in a control block flags field.
276 * NOTE: these must be out of the range of bits defined in ../net/raw_cb.h
277 */
278 #define CLNP_NO_SEG 0x010 /* segmentation not permitted */
279 #define CLNP_NO_ER 0x020 /* do not generate ERs */
280 #define CLNP_SEND_RAW 0x080 /* send pkt as RAW DT not TP DT */
281 #define CLNP_NO_CKSUM 0x100 /* don't use clnp checksum */
282 #define CLNP_ECHO 0x200 /* send echo request */
283 #define CLNP_NOCACHE 0x400 /* don't store cache information */
284 #define CLNP_ECHOR 0x800 /* send echo reply */
285
286 /* valid clnp flags */
287 #define CLNP_VFLAGS \
288 (CLNP_SEND_RAW|CLNP_NO_SEG|CLNP_NO_ER|CLNP_NO_CKSUM|\
289 CLNP_ECHO|CLNP_NOCACHE|CLNP_ECHOR)
290
291 /*
292 * Constants used by clnp
293 */
294 #define CLNP_HDR_MIN (sizeof (struct clnp_fixed))
295 #define CLNP_HDR_MAX (254)
296 #define CLNP_TTL_UNITS 2 /* 500 milliseconds */
297 #define CLNP_TTL 15*CLNP_TTL_UNITS /* time to live (seconds) */
298 #define ISO8473_V1 0x01
299
300 /*
301 * Clnp packet types
302 * In order to test raw clnp and tp/clnp simultaneously, a third type of
303 * packet has been defined: CLNP_RAW. This is done so that the input
304 * routine can switch to the correct input routine (rclnp_input or
305 * tpclnp_input) based on the type field. If clnp had a higher level
306 * protocol field, this would not be necessary.
307 */
308 #define CLNP_DT 0x1C /* normal data */
309 #define CLNP_ER 0x01 /* error report */
310 #define CLNP_RAW 0x1D /* debug only */
311 #define CLNP_EC 0x1E /* echo packet */
312 #define CLNP_ECR 0x1F /* echo reply */
313
314 /*
315 * ER pdu error codes
316 */
317 #define GEN_NOREAS 0x00 /* reason not specified */
318 #define GEN_PROTOERR 0x01 /* protocol procedure error */
319 #define GEN_BADCSUM 0x02 /* incorrect checksum */
320 #define GEN_CONGEST 0x03 /* pdu discarded due to congestion */
321 #define GEN_HDRSYNTAX 0x04 /* header syntax error */
322 #define GEN_SEGNEEDED 0x05 /* need segmentation but not allowed */
323 #define GEN_INCOMPLETE 0x06 /* incomplete pdu received */
324 #define GEN_DUPOPT 0x07 /* duplicate option */
325
326 /* address errors */
327 #define ADDR_DESTUNREACH 0x80 /* destination address unreachable */
328 #define ADDR_DESTUNKNOWN 0x81 /* destination address unknown */
329
330 /* source routing */
331 #define SRCRT_UNSPECERR 0x90 /* unspecified src rt error */
332 #define SRCRT_SYNTAX 0x91 /* syntax error in src rt field */
333 #define SRCRT_UNKNOWNADDR 0x92 /* unknown addr in src rt field */
334 #define SRCRT_BADPATH 0x93 /* path not acceptable */
335
336 /* lifetime */
337 #define TTL_EXPTRANSIT 0xa0 /* lifetime expired during transit */
338 #define TTL_EXPREASS 0xa1 /* lifetime expired during reassembly */
339
340 /* pdu discarded */
341 #define DISC_UNSUPPOPT 0xb0 /* unsupported option not specified? */
342 #define DISC_UNSUPPVERS 0xb1 /* unsupported protocol version */
343 #define DISC_UNSUPPSECURE 0xb2 /* unsupported security option */
344 #define DISC_UNSUPPSRCRT 0xb3 /* unsupported src rt option */
345 #define DISC_UNSUPPRECRT 0xb4 /* unsupported rec rt option */
346
347 /* reassembly */
348 #define REASS_INTERFERE 0xc0 /* reassembly interference */
349 #define CLNP_ERRORS 22
350
351
352 #ifdef CLNP_ER_CODES
353 u_char clnp_er_codes[CLNP_ERRORS] = {
354 GEN_NOREAS, GEN_PROTOERR, GEN_BADCSUM, GEN_CONGEST,
355 GEN_HDRSYNTAX, GEN_SEGNEEDED, GEN_INCOMPLETE, GEN_DUPOPT,
356 ADDR_DESTUNREACH, ADDR_DESTUNKNOWN,
357 SRCRT_UNSPECERR, SRCRT_SYNTAX, SRCRT_UNKNOWNADDR, SRCRT_BADPATH,
358 TTL_EXPTRANSIT, TTL_EXPREASS,
359 DISC_UNSUPPOPT, DISC_UNSUPPVERS, DISC_UNSUPPSECURE,
360 DISC_UNSUPPSRCRT, DISC_UNSUPPRECRT, REASS_INTERFERE
361 };
362 #endif
363
364 #ifdef TROLL
365
366 #define TR_DUPEND 0x01 /* duplicate end of fragment */
367 #define TR_DUPPKT 0x02 /* duplicate entire packet */
368 #define TR_DROPPKT 0x04 /* drop packet on output */
369 #define TR_TRIM 0x08 /* trim bytes from packet */
370 #define TR_CHANGE 0x10 /* change bytes in packet */
371 #define TR_MTU 0x20 /* delta to change device mtu */
372 #define TR_CHUCK 0x40 /* drop packet in rclnp_input */
373 #define TR_BLAST 0x80 /* force rclnp_output to blast many
374 * packet */
375 #define TR_RAWLOOP 0x100 /* make if_loop call clnpintr
376 * directly */
377 struct troll {
378 int tr_ops; /* operations to perform */
379 float tr_dup_size; /* % to duplicate */
380 float tr_dup_freq; /* frequency to duplicate packets */
381 float tr_drop_freq; /* frequence to drop packets */
382 int tr_mtu_adj; /* delta to adjust if mtu */
383 int tr_blast_cnt; /* # of pkts to blast out */
384 };
385
386 #define SN_OUTPUT(clcp, m)\
387 troll_output(clcp->clc_ifp, m, clcp->clc_firsthop, clcp->clc_rt)
388
389 #define SN_MTU(ifp, rt) (((rt && rt->rt_rmx.rmx_mtu) ?\
390 rt->rt_rmx.rmx_mtu : clnp_badmtu(ifp, rt, __LINE__, __FILE__))\
391 - trollctl.tr_mtu_adj)
392
393 #ifdef _KERNEL
394 extern float troll_random;
395 #endif
396
397 #else /* NO TROLL */
398
399 #define SN_OUTPUT(clcp, m)\
400 (*clcp->clc_ifp->if_output)(clcp->clc_ifp, m, clcp->clc_firsthop, \
401 clcp->clc_rt)
402
403 #define SN_MTU(ifp, rt) (((rt && rt->rt_rmx.rmx_mtu) ?\
404 rt->rt_rmx.rmx_mtu : clnp_badmtu(ifp, rt, __LINE__, __FILE__)))
405
406 #endif /* TROLL */
407
408 /*
409 * Macro to remove an address from a clnp header
410 */
411 #define CLNP_EXTRACT_ADDR(isoa, hoff, hend)\
412 {\
413 isoa.isoa_len = (u_char)*hoff;\
414 if ((((++hoff) + isoa.isoa_len) > hend) ||\
415 (isoa.isoa_len > 20) || (isoa.isoa_len == 0)) {\
416 hoff = (caddr_t)0;\
417 } else {\
418 (void) bcopy(hoff, (caddr_t)isoa.isoa_genaddr, \
419 isoa.isoa_len);\
420 hoff += isoa.isoa_len;\
421 }\
422 }
423
424 /*
425 * Macro to insert an address into a clnp header
426 */
427 #define CLNP_INSERT_ADDR(hoff, isoa)\
428 *hoff++ = (isoa).isoa_len;\
429 (void) bcopy((caddr_t)((isoa).isoa_genaddr), hoff, (isoa).isoa_len);\
430 hoff += (isoa).isoa_len;
431
432 /*
433 * Clnp hdr cache. Whenever a clnp packet is sent, a copy of the
434 * header is made and kept in this cache. In addition to a copy of
435 * the cached clnp hdr, the cache contains
436 * information necessary to determine whether the new packet
437 * to send requires a new header to be built.
438 */
439 struct clnp_cache {
440 /* these fields are used to check the validity of the cache */
441 struct iso_addr clc_dst;/* destination of packet */
442 struct mbuf *clc_options; /* ptr to options mbuf */
443 int clc_flags; /* flags passed to clnp_output */
444
445 /* these fields are state that clnp_output requires to finish the pkt */
446 int clc_segoff; /* offset of seg part of header */
447 struct rtentry *clc_rt; /* ptr to rtentry (points into the route
448 * structure) */
449 struct sockaddr *clc_firsthop; /* first hop of packet */
450 struct ifnet *clc_ifp;/* ptr to interface structure */
451 struct iso_ifaddr
452 *clc_ifa;/* ptr to interface address */
453 struct mbuf *clc_hdr;/* cached pkt hdr (finally)! */
454 };
455
456 #ifdef _KERNEL
457 struct iso_addr;
458 struct sockaddr_iso;
459 struct mbuf;
460 struct clnp_segment;
461 struct sockaddr;
462 struct rt_entry;
463 struct clnp_fragl;
464 struct clnp_optidx;
465 struct isopcb;
466 struct snpa_hdr;
467 struct iso_ifaddr;
468 struct route_iso;
469
470 /* clnp_debug.c */
471 char *clnp_hexp (const char *, int, char *);
472 char *clnp_iso_addrp (struct iso_addr *);
473 char *clnp_saddr_isop (struct sockaddr_iso *);
474
475 /* clnp_er.c */
476 void clnp_er_input (struct mbuf *, struct iso_addr *, u_int);
477 void clnp_discard (struct mbuf *, u_int);
478 void clnp_emit_er (struct mbuf *, u_int);
479 int clnp_er_index (u_int);
480
481 int clnp_fragment (struct ifnet *, struct mbuf *, struct sockaddr *,
482 int, int, int, struct rtentry *);
483 struct mbuf *clnp_reass (struct mbuf *, struct iso_addr *,
484 struct iso_addr *, struct clnp_segment *);
485 int clnp_newpkt (struct mbuf *, struct iso_addr *, struct iso_addr *,
486 struct clnp_segment *);
487 void clnp_insert_frag (struct clnp_fragl *, struct mbuf *,
488 struct clnp_segment *);
489 struct mbuf *clnp_comp_pdu (struct clnp_fragl *);
490 #ifdef TROLL
491 float troll_random (void);
492 int troll_output (struct ifnet *, struct mbuf *, struct sockaddr *,
493 struct rtentry *);
494 #endif
495
496 /* clnp_input.c */
497 void clnp_init (void);
498 void clnlintr (void);
499 void clnp_input (struct mbuf *, ...);
500
501 /* clnp_options.c */
502 void clnp_update_srcrt (struct mbuf *, struct clnp_optidx *);
503 void clnp_dooptions (struct mbuf *, struct clnp_optidx *, struct ifnet *,
504 struct iso_addr *);
505 int clnp_set_opts (struct mbuf **, struct mbuf **);
506 int clnp_opt_sanity (struct mbuf *, caddr_t, int, struct clnp_optidx *);
507
508 /* clnp_output.c */
509 int clnp_output (struct mbuf *, ...);
510 void clnp_ctloutput (void);
511
512 /* clnp_raw.c */
513 void rclnp_input (struct mbuf *, ...);
514 int rclnp_output (struct mbuf *, ...);
515 int rclnp_ctloutput (int, struct socket *, int, int, struct mbuf **);
516 int clnp_usrreq (struct socket *, int, struct mbuf *, struct mbuf *,
517 struct mbuf *, struct proc *);
518
519 /* clnp_subr.c */
520 struct mbuf *clnp_data_ck (struct mbuf *, int);
521 caddr_t clnp_extract_addr (caddr_t, int, struct iso_addr *,
522 struct iso_addr *);
523 int clnp_ours (struct iso_addr *);
524 void clnp_forward (struct mbuf *, int, struct iso_addr *,
525 struct clnp_optidx *, int, struct snpa_hdr *);
526 caddr_t clnp_insert_addr (caddr_t, struct iso_addr *, struct iso_addr *);
527 int clnp_route (struct iso_addr *, struct route_iso *, int,
528 struct sockaddr **, struct iso_ifaddr **);
529 int clnp_srcroute (struct mbuf *, struct clnp_optidx *, struct route_iso *,
530 struct sockaddr **, struct iso_ifaddr **,
531 struct iso_addr *);
532 int clnp_echoreply (struct mbuf *, int, struct sockaddr_iso *,
533 struct sockaddr_iso *, struct clnp_optidx *);
534 int clnp_badmtu (struct ifnet *, struct rtentry *, int, char *);
535 void clnp_ypocb (caddr_t, caddr_t, u_int);
536
537 /* clnp_timer.c */
538 struct clnp_fragl *clnp_freefrags (struct clnp_fragl *);
539 void clnp_slowtimo (void);
540 void clnp_drain (void);
541
542 #ifdef TROLL
543 struct troll trollctl;
544 #endif /* TROLL */
545
546 #endif /* _KERNEL */
547
548 #endif /* !_NETISO_CLNP_H */
Cache object: 0940ae6e1a1483390cd6fecd3064c221
|