Lines Matching refs:igmp

84 #include "lwip/igmp.h"
203 /* Allow the igmp messages at the MAC level */
308 * Search for a specific igmp group and create a new one if not found-
384 * @param p received igmp packet, p->payload pointing to the ip header
386 * @param dest destination ip address of the igmp packet
392 struct igmp_msg* igmp;
396 IGMP_STATS_INC(igmp.recv);
402 IGMP_STATS_INC(igmp.lenerr);
414 igmp = (struct igmp_msg *)p->payload;
415 if (inet_chksum(igmp, p->len)) {
417 IGMP_STATS_INC(igmp.chkerr);
428 IGMP_STATS_INC(igmp.drop);
434 switch (igmp->igmp_msgtype) {
437 if ((ip_addr_cmp(dest, &allsystems)) && ip_addr_isany(&igmp->igmp_group_address)) {
439 LWIP_DEBUGF(IGMP_DEBUG, ("igmp_input: General IGMP_MEMB_QUERY on \"ALL SYSTEMS\" address (224.0.0.1) [igmp_maxresp=%i]\n", (int)(igmp->igmp_maxresp)));
441 if (igmp->igmp_maxresp == 0) {
442 IGMP_STATS_INC(igmp.rx_v1);
444 igmp->igmp_maxresp = IGMP_V1_DELAYING_MEMBER_TMR;
446 IGMP_STATS_INC(igmp.rx_general);
453 igmp_delaying_member(groupref, igmp->igmp_maxresp);
459 if (!ip_addr_isany(&igmp->igmp_group_address)) {
461 ip_addr_debug_print(IGMP_DEBUG, &igmp->igmp_group_address);
464 LWIP_DEBUGF(IGMP_DEBUG, (" using \"ALL SYSTEMS\" address (224.0.0.1) [igmp_maxresp=%i]\n", (int)(igmp->igmp_maxresp)));
466 ip_addr_copy(groupaddr, igmp->igmp_group_address);
469 LWIP_DEBUGF(IGMP_DEBUG, (" with the group address as destination [igmp_maxresp=%i]\n", (int)(igmp->igmp_maxresp)));
473 IGMP_STATS_INC(igmp.rx_group);
474 igmp_delaying_member(group, igmp->igmp_maxresp);
476 IGMP_STATS_INC(igmp.drop);
479 IGMP_STATS_INC(igmp.proterr);
486 IGMP_STATS_INC(igmp.rx_report);
497 igmp->igmp_msgtype, group->group_state, &group, group->netif));
498 IGMP_STATS_INC(igmp.proterr);
551 IGMP_STATS_INC(igmp.tx_join);
614 IGMP_STATS_INC(igmp.tx_leave);
651 * The igmp timer function (both for NO_SYS=1 and =0)
685 IGMP_STATS_INC(igmp.tx_report);
691 * Start a timer for an igmp group
751 IGMP_STATS_INC(igmp.xmit);
756 * Send an igmp packet to a specific group.
759 * @param type the type of igmp packet to send
765 struct igmp_msg* igmp = NULL;
773 igmp = (struct igmp_msg *)p->payload;
780 ip_addr_copy(igmp->igmp_group_address, group->group_address);
785 ip_addr_copy(igmp->igmp_group_address, group->group_address);
790 igmp->igmp_msgtype = type;
791 igmp->igmp_maxresp = 0;
792 igmp->igmp_checksum = 0;
793 igmp->igmp_checksum = inet_chksum(igmp, IGMP_MINLEN);
801 IGMP_STATS_INC(igmp.memerr);