]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
4.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Feb 2021 13:20:24 +0000 (14:20 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Feb 2021 13:20:24 +0000 (14:20 +0100)
added patches:
net-dsa-mv88e6xxx-override-existent-unicast-portvec-in-port_fdb_add.patch

queue-4.14/net-dsa-mv88e6xxx-override-existent-unicast-portvec-in-port_fdb_add.patch [new file with mode: 0644]
queue-4.14/series

diff --git a/queue-4.14/net-dsa-mv88e6xxx-override-existent-unicast-portvec-in-port_fdb_add.patch b/queue-4.14/net-dsa-mv88e6xxx-override-existent-unicast-portvec-in-port_fdb_add.patch
new file mode 100644 (file)
index 0000000..c04e87b
--- /dev/null
@@ -0,0 +1,39 @@
+From f72f2fb8fb6be095b98af5d740ac50cffd0b0cae Mon Sep 17 00:00:00 2001
+From: DENG Qingfang <dqfext@gmail.com>
+Date: Sat, 30 Jan 2021 21:43:34 +0800
+Subject: net: dsa: mv88e6xxx: override existent unicast portvec in port_fdb_add
+
+From: DENG Qingfang <dqfext@gmail.com>
+
+commit f72f2fb8fb6be095b98af5d740ac50cffd0b0cae upstream.
+
+Having multiple destination ports for a unicast address does not make
+sense.
+Make port_db_load_purge override existent unicast portvec instead of
+adding a new port bit.
+
+Fixes: 884729399260 ("net: dsa: mv88e6xxx: handle multiple ports in ATU")
+Signed-off-by: DENG Qingfang <dqfext@gmail.com>
+Reviewed-by: Vladimir Oltean <olteanv@gmail.com>
+Link: https://lore.kernel.org/r/20210130134334.10243-1-dqfext@gmail.com
+Signed-off-by: Jakub Kicinski <kuba@kernel.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/dsa/mv88e6xxx/chip.c |    6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+--- a/drivers/net/dsa/mv88e6xxx/chip.c
++++ b/drivers/net/dsa/mv88e6xxx/chip.c
+@@ -1364,7 +1364,11 @@ static int mv88e6xxx_port_db_load_purge(
+               if (!entry.portvec)
+                       entry.state = MV88E6XXX_G1_ATU_DATA_STATE_UNUSED;
+       } else {
+-              entry.portvec |= BIT(port);
++              if (state == MV88E6XXX_G1_ATU_DATA_STATE_UC_STATIC)
++                      entry.portvec = BIT(port);
++              else
++                      entry.portvec |= BIT(port);
++
+               entry.state = state;
+       }
index a046f32a5ca6ef924a4d28d190ee3f348a47046d..a4a09e6b12ae76e6393af74f6ed74dbfd642acc7 100644 (file)
@@ -27,3 +27,4 @@ x86-build-disable-cet-instrumentation-in-the-kernel.patch
 x86-apic-add-extra-serialization-for-non-serializing-msrs.patch
 input-xpad-sync-supported-devices-with-fork-on-github.patch
 iommu-vt-d-do-not-use-flush-queue-when-caching-mode-is-on.patch
+net-dsa-mv88e6xxx-override-existent-unicast-portvec-in-port_fdb_add.patch