From 8d6d74cdf43d7560eab3cf609cab27e5deb816e0 Mon Sep 17 00:00:00 2001 From: Neale Ranns Date: Thu, 20 Feb 2020 09:45:16 +0000 Subject: vlib: Punt reason allocation listener enable/disable callback Type: improvement allow clients that allocate punt reasons to pass a callback function that is invoked when the first/last client registers to use/listen on that punt reason. This allows the client to perform some necessary configs that might not otherwise be enabled. IPSec uses this callback to register the ESP proto and UDP handling nodes, that would not otherwise be enabled unless a tunnel was present. Change-Id: I9759349903f21ffeeb253d4271e619e6bf46054b Signed-off-by: Neale Ranns --- src/vnet/ip/ip_types.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/vnet/ip') diff --git a/src/vnet/ip/ip_types.h b/src/vnet/ip/ip_types.h index dc07d23087d..720ef1a5edf 100644 --- a/src/vnet/ip/ip_types.h +++ b/src/vnet/ip/ip_types.h @@ -24,6 +24,8 @@ typedef enum ip_address_family_t_ AF_IP6, } ip_address_family_t; +#define N_AF (AF_IP6+1) + extern uword unformat_ip_address_family (unformat_input_t * input, va_list * args); extern u8 *format_ip_address_family (u8 * s, va_list * args); -- cgit 1.2.3-korg