diff options
author | Satish Ashok <sashok@cumulusnetworks.com> | 2015-06-19 04:22:57 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-06-23 06:31:29 -0400 |
commit | 754bc547f0a79f7568b5b81c7fc0a8d044a6571a (patch) | |
tree | 1e3f32959fbba7ddd144f2d09b07c4b55353cd4c /net | |
parent | d496f7842aada20c61e6044b3395383fa972872c (diff) |
bridge: multicast: restore router configuration on port link down/up
When a port goes through a link down/up the multicast router configuration
is not restored.
Signed-off-by: Satish Ashok <sashok@cumulusnetworks.com>
Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Fixes: 0909e11758bd ("bridge: Add multicast_router sysfs entries")
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/bridge/br_multicast.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/bridge/br_multicast.c b/net/bridge/br_multicast.c index ff667e18b2d6..761fc733bf6d 100644 --- a/net/bridge/br_multicast.c +++ b/net/bridge/br_multicast.c | |||
@@ -37,6 +37,8 @@ | |||
37 | 37 | ||
38 | static void br_multicast_start_querier(struct net_bridge *br, | 38 | static void br_multicast_start_querier(struct net_bridge *br, |
39 | struct bridge_mcast_own_query *query); | 39 | struct bridge_mcast_own_query *query); |
40 | static void br_multicast_add_router(struct net_bridge *br, | ||
41 | struct net_bridge_port *port); | ||
40 | unsigned int br_mdb_rehash_seq; | 42 | unsigned int br_mdb_rehash_seq; |
41 | 43 | ||
42 | static inline int br_ip_equal(const struct br_ip *a, const struct br_ip *b) | 44 | static inline int br_ip_equal(const struct br_ip *a, const struct br_ip *b) |
@@ -936,6 +938,8 @@ void br_multicast_enable_port(struct net_bridge_port *port) | |||
936 | #if IS_ENABLED(CONFIG_IPV6) | 938 | #if IS_ENABLED(CONFIG_IPV6) |
937 | br_multicast_enable(&port->ip6_own_query); | 939 | br_multicast_enable(&port->ip6_own_query); |
938 | #endif | 940 | #endif |
941 | if (port->multicast_router == 2 && hlist_unhashed(&port->rlist)) | ||
942 | br_multicast_add_router(br, port); | ||
939 | 943 | ||
940 | out: | 944 | out: |
941 | spin_unlock(&br->multicast_lock); | 945 | spin_unlock(&br->multicast_lock); |