kernel: bump 5.15 to 5.15.116
[openwrt/openwrt.git] / target / linux / generic / backport-5.15 / 777-v6.2-02-net-dsa-tag_qca-fix-wrong-MGMT_DATA2-size.patch
1 From d9dba91be71f03cc75bcf39fc0d5d99ff33f1ae0 Mon Sep 17 00:00:00 2001
2 From: Christian Marangi <ansuelsmth@gmail.com>
3 Date: Thu, 29 Dec 2022 17:33:33 +0100
4 Subject: [PATCH 2/5] net: dsa: tag_qca: fix wrong MGMT_DATA2 size
5
6 It was discovered that MGMT_DATA2 can contain up to 28 bytes of data
7 instead of the 12 bytes written in the Documentation by accounting the
8 limit of 16 bytes declared in Documentation subtracting the first 4 byte
9 in the packet header.
10
11 Update the define with the real world value.
12
13 Tested-by: Ronald Wahl <ronald.wahl@raritan.com>
14 Fixes: c2ee8181fddb ("net: dsa: tag_qca: add define for handling mgmt Ethernet packet")
15 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
16 Cc: stable@vger.kernel.org # v5.18+
17 Signed-off-by: David S. Miller <davem@davemloft.net>
18 ---
19 include/linux/dsa/tag_qca.h | 4 ++--
20 1 file changed, 2 insertions(+), 2 deletions(-)
21
22 --- a/include/linux/dsa/tag_qca.h
23 +++ b/include/linux/dsa/tag_qca.h
24 @@ -40,8 +40,8 @@
25 QCA_HDR_MGMT_COMMAND_LEN + \
26 QCA_HDR_MGMT_DATA1_LEN)
27
28 -#define QCA_HDR_MGMT_DATA2_LEN 12 /* Other 12 byte for the mdio data */
29 -#define QCA_HDR_MGMT_PADDING_LEN 34 /* Padding to reach the min Ethernet packet */
30 +#define QCA_HDR_MGMT_DATA2_LEN 28 /* Other 28 byte for the mdio data */
31 +#define QCA_HDR_MGMT_PADDING_LEN 18 /* Padding to reach the min Ethernet packet */
32
33 #define QCA_HDR_MGMT_PKT_LEN (QCA_HDR_MGMT_HEADER_LEN + \
34 QCA_HDR_LEN + \