X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=src%2Fplugins%2Figmp%2Figmp_config.h;h=e3cd5d844c87d4d3b8f59c8796e9927e27a610ef;hb=c415d0a8e34a30aeb7efe2360937426b724206c2;hp=a9f48a768fac2acd633f2c9c2ae17147252dd2b9;hpb=bdc0e6b7204ea0211d4f7881497e4306586fb9ef;p=vpp.git diff --git a/src/plugins/igmp/igmp_config.h b/src/plugins/igmp/igmp_config.h index a9f48a768fa..e3cd5d844c8 100644 --- a/src/plugins/igmp/igmp_config.h +++ b/src/plugins/igmp/igmp_config.h @@ -22,21 +22,25 @@ #include #include +/** + * GENERAL_REPORT = On expiry send a general report + * GENERAL_QUERY = On expiry send a general query + */ +#define foreach_igmp_config_timer_type \ + _(GENERAL_REPORT, "general-report") \ + _(GENERAL_QUERY, "general-query") + typedef enum igmp_config_timer_type_t_ { - /** - * On expiry send a general report - */ - IGMP_CONFIG_TIMER_GENERAL_REPORT, - - /** - * On expiry send a general query - */ - IGMP_CONFIG_TIMER_GENERAL_QUERY, +#define _(v,s) IGMP_CONFIG_TIMER_##v, + foreach_igmp_config_timer_type +#undef _ } igmp_config_timer_type_t; #define IGMP_CONFIG_N_TIMERS (IGMP_CONFIG_TIMER_GENERAL_QUERY + 1) +extern u8 *format_igmp_config_timer_type (u8 * s, va_list * args); + /** * @brief IGMP interface configuration */ @@ -53,7 +57,7 @@ typedef struct igmp_config_t_ adj_index_t adj_index; /** - * @param moe - host or router + * @param mode - host or router */ igmp_mode_t mode; @@ -71,6 +75,11 @@ typedef struct igmp_config_t_ * A vector of scheduled query-response timers */ igmp_timer_id_t timers[IGMP_CONFIG_N_TIMERS]; + + /** + * ID of a proxy device this configuration is on + */ + u32 proxy_device_id; } igmp_config_t; #define FOR_EACH_GROUP(_group, _config, _body) \ @@ -117,6 +126,8 @@ extern igmp_config_t *igmp_config_get (u32 index); extern igmp_group_t *igmp_group_lookup (igmp_config_t * config, const igmp_key_t * key); +extern u8 *format_igmp_config (u8 * s, va_list * args); + #endif /*