3 @@ -8228,8 +8228,14 @@ bgp_str2route_type (int afi, const char
4 return ZEBRA_ROUTE_STATIC;
5 else if (strncmp (str, "r", 1) == 0)
6 return ZEBRA_ROUTE_RIP;
7 - else if (strncmp (str, "o", 1) == 0)
8 + else if (strncmp (str, "os", 2) == 0)
9 return ZEBRA_ROUTE_OSPF;
10 + else if (strncmp (str, "h", 1) == 0)
11 + return ZEBRA_ROUTE_HSLS;
12 + else if (strncmp (str, "ol", 2) == 0)
13 + return ZEBRA_ROUTE_OLSR;
14 + else if (strncmp (str, "b", 1) == 0)
15 + return ZEBRA_ROUTE_BATMAN;
19 @@ -8241,21 +8247,30 @@ bgp_str2route_type (int afi, const char
20 return ZEBRA_ROUTE_STATIC;
21 else if (strncmp (str, "r", 1) == 0)
22 return ZEBRA_ROUTE_RIPNG;
23 - else if (strncmp (str, "o", 1) == 0)
24 + else if (strncmp (str, "os", 2) == 0)
25 return ZEBRA_ROUTE_OSPF6;
26 + else if (strncmp (str, "h", 1) == 0)
27 + return ZEBRA_ROUTE_HSLS;
28 + else if (strncmp (str, "ol", 2) == 0)
29 + return ZEBRA_ROUTE_OLSR;
30 + else if (strncmp (str, "b", 1) == 0)
31 + return ZEBRA_ROUTE_BATMAN;
36 DEFUN (bgp_redistribute_ipv4,
37 bgp_redistribute_ipv4_cmd,
38 - "redistribute (connected|kernel|ospf|rip|static)",
39 + "redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman)",
40 "Redistribute information from another routing protocol\n"
43 "Open Shurtest Path First (OSPF)\n"
44 "Routing Information Protocol (RIP)\n"
47 + "Hazy-Sighted Link State Protocol (HSLS)\n"
48 + "Optimized Link State Routing (OLSR)\n"
49 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n")
53 @@ -8270,13 +8285,16 @@ DEFUN (bgp_redistribute_ipv4,
55 DEFUN (bgp_redistribute_ipv4_rmap,
56 bgp_redistribute_ipv4_rmap_cmd,
57 - "redistribute (connected|kernel|ospf|rip|static) route-map WORD",
58 + "redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) route-map WORD",
59 "Redistribute information from another routing protocol\n"
62 "Open Shurtest Path First (OSPF)\n"
63 "Routing Information Protocol (RIP)\n"
65 + "Hazy-Sighted Link State Protocol (HSLS)\n"
66 + "Optimized Link State Routing (OLSR)\n"
67 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
68 "Route map reference\n"
69 "Pointer to route-map entries\n")
71 @@ -8295,13 +8313,16 @@ DEFUN (bgp_redistribute_ipv4_rmap,
73 DEFUN (bgp_redistribute_ipv4_metric,
74 bgp_redistribute_ipv4_metric_cmd,
75 - "redistribute (connected|kernel|ospf|rip|static) metric <0-4294967295>",
76 + "redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) metric <0-4294967295>",
77 "Redistribute information from another routing protocol\n"
80 "Open Shurtest Path First (OSPF)\n"
81 "Routing Information Protocol (RIP)\n"
83 + "Hazy-Sighted Link State Protocol (HSLS)\n"
84 + "Optimized Link State Routing (OLSR)\n"
85 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
86 "Metric for redistributed routes\n"
89 @@ -8322,13 +8343,16 @@ DEFUN (bgp_redistribute_ipv4_metric,
91 DEFUN (bgp_redistribute_ipv4_rmap_metric,
92 bgp_redistribute_ipv4_rmap_metric_cmd,
93 - "redistribute (connected|kernel|ospf|rip|static) route-map WORD metric <0-4294967295>",
94 + "redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) route-map WORD metric <0-4294967295>",
95 "Redistribute information from another routing protocol\n"
98 "Open Shurtest Path First (OSPF)\n"
99 "Routing Information Protocol (RIP)\n"
101 + "Hazy-Sighted Link State Protocol (HSLS)\n"
102 + "Optimized Link State Routing (OLSR)\n"
103 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
104 "Route map reference\n"
105 "Pointer to route-map entries\n"
106 "Metric for redistributed routes\n"
107 @@ -8352,13 +8376,16 @@ DEFUN (bgp_redistribute_ipv4_rmap_metric
109 DEFUN (bgp_redistribute_ipv4_metric_rmap,
110 bgp_redistribute_ipv4_metric_rmap_cmd,
111 - "redistribute (connected|kernel|ospf|rip|static) metric <0-4294967295> route-map WORD",
112 + "redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) metric <0-4294967295> route-map WORD",
113 "Redistribute information from another routing protocol\n"
116 "Open Shurtest Path First (OSPF)\n"
117 "Routing Information Protocol (RIP)\n"
119 + "Hazy-Sighted Link State Protocol (HSLS)\n"
120 + "Optimized Link State Routing (OLSR)\n"
121 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
122 "Metric for redistributed routes\n"
124 "Route map reference\n"
125 @@ -8382,14 +8409,17 @@ DEFUN (bgp_redistribute_ipv4_metric_rmap
127 DEFUN (no_bgp_redistribute_ipv4,
128 no_bgp_redistribute_ipv4_cmd,
129 - "no redistribute (connected|kernel|ospf|rip|static)",
130 + "no redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman)",
132 "Redistribute information from another routing protocol\n"
135 "Open Shurtest Path First (OSPF)\n"
136 "Routing Information Protocol (RIP)\n"
139 + "Hazy-Sighted Link State Protocol (HSLS)\n"
140 + "Optimized Link State Routing (OLSR)\n"
141 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n")
145 @@ -8405,7 +8435,7 @@ DEFUN (no_bgp_redistribute_ipv4,
147 DEFUN (no_bgp_redistribute_ipv4_rmap,
148 no_bgp_redistribute_ipv4_rmap_cmd,
149 - "no redistribute (connected|kernel|ospf|rip|static) route-map WORD",
150 + "no redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) route-map WORD",
152 "Redistribute information from another routing protocol\n"
154 @@ -8413,6 +8443,9 @@ DEFUN (no_bgp_redistribute_ipv4_rmap,
155 "Open Shurtest Path First (OSPF)\n"
156 "Routing Information Protocol (RIP)\n"
158 + "Hazy-Sighted Link State Protocol (HSLS)\n"
159 + "Optimized Link State Routing (OLSR)\n"
160 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
161 "Route map reference\n"
162 "Pointer to route-map entries\n")
164 @@ -8431,7 +8464,7 @@ DEFUN (no_bgp_redistribute_ipv4_rmap,
166 DEFUN (no_bgp_redistribute_ipv4_metric,
167 no_bgp_redistribute_ipv4_metric_cmd,
168 - "no redistribute (connected|kernel|ospf|rip|static) metric <0-4294967295>",
169 + "no redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) metric <0-4294967295>",
171 "Redistribute information from another routing protocol\n"
173 @@ -8439,6 +8472,9 @@ DEFUN (no_bgp_redistribute_ipv4_metric,
174 "Open Shurtest Path First (OSPF)\n"
175 "Routing Information Protocol (RIP)\n"
177 + "Hazy-Sighted Link State Protocol (HSLS)\n"
178 + "Optimized Link State Routing (OLSR)\n"
179 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
180 "Metric for redistributed routes\n"
183 @@ -8457,7 +8493,7 @@ DEFUN (no_bgp_redistribute_ipv4_metric,
185 DEFUN (no_bgp_redistribute_ipv4_rmap_metric,
186 no_bgp_redistribute_ipv4_rmap_metric_cmd,
187 - "no redistribute (connected|kernel|ospf|rip|static) route-map WORD metric <0-4294967295>",
188 + "no redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) route-map WORD metric <0-4294967295>",
190 "Redistribute information from another routing protocol\n"
192 @@ -8465,6 +8501,9 @@ DEFUN (no_bgp_redistribute_ipv4_rmap_met
193 "Open Shurtest Path First (OSPF)\n"
194 "Routing Information Protocol (RIP)\n"
196 + "Hazy-Sighted Link State Protocol (HSLS)\n"
197 + "Optimized Link State Routing (OLSR)\n"
198 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
199 "Route map reference\n"
200 "Pointer to route-map entries\n"
201 "Metric for redistributed routes\n"
202 @@ -8486,7 +8525,7 @@ DEFUN (no_bgp_redistribute_ipv4_rmap_met
204 ALIAS (no_bgp_redistribute_ipv4_rmap_metric,
205 no_bgp_redistribute_ipv4_metric_rmap_cmd,
206 - "no redistribute (connected|kernel|ospf|rip|static) metric <0-4294967295> route-map WORD",
207 + "no redistribute (connected|kernel|ospf|rip|static|hsls|olsr|batman) metric <0-4294967295> route-map WORD",
209 "Redistribute information from another routing protocol\n"
211 @@ -8494,6 +8533,9 @@ ALIAS (no_bgp_redistribute_ipv4_rmap_met
212 "Open Shurtest Path First (OSPF)\n"
213 "Routing Information Protocol (RIP)\n"
215 + "Hazy-Sighted Link State Protocol (HSLS)\n"
216 + "Optimized Link State Routing (OLSR)\n"
217 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
218 "Metric for redistributed routes\n"
220 "Route map reference\n"
221 @@ -8502,13 +8544,16 @@ ALIAS (no_bgp_redistribute_ipv4_rmap_met
223 DEFUN (bgp_redistribute_ipv6,
224 bgp_redistribute_ipv6_cmd,
225 - "redistribute (connected|kernel|ospf6|ripng|static)",
226 + "redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman)",
227 "Redistribute information from another routing protocol\n"
230 "Open Shurtest Path First (OSPFv3)\n"
231 "Routing Information Protocol (RIPng)\n"
234 + "Hazy-Sighted Link State Protocol (HSLS)\n"
235 + "Optimized Link State Routing (OLSR)\n"
236 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n")
240 @@ -8524,13 +8569,16 @@ DEFUN (bgp_redistribute_ipv6,
242 DEFUN (bgp_redistribute_ipv6_rmap,
243 bgp_redistribute_ipv6_rmap_cmd,
244 - "redistribute (connected|kernel|ospf6|ripng|static) route-map WORD",
245 + "redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) route-map WORD",
246 "Redistribute information from another routing protocol\n"
249 "Open Shurtest Path First (OSPFv3)\n"
250 "Routing Information Protocol (RIPng)\n"
252 + "Hazy-Sighted Link State Protocol (HSLS)\n"
253 + "Optimized Link State Routing (OLSR)\n"
254 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
255 "Route map reference\n"
256 "Pointer to route-map entries\n")
258 @@ -8549,13 +8597,16 @@ DEFUN (bgp_redistribute_ipv6_rmap,
260 DEFUN (bgp_redistribute_ipv6_metric,
261 bgp_redistribute_ipv6_metric_cmd,
262 - "redistribute (connected|kernel|ospf6|ripng|static) metric <0-4294967295>",
263 + "redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) metric <0-4294967295>",
264 "Redistribute information from another routing protocol\n"
267 "Open Shurtest Path First (OSPFv3)\n"
268 "Routing Information Protocol (RIPng)\n"
270 + "Hazy-Sighted Link State Protocol (HSLS)\n"
271 + "Optimized Link State Routing (OLSR)\n"
272 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
273 "Metric for redistributed routes\n"
276 @@ -8576,13 +8627,16 @@ DEFUN (bgp_redistribute_ipv6_metric,
278 DEFUN (bgp_redistribute_ipv6_rmap_metric,
279 bgp_redistribute_ipv6_rmap_metric_cmd,
280 - "redistribute (connected|kernel|ospf6|ripng|static) route-map WORD metric <0-4294967295>",
281 + "redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) route-map WORD metric <0-4294967295>",
282 "Redistribute information from another routing protocol\n"
285 "Open Shurtest Path First (OSPFv3)\n"
286 "Routing Information Protocol (RIPng)\n"
288 + "Hazy-Sighted Link State Protocol (HSLS)\n"
289 + "Optimized Link State Routing (OLSR)\n"
290 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
291 "Route map reference\n"
292 "Pointer to route-map entries\n"
293 "Metric for redistributed routes\n"
294 @@ -8606,13 +8660,16 @@ DEFUN (bgp_redistribute_ipv6_rmap_metric
296 DEFUN (bgp_redistribute_ipv6_metric_rmap,
297 bgp_redistribute_ipv6_metric_rmap_cmd,
298 - "redistribute (connected|kernel|ospf6|ripng|static) metric <0-4294967295> route-map WORD",
299 + "redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) metric <0-4294967295> route-map WORD",
300 "Redistribute information from another routing protocol\n"
303 "Open Shurtest Path First (OSPFv3)\n"
304 "Routing Information Protocol (RIPng)\n"
306 + "Hazy-Sighted Link State Protocol (HSLS)\n"
307 + "Optimized Link State Routing (OLSR)\n"
308 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
309 "Metric for redistributed routes\n"
311 "Route map reference\n"
312 @@ -8636,14 +8693,17 @@ DEFUN (bgp_redistribute_ipv6_metric_rmap
314 DEFUN (no_bgp_redistribute_ipv6,
315 no_bgp_redistribute_ipv6_cmd,
316 - "no redistribute (connected|kernel|ospf6|ripng|static)",
317 + "no redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman)",
319 "Redistribute information from another routing protocol\n"
322 "Open Shurtest Path First (OSPFv3)\n"
323 "Routing Information Protocol (RIPng)\n"
326 + "Hazy-Sighted Link State Protocol (HSLS)\n"
327 + "Optimized Link State Routing (OLSR)\n"
328 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n")
332 @@ -8659,7 +8719,7 @@ DEFUN (no_bgp_redistribute_ipv6,
334 DEFUN (no_bgp_redistribute_ipv6_rmap,
335 no_bgp_redistribute_ipv6_rmap_cmd,
336 - "no redistribute (connected|kernel|ospf6|ripng|static) route-map WORD",
337 + "no redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) route-map WORD",
339 "Redistribute information from another routing protocol\n"
341 @@ -8667,6 +8727,9 @@ DEFUN (no_bgp_redistribute_ipv6_rmap,
342 "Open Shurtest Path First (OSPFv3)\n"
343 "Routing Information Protocol (RIPng)\n"
345 + "Hazy-Sighted Link State Protocol (HSLS)\n"
346 + "Optimized Link State Routing (OLSR)\n"
347 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
348 "Route map reference\n"
349 "Pointer to route-map entries\n")
351 @@ -8685,7 +8748,7 @@ DEFUN (no_bgp_redistribute_ipv6_rmap,
353 DEFUN (no_bgp_redistribute_ipv6_metric,
354 no_bgp_redistribute_ipv6_metric_cmd,
355 - "no redistribute (connected|kernel|ospf6|ripng|static) metric <0-4294967295>",
356 + "no redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) metric <0-4294967295>",
358 "Redistribute information from another routing protocol\n"
360 @@ -8693,6 +8756,9 @@ DEFUN (no_bgp_redistribute_ipv6_metric,
361 "Open Shurtest Path First (OSPFv3)\n"
362 "Routing Information Protocol (RIPng)\n"
364 + "Hazy-Sighted Link State Protocol (HSLS)\n"
365 + "Optimized Link State Routing (OLSR)\n"
366 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
367 "Metric for redistributed routes\n"
370 @@ -8711,7 +8777,7 @@ DEFUN (no_bgp_redistribute_ipv6_metric,
372 DEFUN (no_bgp_redistribute_ipv6_rmap_metric,
373 no_bgp_redistribute_ipv6_rmap_metric_cmd,
374 - "no redistribute (connected|kernel|ospf6|ripng|static) route-map WORD metric <0-4294967295>",
375 + "no redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) route-map WORD metric <0-4294967295>",
377 "Redistribute information from another routing protocol\n"
379 @@ -8719,6 +8785,9 @@ DEFUN (no_bgp_redistribute_ipv6_rmap_met
380 "Open Shurtest Path First (OSPFv3)\n"
381 "Routing Information Protocol (RIPng)\n"
383 + "Hazy-Sighted Link State Protocol (HSLS)\n"
384 + "Optimized Link State Routing (OLSR)\n"
385 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
386 "Route map reference\n"
387 "Pointer to route-map entries\n"
388 "Metric for redistributed routes\n"
389 @@ -8740,7 +8809,7 @@ DEFUN (no_bgp_redistribute_ipv6_rmap_met
391 ALIAS (no_bgp_redistribute_ipv6_rmap_metric,
392 no_bgp_redistribute_ipv6_metric_rmap_cmd,
393 - "no redistribute (connected|kernel|ospf6|ripng|static) metric <0-4294967295> route-map WORD",
394 + "no redistribute (connected|kernel|ospf6|ripng|static|hsls|olsr|batman) metric <0-4294967295> route-map WORD",
396 "Redistribute information from another routing protocol\n"
398 @@ -8748,6 +8817,9 @@ ALIAS (no_bgp_redistribute_ipv6_rmap_met
399 "Open Shurtest Path First (OSPFv3)\n"
400 "Routing Information Protocol (RIPng)\n"
402 + "Hazy-Sighted Link State Protocol (HSLS)\n"
403 + "Optimized Link State Routing (OLSR)\n"
404 + "Better Approach to Mobile Ad-Hoc Networking (BATMAN)\n"
405 "Metric for redistributed routes\n"
407 "Route map reference\n"
410 @@ -835,6 +835,8 @@ static const struct zebra_desc_table rou
411 DESC_ENTRY (ZEBRA_ROUTE_ISIS, "isis", 'I' ),
412 DESC_ENTRY (ZEBRA_ROUTE_BGP, "bgp", 'B' ),
413 DESC_ENTRY (ZEBRA_ROUTE_HSLS, "hsls", 'H' ),
414 + DESC_ENTRY (ZEBRA_ROUTE_OLSR, "olsr", 'o' ),
415 + DESC_ENTRY (ZEBRA_ROUTE_BATMAN, "batman", 'b' ),
419 --- a/lib/route_types.txt
420 +++ b/lib/route_types.txt
421 @@ -51,13 +51,9 @@ ZEBRA_ROUTE_OSPF, ospf, ospfd
422 ZEBRA_ROUTE_OSPF6, ospf6, ospf6d, 'O', 0, 1, "OSPF"
423 ZEBRA_ROUTE_ISIS, isis, isisd, 'I', 1, 1, "IS-IS"
424 ZEBRA_ROUTE_BGP, bgp, bgpd, 'B', 1, 1, "BGP"
425 -# HSLS and OLSR both are AFI independent (so: 1, 1), however
426 -# we want to disable for them for general Quagga distribution.
427 -# This at least makes it trivial for users of these protocols
428 -# to 'switch on' redist support (direct numeric entry remaining
430 -ZEBRA_ROUTE_HSLS, hsls, hslsd, 'H', 0, 0, "HSLS"
431 -ZEBRA_ROUTE_OLSR, olsr, oslrd, 'o', 0, 0, "OLSR"
432 +ZEBRA_ROUTE_HSLS, hsls, hslsd, 'H', 1, 1, "HSLS"
433 +ZEBRA_ROUTE_OLSR, olsr, olsrd, 'o', 1, 1, "OLSR"
434 +ZEBRA_ROUTE_BATMAN, batman, batmand,'b', 1, 1, "BATMAN"
437 ZEBRA_ROUTE_SYSTEM, "Reserved route type, for internal use only"
438 @@ -71,4 +67,5 @@ ZEBRA_ROUTE_OSPF6, "Open Shortest Path
439 ZEBRA_ROUTE_ISIS, "Intermediate System to Intermediate System (IS-IS)"
440 ZEBRA_ROUTE_BGP, "Border Gateway Protocol (BGP)"
441 ZEBRA_ROUTE_HSLS, "Hazy-Sighted Link State Protocol (HSLS)"
442 -ZEBRA_ROUTE_OLSR, "Optimised Link State Routing (OLSR)"
443 +ZEBRA_ROUTE_OLSR, "Optimized Link State Routing (OLSR)"
444 +ZEBRA_ROUTE_BATMAN, "Better Approach to Mobile Ad-Hoc Networking (BATMAN)"
447 @@ -441,7 +441,9 @@ struct in_pktinfo
448 #define ZEBRA_ROUTE_ISIS 8
449 #define ZEBRA_ROUTE_BGP 9
450 #define ZEBRA_ROUTE_HSLS 10
451 -#define ZEBRA_ROUTE_MAX 11
452 +#define ZEBRA_ROUTE_OLSR 11
453 +#define ZEBRA_ROUTE_BATMAN 12
454 +#define ZEBRA_ROUTE_MAX 13
456 /* Note: whenever a new route-type or zserv-command is added the
457 * corresponding {command,route}_types[] table in lib/log.c MUST be
458 --- a/ospf6d/ospf6_asbr.c
459 +++ b/ospf6d/ospf6_asbr.c
460 @@ -616,13 +616,16 @@ ospf6_asbr_redistribute_remove (int type
462 DEFUN (ospf6_redistribute,
463 ospf6_redistribute_cmd,
464 - "redistribute (static|kernel|connected|ripng|bgp)",
465 + "redistribute (static|kernel|connected|ripng|bgp|hsls|olsr|batman)",
478 @@ -637,6 +640,12 @@ DEFUN (ospf6_redistribute,
479 type = ZEBRA_ROUTE_RIPNG;
480 else if (strncmp (argv[0], "bgp", 3) == 0)
481 type = ZEBRA_ROUTE_BGP;
482 + else if (strncmp (argv[0], "h", 1) == 0)
483 + type = ZEBRA_ROUTE_HSLS;
484 + else if (strncmp (argv[0], "o", 1) == 0)
485 + type = ZEBRA_ROUTE_OLSR;
486 + else if (strncmp (argv[0], "ba", 2) == 0)
487 + type = ZEBRA_ROUTE_BATMAN;
489 ospf6_asbr_redistribute_unset (type);
490 ospf6_asbr_routemap_unset (type);
491 @@ -646,13 +655,16 @@ DEFUN (ospf6_redistribute,
493 DEFUN (ospf6_redistribute_routemap,
494 ospf6_redistribute_routemap_cmd,
495 - "redistribute (static|kernel|connected|ripng|bgp) route-map WORD",
496 + "redistribute (static|kernel|connected|ripng|bgp|hsls|olsr|batman) route-map WORD",
506 "Route map reference\n"
509 @@ -669,6 +681,12 @@ DEFUN (ospf6_redistribute_routemap,
510 type = ZEBRA_ROUTE_RIPNG;
511 else if (strncmp (argv[0], "bgp", 3) == 0)
512 type = ZEBRA_ROUTE_BGP;
513 + else if (strncmp (argv[0], "h", 1) == 0)
514 + type = ZEBRA_ROUTE_HSLS;
515 + else if (strncmp (argv[0], "o", 1) == 0)
516 + type = ZEBRA_ROUTE_OLSR;
517 + else if (strncmp (argv[0], "ba", 2) == 0)
518 + type = ZEBRA_ROUTE_BATMAN;
520 ospf6_asbr_redistribute_unset (type);
521 ospf6_asbr_routemap_set (type, argv[1]);
522 @@ -678,7 +696,7 @@ DEFUN (ospf6_redistribute_routemap,
524 DEFUN (no_ospf6_redistribute,
525 no_ospf6_redistribute_cmd,
526 - "no redistribute (static|kernel|connected|ripng|bgp)",
527 + "no redistribute (static|kernel|connected|ripng|bgp|hsls|olsr|batman)",
531 @@ -686,6 +704,9 @@ DEFUN (no_ospf6_redistribute,
541 @@ -700,6 +721,12 @@ DEFUN (no_ospf6_redistribute,
542 type = ZEBRA_ROUTE_RIPNG;
543 else if (strncmp (argv[0], "bgp", 3) == 0)
544 type = ZEBRA_ROUTE_BGP;
545 + else if (strncmp (argv[0], "h", 1) == 0)
546 + type = ZEBRA_ROUTE_HSLS;
547 + else if (strncmp (argv[0], "o", 1) == 0)
548 + type = ZEBRA_ROUTE_OLSR;
549 + else if (strncmp (argv[0], "ba", 2) == 0)
550 + type = ZEBRA_ROUTE_BATMAN;
552 ospf6_asbr_redistribute_unset (type);
553 ospf6_asbr_routemap_unset (type);
554 --- a/ospfd/ospf_vty.c
555 +++ b/ospfd/ospf_vty.c
556 @@ -107,8 +107,14 @@ str2distribute_source (const char *str,
557 *source = ZEBRA_ROUTE_STATIC;
558 else if (strncmp (str, "r", 1) == 0)
559 *source = ZEBRA_ROUTE_RIP;
560 - else if (strncmp (str, "b", 1) == 0)
561 + else if (strncmp (str, "bg", 2) == 0)
562 *source = ZEBRA_ROUTE_BGP;
563 + else if (strncmp (str, "h", 1) == 0)
564 + *source = ZEBRA_ROUTE_HSLS;
565 + else if (strncmp (str, "o", 1) == 0)
566 + *source = ZEBRA_ROUTE_OLSR;
567 + else if (strncmp (str, "ba", 2) == 0)
568 + *source = ZEBRA_ROUTE_BATMAN;
572 --- a/ripd/rip_zebra.c
573 +++ b/ripd/rip_zebra.c
574 @@ -204,8 +204,11 @@ static struct {
575 {ZEBRA_ROUTE_KERNEL, 1, "kernel"},
576 {ZEBRA_ROUTE_CONNECT, 1, "connected"},
577 {ZEBRA_ROUTE_STATIC, 1, "static"},
578 - {ZEBRA_ROUTE_OSPF, 1, "ospf"},
579 - {ZEBRA_ROUTE_BGP, 1, "bgp"},
580 + {ZEBRA_ROUTE_OSPF, 2, "ospf"},
581 + {ZEBRA_ROUTE_BGP, 2, "bgp"},
582 + {ZEBRA_ROUTE_HSLS, 1, "hsls"},
583 + {ZEBRA_ROUTE_OLSR, 2, "olsr"},
584 + {ZEBRA_ROUTE_BATMAN, 2, "batman"},
588 --- a/ripngd/ripng_zebra.c
589 +++ b/ripngd/ripng_zebra.c
590 @@ -214,8 +214,11 @@ static struct {
591 {ZEBRA_ROUTE_KERNEL, 1, "kernel"},
592 {ZEBRA_ROUTE_CONNECT, 1, "connected"},
593 {ZEBRA_ROUTE_STATIC, 1, "static"},
594 - {ZEBRA_ROUTE_OSPF6, 1, "ospf6"},
595 - {ZEBRA_ROUTE_BGP, 1, "bgp"},
596 + {ZEBRA_ROUTE_OSPF6, 2, "ospf6"},
597 + {ZEBRA_ROUTE_BGP, 2, "bgp"},
598 + {ZEBRA_ROUTE_HSLS, 1, "hsls"},
599 + {ZEBRA_ROUTE_OLSR, 2, "olsr"},
600 + {ZEBRA_ROUTE_BATMAN, 2, "batman"},
604 --- a/zebra/redistribute.c
605 +++ b/zebra/redistribute.c
606 @@ -255,6 +255,9 @@ zebra_redistribute_add (int command, str
607 case ZEBRA_ROUTE_OSPF:
608 case ZEBRA_ROUTE_OSPF6:
609 case ZEBRA_ROUTE_BGP:
610 + case ZEBRA_ROUTE_HSLS:
611 + case ZEBRA_ROUTE_OLSR:
612 + case ZEBRA_ROUTE_BATMAN:
613 if (! client->redist[type])
615 client->redist[type] = 1;
616 @@ -283,6 +286,9 @@ zebra_redistribute_delete (int command,
617 case ZEBRA_ROUTE_OSPF:
618 case ZEBRA_ROUTE_OSPF6:
619 case ZEBRA_ROUTE_BGP:
620 + case ZEBRA_ROUTE_HSLS:
621 + case ZEBRA_ROUTE_OLSR:
622 + case ZEBRA_ROUTE_BATMAN:
623 client->redist[type] = 0;
626 --- a/zebra/zebra_rib.c
627 +++ b/zebra/zebra_rib.c
628 @@ -66,7 +66,10 @@ static const struct
629 {ZEBRA_ROUTE_OSPF, 110},
630 {ZEBRA_ROUTE_OSPF6, 110},
631 {ZEBRA_ROUTE_ISIS, 115},
632 - {ZEBRA_ROUTE_BGP, 20 /* IBGP is 200. */}
633 + {ZEBRA_ROUTE_BGP, 20 /* IBGP is 200. */},
634 + {ZEBRA_ROUTE_HSLS, 0},
635 + {ZEBRA_ROUTE_OLSR, 0},
636 + {ZEBRA_ROUTE_BATMAN, 0}
639 /* Vector for routing table. */
640 @@ -1229,6 +1232,8 @@ static const u_char meta_queue_map[ZEBRA
641 [ZEBRA_ROUTE_ISIS] = 2,
642 [ZEBRA_ROUTE_BGP] = 3,
643 [ZEBRA_ROUTE_HSLS] = 4,
644 + [ZEBRA_ROUTE_OLSR] = 4,
645 + [ZEBRA_ROUTE_BATMAN] = 4,
648 /* Look into the RN and queue it into one or more priority queues,
649 --- a/zebra/zebra_snmp.c
650 +++ b/zebra/zebra_snmp.c
651 @@ -251,6 +251,12 @@ proto_trans(int type)
652 return 1; /* shouldn't happen */
653 case ZEBRA_ROUTE_BGP:
655 + case ZEBRA_ROUTE_HSLS:
656 + return 1; /* other */
657 + case ZEBRA_ROUTE_OLSR:
658 + return 1; /* other */
659 + case ZEBRA_ROUTE_BATMAN:
660 + return 1; /* other */
662 return 1; /* other */
664 --- a/zebra/zebra_vty.c
665 +++ b/zebra/zebra_vty.c
666 @@ -557,7 +557,10 @@ vty_show_ip_route_detail (struct vty *vt
667 if (rib->type == ZEBRA_ROUTE_RIP
668 || rib->type == ZEBRA_ROUTE_OSPF
669 || rib->type == ZEBRA_ROUTE_ISIS
670 - || rib->type == ZEBRA_ROUTE_BGP)
671 + || rib->type == ZEBRA_ROUTE_BGP
672 + || rib->type == ZEBRA_ROUTE_HSLS
673 + || rib->type == ZEBRA_ROUTE_OLSR
674 + || rib->type == ZEBRA_ROUTE_BATMAN)
678 @@ -775,7 +778,10 @@ vty_show_ip_route (struct vty *vty, stru
679 if (rib->type == ZEBRA_ROUTE_RIP
680 || rib->type == ZEBRA_ROUTE_OSPF
681 || rib->type == ZEBRA_ROUTE_ISIS
682 - || rib->type == ZEBRA_ROUTE_BGP)
683 + || rib->type == ZEBRA_ROUTE_BGP
684 + || rib->type == ZEBRA_ROUTE_HSLS
685 + || rib->type == ZEBRA_ROUTE_OLSR
686 + || rib->type == ZEBRA_ROUTE_BATMAN)
690 @@ -803,8 +809,8 @@ vty_show_ip_route (struct vty *vty, stru
693 #define SHOW_ROUTE_V4_HEADER "Codes: K - kernel route, C - connected, " \
694 - "S - static, R - RIP, O - OSPF,%s I - ISIS, B - BGP, " \
695 - "> - selected route, * - FIB route%s%s"
696 + "S - static, R - RIP, O - OSPF,%s I - ISIS, B - BGP, H - HSLS, " \
697 + "o - OLSR, b - BATMAN,%s > - selected route, * - FIB route%s%s"
699 DEFUN (show_ip_route,
701 @@ -829,7 +835,7 @@ DEFUN (show_ip_route,
704 vty_out (vty, SHOW_ROUTE_V4_HEADER, VTY_NEWLINE, VTY_NEWLINE,
706 + VTY_NEWLINE, VTY_NEWLINE);
709 vty_show_ip_route (vty, rn, rib);
710 @@ -872,7 +878,7 @@ DEFUN (show_ip_route_prefix_longer,
713 vty_out (vty, SHOW_ROUTE_V4_HEADER, VTY_NEWLINE,
714 - VTY_NEWLINE, VTY_NEWLINE);
715 + VTY_NEWLINE, VTY_NEWLINE, VTY_NEWLINE);
718 vty_show_ip_route (vty, rn, rib);
719 @@ -911,7 +917,7 @@ DEFUN (show_ip_route_supernets,
722 vty_out (vty, SHOW_ROUTE_V4_HEADER, VTY_NEWLINE,
723 - VTY_NEWLINE, VTY_NEWLINE);
724 + VTY_NEWLINE, VTY_NEWLINE, VTY_NEWLINE);
727 vty_show_ip_route (vty, rn, rib);
728 @@ -922,7 +928,7 @@ DEFUN (show_ip_route_supernets,
730 DEFUN (show_ip_route_protocol,
731 show_ip_route_protocol_cmd,
732 - "show ip route (bgp|connected|isis|kernel|ospf|rip|static)",
733 + "show ip route (bgp|connected|isis|kernel|ospf|rip|static|hsls|olsr|batman)",
737 @@ -940,13 +946,13 @@ DEFUN (show_ip_route_protocol,
741 - if (strncmp (argv[0], "b", 1) == 0)
742 + if (strncmp (argv[0], "bg", 2) == 0)
743 type = ZEBRA_ROUTE_BGP;
744 else if (strncmp (argv[0], "c", 1) == 0)
745 type = ZEBRA_ROUTE_CONNECT;
746 else if (strncmp (argv[0], "k", 1) ==0)
747 type = ZEBRA_ROUTE_KERNEL;
748 - else if (strncmp (argv[0], "o", 1) == 0)
749 + else if (strncmp (argv[0], "os", 2) == 0)
750 type = ZEBRA_ROUTE_OSPF;
751 else if (strncmp (argv[0], "i", 1) == 0)
752 type = ZEBRA_ROUTE_ISIS;
753 @@ -954,6 +960,12 @@ DEFUN (show_ip_route_protocol,
754 type = ZEBRA_ROUTE_RIP;
755 else if (strncmp (argv[0], "s", 1) == 0)
756 type = ZEBRA_ROUTE_STATIC;
757 + else if (strncmp (argv[0], "h", 1) == 0)
758 + type = ZEBRA_ROUTE_HSLS;
759 + else if (strncmp (argv[0], "ol", 2) == 0)
760 + type = ZEBRA_ROUTE_OLSR;
761 + else if (strncmp (argv[0], "ba", 2) == 0)
762 + type = ZEBRA_ROUTE_BATMAN;
765 vty_out (vty, "Unknown route type%s", VTY_NEWLINE);
766 @@ -971,7 +983,7 @@ DEFUN (show_ip_route_protocol,
770 - vty_out (vty, SHOW_ROUTE_V4_HEADER,
771 + vty_out (vty, SHOW_ROUTE_V4_HEADER, VTY_NEWLINE,
772 VTY_NEWLINE, VTY_NEWLINE, VTY_NEWLINE);
775 @@ -1560,7 +1572,10 @@ vty_show_ipv6_route_detail (struct vty *
776 if (rib->type == ZEBRA_ROUTE_RIPNG
777 || rib->type == ZEBRA_ROUTE_OSPF6
778 || rib->type == ZEBRA_ROUTE_ISIS
779 - || rib->type == ZEBRA_ROUTE_BGP)
780 + || rib->type == ZEBRA_ROUTE_BGP
781 + || rib->type == ZEBRA_ROUTE_HSLS
782 + || rib->type == ZEBRA_ROUTE_OLSR
783 + || rib->type == ZEBRA_ROUTE_BATMAN)
787 @@ -1739,7 +1754,10 @@ vty_show_ipv6_route (struct vty *vty, st
788 if (rib->type == ZEBRA_ROUTE_RIPNG
789 || rib->type == ZEBRA_ROUTE_OSPF6
790 || rib->type == ZEBRA_ROUTE_ISIS
791 - || rib->type == ZEBRA_ROUTE_BGP)
792 + || rib->type == ZEBRA_ROUTE_BGP
793 + || rib->type == ZEBRA_ROUTE_HSLS
794 + || rib->type == ZEBRA_ROUTE_OLSR
795 + || rib->type == ZEBRA_ROUTE_BATMAN)
799 @@ -1766,7 +1784,7 @@ vty_show_ipv6_route (struct vty *vty, st
803 -#define SHOW_ROUTE_V6_HEADER "Codes: K - kernel route, C - connected, S - static, R - RIPng, O - OSPFv3,%s I - ISIS, B - BGP, * - FIB route.%s%s"
804 +#define SHOW_ROUTE_V6_HEADER "Codes: K - kernel route, C - connected, S - static, R - RIPng, O - OSPFv3,%s I - ISIS, B - BGP, H - HSLS, o - OLSR, b - BATMAN, * - FIB route.%s%s"
806 DEFUN (show_ipv6_route,
808 @@ -1842,7 +1860,7 @@ DEFUN (show_ipv6_route_prefix_longer,
810 DEFUN (show_ipv6_route_protocol,
811 show_ipv6_route_protocol_cmd,
812 - "show ipv6 route (bgp|connected|isis|kernel|ospf6|ripng|static)",
813 + "show ipv6 route (bgp|connected|isis|kernel|ospf6|ripng|static|hsls|olsr|batman)",
817 @@ -1860,13 +1878,13 @@ DEFUN (show_ipv6_route_protocol,
821 - if (strncmp (argv[0], "b", 1) == 0)
822 + if (strncmp (argv[0], "bg", 2) == 0)
823 type = ZEBRA_ROUTE_BGP;
824 else if (strncmp (argv[0], "c", 1) == 0)
825 type = ZEBRA_ROUTE_CONNECT;
826 else if (strncmp (argv[0], "k", 1) ==0)
827 type = ZEBRA_ROUTE_KERNEL;
828 - else if (strncmp (argv[0], "o", 1) == 0)
829 + else if (strncmp (argv[0], "os", 2) == 0)
830 type = ZEBRA_ROUTE_OSPF6;
831 else if (strncmp (argv[0], "i", 1) == 0)
832 type = ZEBRA_ROUTE_ISIS;
833 @@ -1874,6 +1892,12 @@ DEFUN (show_ipv6_route_protocol,
834 type = ZEBRA_ROUTE_RIPNG;
835 else if (strncmp (argv[0], "s", 1) == 0)
836 type = ZEBRA_ROUTE_STATIC;
837 + else if (strncmp (argv[0], "h", 1) == 0)
838 + type = ZEBRA_ROUTE_HSLS;
839 + else if (strncmp (argv[0], "ol", 2) == 0)
840 + type = ZEBRA_ROUTE_OLSR;
841 + else if (strncmp (argv[0], "ba", 2) == 0)
842 + type = ZEBRA_ROUTE_BATMAN;
845 vty_out (vty, "Unknown route type%s", VTY_NEWLINE);