summaryrefslogtreecommitdiffstats
path: root/src/vnet/interface.h
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2022-01-06 21:14:08 +0100
committerDamjan Marion <damarion@cisco.com>2022-01-17 12:41:24 +0100
commit88a9c0e02ab919cadd4e035133995a6afb4d1c32 (patch)
tree15741e8bbe6c9d7077fa2a62b6ac369a17836cfb /src/vnet/interface.h
parent81bb6fc611d321a92ad2218e1b852db67980768a (diff)
interface: improve MTU handling
- per hw-interface-class handlers - ethernet set_mtu callback - driver can now refuse MTU change Type: improvement Change-Id: I3d37c9129930ebec7bb70caf4263025413873048 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/interface.h')
-rw-r--r--src/vnet/interface.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/vnet/interface.h b/src/vnet/interface.h
index 801298a0f05..2eb50aed5e8 100644
--- a/src/vnet/interface.h
+++ b/src/vnet/interface.h
@@ -70,6 +70,10 @@ typedef clib_error_t *(vnet_subif_add_del_function_t)
(struct vnet_main_t * vnm, u32 if_index,
struct vnet_sw_interface_t * template, int is_add);
+/* Interface set mtu callback. */
+typedef clib_error_t *(vnet_interface_set_mtu_function_t) (
+ struct vnet_main_t *vnm, struct vnet_hw_interface_t *hi, u32 mtu);
+
/* Interface set mac address callback. */
typedef clib_error_t *(vnet_interface_set_mac_address_function_t)
(struct vnet_hw_interface_t * hi,
@@ -428,6 +432,8 @@ typedef struct _vnet_hw_interface_class
/* Function to add/delete additional MAC addresses */
vnet_interface_add_del_mac_address_function_t *mac_addr_add_del_function;
+ /* Function to set mtu. */
+ vnet_interface_set_mtu_function_t *set_mtu;
/* Format function to display interface name. */
format_function_t *format_interface_name;