All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net] bridge: mdb: fix double add notification
@ 2015-07-13 13:36 ` Nikolay Aleksandrov
  0 siblings, 0 replies; 6+ messages in thread
From: Nikolay Aleksandrov @ 2015-07-13 13:36 UTC (permalink / raw)
  To: netdev; +Cc: bridge, amwang, davem, stephen, Nikolay Aleksandrov

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@debian:~# 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@debian:~# bridge monitor all
 [MDB]dev br0 port eth1 grp 239.0.0.1 permanent

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.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;
 }
 
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Bridge] [PATCH net] bridge: mdb: fix double add notification
@ 2015-07-13 13:36 ` Nikolay Aleksandrov
  0 siblings, 0 replies; 6+ messages in thread
From: Nikolay Aleksandrov @ 2015-07-13 13:36 UTC (permalink / raw)
  To: netdev; +Cc: Nikolay Aleksandrov, bridge, amwang, davem

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@debian:~# 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@debian:~# bridge monitor all
 [MDB]dev br0 port eth1 grp 239.0.0.1 permanent

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.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;
 }
 
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH net] bridge: mdb: fix double add notification
  2015-07-13 13:36 ` [Bridge] " Nikolay Aleksandrov
@ 2015-07-14  3:53   ` Cong Wang
  -1 siblings, 0 replies; 6+ messages in thread
From: Cong Wang @ 2015-07-14  3:53 UTC (permalink / raw)
  To: Nikolay Aleksandrov
  Cc: netdev, bridge@lists.linux-foundation.org, Cong Wang,
	David Miller, Stephen Hemminger

On Mon, Jul 13, 2015 at 6:36 AM, Nikolay Aleksandrov
<nikolay@cumulusnetworks.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@debian:~# 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@debian:~# bridge monitor all
>  [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
>
> Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.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.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Bridge] [PATCH net] bridge: mdb: fix double add notification
@ 2015-07-14  3:53   ` Cong Wang
  0 siblings, 0 replies; 6+ messages in thread
From: Cong Wang @ 2015-07-14  3:53 UTC (permalink / raw)
  To: Nikolay Aleksandrov
  Cc: netdev, bridge@lists.linux-foundation.org, Cong Wang,
	David Miller

On Mon, Jul 13, 2015 at 6:36 AM, Nikolay Aleksandrov
<nikolay@cumulusnetworks.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@debian:~# 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@debian:~# bridge monitor all
>  [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
>
> Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.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.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH net] bridge: mdb: fix double add notification
  2015-07-13 13:36 ` [Bridge] " Nikolay Aleksandrov
@ 2015-07-16  0:15   ` David Miller
  -1 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2015-07-16  0:15 UTC (permalink / raw)
  To: nikolay; +Cc: netdev, bridge, amwang

From: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Date: Mon, 13 Jul 2015 06:36:19 -0700

> 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@debian:~# 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@debian:~# bridge monitor all
>  [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
> 
> Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
> Fixes: cfd567543590 ("bridge: add support of adding and deleting mdb entries")

Applied and queued up for -stable, thanks.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Bridge] [PATCH net] bridge: mdb: fix double add notification
@ 2015-07-16  0:15   ` David Miller
  0 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2015-07-16  0:15 UTC (permalink / raw)
  To: nikolay; +Cc: netdev, bridge, amwang

From: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Date: Mon, 13 Jul 2015 06:36:19 -0700

> 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@debian:~# 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@debian:~# bridge monitor all
>  [MDB]dev br0 port eth1 grp 239.0.0.1 permanent
> 
> Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
> Fixes: cfd567543590 ("bridge: add support of adding and deleting mdb entries")

Applied and queued up for -stable, thanks.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-07-16  0:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-13 13:36 [PATCH net] bridge: mdb: fix double add notification Nikolay Aleksandrov
2015-07-13 13:36 ` [Bridge] " Nikolay Aleksandrov
2015-07-14  3:53 ` Cong Wang
2015-07-14  3:53   ` [Bridge] " Cong Wang
2015-07-16  0:15 ` David Miller
2015-07-16  0:15   ` [Bridge] " David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.