aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/ethernet/mac_address.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vnet/ethernet/mac_address.c')
-rw-r--r--src/vnet/ethernet/mac_address.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/vnet/ethernet/mac_address.c b/src/vnet/ethernet/mac_address.c
index 6f40e50efa2..b7981299700 100644
--- a/src/vnet/ethernet/mac_address.c
+++ b/src/vnet/ethernet/mac_address.c
@@ -61,6 +61,16 @@ unformat_mac_address_t (unformat_input_t * input, va_list * args)
return (0);
}
+void
+mac_address_increment (mac_address_t * mac)
+{
+ u64 a;
+
+ a = mac_address_as_u64 (mac);
+ a++;
+ mac_address_from_u64 (mac, a);
+}
+
/*
* fd.io coding-style-patch-verification: ON
*