![]() |
FD.io VPP
v16.12-rc0-308-g931be3a
Vector Packet Processing
|
Go to the source code of this file.
Data Structures | |
struct | fib_prefix_t_ |
Aggregrate type for a prefix. More... | |
struct | fib_route_path_t_ |
A representation of a path as described by a route producer. More... | |
Macros | |
#define | FIB_NODE_INDEX_INVALID ((fib_node_index_t)(~0)) |
#define | FIB_PROTOCOLS |
#define | FIB_PROTOCOL_MAX (FIB_PROTOCOL_MPLS + 1) |
Definition outside of enum so it does not need to be included in non-defaulted switch statements. More... | |
#define | FIB_PROTOCOL_NONE (FIB_PROTOCOL_MAX+1) |
Not part of the enum so it does not have to be handled in switch statements. More... | |
#define | FOR_EACH_FIB_PROTOCOL(_item) |
#define | FOR_EACH_FIB_IP_PROTOCOL(_item) |
#define | FIB_FORW_CHAINS |
#define | FIB_FORW_CHAIN_NUM (FIB_FORW_CHAIN_TYPE_MPLS_ETHERNET+1) |
#define | FIB_FORW_CHAIN_MPLS_NUM (FIB_FORW_CHAIN_TYPE_MPLS_EOS+1) |
#define | FOR_EACH_FIB_FORW_CHAIN(_item) |
#define | FOR_EACH_FIB_FORW_MPLS_CHAIN(_item) |
#define | FIB_SPEICAL_TYPE_MAX (FIB_SPEICAL_TYPE_LAST + 1) |
The maximum number of types. More... | |
#define | FOR_EACH_FIB_SPEICAL_TYPE(_item) |
Typedefs | |
typedef u32 | fib_node_index_t |
A typedef of a node index. More... | |
typedef enum fib_protocol_t_ | fib_protocol_t |
Protocol Type. More... | |
typedef enum fib_forward_chain_type_t_ | fib_forward_chain_type_t |
FIB output chain type. More... | |
typedef struct fib_prefix_t_ | fib_prefix_t |
Aggregrate type for a prefix. More... | |
typedef enum fib_special_type_t_ | fib_special_type_t |
Enurmeration of special path/entry types. More... | |
typedef enum fib_route_path_flags_t_ | fib_route_path_flags_t |
Path flags from the control plane. More... | |
typedef struct fib_route_path_t_ | fib_route_path_t |
A representation of a path as described by a route producer. More... | |
Enumerations | |
enum | fib_protocol_t_ { FIB_PROTOCOL_IP4 = 1, FIB_PROTOCOL_IP6, FIB_PROTOCOL_MPLS } |
Protocol Type. More... | |
enum | fib_forward_chain_type_t_ { FIB_FORW_CHAIN_TYPE_UNICAST_IP4, FIB_FORW_CHAIN_TYPE_UNICAST_IP6, FIB_FORW_CHAIN_TYPE_MPLS_NON_EOS, FIB_FORW_CHAIN_TYPE_MPLS_EOS, FIB_FORW_CHAIN_TYPE_ETHERNET } |
FIB output chain type. More... | |
enum | fib_special_type_t_ { FIB_SPECIAL_TYPE_FIRST = 0, FIB_SPECIAL_TYPE_LOCAL = FIB_SPECIAL_TYPE_FIRST, FIB_SPECIAL_TYPE_DROP, FIB_SPECIAL_TYPE_LAST = FIB_SPECIAL_TYPE_DROP } |
Enurmeration of special path/entry types. More... | |
enum | fib_route_path_flags_t_ { FIB_ROUTE_PATH_FLAG_NONE = 0, FIB_ROUTE_PATH_RESOLVE_VIA_HOST = (1 << 0), FIB_ROUTE_PATH_RESOLVE_VIA_ATTACHED = (1 << 1) } |
Path flags from the control plane. More... | |
#define FIB_FORW_CHAIN_MPLS_NUM (FIB_FORW_CHAIN_TYPE_MPLS_EOS+1) |
Definition at line 119 of file fib_types.h.
#define FIB_FORW_CHAIN_NUM (FIB_FORW_CHAIN_TYPE_MPLS_ETHERNET+1) |
Definition at line 118 of file fib_types.h.
#define FIB_FORW_CHAINS |
Definition at line 110 of file fib_types.h.
#define FIB_NODE_INDEX_INVALID ((fib_node_index_t)(~0)) |
Definition at line 29 of file fib_types.h.
#define FIB_PROTOCOL_MAX (FIB_PROTOCOL_MPLS + 1) |
Definition outside of enum so it does not need to be included in non-defaulted switch statements.
Definition at line 54 of file fib_types.h.
#define FIB_PROTOCOL_NONE (FIB_PROTOCOL_MAX+1) |
Not part of the enum so it does not have to be handled in switch statements.
Definition at line 59 of file fib_types.h.
#define FIB_PROTOCOLS |
Definition at line 44 of file fib_types.h.
#define FIB_SPEICAL_TYPE_MAX (FIB_SPEICAL_TYPE_LAST + 1) |
The maximum number of types.
Definition at line 241 of file fib_types.h.
#define FOR_EACH_FIB_FORW_CHAIN | ( | _item | ) |
Definition at line 121 of file fib_types.h.
#define FOR_EACH_FIB_FORW_MPLS_CHAIN | ( | _item | ) |
Definition at line 126 of file fib_types.h.
#define FOR_EACH_FIB_IP_PROTOCOL | ( | _item | ) |
Definition at line 66 of file fib_types.h.
#define FOR_EACH_FIB_PROTOCOL | ( | _item | ) |
Definition at line 61 of file fib_types.h.
#define FOR_EACH_FIB_SPEICAL_TYPE | ( | _item | ) |
Definition at line 243 of file fib_types.h.
typedef enum fib_forward_chain_type_t_ fib_forward_chain_type_t |
FIB output chain type.
When a child object requests a forwarding contribution from a parent, it does so for a particular scenario. This enumererates those sceanrios
typedef u32 fib_node_index_t |
A typedef of a node index.
we make this typedef so the code becomes easier for a human to parse.
Definition at line 28 of file fib_types.h.
typedef struct fib_prefix_t_ fib_prefix_t |
Aggregrate type for a prefix.
typedef enum fib_protocol_t_ fib_protocol_t |
Protocol Type.
packed so it consumes a u8 only
typedef enum fib_route_path_flags_t_ fib_route_path_flags_t |
Path flags from the control plane.
typedef struct fib_route_path_t_ fib_route_path_t |
A representation of a path as described by a route producer.
These paramenters will determine the path 'type', of which there are: 1) Attached-next-hop: a single peer on a link. It is 'attached' because it is in the same sub-net as the router, on a link directly connected to the route. It is 'next=hop' since the next-hop address of the peer is known. 2) Attached: the next-hop is not known. but we can ARP for it. 3) Recursive. The next-hop is known but the interface is not. So to find the adj to use we must recursively resolve the next-hop. 3) deaggregate (deag) A further lookup is required.
typedef enum fib_special_type_t_ fib_special_type_t |
Enurmeration of special path/entry types.
FIB output chain type.
When a child object requests a forwarding contribution from a parent, it does so for a particular scenario. This enumererates those sceanrios
Definition at line 81 of file fib_types.h.
enum fib_protocol_t_ |
Protocol Type.
packed so it consumes a u8 only
Enumerator | |
---|---|
FIB_PROTOCOL_IP4 | |
FIB_PROTOCOL_IP6 | |
FIB_PROTOCOL_MPLS |
Definition at line 34 of file fib_types.h.
Path flags from the control plane.
Enumerator | |
---|---|
FIB_ROUTE_PATH_FLAG_NONE | |
FIB_ROUTE_PATH_RESOLVE_VIA_HOST |
Recursion constraint of via a host prefix. |
FIB_ROUTE_PATH_RESOLVE_VIA_ATTACHED |
Recursion constraint of via an attahced prefix. |
Definition at line 253 of file fib_types.h.
enum fib_special_type_t_ |
Enurmeration of special path/entry types.
Definition at line 219 of file fib_types.h.
fib_protocol_t dpo_proto_to_fib | ( | dpo_proto_t | dpo_proto | ) |
fib_forward_chain_type_t fib_forw_chain_type_from_dpo_proto | ( | dpo_proto_t | proto | ) |
Convert from a payload-protocol to a chain type.
Definition at line 272 of file fib_types.c.
dpo_proto_t fib_forw_chain_type_to_dpo_proto | ( | fib_forward_chain_type_t | fct | ) |
Convert from a chain type to the DPO proto it will install.
Definition at line 313 of file fib_types.c.
vnet_link_t fib_forw_chain_type_to_link_type | ( | fib_forward_chain_type_t | fct | ) |
Convert from a chain type to the adjacencies link type.
Definition at line 290 of file fib_types.c.
int fib_prefix_cmp | ( | const fib_prefix_t * | p1, |
const fib_prefix_t * | p2 | ||
) |
Compare two prefixes for equality.
Definition at line 68 of file fib_types.c.
int fib_prefix_is_cover | ( | const fib_prefix_t * | p1, |
const fib_prefix_t * | p2 | ||
) |
Compare two prefixes for covering relationship.
Definition at line 103 of file fib_types.c.
int fib_prefix_is_host | ( | const fib_prefix_t * | p | ) |
Return true is the prefix is a host prefix.
Definition at line 125 of file fib_types.c.
dpo_proto_t fib_proto_to_dpo | ( | fib_protocol_t | fib_proto | ) |
vnet_link_t fib_proto_to_link | ( | fib_protocol_t | proto | ) |
Convert from a protocol to a link type.
Definition at line 256 of file fib_types.c.
Definition at line 46 of file fib_types.c.
Definition at line 140 of file fib_types.c.
Definition at line 30 of file fib_types.c.
Definition at line 38 of file fib_types.c.
dpo_proto_t vnet_link_to_dpo_proto | ( | vnet_link_t | linkt | ) |