diff options
Diffstat (limited to 'src/vnet/tunnel/tunnel.c')
-rw-r--r-- | src/vnet/tunnel/tunnel.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/vnet/tunnel/tunnel.c b/src/vnet/tunnel/tunnel.c index 96d7fd12b52..38bde34e7f2 100644 --- a/src/vnet/tunnel/tunnel.c +++ b/src/vnet/tunnel/tunnel.c @@ -62,6 +62,20 @@ format_tunnel_encap_decap_flags (u8 * s, va_list * args) return (s); } +uword +unformat_tunnel_encap_decap_flags (unformat_input_t * input, va_list * args) +{ + tunnel_encap_decap_flags_t *f = + va_arg (*args, tunnel_encap_decap_flags_t *); +#define _(a,b,c) if (unformat(input, b)) {\ + *f |= TUNNEL_ENCAP_DECAP_FLAG_##a;\ + return 1;\ + } + forech_tunnel_encap_decap_flag; +#undef _ + return 0; +} + /* * fd.io coding-style-patch-verification: ON |