[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHA+R7OJ0bQ_vG7Tt8jZ8gkdjevjXL-4ER7ZhTjL1CmARsFqgw@mail.gmail.com>
Date: Mon, 13 Jul 2015 20:53:38 -0700
From: Cong Wang <cwang@...pensource.com>
To: Nikolay Aleksandrov <nikolay@...ulusnetworks.com>
Cc: netdev <netdev@...r.kernel.org>,
"bridge@...ts.linux-foundation.org"
<bridge@...ts.linux-foundation.org>, Cong Wang <amwang@...hat.com>,
David Miller <davem@...emloft.net>,
Stephen Hemminger <stephen@...workplumber.org>
Subject: Re: [PATCH net] bridge: mdb: fix double add notification
On Mon, Jul 13, 2015 at 6:36 AM, Nikolay Aleksandrov
<nikolay@...ulusnetworks.com> wrote:
> Since the mdb add/del code was introduced there have been 2 br_mdb_notify
> calls when doing br_mdb_add() resulting in 2 notifications on each add.
>
> Example:
> Command: bridge mdb add dev br0 port eth1 grp 239.0.0.1 permanent
> Before patch:
> root@...ian:~# bridge monitor all
> [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
> [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
>
> After patch:
> root@...ian:~# bridge monitor all
> [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
>
> Signed-off-by: Nikolay Aleksandrov <nikolay@...ulusnetworks.com>
> Fixes: cfd567543590 ("bridge: add support of adding and deleting mdb entries")
> ---
> net/bridge/br_mdb.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/net/bridge/br_mdb.c b/net/bridge/br_mdb.c
> index c11cf2611db0..1198a3dbad95 100644
> --- a/net/bridge/br_mdb.c
> +++ b/net/bridge/br_mdb.c
> @@ -351,7 +351,6 @@ static int br_mdb_add_group(struct net_bridge *br, struct net_bridge_port *port,
> if (state == MDB_TEMPORARY)
> mod_timer(&p->timer, now + br->multicast_membership_interval);
>
> - br_mdb_notify(br->dev, port, group, RTM_NEWMDB);
> return 0;
> }
Looks good to me.
And probably we can convert existing __br_mdb_notify() to using
non-atomic allocation too, but that is for net-next.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists