Home
last modified time | relevance | path

Searched refs:mreq (Results 1 – 4 of 4) sorted by relevance

/linux-2.4.37.9/net/ipv4/
Dip_sockglue.c533 struct ip_mreqn mreq; in ip_setsockopt() local
544 if (copy_from_user(&mreq,optval,sizeof(mreq))) in ip_setsockopt()
547 memset(&mreq, 0, sizeof(mreq)); in ip_setsockopt()
549 copy_from_user(&mreq.imr_address,optval,sizeof(struct in_addr))) in ip_setsockopt()
553 if (!mreq.imr_ifindex) { in ip_setsockopt()
554 if (mreq.imr_address.s_addr == INADDR_ANY) { in ip_setsockopt()
560 dev = ip_dev_find(mreq.imr_address.s_addr); in ip_setsockopt()
562 mreq.imr_ifindex = dev->ifindex; in ip_setsockopt()
566 dev = __dev_get_by_index(mreq.imr_ifindex); in ip_setsockopt()
574 if (sk->bound_dev_if && mreq.imr_ifindex != sk->bound_dev_if) in ip_setsockopt()
[all …]
/linux-2.4.37.9/net/ipv6/
Dipv6_sockglue.c359 struct ipv6_mreq mreq; in ipv6_setsockopt() local
362 if (copy_from_user(&mreq, optval, sizeof(struct ipv6_mreq))) in ipv6_setsockopt()
366 retv = ipv6_sock_mc_join(sk, mreq.ipv6mr_ifindex, &mreq.ipv6mr_multiaddr); in ipv6_setsockopt()
368 retv = ipv6_sock_mc_drop(sk, mreq.ipv6mr_ifindex, &mreq.ipv6mr_multiaddr); in ipv6_setsockopt()
374 struct ipv6_mreq mreq; in ipv6_setsockopt() local
380 if (copy_from_user(&mreq, optval, sizeof(struct ipv6_mreq))) in ipv6_setsockopt()
384 retv = ipv6_sock_ac_join(sk, mreq.ipv6mr_ifindex, &mreq.ipv6mr_acaddr); in ipv6_setsockopt()
386 retv = ipv6_sock_ac_drop(sk, mreq.ipv6mr_ifindex, &mreq.ipv6mr_acaddr); in ipv6_setsockopt()
/linux-2.4.37.9/net/packet/
Daf_packet.c1193 static int packet_mc_add(struct sock *sk, struct packet_mreq *mreq) in packet_mc_add() argument
1202 dev = __dev_get_by_index(mreq->mr_ifindex); in packet_mc_add()
1207 if (mreq->mr_alen > dev->addr_len) in packet_mc_add()
1217 if (ml->ifindex == mreq->mr_ifindex && in packet_mc_add()
1218 ml->type == mreq->mr_type && in packet_mc_add()
1219 ml->alen == mreq->mr_alen && in packet_mc_add()
1220 memcmp(ml->addr, mreq->mr_address, ml->alen) == 0) { in packet_mc_add()
1228 i->type = mreq->mr_type; in packet_mc_add()
1229 i->ifindex = mreq->mr_ifindex; in packet_mc_add()
1230 i->alen = mreq->mr_alen; in packet_mc_add()
[all …]
/linux-2.4.37.9/net/ipv4/ipvs/
Dip_vs_sync.c398 struct ip_mreqn mreq; in join_mcast_group() local
402 memset(&mreq, 0, sizeof(mreq)); in join_mcast_group()
403 memcpy(&mreq.imr_multiaddr, addr, sizeof(struct in_addr)); in join_mcast_group()
410 mreq.imr_ifindex = dev->ifindex; in join_mcast_group()
413 ret = ip_mc_join_group(sk, &mreq); in join_mcast_group()