2 * Copyright (c) 2016 Cisco and/or its affiliates.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at:
7 * http://www.apache.org/licenses/LICENSE-2.0
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
16 #include <vnet/fib/ip6_fib.h>
17 #include <vnet/fib/fib_table.h>
18 #include <vnet/dpo/ip6_ll_dpo.h>
20 #include <vppinfra/bihash_24_8.h>
21 #include <vppinfra/bihash_template.c>
23 ip6_fib_table_instance_t ip6_fib_table[IP6_FIB_NUM_TABLES];
25 /* ip6 lookup table config parameters */
26 u32 ip6_fib_table_nbuckets;
27 uword ip6_fib_table_size;
30 vnet_ip6_fib_init (u32 fib_index)
33 .fp_proto = FIB_PROTOCOL_IP6,
43 * Add the default route.
45 fib_table_entry_special_add(fib_index,
47 FIB_SOURCE_DEFAULT_ROUTE,
51 * all link local via the link local lookup DPO
53 pfx.fp_addr.ip6.as_u64[0] = clib_host_to_net_u64 (0xFE80000000000000ULL);
54 pfx.fp_addr.ip6.as_u64[1] = 0;
56 fib_table_entry_special_dpo_add(fib_index,
64 create_fib_with_table_id (u32 table_id,
66 fib_table_flags_t flags,
69 fib_table_t *fib_table;
72 pool_get(ip6_main.fibs, fib_table);
73 pool_get_aligned(ip6_main.v6_fibs, v6_fib, CLIB_CACHE_LINE_BYTES);
75 clib_memset(fib_table, 0, sizeof(*fib_table));
76 clib_memset(v6_fib, 0, sizeof(*v6_fib));
78 ASSERT((fib_table - ip6_main.fibs) ==
79 (v6_fib - ip6_main.v6_fibs));
81 fib_table->ft_proto = FIB_PROTOCOL_IP6;
84 (fib_table - ip6_main.fibs);
86 hash_set(ip6_main.fib_index_by_table_id, table_id, fib_table->ft_index);
88 fib_table->ft_table_id =
91 fib_table->ft_flow_hash_config = IP_FLOW_HASH_DEFAULT;
92 fib_table->ft_flags = flags;
93 fib_table->ft_desc = desc;
95 vnet_ip6_fib_init(fib_table->ft_index);
96 fib_table_lock(fib_table->ft_index, FIB_PROTOCOL_IP6, src);
98 return (fib_table->ft_index);
102 ip6_fib_table_find_or_create_and_lock (u32 table_id,
107 p = hash_get (ip6_main.fib_index_by_table_id, table_id);
109 return create_fib_with_table_id(table_id, src,
113 fib_table_lock(p[0], FIB_PROTOCOL_IP6, src);
119 ip6_fib_table_create_and_lock (fib_source_t src,
120 fib_table_flags_t flags,
123 return (create_fib_with_table_id(~0, src, flags, desc));
127 ip6_fib_table_destroy (u32 fib_index)
130 * all link local first ...
133 .fp_proto = FIB_PROTOCOL_IP6,
144 fib_table_entry_delete(fib_index,
149 * ... then the default route.
151 pfx.fp_addr.ip6.as_u64[0] = 0;
153 fib_table_entry_special_remove(fib_index,
155 FIB_SOURCE_DEFAULT_ROUTE);
157 fib_table_t *fib_table = fib_table_get(fib_index, FIB_PROTOCOL_IP6);
161 * validate no more routes.
164 if (0 != fib_table->ft_total_route_counts)
165 fib_table_assert_empty(fib_table);
168 vec_foreach_index(source, fib_table->ft_src_route_counts)
170 ASSERT(0 == fib_table->ft_src_route_counts[source]);
173 if (~0 != fib_table->ft_table_id)
175 hash_unset (ip6_main.fib_index_by_table_id, fib_table->ft_table_id);
177 vec_free(fib_table->ft_src_route_counts);
178 pool_put_index(ip6_main.v6_fibs, fib_table->ft_index);
179 pool_put(ip6_main.fibs, fib_table);
183 ip6_fib_table_lookup (u32 fib_index,
184 const ip6_address_t *addr,
187 ip6_fib_table_instance_t *table;
188 clib_bihash_kv_24_8_t kv, value;
192 table = &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING];
193 n_p = vec_len (table->prefix_lengths_in_search_order);
195 kv.key[0] = addr->as_u64[0];
196 kv.key[1] = addr->as_u64[1];
197 fib = ((u64)((fib_index))<<32);
200 * start search from a mask length same length or shorter.
201 * we don't want matches longer than the mask passed
204 while (i < n_p && table->prefix_lengths_in_search_order[i] > len)
211 int dst_address_length = table->prefix_lengths_in_search_order[i];
212 ip6_address_t * mask = &ip6_main.fib_masks[dst_address_length];
214 ASSERT(dst_address_length >= 0 && dst_address_length <= 128);
215 //As lengths are decreasing, masks are increasingly specific.
216 kv.key[0] &= mask->as_u64[0];
217 kv.key[1] &= mask->as_u64[1];
218 kv.key[2] = fib | dst_address_length;
220 rv = clib_bihash_search_inline_2_24_8(&table->ip6_hash, &kv, &value);
225 return (FIB_NODE_INDEX_INVALID);
229 ip6_fib_table_lookup_exact_match (u32 fib_index,
230 const ip6_address_t *addr,
233 ip6_fib_table_instance_t *table;
234 clib_bihash_kv_24_8_t kv, value;
239 table = &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING];
240 mask = &ip6_main.fib_masks[len];
241 fib = ((u64)((fib_index))<<32);
243 kv.key[0] = addr->as_u64[0] & mask->as_u64[0];
244 kv.key[1] = addr->as_u64[1] & mask->as_u64[1];
245 kv.key[2] = fib | len;
247 rv = clib_bihash_search_inline_2_24_8(&table->ip6_hash, &kv, &value);
251 return (FIB_NODE_INDEX_INVALID);
255 compute_prefix_lengths_in_search_order (ip6_fib_table_instance_t *table)
257 u8 *old, *prefix_lengths_in_search_order = NULL;
261 * build the list in a scratch space then cutover so the workers
262 * can continue uninterrupted.
264 old = table->prefix_lengths_in_search_order;
266 /* Note: bitmap reversed so this is in fact a longest prefix match */
267 clib_bitmap_foreach (i, table->non_empty_dst_address_length_bitmap)
269 int dst_address_length = 128 - i;
270 vec_add1(prefix_lengths_in_search_order, dst_address_length);
273 table->prefix_lengths_in_search_order = prefix_lengths_in_search_order;
276 * let the workers go once round the track before we free the old set
278 vlib_worker_wait_one_loop();
283 ip6_fib_table_entry_remove (u32 fib_index,
284 const ip6_address_t *addr,
287 ip6_fib_table_instance_t *table;
288 clib_bihash_kv_24_8_t kv;
292 table = &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING];
293 mask = &ip6_main.fib_masks[len];
294 fib = ((u64)((fib_index))<<32);
296 kv.key[0] = addr->as_u64[0] & mask->as_u64[0];
297 kv.key[1] = addr->as_u64[1] & mask->as_u64[1];
298 kv.key[2] = fib | len;
300 clib_bihash_add_del_24_8(&table->ip6_hash, &kv, 0);
302 /* refcount accounting */
303 ASSERT (table->dst_address_length_refcounts[len] > 0);
304 if (--table->dst_address_length_refcounts[len] == 0)
306 table->non_empty_dst_address_length_bitmap =
307 clib_bitmap_set (table->non_empty_dst_address_length_bitmap,
309 compute_prefix_lengths_in_search_order (table);
314 ip6_fib_table_entry_insert (u32 fib_index,
315 const ip6_address_t *addr,
317 fib_node_index_t fib_entry_index)
319 ip6_fib_table_instance_t *table;
320 clib_bihash_kv_24_8_t kv;
324 table = &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING];
325 mask = &ip6_main.fib_masks[len];
326 fib = ((u64)((fib_index))<<32);
328 kv.key[0] = addr->as_u64[0] & mask->as_u64[0];
329 kv.key[1] = addr->as_u64[1] & mask->as_u64[1];
330 kv.key[2] = fib | len;
331 kv.value = fib_entry_index;
333 clib_bihash_add_del_24_8(&table->ip6_hash, &kv, 1);
335 if (0 == table->dst_address_length_refcounts[len]++)
337 table->non_empty_dst_address_length_bitmap =
338 clib_bitmap_set (table->non_empty_dst_address_length_bitmap,
340 compute_prefix_lengths_in_search_order (table);
344 u32 ip6_fib_table_fwding_lookup_with_if_index (ip6_main_t * im,
346 const ip6_address_t * dst)
348 u32 fib_index = vec_elt (im->fib_index_by_sw_if_index, sw_if_index);
349 return ip6_fib_table_fwding_lookup(fib_index, dst);
353 ip6_fib_table_get_index_for_sw_if_index (u32 sw_if_index)
355 if (sw_if_index >= vec_len(ip6_main.fib_index_by_sw_if_index))
358 * This is the case for interfaces that are not yet mapped to
363 return (ip6_main.fib_index_by_sw_if_index[sw_if_index]);
367 ip6_fib_table_fwding_dpo_update (u32 fib_index,
368 const ip6_address_t *addr,
372 ip6_fib_table_instance_t *table;
373 clib_bihash_kv_24_8_t kv;
377 table = &ip6_fib_table[IP6_FIB_TABLE_FWDING];
378 mask = &ip6_main.fib_masks[len];
379 fib = ((u64)((fib_index))<<32);
381 kv.key[0] = addr->as_u64[0] & mask->as_u64[0];
382 kv.key[1] = addr->as_u64[1] & mask->as_u64[1];
383 kv.key[2] = fib | len;
384 kv.value = dpo->dpoi_index;
386 clib_bihash_add_del_24_8(&table->ip6_hash, &kv, 1);
388 if (0 == table->dst_address_length_refcounts[len]++)
390 table->non_empty_dst_address_length_bitmap =
391 clib_bitmap_set (table->non_empty_dst_address_length_bitmap,
393 compute_prefix_lengths_in_search_order (table);
398 ip6_fib_table_fwding_dpo_remove (u32 fib_index,
399 const ip6_address_t *addr,
403 ip6_fib_table_instance_t *table;
404 clib_bihash_kv_24_8_t kv;
408 table = &ip6_fib_table[IP6_FIB_TABLE_FWDING];
409 mask = &ip6_main.fib_masks[len];
410 fib = ((u64)((fib_index))<<32);
412 kv.key[0] = addr->as_u64[0] & mask->as_u64[0];
413 kv.key[1] = addr->as_u64[1] & mask->as_u64[1];
414 kv.key[2] = fib | len;
415 kv.value = dpo->dpoi_index;
417 clib_bihash_add_del_24_8(&table->ip6_hash, &kv, 0);
419 /* refcount accounting */
420 ASSERT (table->dst_address_length_refcounts[len] > 0);
421 if (--table->dst_address_length_refcounts[len] == 0)
423 table->non_empty_dst_address_length_bitmap =
424 clib_bitmap_set (table->non_empty_dst_address_length_bitmap,
426 compute_prefix_lengths_in_search_order (table);
431 * @brief Context when walking the IPv6 table. Since all VRFs are in the
432 * same hash table, we need to filter only those we need as we walk
434 typedef struct ip6_fib_walk_ctx_t_
437 fib_table_walk_fn_t i6w_fn;
439 fib_prefix_t i6w_root;
440 fib_prefix_t *i6w_sub_trees;
441 } ip6_fib_walk_ctx_t;
444 ip6_fib_walk_cb (clib_bihash_kv_24_8_t * kvp,
447 ip6_fib_walk_ctx_t *ctx = arg;
450 if ((kvp->key[2] >> 32) == ctx->i6w_fib_index)
452 key.as_u64[0] = kvp->key[0];
453 key.as_u64[1] = kvp->key[1];
455 if (ip6_destination_matches_route(&ip6_main,
457 &ctx->i6w_root.fp_addr.ip6,
458 ctx->i6w_root.fp_len))
460 const fib_prefix_t *sub_tree;
464 * exclude sub-trees the walk does not want to explore
466 vec_foreach(sub_tree, ctx->i6w_sub_trees)
468 if (ip6_destination_matches_route(&ip6_main,
470 &sub_tree->fp_addr.ip6,
480 switch (ctx->i6w_fn(kvp->value, ctx->i6w_ctx))
482 case FIB_TABLE_WALK_CONTINUE:
484 case FIB_TABLE_WALK_SUB_TREE_STOP: {
486 .fp_proto = FIB_PROTOCOL_IP6,
487 .fp_len = kvp->key[2] & 0xffffffff,
490 vec_add1(ctx->i6w_sub_trees, pfx);
493 case FIB_TABLE_WALK_STOP:
505 ip6_fib_table_walk (u32 fib_index,
506 fib_table_walk_fn_t fn,
509 ip6_fib_walk_ctx_t ctx = {
510 .i6w_fib_index = fib_index,
514 .fp_proto = FIB_PROTOCOL_IP6,
516 .i6w_sub_trees = NULL,
519 clib_bihash_foreach_key_value_pair_24_8(
520 &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash,
524 vec_free(ctx.i6w_sub_trees);
528 ip6_fib_table_sub_tree_walk (u32 fib_index,
529 const fib_prefix_t *root,
530 fib_table_walk_fn_t fn,
533 ip6_fib_walk_ctx_t ctx = {
534 .i6w_fib_index = fib_index,
540 clib_bihash_foreach_key_value_pair_24_8(
541 &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash,
546 typedef struct ip6_fib_show_ctx_t_ {
547 fib_node_index_t *entries;
548 } ip6_fib_show_ctx_t;
550 static fib_table_walk_rc_t
551 ip6_fib_table_show_walk (fib_node_index_t fib_entry_index,
554 ip6_fib_show_ctx_t *ctx = arg;
556 vec_add1(ctx->entries, fib_entry_index);
558 return (FIB_TABLE_WALK_CONTINUE);
562 ip6_fib_table_show_all (ip6_fib_t *fib,
565 fib_node_index_t *fib_entry_index;
566 ip6_fib_show_ctx_t ctx = {
570 ip6_fib_table_walk(fib->index, ip6_fib_table_show_walk, &ctx);
571 vec_sort_with_function(ctx.entries, fib_entry_cmp_for_sort);
573 vec_foreach(fib_entry_index, ctx.entries)
575 vlib_cli_output(vm, "%U",
578 FIB_ENTRY_FORMAT_BRIEF);
581 vec_free(ctx.entries);
585 ip6_fib_table_show_one (ip6_fib_t *fib,
587 ip6_address_t *address,
591 vlib_cli_output(vm, "%U",
593 ip6_fib_table_lookup(fib->index, address, mask_len),
595 FIB_ENTRY_FORMAT_DETAIL2:
596 FIB_ENTRY_FORMAT_DETAIL));
600 format_ip6_fib_table_memory (u8 * s, va_list * args)
604 bytes_inuse = (alloc_arena_next(&(ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash)) +
605 alloc_arena_next(&(ip6_fib_table[IP6_FIB_TABLE_FWDING].ip6_hash)));
607 s = format(s, "%=30s %=6d %=12ld\n",
609 pool_elts(ip6_main.fibs),
616 u64 count_by_prefix_length[129];
617 } count_routes_in_fib_at_prefix_length_arg_t;
620 count_routes_in_fib_at_prefix_length (clib_bihash_kv_24_8_t * kvp,
623 count_routes_in_fib_at_prefix_length_arg_t * ap = arg;
626 if ((kvp->key[2]>>32) != ap->fib_index)
627 return (BIHASH_WALK_CONTINUE);
629 mask_width = kvp->key[2] & 0xFF;
631 ap->count_by_prefix_length[mask_width]++;
633 return (BIHASH_WALK_CONTINUE);
636 static clib_error_t *
637 ip6_show_fib (vlib_main_t * vm,
638 unformat_input_t * input,
639 vlib_cli_command_t * cmd)
641 count_routes_in_fib_at_prefix_length_arg_t _ca, *ca = &_ca;
642 ip6_main_t * im6 = &ip6_main;
643 fib_table_t *fib_table;
645 int verbose, matching;
646 ip6_address_t matching_address;
648 int table_id = -1, fib_index = ~0;
655 while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
657 if (unformat (input, "brief") ||
658 unformat (input, "summary") ||
659 unformat (input, "sum"))
662 else if (unformat (input, "detail") ||
663 unformat (input, "det"))
666 else if (unformat (input, "hash") ||
667 unformat (input, "mem") ||
668 unformat (input, "memory"))
671 else if (unformat (input, "%U/%d",
672 unformat_ip6_address, &matching_address, &mask_len))
675 else if (unformat (input, "%U", unformat_ip6_address, &matching_address))
678 else if (unformat (input, "table %d", &table_id))
680 else if (unformat (input, "index %d", &fib_index))
688 vlib_cli_output (vm, "IPv6 Non-Forwarding Hash Table:\n%U\n",
690 &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash,
692 vlib_cli_output (vm, "IPv6 Forwarding Hash Table:\n%U\n",
694 &ip6_fib_table[IP6_FIB_TABLE_FWDING].ip6_hash,
699 pool_foreach (fib_table, im6->fibs)
704 fib = pool_elt_at_index(im6->v6_fibs, fib_table->ft_index);
705 if (table_id >= 0 && table_id != (int)fib->table_id)
707 if (fib_index != ~0 && fib_index != (int)fib->index)
709 if (fib_table->ft_flags & FIB_TABLE_FLAG_IP6_LL)
712 s = format(s, "%U, fib_index:%d, flow hash:[%U] epoch:%d flags:%U locks:[",
713 format_fib_table_name, fib->index,
716 format_ip_flow_hash_config,
717 fib_table->ft_flow_hash_config,
719 format_fib_table_flags, fib_table->ft_flags);
721 vec_foreach_index(source, fib_table->ft_locks)
723 if (0 != fib_table->ft_locks[source])
725 s = format(s, "%U:%d, ",
726 format_fib_source, source,
727 fib_table->ft_locks[source]);
731 vlib_cli_output (vm, "%v", s);
737 clib_bihash_24_8_t * h = &ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash;
740 vlib_cli_output (vm, "%=20s%=16s", "Prefix length", "Count");
742 clib_memset (ca, 0, sizeof(*ca));
743 ca->fib_index = fib->index;
745 clib_bihash_foreach_key_value_pair_24_8
746 (h, count_routes_in_fib_at_prefix_length, ca);
748 for (len = 128; len >= 0; len--)
750 if (ca->count_by_prefix_length[len])
751 vlib_cli_output (vm, "%=20d%=16lld",
752 len, ca->count_by_prefix_length[len]);
759 ip6_fib_table_show_all(fib, vm);
763 ip6_fib_table_show_one(fib, vm, &matching_address, mask_len, detail);
771 * This command displays the IPv6 FIB Tables (VRF Tables) and the route
772 * entries for each table.
774 * @note This command will run for a long time when the FIB tables are
775 * comprised of millions of entries. For those senarios, consider displaying
780 * Example of how to display all the IPv6 FIB tables:
781 * @cliexstart{show ip6 fib}
782 * ipv6-VRF:0, fib_index 0, flow hash: src dst sport dport proto
785 * [@0]: dpo-load-balance: [index:5 buckets:1 uRPF:5 to:[0:0]]
786 * [0] [@0]: dpo-drop ip6
789 * [@0]: dpo-load-balance: [index:10 buckets:1 uRPF:10 to:[0:0]]
790 * [0] [@2]: dpo-receive
793 * [@0]: dpo-load-balance: [index:8 buckets:1 uRPF:8 to:[0:0]]
794 * [0] [@2]: dpo-receive
797 * [@0]: dpo-load-balance: [index:7 buckets:1 uRPF:7 to:[0:0]]
798 * [0] [@2]: dpo-receive
801 * [@0]: dpo-load-balance: [index:9 buckets:1 uRPF:9 to:[0:0]]
802 * [0] [@2]: dpo-receive
805 * [@0]: dpo-load-balance: [index:6 buckets:1 uRPF:6 to:[0:0]]
806 * [0] [@2]: dpo-receive
807 * ipv6-VRF:8, fib_index 1, flow hash: src dst sport dport proto
810 * [@0]: dpo-load-balance: [index:21 buckets:1 uRPF:20 to:[0:0]]
811 * [0] [@0]: dpo-drop ip6
814 * [@0]: dpo-load-balance: [index:27 buckets:1 uRPF:26 to:[0:0]]
815 * [0] [@4]: ipv6-glean: af_packet0
818 * [@0]: dpo-load-balance: [index:28 buckets:1 uRPF:27 to:[0:0]]
819 * [0] [@2]: dpo-receive: @::a:1:1:0:7 on af_packet0
822 * [@0]: dpo-load-balance: [index:26 buckets:1 uRPF:25 to:[0:0]]
823 * [0] [@2]: dpo-receive
824 * fe80::fe:3eff:fe3e:9222/128
826 * [@0]: dpo-load-balance: [index:29 buckets:1 uRPF:28 to:[0:0]]
827 * [0] [@2]: dpo-receive: fe80::fe:3eff:fe3e:9222 on af_packet0
830 * [@0]: dpo-load-balance: [index:24 buckets:1 uRPF:23 to:[0:0]]
831 * [0] [@2]: dpo-receive
834 * [@0]: dpo-load-balance: [index:23 buckets:1 uRPF:22 to:[0:0]]
835 * [0] [@2]: dpo-receive
838 * [@0]: dpo-load-balance: [index:25 buckets:1 uRPF:24 to:[0:0]]
839 * [0] [@2]: dpo-receive
842 * [@0]: dpo-load-balance: [index:22 buckets:1 uRPF:21 to:[0:0]]
843 * [0] [@2]: dpo-receive
846 * Example of how to display a summary of all IPv6 FIB tables:
847 * @cliexstart{show ip6 fib summary}
848 * ipv6-VRF:0, fib_index 0, flow hash: src dst sport dport proto
849 * Prefix length Count
854 * ipv6-VRF:8, fib_index 1, flow hash: src dst sport dport proto
855 * Prefix length Count
865 VLIB_CLI_COMMAND (ip6_show_fib_command, static) = {
866 .path = "show ip6 fib",
867 .short_help = "show ip6 fib [summary] [table <table-id>] [index <fib-id>] [<ip6-addr>[/<width>]] [detail]",
868 .function = ip6_show_fib,
872 static clib_error_t *
873 ip6_config (vlib_main_t * vm, unformat_input_t * input)
878 while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
880 if (unformat (input, "hash-buckets %d", &nbuckets))
882 else if (unformat (input, "heap-size %U",
883 unformat_memory_size, &heapsize))
886 return clib_error_return (0, "unknown input '%U'",
887 format_unformat_error, input);
890 ip6_fib_table_nbuckets = nbuckets;
891 ip6_fib_table_size = heapsize;
896 VLIB_EARLY_CONFIG_FUNCTION (ip6_config, "ip6");
898 static clib_error_t *
899 ip6_fib_init (vlib_main_t * vm)
901 if (ip6_fib_table_nbuckets == 0)
902 ip6_fib_table_nbuckets = IP6_FIB_DEFAULT_HASH_NUM_BUCKETS;
904 ip6_fib_table_nbuckets = 1 << max_log2 (ip6_fib_table_nbuckets);
906 if (ip6_fib_table_size == 0)
907 ip6_fib_table_size = IP6_FIB_DEFAULT_HASH_MEMORY_SIZE;
909 clib_bihash_init_24_8 (&(ip6_fib_table[IP6_FIB_TABLE_FWDING].ip6_hash),
910 "ip6 FIB fwding table",
911 ip6_fib_table_nbuckets, ip6_fib_table_size);
912 clib_bihash_init_24_8 (&ip6_fib_table[IP6_FIB_TABLE_NON_FWDING].ip6_hash,
913 "ip6 FIB non-fwding table",
914 ip6_fib_table_nbuckets, ip6_fib_table_size);
919 VLIB_INIT_FUNCTION (ip6_fib_init) =
921 .runs_before = VLIB_INITS("ip6_lookup_init"),