]> git.proxmox.com Git - mirror_frr.git/blame - ospfd/ospfd.h
Update PR #839 following review
[mirror_frr.git] / ospfd / ospfd.h
CommitLineData
718e3744 1/*
2 * OSPFd main header.
3 * Copyright (C) 1998, 99, 2000 Kunihiro Ishiguro, Toshiaki Takada
4 *
5 * This file is part of GNU Zebra.
6 *
7 * GNU Zebra is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the
9 * Free Software Foundation; either version 2, or (at your option) any
10 * later version.
896014f4 11 *
718e3744 12 * GNU Zebra is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * General Public License for more details.
16 *
896014f4
DL
17 * You should have received a copy of the GNU General Public License along
18 * with this program; see the file COPYING; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
718e3744 20 */
21
22#ifndef _ZEBRA_OSPFD_H
23#define _ZEBRA_OSPFD_H
24
c514adc6 25#include <zebra.h>
ae19c240 26#include "qobj.h"
8551e6da 27#include "libospf.h"
c514adc6 28
718e3744 29#include "filter.h"
343f5cc7 30#include "log.h"
718e3744 31
4a1ab8e4 32#include "ospf_memory.h"
0a3fc2a5 33#include "ospf_dump_api.h"
4a1ab8e4 34
718e3744 35#define OSPF_VERSION 2
36
718e3744 37/* VTY port number. */
38#define OSPF_VTY_PORT 2604
718e3744 39
40/* IP TTL for OSPF protocol. */
41#define OSPF_IP_TTL 1
42#define OSPF_VL_IP_TTL 100
43
44/* Default configuration file name for ospfd. */
45#define OSPF_DEFAULT_CONFIG "ospfd.conf"
46
464c8204 47#define OSPF_NSSA_TRANS_STABLE_DEFAULT 40
718e3744 48
49#define OSPF_ALLSPFROUTERS 0xe0000005 /* 224.0.0.5 */
50#define OSPF_ALLDROUTERS 0xe0000006 /* 224.0.0.6 */
51
718e3744 52/* OSPF Authentication Type. */
53#define OSPF_AUTH_NULL 0
54#define OSPF_AUTH_SIMPLE 1
55#define OSPF_AUTH_CRYPTOGRAPHIC 2
56/* For Interface authentication setting default */
57#define OSPF_AUTH_NOTSET -1
d62a17ae 58/* For the consumption and sanity of the command handler */
718e3744 59/* DO NIOT REMOVE!!! Need to detect whether a value has
60 been given or not in VLink command handlers */
61#define OSPF_AUTH_CMD_NOTSEEN -2
62
718e3744 63/* OSPF options. */
16f1b9ee 64#define OSPF_OPTION_MT 0x01 /* M/T */
718e3744 65#define OSPF_OPTION_E 0x02
66#define OSPF_OPTION_MC 0x04
67#define OSPF_OPTION_NP 0x08
68#define OSPF_OPTION_EA 0x10
69#define OSPF_OPTION_DC 0x20
70#define OSPF_OPTION_O 0x40
16f1b9ee 71#define OSPF_OPTION_DN 0x80
718e3744 72
73/* OSPF Database Description flags. */
74#define OSPF_DD_FLAG_MS 0x01
75#define OSPF_DD_FLAG_M 0x02
76#define OSPF_DD_FLAG_I 0x04
77#define OSPF_DD_FLAG_ALL 0x07
78
718e3744 79#define OSPF_LS_REFRESH_SHIFT (60 * 15)
80#define OSPF_LS_REFRESH_JITTER 60
81
d62a17ae 82struct ospf_external {
83 u_short instance;
84 struct route_table *external_info;
7c8ff89e
DS
85};
86
020709f9 87/* OSPF master for system wide configuration and variables. */
d62a17ae 88struct ospf_master {
89 /* OSPF instance. */
90 struct list *ospf;
020709f9 91
d62a17ae 92 /* OSPF thread master. */
93 struct thread_master *master;
020709f9 94
d62a17ae 95 /* Zebra interface list. */
96 struct list *iflist;
020709f9 97
d62a17ae 98 /* Redistributed external information. */
99 struct list *external[ZEBRA_ROUTE_MAX + 1];
7c8ff89e 100#define EXTERNAL_INFO(E) (E->external_info)
020709f9 101
d62a17ae 102 /* Various OSPF global configuration. */
103 u_char options;
32ab5cf4 104#define OSPF_MASTER_SHUTDOWN (1 << 0) /* deferred-shutdown */
020709f9 105};
106
d62a17ae 107struct ospf_redist {
108 u_short instance;
109
110 /* Redistribute metric info. */
111 struct {
112 int type; /* External metric type (E1 or E2). */
113 int value; /* Value for static metric (24-bit).
114 -1 means metric value is not set. */
115 } dmetric;
116
117 /* For redistribute route map. */
118 struct {
119 char *name;
120 struct route_map *map;
121 } route_map; /* +1 is for default-information */
7c8ff89e
DS
122#define ROUTEMAP_NAME(R) (R->route_map.name)
123#define ROUTEMAP(R) (R->route_map.map)
124};
125
718e3744 126/* OSPF instance structure. */
d62a17ae 127struct ospf {
128 /* OSPF's running state based on the '[no] router ospf [<instance>]'
129 * config. */
130 u_char oi_running;
0bad4851 131
d62a17ae 132 /* OSPF instance ID */
133 u_short instance;
7c8ff89e 134
d62a17ae 135 /* OSPF Router ID. */
136 struct in_addr router_id; /* Configured automatically. */
137 struct in_addr router_id_static; /* Configured manually. */
718e3744 138
d62a17ae 139 /* ABR/ASBR internal flags. */
140 u_char flags;
718e3744 141#define OSPF_FLAG_ABR 0x0001
142#define OSPF_FLAG_ASBR 0x0002
143
d62a17ae 144 /* ABR type. */
145 u_char abr_type;
718e3744 146#define OSPF_ABR_UNKNOWN 0
147#define OSPF_ABR_STAND 1
148#define OSPF_ABR_IBM 2
149#define OSPF_ABR_CISCO 3
150#define OSPF_ABR_SHORTCUT 4
d57834f6 151#define OSPF_ABR_DEFAULT OSPF_ABR_CISCO
718e3744 152
d62a17ae 153 /* NSSA ABR */
154 u_char anyNSSA; /* Bump for every NSSA attached. */
718e3744 155
d62a17ae 156 /* Configured variables. */
157 u_char config;
718e3744 158#define OSPF_RFC1583_COMPATIBLE (1 << 0)
159#define OSPF_OPAQUE_CAPABLE (1 << 2)
d7e60dd7
AS
160#define OSPF_LOG_ADJACENCY_CHANGES (1 << 3)
161#define OSPF_LOG_ADJACENCY_DETAIL (1 << 4)
718e3744 162
d62a17ae 163 /* Opaque-LSA administrative flags. */
164 u_char opaque;
718e3744 165#define OPAQUE_OPERATION_READY_BIT (1 << 0)
718e3744 166
d62a17ae 167 /* RFC3137 stub router. Configured time to stay stub / max-metric */
168 unsigned int stub_router_startup_time; /* seconds */
169 unsigned int stub_router_shutdown_time; /* seconds */
170 /* $FRR indent$ */
171 /* clang-format off */
88d6cf37 172#define OSPF_STUB_ROUTER_UNCONFIGURED 0
d62a17ae 173 u_char stub_router_admin_set;
4ba4fc85
AB
174#define OSPF_STUB_ROUTER_ADMINISTRATIVE_SET 1
175#define OSPF_STUB_ROUTER_ADMINISTRATIVE_UNSET 0
88d6cf37 176
b4154c14
JR
177#define OSPF_STUB_MAX_METRIC_SUMMARY_COST 0x00ff0000
178
d62a17ae 179 /* LSA timers */
180 unsigned int min_ls_interval; /* minimum delay between LSAs (in msec) */
181 unsigned int min_ls_arrival; /* minimum interarrival time between LSAs
182 (in msec) */
183
184 /* SPF parameters */
185 unsigned int spf_delay; /* SPF delay time. */
186 unsigned int spf_holdtime; /* SPF hold time. */
187 unsigned int spf_max_holdtime; /* SPF maximum-holdtime */
188 unsigned int
189 spf_hold_multiplier; /* Adaptive multiplier for hold time */
190
191 int default_originate; /* Default information originate. */
192 /* $FRR indent$ */
193 /* clang-format off */
718e3744 194#define DEFAULT_ORIGINATE_NONE 0
195#define DEFAULT_ORIGINATE_ZEBRA 1
196#define DEFAULT_ORIGINATE_ALWAYS 2
d62a17ae 197 u_int32_t ref_bandwidth; /* Reference Bandwidth (Kbps). */
198 struct route_table *networks; /* OSPF config networks. */
199 struct list *vlinks; /* Configured Virtual-Links. */
200 struct list *areas; /* OSPF areas. */
201 struct route_table *nbr_nbma;
202 struct ospf_area *backbone; /* Pointer to the Backbone Area. */
203
204 struct list *oiflist; /* ospf interfaces */
205 u_char passive_interface_default; /* passive-interface default */
206
207 /* LSDB of AS-external-LSAs. */
208 struct ospf_lsdb *lsdb;
209
210 /* Flags. */
211 int external_origin; /* AS-external-LSA origin flag. */
212 int ase_calc; /* ASE calculation flag. */
213
214 struct list *opaque_lsa_self; /* Type-11 Opaque-LSAs */
215
216 /* Routing tables. */
217 struct route_table *old_table; /* Old routing table. */
218 struct route_table *new_table; /* Current routing table. */
219
220 struct route_table *old_rtrs; /* Old ABR/ASBR RT. */
221 struct route_table *new_rtrs; /* New ABR/ASBR RT. */
222
223 struct route_table *new_external_route; /* New External Route. */
224 struct route_table *old_external_route; /* Old External Route. */
225
226 struct route_table *external_lsas; /* Database of external LSAs,
227 prefix is LSA's adv. network*/
228
229 /* Time stamps */
230 struct timeval ts_spf; /* SPF calculation time stamp. */
231 struct timeval ts_spf_duration; /* Execution time of last SPF */
232
233 struct route_table *maxage_lsa; /* List of MaxAge LSA for deletion. */
234 int redistribute; /* Num of redistributed protocols. */
235
236 /* Threads. */
237 struct thread *t_abr_task; /* ABR task timer. */
238 struct thread *t_asbr_check; /* ASBR check timer. */
239 struct thread *t_distribute_update; /* Distirbute list update timer. */
240 struct thread *t_spf_calc; /* SPF calculation timer. */
241 struct thread *t_ase_calc; /* ASE calculation timer. */
242 struct thread *t_external_lsa; /* AS-external-LSA origin timer. */
243 struct thread
244 *t_opaque_lsa_self; /* Type-11 Opaque-LSAs origin event. */
245
246 unsigned int maxage_delay; /* Delay on Maxage remover timer, sec */
247 struct thread *t_maxage; /* MaxAge LSA remover timer. */
248 struct thread *t_maxage_walker; /* MaxAge LSA checking timer. */
249
250 struct thread
251 *t_deferred_shutdown; /* deferred/stub-router shutdown timer*/
252
253 struct thread *t_write;
e8f45e82 254#define OSPF_WRITE_INTERFACE_COUNT_DEFAULT 20
d62a17ae 255 int write_oi_count; /* Num of packets sent per thread invocation */
256 struct thread *t_read;
257 int fd;
258 struct stream *ibuf;
259 struct list *oi_write_q;
260
261 /* Distribute lists out of other route sources. */
262 struct {
263 char *name;
264 struct access_list *list;
265 } dlist[ZEBRA_ROUTE_MAX];
020709f9 266#define DISTRIBUTE_NAME(O,T) (O)->dlist[T].name
267#define DISTRIBUTE_LIST(O,T) (O)->dlist[T].list
718e3744 268
d62a17ae 269 /* OSPF redistribute configuration */
270 struct list *redist[ZEBRA_ROUTE_MAX + 1];
718e3744 271
d62a17ae 272 /* Redistribute tag info. */
273 route_tag_t
274 dtag[ZEBRA_ROUTE_MAX + 1]; // Pending: cant configure as of now
0d9551dc 275
d62a17ae 276 int default_metric; /* Default metric for redistribute. */
718e3744 277
278#define OSPF_LSA_REFRESHER_GRANULARITY 10
d62a17ae 279#define OSPF_LSA_REFRESHER_SLOTS \
280 ((OSPF_LS_REFRESH_TIME + OSPF_LS_REFRESH_SHIFT) \
281 / OSPF_LSA_REFRESHER_GRANULARITY \
282 + 1)
283 struct {
284 u_int16_t index;
285 struct list *qs[OSPF_LSA_REFRESHER_SLOTS];
286 } lsa_refresh_queue;
287
288 struct thread *t_lsa_refresher;
289 time_t lsa_refresher_started;
718e3744 290#define OSPF_LSA_REFRESH_INTERVAL_DEFAULT 10
d62a17ae 291 u_int16_t lsa_refresh_interval;
292
293 /* Distance parameter. */
294 u_char distance_all;
295 u_char distance_intra;
296 u_char distance_inter;
297 u_char distance_external;
298
299 /* Statistics for LSA origination. */
300 u_int32_t lsa_originate_count;
301
302 /* Statistics for LSA used for new instantiation. */
303 u_int32_t rx_lsa_count;
304
305 /* Counter of "ip ospf area x.x.x.x" */
306 u_int32_t if_ospf_cli_count;
307
308 struct route_table *distance_table;
309
310 QOBJ_FIELDS
718e3744 311};
ae19c240 312DECLARE_QOBJ_TYPE(ospf)
718e3744 313
314/* OSPF area structure. */
d62a17ae 315struct ospf_area {
316 /* OSPF instance. */
317 struct ospf *ospf;
718e3744 318
d62a17ae 319 /* Zebra interface list belonging to the area. */
320 struct list *oiflist;
718e3744 321
d62a17ae 322 /* Area ID. */
323 struct in_addr area_id;
718e3744 324
d62a17ae 325 /* Area ID format. */
326 int area_id_fmt;
86573dcb
QY
327#define OSPF_AREA_ID_FMT_DOTTEDQUAD 1
328#define OSPF_AREA_ID_FMT_DECIMAL 2
718e3744 329
d62a17ae 330 /* Address range. */
331 struct list *address_range;
718e3744 332
d62a17ae 333 /* Configured variables. */
334 int external_routing; /* ExternalRoutingCapability. */
335 int no_summary; /* Don't inject summaries into stub.*/
336 int shortcut_configured; /* Area configured as shortcut. */
337 /* $FRR indent$ */
338 /* clang-format off */
718e3744 339#define OSPF_SHORTCUT_DEFAULT 0
340#define OSPF_SHORTCUT_ENABLE 1
341#define OSPF_SHORTCUT_DISABLE 2
d62a17ae 342 int shortcut_capability; /* Other ABRs agree on S-bit */
343 u_int32_t default_cost; /* StubDefaultCost. */
344 int auth_type; /* Authentication type. */
718e3744 345
d62a17ae 346
347 u_char NSSATranslatorRole; /* NSSA configured role */
348 /* $FRR indent$ */
349 /* clang-format off */
718e3744 350#define OSPF_NSSA_ROLE_NEVER 0
d4a53d58 351#define OSPF_NSSA_ROLE_CANDIDATE 1
352#define OSPF_NSSA_ROLE_ALWAYS 2
d62a17ae 353 u_char NSSATranslatorState; /* NSSA operational role */
354 /* $FRR indent$ */
355 /* clang-format off */
d4a53d58 356#define OSPF_NSSA_TRANSLATE_DISABLED 0
357#define OSPF_NSSA_TRANSLATE_ENABLED 1
d62a17ae 358 int NSSATranslatorStabilityInterval;
359
360 u_char transit; /* TransitCapability. */
361 /* $FRR indent$ */
362 /* clang-format off */
718e3744 363#define OSPF_TRANSIT_FALSE 0
364#define OSPF_TRANSIT_TRUE 1
d62a17ae 365 struct route_table *ranges; /* Configured Area Ranges. */
366
367 /* RFC3137 stub router state flags for area */
368 u_char stub_router_state;
88d6cf37 369#define OSPF_AREA_ADMIN_STUB_ROUTED (1 << 0) /* admin stub-router set */
370#define OSPF_AREA_IS_STUB_ROUTED (1 << 1) /* stub-router active */
371#define OSPF_AREA_WAS_START_STUB_ROUTED (1 << 2) /* startup SR was done */
d62a17ae 372 /* Area related LSDBs[Type1-4]. */
373 struct ospf_lsdb *lsdb;
374
375 /* Self-originated LSAs. */
376 struct ospf_lsa *router_lsa_self;
377 struct list *opaque_lsa_self; /* Type-10 Opaque-LSAs */
378
379 /* Area announce list. */
380 struct {
381 char *name;
382 struct access_list *list;
383 } _export;
dea04441
PJ
384#define EXPORT_NAME(A) (A)->_export.name
385#define EXPORT_LIST(A) (A)->_export.list
718e3744 386
d62a17ae 387 /* Area acceptance list. */
388 struct {
389 char *name;
390 struct access_list *list;
391 } import;
718e3744 392#define IMPORT_NAME(A) (A)->import.name
393#define IMPORT_LIST(A) (A)->import.list
394
d62a17ae 395 /* Type 3 LSA Area prefix-list. */
396 struct {
397 char *name;
398 struct prefix_list *list;
399 } plist_in;
718e3744 400#define PREFIX_LIST_IN(A) (A)->plist_in.list
401#define PREFIX_NAME_IN(A) (A)->plist_in.name
402
d62a17ae 403 struct {
404 char *name;
405 struct prefix_list *list;
406 } plist_out;
718e3744 407#define PREFIX_LIST_OUT(A) (A)->plist_out.list
408#define PREFIX_NAME_OUT(A) (A)->plist_out.name
409
d62a17ae 410 /* Shortest Path Tree. */
411 struct vertex *spf;
718e3744 412
d62a17ae 413 /* Threads. */
414 struct thread *t_stub_router; /* Stub-router timer */
415 struct thread *t_opaque_lsa_self; /* Type-10 Opaque-LSAs origin. */
718e3744 416
d62a17ae 417 /* Statistics field. */
418 u_int32_t spf_calculation; /* SPF Calculation Count. */
718e3744 419
d62a17ae 420 /* Time stamps. */
421 struct timeval ts_spf; /* SPF calculation time stamp. */
cf744958 422
d62a17ae 423 /* Router count. */
424 u_int32_t abr_count; /* ABR router in this area. */
425 u_int32_t asbr_count; /* ASBR router in this area. */
718e3744 426
d62a17ae 427 /* Counters. */
428 u_int32_t act_ints; /* Active interfaces. */
429 u_int32_t full_nbrs; /* Fully adjacent neighbors. */
430 u_int32_t full_vls; /* Fully adjacent virtual neighbors. */
718e3744 431};
432
433/* OSPF config network structure. */
d62a17ae 434struct ospf_network {
435 /* Area ID. */
436 struct in_addr area_id;
437 int area_id_fmt;
718e3744 438};
439
440/* OSPF NBMA neighbor structure. */
d62a17ae 441struct ospf_nbr_nbma {
442 /* Neighbor IP address. */
443 struct in_addr addr;
718e3744 444
d62a17ae 445 /* OSPF interface. */
446 struct ospf_interface *oi;
718e3744 447
d62a17ae 448 /* OSPF neighbor structure. */
449 struct ospf_neighbor *nbr;
718e3744 450
d62a17ae 451 /* Neighbor priority. */
452 u_char priority;
718e3744 453
d62a17ae 454 /* Poll timer value. */
455 u_int32_t v_poll;
718e3744 456
d62a17ae 457 /* Poll timer thread. */
458 struct thread *t_poll;
718e3744 459
d62a17ae 460 /* State change. */
461 u_int32_t state_change;
718e3744 462};
463
464/* Macro. */
d62a17ae 465#define OSPF_AREA_SAME(X, Y) \
466 (memcmp((X->area_id), (Y->area_id), IPV4_MAX_BYTELEN) == 0)
718e3744 467
020709f9 468#define IS_OSPF_ABR(O) ((O)->flags & OSPF_FLAG_ABR)
469#define IS_OSPF_ASBR(O) ((O)->flags & OSPF_FLAG_ASBR)
718e3744 470
471#define OSPF_IS_AREA_ID_BACKBONE(I) ((I).s_addr == OSPF_AREA_BACKBONE)
472#define OSPF_IS_AREA_BACKBONE(A) OSPF_IS_AREA_ID_BACKBONE ((A)->area_id)
473
474#ifdef roundup
475# define ROUNDUP(val, gran) roundup(val, gran)
d62a17ae 476#else /* roundup */
718e3744 477# define ROUNDUP(val, gran) (((val) - 1 | (gran) - 1) + 1)
478#endif /* roundup */
479
d62a17ae 480#define LSA_OPTIONS_GET(area) \
481 (((area)->external_routing == OSPF_AREA_DEFAULT) ? OSPF_OPTION_E : 0)
482#define LSA_OPTIONS_NSSA_GET(area) \
483 (((area)->external_routing == OSPF_AREA_NSSA) ? OSPF_OPTION_NP : 0)
718e3744 484
ffa2c898
QY
485#define OSPF_TIMER_ON(T,F,V) thread_add_timer (master,(F),ospf,(V),&(T))
486#define OSPF_AREA_TIMER_ON(T,F,V) thread_add_timer (master, (F), area, (V), &(T))
487#define OSPF_POLL_TIMER_ON(T,F,V) thread_add_timer (master, (F), nbr_nbma, (V), &(T))
488#define OSPF_POLL_TIMER_OFF(X) OSPF_TIMER_OFF((X))
d62a17ae 489#define OSPF_TIMER_OFF(X) \
490 do { \
491 if (X) { \
492 thread_cancel(X); \
493 (X) = NULL; \
494 } \
495 } while (0)
718e3744 496
020709f9 497/* Extern variables. */
498extern struct ospf_master *om;
7ba82f70 499extern const int ospf_redistributed_proto_max;
718e3744 500extern struct zclient *zclient;
501extern struct thread_master *master;
718e3744 502extern int ospf_zlog;
503
504/* Prototypes. */
f52d13cb 505extern const char *ospf_redist_string(u_int route_type);
d62a17ae 506extern struct ospf *ospf_lookup(void);
507extern struct ospf *ospf_lookup_instance(u_short);
508extern struct ospf *ospf_get(void);
509extern struct ospf *ospf_get_instance(u_short);
510extern void ospf_finish(struct ospf *);
511extern void ospf_router_id_update(struct ospf *ospf);
512extern int ospf_network_set(struct ospf *, struct prefix_ipv4 *, struct in_addr,
513 int);
514extern int ospf_network_unset(struct ospf *, struct prefix_ipv4 *,
515 struct in_addr);
516extern int ospf_area_display_format_set(struct ospf *, struct ospf_area *area,
517 int df);
518extern int ospf_area_stub_set(struct ospf *, struct in_addr);
519extern int ospf_area_stub_unset(struct ospf *, struct in_addr);
520extern int ospf_area_no_summary_set(struct ospf *, struct in_addr);
521extern int ospf_area_no_summary_unset(struct ospf *, struct in_addr);
522extern int ospf_area_nssa_set(struct ospf *, struct in_addr);
523extern int ospf_area_nssa_unset(struct ospf *, struct in_addr);
524extern int ospf_area_nssa_translator_role_set(struct ospf *, struct in_addr,
525 int);
526extern int ospf_area_export_list_set(struct ospf *, struct ospf_area *,
527 const char *);
528extern int ospf_area_export_list_unset(struct ospf *, struct ospf_area *);
529extern int ospf_area_import_list_set(struct ospf *, struct ospf_area *,
530 const char *);
531extern int ospf_area_import_list_unset(struct ospf *, struct ospf_area *);
532extern int ospf_area_shortcut_set(struct ospf *, struct ospf_area *, int);
533extern int ospf_area_shortcut_unset(struct ospf *, struct ospf_area *);
534extern int ospf_timers_refresh_set(struct ospf *, int);
535extern int ospf_timers_refresh_unset(struct ospf *);
536extern int ospf_nbr_nbma_set(struct ospf *, struct in_addr);
537extern int ospf_nbr_nbma_unset(struct ospf *, struct in_addr);
538extern int ospf_nbr_nbma_priority_set(struct ospf *, struct in_addr, u_char);
539extern int ospf_nbr_nbma_priority_unset(struct ospf *, struct in_addr);
540extern int ospf_nbr_nbma_poll_interval_set(struct ospf *, struct in_addr,
541 unsigned int);
542extern int ospf_nbr_nbma_poll_interval_unset(struct ospf *, struct in_addr);
543extern void ospf_prefix_list_update(struct prefix_list *);
544extern void ospf_init(void);
545extern void ospf_if_update(struct ospf *, struct interface *);
546extern void ospf_ls_upd_queue_empty(struct ospf_interface *);
547extern void ospf_terminate(void);
548extern void ospf_nbr_nbma_if_update(struct ospf *, struct ospf_interface *);
549extern struct ospf_nbr_nbma *ospf_nbr_nbma_lookup(struct ospf *,
550 struct in_addr);
551extern struct ospf_nbr_nbma *ospf_nbr_nbma_lookup_next(struct ospf *,
552 struct in_addr *, int);
553extern int ospf_oi_count(struct interface *);
554
555extern struct ospf_area *ospf_area_get(struct ospf *, struct in_addr);
556extern void ospf_area_check_free(struct ospf *, struct in_addr);
557extern struct ospf_area *ospf_area_lookup_by_area_id(struct ospf *,
558 struct in_addr);
559extern void ospf_area_add_if(struct ospf_area *, struct ospf_interface *);
560extern void ospf_area_del_if(struct ospf_area *, struct ospf_interface *);
561
562extern void ospf_interface_area_set(struct interface *);
563extern void ospf_interface_area_unset(struct interface *);
564
565extern void ospf_route_map_init(void);
566
567extern void ospf_master_init(struct thread_master *master);
020709f9 568
718e3744 569#endif /* _ZEBRA_OSPFD_H */