All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next v2] bridge: multicast: start querier timer when running user-space stp
@ 2015-06-19  8:45 Nikolay Aleksandrov
  2015-06-19 13:47 ` Herbert Xu
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Nikolay Aleksandrov @ 2015-06-19  8:45 UTC (permalink / raw)
  To: netdev; +Cc: davem, stephen, herbert, sashok, Nikolay Aleksandrov

When STP is running in user-space and querier is configured, the
querier timer is not started when a port goes to a non-blocking state.
This patch unifies the user- and kernel-space stp multicast port enable
path and enables it in all states different from blocking. Note that when a
port goes in BR_STATE_DISABLED it's not enabled because that is handled
in the beginning of the port list loop.

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
---
v2: Repurposed for net-next and implemented Herbert's suggestion for
    unifying both user- and kernel-space multicast enable port paths.

 net/bridge/br_stp.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/net/bridge/br_stp.c b/net/bridge/br_stp.c
index 45f1ff113af9..e7ab74b405a1 100644
--- a/net/bridge/br_stp.c
+++ b/net/bridge/br_stp.c
@@ -428,7 +428,6 @@ static void br_make_forwarding(struct net_bridge_port *p)
 	else
 		br_set_state(p, BR_STATE_LEARNING);
 
-	br_multicast_enable_port(p);
 	br_log_state(p);
 	br_ifinfo_notify(RTM_NEWLINK, p);
 
@@ -462,6 +461,8 @@ void br_port_state_selection(struct net_bridge *br)
 			}
 		}
 
+		if (p->state != BR_STATE_BLOCKING)
+			br_multicast_enable_port(p);
 		if (p->state == BR_STATE_FORWARDING)
 			++liveports;
 	}
-- 
2.4.3

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

end of thread, other threads:[~2015-06-23 13:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-19  8:45 [PATCH net-next v2] bridge: multicast: start querier timer when running user-space stp Nikolay Aleksandrov
2015-06-19 13:47 ` Herbert Xu
2015-06-19 13:51   ` Nikolay Aleksandrov
2015-06-22 20:12 ` [PATCH net-next] bridge: multicast: disable port when in blocking state Nikolay Aleksandrov
2015-06-22 20:25   ` Nikolay Aleksandrov
2015-06-22 20:38     ` Nikolay Aleksandrov
2015-06-22 23:52       ` Herbert Xu
2015-06-23 10:26         ` Nikolay Aleksandrov
2015-06-23 11:47           ` [PATCH net-next] bridge: multicast: add a comment to br_port_state_selection about " Nikolay Aleksandrov
2015-06-23 13:26             ` Herbert Xu
2015-06-23 10:31 ` [PATCH net-next v2] bridge: multicast: start querier timer when running user-space stp 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.