]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
5.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 29 Mar 2021 06:23:39 +0000 (08:23 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 29 Mar 2021 06:23:39 +0000 (08:23 +0200)
added patches:
net-dsa-b53-vlan-filtering-is-global-to-all-users.patch

queue-5.4/net-dsa-b53-vlan-filtering-is-global-to-all-users.patch [new file with mode: 0644]
queue-5.4/series

diff --git a/queue-5.4/net-dsa-b53-vlan-filtering-is-global-to-all-users.patch b/queue-5.4/net-dsa-b53-vlan-filtering-is-global-to-all-users.patch
new file mode 100644 (file)
index 0000000..95dd7b0
--- /dev/null
@@ -0,0 +1,52 @@
+From d45c36bafb94e72fdb6dee437279b61b6d97e706 Mon Sep 17 00:00:00 2001
+From: Florian Fainelli <f.fainelli@gmail.com>
+Date: Wed, 10 Mar 2021 10:46:10 -0800
+Subject: net: dsa: b53: VLAN filtering is global to all users
+
+From: Florian Fainelli <f.fainelli@gmail.com>
+
+commit d45c36bafb94e72fdb6dee437279b61b6d97e706 upstream.
+
+The bcm_sf2 driver uses the b53 driver as a library but does not make
+usre of the b53_setup() function, this made it fail to inherit the
+vlan_filtering_is_global attribute. Fix this by moving the assignment to
+b53_switch_alloc() which is used by bcm_sf2.
+
+Fixes: 7228b23e68f7 ("net: dsa: b53: Let DSA handle mismatched VLAN filtering settings")
+Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/dsa/b53/b53_common.c |   14 +++++++-------
+ 1 file changed, 7 insertions(+), 7 deletions(-)
+
+--- a/drivers/net/dsa/b53/b53_common.c
++++ b/drivers/net/dsa/b53/b53_common.c
+@@ -996,13 +996,6 @@ static int b53_setup(struct dsa_switch *
+                       b53_disable_port(ds, port);
+       }
+-      /* Let DSA handle the case were multiple bridges span the same switch
+-       * device and different VLAN awareness settings are requested, which
+-       * would be breaking filtering semantics for any of the other bridge
+-       * devices. (not hardware supported)
+-       */
+-      ds->vlan_filtering_is_global = true;
+-
+       return ret;
+ }
+@@ -2418,6 +2411,13 @@ struct b53_device *b53_switch_alloc(stru
+       dev->priv = priv;
+       dev->ops = ops;
+       ds->ops = &b53_switch_ops;
++      /* Let DSA handle the case were multiple bridges span the same switch
++       * device and different VLAN awareness settings are requested, which
++       * would be breaking filtering semantics for any of the other bridge
++       * devices. (not hardware supported)
++       */
++      ds->vlan_filtering_is_global = true;
++
+       mutex_init(&dev->reg_mutex);
+       mutex_init(&dev->stats_mutex);
index 70f4417fe90cc21ed66e7f0446368b84cafdc789..b1e4c86d1a8c30d508953bb5ddebd70d606216b4 100644 (file)
@@ -104,3 +104,4 @@ scsi-mpt3sas-fix-error-return-code-of-mpt3sas_base_a.patch
 locking-mutex-fix-non-debug-version-of-mutex_lock_io_nested.patch
 x86-mem_encrypt-correct-physical-address-calculation-in-__set_clr_pte_enc.patch
 can-dev-move-device-back-to-init-netns-on-owning-netns-delete.patch
+net-dsa-b53-vlan-filtering-is-global-to-all-users.patch