summaryrefslogtreecommitdiffstats
path: root/src/vnet/policer/policer.api
diff options
context:
space:
mode:
authorBrian Russell <brian@graphiant.com>2021-02-17 15:51:45 +0000
committerNeale Ranns <neale@graphiant.com>2021-02-19 10:46:58 +0000
commitb046830173a95b9f2d72865b3389174b7b7ff5d9 (patch)
tree83521ea1fd26e0f4de8d35d3ac0bfe28dcd0e754 /src/vnet/policer/policer.api
parent15c18e3e40d3bf754e5b6969c7478ad9f1d5e95b (diff)
policer: add api to configure input policing
Add a new API to apply a policer to an input interface. Type: improvement Signed-off-by: Brian Russell <brian@graphiant.com> Change-Id: Ie8aff9120149b63d85363a9a5afdcaed60a93700
Diffstat (limited to 'src/vnet/policer/policer.api')
-rw-r--r--src/vnet/policer/policer.api18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/vnet/policer/policer.api b/src/vnet/policer/policer.api
index c3b8d7cd061..a664ab0be76 100644
--- a/src/vnet/policer/policer.api
+++ b/src/vnet/policer/policer.api
@@ -15,6 +15,7 @@
option version = "2.0.0";
+import "vnet/interface_types.api";
import "vnet/policer/policer_types.api";
/** \brief policer bind: Associate/disassociate a policer with a worker thread.
@@ -34,6 +35,23 @@ autoreply define policer_bind
bool bind_enable;
};
+/** \brief policer input: Apply policer as an input feature.
+ @param client_index - opaque cookie to identify the sender
+ @param context - sender context, to match reply w/ request
+ @param name - policer name
+ @param sw_if_index - interface to apply the policer
+ @param apply - Apply/remove
+*/
+autoreply define policer_input
+{
+ u32 client_index;
+ u32 context;
+
+ string name[64];
+ vl_api_interface_index_t sw_if_index;
+ bool apply;
+};
+
/** \brief Add/del policer
@param client_index - opaque cookie to identify the sender
@param context - sender context, to match reply w/ request