FD.io VPP  v17.10-9-gd594711
Vector Packet Processing
fib_internal.h
Go to the documentation of this file.
1 /*
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:
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
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.
14  */
15 
16 #ifndef __FIB_INTERNAL_H__
17 #define __FIB_INTERNAL_H__
18 
19 #include <vnet/ip/ip.h>
20 #include <vnet/dpo/dpo.h>
21 
22 /**
23  * Big train switch; FIB debugs on or off
24  */
25 #undef FIB_DEBUG
26 
28  mpls_eos_bit_t eos,
29  fib_prefix_t *prf);
30 
31 extern int fib_route_path_cmp(const fib_route_path_t *rpath1,
32  const fib_route_path_t *rpath2);
33 
34 /**
35  * @brief
36  * Add or update an entry in the FIB's forwarding table.
37  * This is called from the fib_entry code. It is not meant to be used
38  * by the client/source.
39  *
40  * @param fib_index
41  * The index of the FIB
42  *
43  * @param prefix
44  * The prefix for the entry to add/update
45  *
46  * @param dpo
47  * The data-path object to use for forwarding
48  */
49 extern void fib_table_fwding_dpo_update(u32 fib_index,
50  const fib_prefix_t *prefix,
51  const dpo_id_t *dpo);
52 /**
53  * @brief
54  * remove an entry in the FIB's forwarding table
55  *
56  * @param fib_index
57  * The index of the FIB
58  *
59  * @param prefix
60  * The prefix for the entry to add/update
61  *
62  * @param dpo
63  * The data-path object to use for forwarding
64  */
65 extern void fib_table_fwding_dpo_remove(u32 fib_index,
66  const fib_prefix_t *prefix,
67  const dpo_id_t *dpo);
68 
69 
70 #endif
void fib_table_fwding_dpo_remove(u32 fib_index, const fib_prefix_t *prefix, const dpo_id_t *dpo)
remove an entry in the FIB&#39;s forwarding table
Definition: fib_table.c:261
A representation of a path as described by a route producer.
Definition: fib_types.h:336
int fib_route_path_cmp(const fib_route_path_t *rpath1, const fib_route_path_t *rpath2)
Definition: fib_types.c:188
u32 mpls_label_t
A label value only, i.e.
Definition: packet.h:24
Aggregrate type for a prefix.
Definition: fib_types.h:160
The identity of a DPO is a combination of its type and its instance number/index of objects of that t...
Definition: dpo.h:150
void fib_table_fwding_dpo_update(u32 fib_index, const fib_prefix_t *prefix, const dpo_id_t *dpo)
Add or update an entry in the FIB&#39;s forwarding table.
Definition: fib_table.c:234
void fib_prefix_from_mpls_label(mpls_label_t label, mpls_eos_bit_t eos, fib_prefix_t *prf)
Big train switch; FIB debugs on or off.
Definition: fib_types.c:68
unsigned int u32
Definition: types.h:88
enum mpls_eos_bit_t_ mpls_eos_bit_t