Lines Matching refs:igmp

65  *	@(#)igmp.c	8.1 (Berkeley) 7/19/93
110 #include <netinet/igmp.h>
143 const struct igmp *);
145 const struct igmp *);
151 /*const*/ struct igmp *);
153 /*const*/ struct igmp *);
495 * If the net.inet.igmp.sendlocal sysctl is 0, then IGMP reports are
794 const struct igmp *igmp)
806 if (!in_allhosts(ip->ip_dst) || !in_nullhost(igmp->igmp_group)) {
879 const struct igmp *igmp)
891 if (in_nullhost(igmp->igmp_group)) {
925 timer = igmp->igmp_code * PR_SLOWHZ / IGMP_TIMER_SCALE;
954 IN_LOOKUP_MULTI(&igmp->igmp_group, ifp, inm);
959 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name,
1315 /*const*/ struct igmp *igmp)
1326 if (!IN_MULTICAST(ntohl(igmp->igmp_group.s_addr) ||
1327 !in_hosteq(igmp->igmp_group, ip->ip_dst))) {
1351 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name, ifp->if_unit));
1359 IN_LOOKUP_MULTI(&igmp->igmp_group, ifp, inm);
1398 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name,
1405 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name,
1432 /*const*/ struct igmp *igmp)
1462 if (!IN_MULTICAST(ntohl(igmp->igmp_group.s_addr)) ||
1463 !in_hosteq(igmp->igmp_group, ip->ip_dst)) {
1489 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name, ifp->if_unit));
1498 IN_LOOKUP_MULTI(&igmp->igmp_group, ifp, inm);
1536 inet_ntoa(igmp->igmp_group), ifp, ifp->if_name,
1559 struct igmp *igmp;
1601 M_STRUCT_GET0(igmp, struct igmp *, m, off, minlen);
1602 if (igmp == NULL) {
1607 VERIFY(IS_P2ALIGNED(igmp, sizeof (u_int32_t)));
1628 if (igmp->igmp_type != IGMP_DVMRP && ip->ip_ttl != 1) {
1634 switch (igmp->igmp_type) {
1637 if (igmp->igmp_code == 0)
1657 if (igmp_input_v1_query(ifp, ip, igmp) != 0) {
1667 if (igmp_input_v2_query(ifp, ip, igmp) != 0) {
1680 igmpv3 = (struct igmpv3 *)igmp;
1718 if (igmp_input_v1_report(ifp, ip, igmp) != 0) {
1731 if (igmp_input_v2_report(ifp, ip, igmp) != 0) {
2392 struct igmp *igmp;
2405 MH_ALIGN(m, sizeof(struct ip) + sizeof(struct igmp));
2407 m->m_pkthdr.len = sizeof(struct ip) + sizeof(struct igmp);
2410 m->m_len = sizeof(struct igmp);
2412 igmp = mtod(m, struct igmp *);
2413 igmp->igmp_type = type;
2414 igmp->igmp_code = 0;
2415 igmp->igmp_group = inm->inm_addr;
2416 igmp->igmp_cksum = 0;
2417 igmp->igmp_cksum = in_cksum(m, sizeof(struct igmp));
2424 ip->ip_len = sizeof(struct ip) + sizeof(struct igmp);
3732 struct igmp_report *igmp;
3755 igmp = mtod(m, struct igmp_report *);
3756 igmp->ir_type = IGMP_v3_HOST_MEMBERSHIP_REPORT;
3757 igmp->ir_rsv1 = 0;
3758 igmp->ir_rsv2 = 0;
3759 igmp->ir_numgrps = htons(m->m_pkthdr.vt_nrecs);
3760 igmp->ir_cksum = 0;
3761 igmp->ir_cksum = in_cksum(m, sizeof(struct igmp_report) + igmpreclen);