aboutsummaryrefslogtreecommitdiffstats
path: root/hicn-plugin/src/hicn.api
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2023-01-20 14:54:19 +0000
committerMauro Sardara <msardara@cisco.com>2023-01-20 18:13:11 +0000
commitda0d60997bce1e40cc0b1c7b7f4f58df56bbead3 (patch)
tree530be0daa63f8632218d73419fa9d05d00d3b5a3 /hicn-plugin/src/hicn.api
parent3e5e7e22f80bd64b51d3182339c77eccb5109c2e (diff)
feat: implement set strategy API for hicn-plugin
Ticket: HICN-829 Change-Id: I3dabc38e9cc2e06ebed14b9ed265d027f77b7e5f Signed-off-by: Mauro Sardara <msardara@cisco.com>
Diffstat (limited to 'hicn-plugin/src/hicn.api')
-rw-r--r--hicn-plugin/src/hicn.api39
1 files changed, 37 insertions, 2 deletions
diff --git a/hicn-plugin/src/hicn.api b/hicn-plugin/src/hicn.api
index 8c1c78eb0..2321e6622 100644
--- a/hicn-plugin/src/hicn.api
+++ b/hicn-plugin/src/hicn.api
@@ -22,6 +22,14 @@ enum hicn_action_type
HICN_ENABLE,
};
+enum hicn_strategy
+{
+ HICN_STRATEGY_MW = 0,
+ HICN_STRATEGY_RR,
+ HICN_STRATEGY_RP,
+ HICN_STRATEGY_LR,
+};
+
typedef hicn_face
{
/* IP local address */
@@ -360,6 +368,33 @@ define hicn_api_routes_dump
u32 context;
};
+define hicn_api_strategy_set
+{
+ /* Client identifier, set from api_main.my_client_index */
+ u32 client_index;
+
+ /* Arbitrary context, so client can match reply to request */
+ u32 context;
+
+ /* Fib prefix for the strategy */
+ vl_api_prefix_t prefix;
+
+ /* ID of the strategy to set for this prefix */
+ vl_api_hicn_strategy_t strategy_id;
+};
+
+define hicn_api_strategy_set_reply
+{
+ /* Client identifier, set from api_main.my_client_index */
+ u32 client_index;
+
+ /* Arbitrary context, so client can match reply to request */
+ u32 context;
+
+ /* Return value, zero means all OK */
+ i32 retval;
+};
+
define hicn_api_strategies_get
{
/* Client identifier, set from api_main.my_client_index */
@@ -381,7 +416,7 @@ define hicn_api_strategies_get_reply
u8 n_strategies;
/* Strategies */
- u32 strategy_id[256];
+ vl_api_hicn_strategy_t strategy_id[256];
/* Return value, zero means all OK */
i32 retval;
@@ -396,7 +431,7 @@ define hicn_api_strategy_get
u32 context;
/* Route prefix */
- u32 strategy_id;
+ vl_api_hicn_strategy_t strategy_id;
};
define hicn_api_strategy_get_reply