Netdev List
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: challa@noironetworks.com
Cc: eric.dumazet@gmail.com, netdev@vger.kernel.org
Subject: Re: [PATCH v2 net-next 2/2] multicast: Extend ip address command to enable multicast group join/leave on IP level.
Date: Sat, 21 Feb 2015 19:04:21 -0500 (EST)	[thread overview]
Message-ID: <20150221.190421.2134726339184440278.davem@davemloft.net> (raw)
In-Reply-To: <1424222346-12736-2-git-send-email-challa@noironetworks.com>

From: Madhu Challa <challa@noironetworks.com>
Date: Tue, 17 Feb 2015 17:19:06 -0800

>     Joining multicast group on ethernet level via "ip maddr" command would
>     not work if we have an Ethernet switch that does igmp snooping since
>     the switch would not replicate multicast packets on ports that did not
>     have IGMP reports for the multicast addresses.
> 
>     Linux vxlan interfaces created via "ip link add vxlan" have the group option
>     that enables then to do the required join.
> 
>     By extending ip address command with option "autojoin" we can get similar
>     functionality for openvswitch vxlan interfaces as well as other tunneling
>     mechanisms that need to receive multicast traffic. The kernel code is
>     structured similar to how the vxlan driver does a group join / leave.
> 
>     example:
>     ip address add 224.1.1.10/24 dev eth5 autojoin
>     ip address del 224.1.1.10/24 dev eth5
> 
>     v2 address review comments from Eric Dumazet.
> 
>     This patch applies on top of
>     [PATCH net-next] igmp: add __ip_mc_{join|leave}_group()
>     by Eric Dumazet. and
>     igmp v6: add __ipv6_sock_mc_join and __ipv6_sock_mc_drop
> 
>     remove the work queue and call the __ip_mc_{join|leave}_group
>     and the ipv6 variant __ipv6_sock_mc_{join|drop}
> 
>     Signed-off-by: Madhu Challa <challa@noironetworks.com>

Please do not add this indentation to every line in your commit message.

Also, you should provide a "[PATCH net-next 0/2] xxx" posting that explains
at a high level what your patch series is doing, and why.

> +static int ip_mc_config(struct sock *sk, bool join, __be32 saddr, int ifindex)
> +{
> +	int ret;
> +	struct ip_mreqn mreq = {
> +		.imr_multiaddr.s_addr = saddr,
> +		.imr_ifindex = ifindex,
> +	};

Please order local variable declarations in "reverse christmas tree"
ordering, meaning longer lines before shorter ones.

> @@ -2740,6 +2740,8 @@ static const struct file_operations igmp_mcf_seq_fops = {
>  static int __net_init igmp_net_init(struct net *net)
>  {
>  	struct proc_dir_entry *pde;
> +	int err;
> +	struct socket *sock = NULL;
>  
>  	pde = proc_create("igmp", S_IRUGO, net->proc_net, &igmp_mc_seq_fops);
>  	if (!pde)

Likewise.

      reply	other threads:[~2015-02-22  0:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-18  1:19 [PATCH v2 net-next 1/2] igmp v6: add __ipv6_sock_mc_join and __ipv6_sock_mc_drop Madhu Challa
2015-02-18  1:19 ` [PATCH v2 net-next 2/2] multicast: Extend ip address command to enable multicast group join/leave on IP level Madhu Challa
2015-02-22  0:04   ` David Miller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150221.190421.2134726339184440278.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=challa@noironetworks.com \
    --cc=eric.dumazet@gmail.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox