Lines Matching refs:ma

73 static void igmp6_join_group(struct ifmcaddr6 *ma);
74 static void igmp6_leave_group(struct ifmcaddr6 *ma);
966 struct ifmcaddr6 *ma, __rcu **map; in __ipv6_dev_mc_dec() local
972 (ma = mc_dereference(*map, idev)); in __ipv6_dev_mc_dec()
973 map = &ma->next) { in __ipv6_dev_mc_dec()
974 if (ipv6_addr_equal(&ma->mca_addr, addr)) { in __ipv6_dev_mc_dec()
975 if (--ma->mca_users == 0) { in __ipv6_dev_mc_dec()
976 *map = ma->next; in __ipv6_dev_mc_dec()
978 igmp6_group_dropped(ma); in __ipv6_dev_mc_dec()
979 ip6_mc_clear_src(ma); in __ipv6_dev_mc_dec()
982 ma_put(ma); in __ipv6_dev_mc_dec()
1118 static void igmp6_group_queried(struct ifmcaddr6 *ma, unsigned long resptime) in igmp6_group_queried() argument
1123 if (ipv6_addr_is_ll_all_nodes(&ma->mca_addr) || in igmp6_group_queried()
1124 IPV6_ADDR_MC_SCOPE(&ma->mca_addr) < IPV6_ADDR_SCOPE_LINKLOCAL) in igmp6_group_queried()
1127 if (cancel_delayed_work(&ma->mca_work)) { in igmp6_group_queried()
1128 refcount_dec(&ma->mca_refcnt); in igmp6_group_queried()
1129 delay = ma->mca_work.timer.expires - jiffies; in igmp6_group_queried()
1135 if (!mod_delayed_work(mld_wq, &ma->mca_work, delay)) in igmp6_group_queried()
1136 refcount_inc(&ma->mca_refcnt); in igmp6_group_queried()
1137 ma->mca_flags |= MAF_TIMER_RUNNING; in igmp6_group_queried()
1403 struct ifmcaddr6 *ma; in __mld_query_work() local
1480 for_each_mc_mclock(idev, ma) { in __mld_query_work()
1481 igmp6_group_queried(ma, max_delay); in __mld_query_work()
1484 for_each_mc_mclock(idev, ma) { in __mld_query_work()
1485 if (!ipv6_addr_equal(group, &ma->mca_addr)) in __mld_query_work()
1487 if (ma->mca_flags & MAF_TIMER_RUNNING) { in __mld_query_work()
1490 ma->mca_flags &= ~MAF_GSQUERY; in __mld_query_work()
1494 ma->mca_flags |= MAF_GSQUERY; in __mld_query_work()
1496 ma->mca_flags &= ~MAF_GSQUERY; in __mld_query_work()
1498 if (!(ma->mca_flags & MAF_GSQUERY) || in __mld_query_work()
1499 mld_marksources(ma, ntohs(mlh2->mld2q_nsrcs), mlh2->mld2q_srcs)) in __mld_query_work()
1500 igmp6_group_queried(ma, max_delay); in __mld_query_work()
1571 struct ifmcaddr6 *ma; in __mld_report_work() local
1603 for_each_mc_mclock(idev, ma) { in __mld_report_work()
1604 if (ipv6_addr_equal(&ma->mca_addr, &mld->mld_mca)) { in __mld_report_work()
1605 if (cancel_delayed_work(&ma->mca_work)) in __mld_report_work()
1606 refcount_dec(&ma->mca_refcnt); in __mld_report_work()
1607 ma->mca_flags &= ~(MAF_LAST_REPORTER | in __mld_report_work()
2574 static void igmp6_join_group(struct ifmcaddr6 *ma) in igmp6_join_group() argument
2578 if (ma->mca_flags & MAF_NOREPORT) in igmp6_join_group()
2581 igmp6_send(&ma->mca_addr, ma->idev->dev, ICMPV6_MGM_REPORT); in igmp6_join_group()
2583 delay = prandom_u32() % unsolicited_report_interval(ma->idev); in igmp6_join_group()
2585 if (cancel_delayed_work(&ma->mca_work)) { in igmp6_join_group()
2586 refcount_dec(&ma->mca_refcnt); in igmp6_join_group()
2587 delay = ma->mca_work.timer.expires - jiffies; in igmp6_join_group()
2590 if (!mod_delayed_work(mld_wq, &ma->mca_work, delay)) in igmp6_join_group()
2591 refcount_inc(&ma->mca_refcnt); in igmp6_join_group()
2592 ma->mca_flags |= MAF_TIMER_RUNNING | MAF_LAST_REPORTER; in igmp6_join_group()
2625 static void igmp6_leave_group(struct ifmcaddr6 *ma) in igmp6_leave_group() argument
2627 if (mld_in_v1_mode(ma->idev)) { in igmp6_leave_group()
2628 if (ma->mca_flags & MAF_LAST_REPORTER) { in igmp6_leave_group()
2629 igmp6_send(&ma->mca_addr, ma->idev->dev, in igmp6_leave_group()
2633 mld_add_delrec(ma->idev, ma); in igmp6_leave_group()
2634 mld_ifc_event(ma->idev); in igmp6_leave_group()
2683 struct ifmcaddr6 *ma = container_of(to_delayed_work(work), in mld_mca_work() local
2686 mutex_lock(&ma->idev->mc_lock); in mld_mca_work()
2687 if (mld_in_v1_mode(ma->idev)) in mld_mca_work()
2688 igmp6_send(&ma->mca_addr, ma->idev->dev, ICMPV6_MGM_REPORT); in mld_mca_work()
2690 mld_send_report(ma->idev, ma); in mld_mca_work()
2691 ma->mca_flags |= MAF_LAST_REPORTER; in mld_mca_work()
2692 ma->mca_flags &= ~MAF_TIMER_RUNNING; in mld_mca_work()
2693 mutex_unlock(&ma->idev->mc_lock); in mld_mca_work()
2695 ma_put(ma); in mld_mca_work()