2 *------------------------------------------------------------------
3 * Copyright (c) 2017 Cisco and/or its affiliates.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at:
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *------------------------------------------------------------------
21 #include <vlib/vlib.h>
22 #include <vnet/ip/ip.h>
25 * @brief IGMP interface enable/disable
26 * Called by a router to enable/disable the reception of IGMP messages
27 * @param sw_if_index - Interface
28 * @param enable - enable/disable
29 * @param mode - Host (1) or router (0)
31 int igmp_enable_disable (u32 sw_if_index, u8 enable, u8 mode);
34 * @brief igmp listen (RFC3376 Section 2).
35 * @param vm - vlib main
36 * @param enable - 0 == remove (S,G), else add (S,G), aka. include/exclude
37 * @param sw_if_index - interface sw_if_index
38 * @param saddr - source address
39 * @param gaddr - group address
41 * Add/del (S,G) on an interface. If user configured,
42 * send a status change report from the interface.
43 * If a report was received on interface notify registered api clients.
45 int igmp_listen (vlib_main_t * vm, u8 enable, u32 sw_if_index,
46 const ip46_address_t * saddr, const ip46_address_t * gaddr);
49 #endif /* _IGMP_API_H_ */
52 * fd.io coding-style-patch-verification: ON
55 * eval: (c-set-style "gnu")