aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/dev/api.h
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2023-11-22 16:25:55 +0000
committerDamjan Marion <damarion@cisco.com>2023-11-25 12:39:25 +0000
commitddf6cec37027547ff7cc61e15bb8080664d41514 (patch)
tree6896d6e6a050a43344a22d0c4bc080db092c9caf /src/vnet/dev/api.h
parent07a62cc236978a0f01ec8be70bdd1d3e8fa27f71 (diff)
dev: initial set of APIs
Type: improvement Change-Id: I9ecbf705d460a1744f36c7005b08097dc58d9522 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/dev/api.h')
-rw-r--r--src/vnet/dev/api.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/vnet/dev/api.h b/src/vnet/dev/api.h
index 69a846296ed..1b7bf27d62a 100644
--- a/src/vnet/dev/api.h
+++ b/src/vnet/dev/api.h
@@ -15,6 +15,9 @@ typedef struct
vnet_dev_driver_name_t driver_name;
vnet_dev_flags_t flags;
u8 *args;
+
+ /* return */
+ u32 dev_index;
} vnet_dev_api_attach_args_t;
vnet_dev_rv_t vnet_dev_api_attach (vlib_main_t *,
@@ -22,7 +25,7 @@ vnet_dev_rv_t vnet_dev_api_attach (vlib_main_t *,
typedef struct
{
- vnet_dev_device_id_t device_id;
+ u32 dev_index;
} vnet_dev_api_detach_args_t;
vnet_dev_rv_t vnet_dev_api_detach (vlib_main_t *,
vnet_dev_api_detach_args_t *);
@@ -35,7 +38,7 @@ vnet_dev_rv_t vnet_dev_api_reset (vlib_main_t *, vnet_dev_api_reset_args_t *);
typedef struct
{
- vnet_dev_device_id_t device_id;
+ u32 dev_index;
vnet_dev_if_name_t intf_name;
u16 num_rx_queues;
u16 num_tx_queues;
@@ -44,6 +47,9 @@ typedef struct
vnet_dev_port_id_t port_id;
vnet_dev_port_flags_t flags;
u8 *args;
+
+ /* return */
+ u32 sw_if_index;
} vnet_dev_api_create_port_if_args_t;
vnet_dev_rv_t