Statistics
| Branch: | Revision:

iof-bird-daemon / proto / ospf / ospf.h @ 061ab802

History | View | Annotate | Download (15.9 KB)

1
/*
2
 *        BIRD -- OSPF
3
 *
4
 *        (c) 1999--2005 Ondrej Filip <feela@network.cz>
5
 *
6
 *        Can be freely distributed and used under the terms of the GNU GPL.
7
 */
8

    
9
#ifndef _BIRD_OSPF_H_
10
#define _BIRD_OSPF_H_
11

    
12
#define MAXNETS 10
13
#define OSPF_VLINK_MTU 576        /* RFC2328 - A.1 */
14
#define OSPF_MAX_PKT_SIZE 65536
15
                        /*
16
                         * RFC 2328 says, maximum packet size is 65535
17
                         * This could be too much for small systems, so I
18
                         * normally allocate 2*mtu - (I found one cisco
19
                         * sending packets mtu+16)
20
                         */
21
#ifdef LOCAL_DEBUG
22
#define OSPF_FORCE_DEBUG 1
23
#else
24
#define OSPF_FORCE_DEBUG 0
25
#endif
26
#define OSPF_TRACE(flags, msg, args...) do { if ((p->debug & flags) || OSPF_FORCE_DEBUG) \
27
  log(L_TRACE "%s: " msg, p->name , ## args ); } while(0)
28

    
29
#define OSPF_PACKET(dumpfn, buffer, msg, args...) \
30
do { if ((p->debug & D_PACKETS) || OSPF_FORCE_DEBUG) \
31
{ log(L_TRACE "%s: " msg, p->name, ## args ); dumpfn(p, buffer); } } while(0)
32

    
33

    
34
#include "nest/bird.h"
35

    
36
#include "lib/checksum.h"
37
#include "lib/ip.h"
38
#include "lib/lists.h"
39
#include "lib/slists.h"
40
#include "lib/socket.h"
41
#include "lib/timer.h"
42
#include "lib/resource.h"
43
#include "nest/protocol.h"
44
#include "nest/iface.h"
45
#include "nest/route.h"
46
#include "nest/cli.h"
47
#include "nest/locks.h"
48
#include "conf/conf.h"
49
#include "lib/string.h"
50

    
51
#define OSPF_PROTO 89
52

    
53
#ifndef IPV6
54
#define OSPFv2 1
55
#define OSPF_VERSION 2
56
#define AllSPFRouters ipa_from_u32(0xe0000005)        /* 224.0.0.5 */
57
#define AllDRouters ipa_from_u32(0xe0000006)        /* 224.0.0.6 */
58
#else
59
#define OSPFv3 1
60
#define OSPF_VERSION 3
61
#define AllSPFRouters _MI(0xFF020000, 0, 0, 5)        /* FF02::5 */
62
#define AllDRouters   _MI(0xFF020000, 0, 0, 6)        /* FF02::6 */
63
#endif
64

    
65

    
66
#define LSREFRESHTIME 1800        /* 30 minutes */
67
#define MINLSINTERVAL 5
68
#define MINLSARRIVAL 1
69
#define LSINFINITY 0xffffff
70

    
71
#define DEFAULT_OSPFTICK 1
72
#define DEFAULT_RFC1583 0        /* compatibility with rfc1583 */
73
#define DEFAULT_STUB_COST 1000
74

    
75

    
76
struct ospf_config
77
{
78
  struct proto_config c;
79
  unsigned tick;
80
  int rfc1583;
81
  list area_list;
82
};
83

    
84
struct nbma_node
85
{
86
  node n;
87
  ip_addr ip;
88
  int eligible;
89
};
90

    
91
struct area_net_config
92
{
93
  node n;
94
  struct prefix px;
95
  int hidden;
96
};
97

    
98
struct area_net
99
{
100
  struct fib_node fn;
101
  int hidden;
102
  int active;
103
  u32 metric;
104
};
105

    
106
struct ospf_stubnet_config
107
{
108
  node n;
109
  struct prefix px;
110
  int hidden, summary;
111
  u32 cost;
112
};
113

    
114
struct ospf_area_config
115
{
116
  node n;
117
  u32 areaid;
118
  int stub;
119
  list patt_list;
120
  list vlink_list;
121
  list net_list;
122
  list stubnet_list;
123
};
124

    
125

    
126
/* Option flags */
127

    
128
#define OPT_E        0x02
129
#define OPT_N        0x08
130
#define OPT_DC        0x20
131

    
132
#ifdef OSPFv2
133
#define OPT_EA        0x10
134

    
135
/* VEB flags are are stored independently in 'u16 options' */
136
#define OPT_RT_B  (0x01 << 8)
137
#define OPT_RT_E  (0x02 << 8)
138
#define OPT_RT_V  (0x04 << 8)
139
#endif
140

    
141
#ifdef OSPFv3
142
#define OPT_V6        0x01
143
#define OPT_R        0x10
144

    
145
/* VEB flags are are stored together with options in 'u32 options' */
146
#define OPT_RT_B  (0x01 << 24)
147
#define OPT_RT_E  (0x02 << 24)
148
#define OPT_RT_V  (0x04 << 24)
149
#define OPT_RT_NT (0x10 << 24)
150

    
151
#define OPT_PX_NU 0x01
152
#define OPT_PX_LA 0x02
153
#define OPT_PX_P  0x08
154
#define OPT_PX_DN 0x10
155
#endif
156

    
157

    
158
struct ospf_iface
159
{
160
  node n;
161
  struct iface *iface;                /* Nest's iface */
162
  struct ospf_area *oa;
163
  struct object_lock *lock;
164
  sock *hello_sk;                /* Hello socket */
165
  sock *dr_sk;                        /* For states DR or BACKUP */
166
  sock *ip_sk;                        /* IP socket (for DD ...) */
167
  list neigh_list;                /* List of neigbours */
168
  u32 cost;                        /* Cost of iface */
169
  u32 waitint;                        /* number of sec before changing state from wait */
170
  u32 rxmtint;                        /* number of seconds between LSA retransmissions */
171
  u32 pollint;                        /* Poll interval */
172
  u32 dead;                        /* after "deadint" missing hellos is router dead */
173
  u32 vid;                        /* Id of peer of virtual link */
174
  ip_addr vip;                        /* IP of peer of virtual link */
175
  struct ospf_area *voa;        /* Area wich the vlink goes through */
176
  u16 inftransdelay;                /* The estimated number of seconds it takes to
177
                                   transmit a Link State Update Packet over this
178
                                   interface.  LSAs contained in the update */
179
  u16 helloint;                        /* number of seconds between hello sending */
180

    
181
#ifdef OSPFv2
182
  list *passwords;
183
  u16 autype;
184
  u32 csn;                      /* Last used crypt seq number */
185
  bird_clock_t csn_use;         /* Last time when packet with that CSN was sent */
186
#endif
187

    
188
  ip_addr drip;                        /* Designated router */
189
  u32 drid;
190
  ip_addr bdrip;                /* Backup DR */
191
  u32 bdrid;
192

    
193
#ifdef OSPFv3
194
  u32 dr_iface_id;                /* if drid is valid, this is iface_id of DR (for connecting network) */
195
  u8 instance_id;                /* Used to differentiate between more OSPF
196
                                   instances on one interface */
197
  ip_addr lladdr;                /* Used link-local addr */
198
#endif
199

    
200
  u8 type;                        /* OSPF view of type */
201
#define OSPF_IT_BCAST 0
202
#define OSPF_IT_NBMA 1
203
#define OSPF_IT_PTP 2
204
#define OSPF_IT_VLINK 3
205
#define OSPF_IT_UNDEF 4
206
  u8 strictnbma;                /* Can I talk with unknown neighbors? */
207
  u8 stub;                        /* Inactive interface */
208
#define OSPF_I_OK 0                /* Everything OK */
209
#define OSPF_I_MC 1                /* I didn't open MC socket */
210
#define OSPF_I_IP 2                /* I didn't open IP socet */
211
  u8 state;                        /* Interface state machine */
212
#define OSPF_IS_DOWN 0                /* Not working */
213
#define OSPF_IS_LOOP 1                /* Should never happen */
214
#define OSPF_IS_WAITING 2        /* Waiting for Wait timer */
215
#define OSPF_IS_PTP 3                /* PTP operational */
216
#define OSPF_IS_DROTHER 4        /* I'm on BCAST or NBMA and I'm not DR */
217
#define OSPF_IS_BACKUP 5        /* I'm BDR */
218
#define OSPF_IS_DR 6                /* I'm DR */
219
  timer *wait_timer;                /* WAIT timer */
220
  timer *hello_timer;                /* HELLOINT timer */
221
  timer *poll_timer;                /* Poll Interval - for NBMA */
222
/* Default values for interface parameters */
223
#define COST_D 10
224
#define RXMTINT_D 5
225
#define INFTRANSDELAY_D 1
226
#define PRIORITY_D 1
227
#define HELLOINT_D 10
228
#define POLLINT_D 20
229
#define DEADC_D 4
230
#define WAIT_DMH 4                
231
  /* Value of Wait timer - not found it in RFC * - using 4*HELLO */
232

    
233
  struct top_hash_entry *net_lsa;        /* Originated network LSA */
234
  int orignet;                                /* Schedule network LSA origination */
235
#ifdef OSPFv3
236
  struct top_hash_entry *link_lsa;        /* Originated link LSA */
237
  int origlink;                                /* Schedule link LSA origination */
238
  struct top_hash_entry *pxn_lsa;        /* Originated prefix LSA */
239
#endif
240
  int fadj;                                /* Number of full adjacent neigh */
241
  list nbma_list;
242
  u8 priority;                                /* A router priority for DR election */
243
  u8 ioprob;
244
  u32 rxbuf;
245
};
246

    
247
struct ospf_md5
248
{
249
  u16 zero;
250
  u8 keyid;
251
  u8 len;
252
  u32 csn;
253
};
254

    
255
union ospf_auth
256
{
257
  u8 password[8];
258
  struct ospf_md5 md5;
259
};
260

    
261

    
262
/* Packet types */
263
#define HELLO_P 1                /* Hello */
264
#define DBDES_P 2                /* Database description */
265
#define LSREQ_P 3                /* Link state request */
266
#define LSUPD_P 4                /* Link state update */
267
#define LSACK_P 5                /* Link state acknowledgement */
268

    
269
/* Area IDs */
270
#define BACKBONE 0
271

    
272

    
273
struct immsb
274
{
275
#ifdef CPU_BIG_ENDIAN
276
  u8 padding:5;
277
  u8 i:1;
278
  u8 m:1;
279
  u8 ms:1;
280
#else
281
  u8 ms:1;
282
  u8 m:1;
283
  u8 i:1;
284
  u8 padding:5;
285
#endif
286
};
287

    
288
union imms
289
{
290
  u8 byte;
291
  struct immsb bit;
292
};
293
#define DBDES_MS 1
294
#define DBDES_M 2
295
#define DBDES_I 4
296

    
297

    
298
#ifdef OSPFv2
299

    
300
struct ospf_packet
301
{
302
  u8 version;
303
  u8 type;
304
  u16 length;
305
  u32 routerid;
306
  u32 areaid;
307
  u16 checksum;
308
  u16 autype;
309
  union ospf_auth u;
310
};
311

    
312

    
313
#else /* OSPFv3 packet descriptions */
314

    
315
struct ospf_packet
316
{
317
  u8 version;
318
  u8 type;
319
  u16 length;
320
  u32 routerid;
321
  u32 areaid;
322
  u16 checksum;
323
  u8 instance_id;
324
  u8 zero;
325
};
326

    
327

    
328
#endif
329

    
330

    
331

    
332

    
333
struct ospf_lsa_header
334
{
335
  u16 age;                        /* LS Age */
336
#define LSA_MAXAGE 3600                /* 1 hour */
337
#define LSA_CHECKAGE 300        /* 5 minutes */
338
#define LSA_MAXAGEDIFF 900        /* 15 minutes */
339

    
340
#ifdef OSPFv2
341
  u8 options;
342
  u8 type;
343

    
344
#define LSA_T_RT        1
345
#define LSA_T_NET        2
346
#define LSA_T_SUM_NET        3
347
#define LSA_T_SUM_RT        4
348
#define LSA_T_EXT        5
349

    
350
#else /* OSPFv3 */
351
  u16 type;
352

    
353
#define LSA_T_RT        0x2001
354
#define LSA_T_NET        0x2002
355
#define LSA_T_SUM_NET        0x2003
356
#define LSA_T_SUM_RT        0x2004
357
#define LSA_T_EXT        0x4005
358
#define LSA_T_LINK        0x0008
359
#define LSA_T_PREFIX        0x2009
360

    
361
#define LSA_UBIT        0x8000
362

    
363
#define LSA_SCOPE_LINK        0x0000
364
#define LSA_SCOPE_AREA        0x2000
365
#define LSA_SCOPE_AS        0x4000
366
#define LSA_SCOPE_RES        0x6000
367
#define LSA_SCOPE_MASK        0x6000
368

    
369
#define LSA_SCOPE(lsa)        ((lsa)->type & LSA_SCOPE_MASK)
370
#endif
371

    
372
  u32 id;
373
  u32 rt;                        /* Advertising router */
374
  s32 sn;                        /* LS Sequence number */
375
#define LSA_INITSEQNO ((s32) 0x80000001)
376
#define LSA_MAXSEQNO ((s32) 0x7fffffff)
377
  u16 checksum;
378
  u16 length;
379
};
380

    
381

    
382
#define LSART_PTP 1
383
#define LSART_NET 2
384
#define LSART_STUB 3
385
#define LSART_VLNK 4
386

    
387

    
388
#ifdef OSPFv2
389

    
390
struct ospf_lsa_rt
391
{
392
  u16 options;        /* VEB flags only */
393
  u16 links;
394
};
395

    
396
struct ospf_lsa_rt_link
397
{
398
  u32 id;
399
  u32 data;
400
  u8 type;
401
  u8 notos;
402
  u16 metric;
403
};
404

    
405
struct ospf_lsa_net
406
{
407
  ip_addr netmask;
408
  u32 routers[];
409
};
410

    
411
struct ospf_lsa_sum
412
{
413
  ip_addr netmask;
414
  u32 metric;
415
};
416

    
417
struct ospf_lsa_ext
418
{
419
  ip_addr netmask;
420
  u32 metric;
421
  ip_addr fwaddr;
422
  u32 tag;
423
};
424

    
425
#define LSA_EXT_EBIT 0x80000000
426

    
427
/* Endianity swap for lsa->type */
428
#define ntoht(x) x
429
#define htont(x) x
430

    
431

    
432
#else  /* OSPFv3 */
433

    
434
struct ospf_lsa_rt
435
{
436
  u32 options;
437
};
438

    
439
struct ospf_lsa_rt_link
440
{
441
  u8 type;
442
  u8 padding;
443
  u16 metric;
444
  u32 lif;        /* Local interface ID */
445
  u32 nif;        /* Neighbor interface ID */
446
  u32 id;        /* Neighbor router ID */
447
};
448

    
449
struct ospf_lsa_net
450
{
451
  u32 options;
452
  u32 routers[];
453
};
454

    
455
struct ospf_lsa_sum_net
456
{
457
  u32 metric;
458
  u32 prefix[];
459
};
460

    
461
struct ospf_lsa_sum_rt
462
{
463
  u32 options;
464
  u32 metric;
465
  u32 drid;
466
};
467

    
468
struct ospf_lsa_ext
469
{
470
  u32 metric;
471
  u32 rest[];
472
};
473

    
474
struct ospf_lsa_link
475
{
476
  u32 options;
477
  ip_addr lladdr;
478
  u32 pxcount;
479
  u32 rest[];
480
};
481

    
482
struct ospf_lsa_prefix
483
{
484
  u16 pxcount;
485
  u16 ref_type;
486
  u32 ref_id;
487
  u32 ref_rt;
488
  u32 rest[];
489
};
490

    
491
#define LSA_EXT_EBIT 0x4000000
492
#define LSA_EXT_FBIT 0x2000000
493
#define LSA_EXT_TBIT 0x1000000
494

    
495
/* Endianity swap for lsa->type */
496
#define ntoht(x) ntohs(x)
497
#define htont(x) htons(x)
498

    
499
#endif
500

    
501
#define METRIC_MASK  0x00FFFFFF
502
#define OPTIONS_MASK 0x00FFFFFF
503

    
504
static inline unsigned lsa_rt_count(struct ospf_lsa_header *lsa)
505
{
506
  return (lsa->length - sizeof(struct ospf_lsa_header) - sizeof(struct ospf_lsa_rt))
507
    / sizeof(struct ospf_lsa_rt_link);
508
}
509

    
510
static inline unsigned lsa_net_count(struct ospf_lsa_header *lsa)
511
{
512
  return (lsa->length - sizeof(struct ospf_lsa_header) - sizeof(struct ospf_lsa_net))
513
    / sizeof(u32);
514
}
515

    
516

    
517
/*
518
struct ospf_lsa_ext_etos 
519
{
520
#ifdef CPU_BIG_ENDIAN
521
  u8 ebit:1;
522
  u8 tos:7;
523
  u8 padding1;
524
  u16 padding2;
525
#else
526
  u16 padding2;
527
  u8 padding1;
528
  u8 tos:7;
529
  u8 ebit:1;
530
#endif
531
};
532

533

534
struct ospf_lsa_sum_tos 
535
{
536
#ifdef CPU_BIG_ENDIAN
537
  u8 tos;
538
  u8 padding1;
539
  u16 padding2;
540
#else
541
  u16 padding2;
542
  u8 padding1;
543
  u8 tos;
544
#endif
545
};
546

547
union ospf_lsa_sum_tm
548
{
549
  struct ospf_lsa_sum_tos tos;
550
  u32 metric;
551
};
552

553
union ospf_lsa_ext_etm
554
{
555
  struct ospf_lsa_ext_etos etos;
556
  u32 metric;
557
};
558

559
struct ospf_lsa_ext_tos
560
{
561
  union ospf_lsa_ext_etm etm;
562
  ip_addr fwaddr;
563
  u32 tag;
564
};
565

566
*/
567

    
568
struct ospf_lsreq_header
569
{
570
  u32 type;
571
  u32 id;
572
  u32 rt;                        /* Advertising router */
573
};
574

    
575
struct l_lsr_head
576
{
577
  node n;
578
  struct ospf_lsreq_header lsh;
579
};
580

    
581

    
582
struct ospf_neighbor
583
{
584
  node n;
585
  pool *pool;
586
  struct ospf_iface *ifa;
587
  u8 state;
588
#define NEIGHBOR_DOWN 0
589
#define NEIGHBOR_ATTEMPT 1
590
#define NEIGHBOR_INIT 2
591
#define NEIGHBOR_2WAY 3
592
#define NEIGHBOR_EXSTART 4
593
#define NEIGHBOR_EXCHANGE 5
594
#define NEIGHBOR_LOADING 6
595
#define NEIGHBOR_FULL 7
596
  timer *inactim;                /* Inactivity timer */
597
  union imms imms;                /* I, M, Master/slave received */
598
  u32 dds;                        /* DD Sequence number being sent */
599
  u32 ddr;                        /* last Dat Des packet received */
600
  union imms myimms;                /* I, M Master/slave */
601
  u32 rid;                        /* Router ID */
602
  ip_addr ip;                        /* IP of it's interface */
603
  u8 priority;                        /* Priority */
604
  u8 adj;                        /* built adjacency? */
605
  u32 options;                        /* Options received */
606

    
607
  /* dr and bdr store IP address in OSPFv2 and router ID in OSPFv3,
608
     we use the same type to simplify handling */
609
  u32 dr;                        /* Neigbour's idea of DR */
610
  u32 bdr;                        /* Neigbour's idea of BDR */
611

    
612
#ifdef OSPFv3
613
  u32 iface_id;                        /* ID of Neighbour's iface connected to common network */
614
#endif
615

    
616
  siterator dbsi;                /* Database summary list iterator */
617
  slist lsrql;                        /* Link state request */
618
  struct top_graph *lsrqh;        /* LSA graph */
619
  siterator lsrqi;
620
  slist lsrtl;                        /* Link state retransmission list */
621
  siterator lsrti;
622
  struct top_graph *lsrth;
623
  void *ldbdes;                        /* Last database description packet */
624
  timer *rxmt_timer;                /* RXMT timer */
625
  list ackl[2];
626
#define ACKL_DIRECT 0
627
#define ACKL_DELAY 1
628
  timer *ackd_timer;                /* Delayed ack timer */
629
  u32 csn;                      /* Last received crypt seq number (for MD5) */
630
};
631

    
632
/* Definitions for interface state machine */
633
#define ISM_UP 0                /* Interface Up */
634
#define ISM_WAITF 1                /* Wait timer fired */
635
#define ISM_BACKS 2                /* Backup seen */
636
#define ISM_NEICH 3                /* Neighbor change */
637
#define ISM_LOOP 4                /* Loop indicated */
638
#define ISM_UNLOOP 5                /* Unloop indicated */
639
#define ISM_DOWN 6                /* Interface down */
640

    
641
/* Definitions for neighbor state machine */
642
#define INM_HELLOREC 0                /* Hello Received */
643
#define INM_START 1                /* Neighbor start - for NBMA */
644
#define INM_2WAYREC 2                /* 2-Way received */
645
#define INM_NEGDONE 3                /* Negotiation done */
646
#define INM_EXDONE 4                /* Exchange done */
647
#define INM_BADLSREQ 5                /* Bad LS Request */
648
#define INM_LOADDONE 6                /* Load done */
649
#define INM_ADJOK 7                /* AdjOK? */
650
#define INM_SEQMIS 8                /* Sequence number mismatch */
651
#define INM_1WAYREC 9                /* 1-Way */
652
#define INM_KILLNBR 10                /* Kill Neighbor */
653
#define INM_INACTTIM 11                /* Inactivity timer */
654
#define INM_LLDOWN 12                /* Line down */
655

    
656
struct ospf_area
657
{
658
  node n;
659
  u32 areaid;
660
  struct ospf_area_config *ac;        /* Related area config */
661
  int origrt;                        /* Rt lsa origination scheduled? */
662
  struct top_hash_entry *rt;        /* My own router LSA */
663
  struct top_hash_entry *pxr_lsa; /* Originated prefix LSA */
664
  list cand;                        /* List of candidates for RT calc. */
665
  struct fib net_fib;                /* Networks to advertise or not */
666
  int stub;
667
  int trcap;                        /* Transit capability? */
668
  u32 options;                        /* Optional features */
669
  struct proto_ospf *po;
670
  struct fib rtr;                /* Routing tables for routers */
671
};
672

    
673
struct proto_ospf
674
{
675
  struct proto proto;
676
  timer *disp_timer;                /* OSPF proto dispatcher */
677
  unsigned tick;
678
  struct top_graph *gr;                /* LSA graph */
679
  slist lsal;                        /* List of all LSA's */
680
  int calcrt;                        /* Routing table calculation scheduled? */
681
  int cleanup;                  /* Should I cleanup after RT calculation? */
682
  list iface_list;                /* Interfaces we really use */
683
  list area_list;
684
  int areano;                        /* Number of area I belong to */
685
  struct fib rtf;                /* Routing table */
686
  int rfc1583;                        /* RFC1583 compatibility */
687
  int ebit;                        /* Did I originate any ext lsa? */
688
  struct ospf_area *backbone;        /* If exists */
689
  void *lsab;                        /* LSA buffer used when originating router LSAs */
690
  int lsab_size, lsab_used;
691
};
692

    
693
struct ospf_iface_patt
694
{
695
  struct iface_patt i;
696
  u32 cost;
697
  u32 helloint;
698
  u32 rxmtint;
699
  u32 pollint;
700
  u32 inftransdelay;
701
  u32 priority;
702
  u32 waitint;
703
  u32 deadc;
704
  u32 dead;
705
  u32 type;
706
  u32 strictnbma;
707
  u32 stub;
708
  u32 vid;
709
  u32 rxbuf;
710
#define OSPF_RXBUF_NORMAL 0
711
#define OSPF_RXBUF_LARGE 1
712
#define OSPF_RXBUF_MINSIZE 256        /* Minimal allowed size */
713
  list nbma_list;
714

    
715
  u32 autype;                          /* Not really used in OSPFv3 */
716
#define OSPF_AUTH_NONE 0
717
#define OSPF_AUTH_SIMPLE 1
718
#define OSPF_AUTH_CRYPT 2
719
#define OSPF_AUTH_CRYPT_SIZE 16
720

    
721
#ifdef OSPFv2
722
  list *passwords;
723
#endif
724

    
725
#ifdef OSPFv3
726
  u8 instance_id;
727
#endif
728
};
729

    
730
int ospf_import_control(struct proto *p, rte **new, ea_list **attrs,
731
                        struct linpool *pool);
732
struct ea_list *ospf_make_tmp_attrs(struct rte *rt, struct linpool *pool);
733
void ospf_store_tmp_attrs(struct rte *rt, struct ea_list *attrs);
734
void schedule_rt_lsa(struct ospf_area *oa);
735
void schedule_rtcalc(struct proto_ospf *po);
736
void schedule_net_lsa(struct ospf_iface *ifa);
737
void ospf_sh_neigh(struct proto *p, char *iff);
738
void ospf_sh(struct proto *p);
739
void ospf_sh_iface(struct proto *p, char *iff);
740

    
741
#define EA_OSPF_METRIC1        EA_CODE(EAP_OSPF, 0)
742
#define EA_OSPF_METRIC2        EA_CODE(EAP_OSPF, 1)
743
#define EA_OSPF_TAG        EA_CODE(EAP_OSPF, 2)
744

    
745
#include "proto/ospf/rt.h"
746
#include "proto/ospf/hello.h"
747
#include "proto/ospf/packet.h"
748
#include "proto/ospf/iface.h"
749
#include "proto/ospf/neighbor.h"
750
#include "proto/ospf/topology.h"
751
#include "proto/ospf/dbdes.h"
752
#include "proto/ospf/lsreq.h"
753
#include "proto/ospf/lsupd.h"
754
#include "proto/ospf/lsack.h"
755
#include "proto/ospf/lsalib.h"
756

    
757
#endif /* _BIRD_OSPF_H_ */