FD.io VPP  v21.06-3-gbb25fbf28
Vector Packet Processing
abf.api
Go to the documentation of this file.
1 /* Hey Emacs use -*- mode: C -*- */
2 /*
3  * Copyright (c) 2016 Cisco and/or its affiliates.
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at:
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 /** \file
18  This file defines the vpp control-plane API messages
19  used to control the ABF plugin
20 */
21 
22 option version = "1.0.0";
23 import "vnet/ip/ip_types.api";
24 import "vnet/fib/fib_types.api";
25 import "vnet/interface_types.api";
26 
27 /** \brief Get the plugin version
28  @param client_index - opaque cookie to identify the sender
29  @param context - sender context, to match reply w/ request
30 */
31 define abf_plugin_get_version
32 {
33  option status="in_progress";
36 };
37 
38 /** \brief Reply to get the plugin version
39  @param context - returned sender context, to match reply w/ request
40  @param major - Incremented every time a known breaking behavior change is introduced
41  @param minor - Incremented with small changes, may be used to avoid buggy versions
42 */
43 define abf_plugin_get_version_reply
44 {
45  option status="in_progress";
49 };
50 
51 /** \brief A description of an ABF policy
52  @param policy_id User chosen Identifier for the policy
53  @param acl_index The ACL that the policy will match against
54  @param n_paths Number of paths
55  @param paths The set of forwarding paths that are being added or removed.
56  */
57 typedef abf_policy
58 {
59  u32 policy_id;
62  vl_api_fib_path_t paths[n_paths];
63 };
64 
65 /** \brief A description of an ABF policy
66  @param is_add Is this the addition or removal of paths from the policy
67  If the policy does not exist it is created. If the last path
68  Is being removed, the policy is deleted
69  @param policy The policy
70  */
71 autoreply define abf_policy_add_del
72 {
73  option status="in_progress";
76  bool is_add;
77  vl_api_abf_policy_t policy;
78 };
79 
80 /** \brief Policy description returned in the dump
81  */
82 define abf_policy_details
83 {
84  option status="in_progress";
86  vl_api_abf_policy_t policy;
87 };
88 
89 /** \brief Dump all ABF policies
90  */
91 define abf_policy_dump
92 {
93  option status="in_progress";
96 };
97 
98 /** \brief A description of a policy attachment to an interface
99  @param The policy ID to attach
100  @param sw_if_index The interface to attach to
101  @param priority The priority of the attachment, w.r.t. to other attachments
102  on this interface. lower value is 'better'
103  @param is_ipv6 Does this attachment apply to IPv6 packets (or IPv4)
104 */
105 typedef abf_itf_attach
106 {
107  u32 policy_id;
108  vl_api_interface_index_t sw_if_index;
110  bool is_ipv6;
111 };
112 
113 /** \brief Add or delete a policy attachment to an interface
114  */
115 autoreply define abf_itf_attach_add_del
116 {
117  option status="in_progress";
120  bool is_add;
121  vl_api_abf_itf_attach_t attach;
122 };
123 
124 /** \brief Attachment details from a dump
125  */
126 define abf_itf_attach_details
127 {
128  option status="in_progress";
130  vl_api_abf_itf_attach_t attach;
131 };
132 
133 /** \brief Dump all the policy attachments
134  */
135 define abf_itf_attach_dump
136 {
137  option status="in_progress";
140 };
141 
vl_api_abf_itf_attach_add_del_t
Add or delete a policy attachment to an interface.
Definition: abf.api:115
vl_api_abf_itf_attach_dump_t::client_index
u32 client_index
Definition: abf.api:138
abf_policy
typedef abf_policy
A description of an ABF policy.
Definition: abf.api:58
vl_api_abf_itf_attach_details_t
Attachment details from a dump.
Definition: abf.api:126
vl_api_abf_plugin_get_version_t::status
option status
Definition: abf.api:33
vl_api_abf_policy_add_del_t::client_index
u32 client_index
Definition: abf.api:74
vl_api_abf_policy_dump_t
Dump all ABF policies.
Definition: abf.api:91
paths
vl_api_fib_path_t paths[n_paths]
Definition: abf.api:62
version
option version
Definition: abf.api:22
is_ipv6
bool is_ipv6
Definition: abf.api:110
vl_api_abf_itf_attach_dump_t::status
option status
Definition: abf.api:137
vl_api_abf_itf_attach_add_del_t::attach
vl_api_abf_itf_attach_t attach
Definition: abf.api:121
sw_if_index
vl_api_interface_index_t sw_if_index
Definition: abf.api:108
vl_api_abf_policy_add_del_t::context
u32 context
Definition: abf.api:75
vl_api_abf_policy_details_t
Policy description returned in the dump.
Definition: abf.api:82
vl_api_abf_plugin_get_version_t::client_index
u32 client_index
Definition: abf.api:34
vl_api_abf_itf_attach_add_del_t::status
option status
Definition: abf.api:117
vl_api_abf_policy_add_del_t
A description of an ABF policy.
Definition: abf.api:71
vl_api_abf_plugin_get_version_reply_t::minor
u32 minor
Definition: abf.api:48
vl_api_abf_plugin_get_version_reply_t::major
u32 major
Definition: abf.api:47
n_paths
u8 n_paths
Definition: abf.api:61
vl_api_abf_plugin_get_version_t::context
u32 context
Definition: abf.api:35
vl_api_abf_plugin_get_version_reply_t::status
option status
Definition: abf.api:45
vl_api_abf_itf_attach_add_del_t::context
u32 context
Definition: abf.api:119
vl_api_abf_itf_attach_add_del_t::is_add
bool is_add
Definition: abf.api:120
acl_index
u32 acl_index
Definition: abf.api:60
priority
u32 priority
Definition: abf.api:109
vl_api_abf_itf_attach_details_t::context
u32 context
Definition: abf.api:129
vl_api_abf_policy_details_t::policy
vl_api_abf_policy_t policy
Definition: abf.api:86
vl_api_abf_itf_attach_details_t::status
option status
Definition: abf.api:128
abf_itf_attach
typedef abf_itf_attach
A description of a policy attachment to an interface.
Definition: abf.api:106
vl_api_abf_plugin_get_version_reply_t
Reply to get the plugin version.
Definition: abf.api:43
vl_api_abf_policy_add_del_t::status
option status
Definition: abf.api:73
u32
unsigned int u32
Definition: types.h:88
vl_api_abf_plugin_get_version_reply_t::context
u32 context
Definition: abf.api:46
vl_api_abf_policy_dump_t::status
option status
Definition: abf.api:93
vl_api_abf_itf_attach_add_del_t::client_index
u32 client_index
Definition: abf.api:118
vl_api_abf_policy_details_t::context
u32 context
Definition: abf.api:85
vl_api_abf_itf_attach_details_t::attach
vl_api_abf_itf_attach_t attach
Definition: abf.api:130
vl_api_abf_policy_details_t::status
option status
Definition: abf.api:84
u8
unsigned char u8
Definition: types.h:56
vl_api_abf_policy_add_del_t::is_add
bool is_add
Definition: abf.api:76
vl_api_abf_plugin_get_version_t
Get the plugin version.
Definition: abf.api:31
vl_api_abf_policy_dump_t::context
u32 context
Definition: abf.api:95
vl_api_abf_policy_add_del_t::policy
vl_api_abf_policy_t policy
Definition: abf.api:77
vl_api_abf_itf_attach_dump_t::context
u32 context
Definition: abf.api:139
vl_api_abf_itf_attach_dump_t
Dump all the policy attachments.
Definition: abf.api:135
vl_api_abf_policy_dump_t::client_index
u32 client_index
Definition: abf.api:94