summaryrefslogtreecommitdiffstats
path: root/src/vnet/interface_format.c
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2018-03-16 01:25:27 +0100
committerDamjan Marion <dmarion.lists@gmail.com>2018-05-10 15:45:03 +0000
commita35cc14d37466f0737fa928d25697fbfe6e7d657 (patch)
tree7242bb0bc9feebc35a2b1ab56986bc2a7ddb0ceb /src/vnet/interface_format.c
parentcd330c878dfdb9f52b372007a5086138b12d89f7 (diff)
vnet: device flow offload infra
Change-Id: Ibea4a96bdec5e368301a03d8b11a0712fa0265e0 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/interface_format.c')
-rw-r--r--src/vnet/interface_format.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/vnet/interface_format.c b/src/vnet/interface_format.c
index e58369a1126..7e94092b52e 100644
--- a/src/vnet/interface_format.c
+++ b/src/vnet/interface_format.c
@@ -177,6 +177,21 @@ format_vnet_sw_if_index_name (u8 * s, va_list * args)
}
u8 *
+format_vnet_hw_if_index_name (u8 * s, va_list * args)
+{
+ vnet_main_t *vnm = va_arg (*args, vnet_main_t *);
+ u32 hw_if_index = va_arg (*args, u32);
+ vnet_hw_interface_t *hi;
+
+ hi = vnet_get_hw_interface (vnm, hw_if_index);
+
+ if (hi == 0)
+ return format (s, "DELETED");
+
+ return format (s, "%v", hi->name);
+}
+
+u8 *
format_vnet_sw_interface_cntrs (u8 * s, vnet_interface_main_t * im,
vnet_sw_interface_t * si)
{