From: Sasha Levin <sashal@kernel.org>
To: linux-kernel@vger.kernel.org, stable@vger.kernel.org
Cc: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>,
"David S . Miller" <davem@davemloft.net>,
Sasha Levin <sashal@kernel.org>,
netdev@vger.kernel.org
Subject: [PATCH AUTOSEL 5.4 05/15] net: mscc: ocelot: fix fields offset in SG_CONFIG_REG_3
Date: Mon, 12 Oct 2020 15:03:02 -0400 [thread overview]
Message-ID: <20201012190313.3279397-5-sashal@kernel.org> (raw)
In-Reply-To: <20201012190313.3279397-1-sashal@kernel.org>
From: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>
[ Upstream commit 4ab810a4e04ab6c851007033d39c13e6d3f55110 ]
INIT_IPS and GATE_ENABLE fields have a wrong offset in SG_CONFIG_REG_3.
This register is used by stream gate control of PSFP, and it has not
been used before, because PSFP is not implemented in ocelot driver.
Signed-off-by: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
---
drivers/net/ethernet/mscc/ocelot_ana.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/ethernet/mscc/ocelot_ana.h b/drivers/net/ethernet/mscc/ocelot_ana.h
index 841c6ec22b641..1669481d97794 100644
--- a/drivers/net/ethernet/mscc/ocelot_ana.h
+++ b/drivers/net/ethernet/mscc/ocelot_ana.h
@@ -252,10 +252,10 @@
#define ANA_SG_CONFIG_REG_3_LIST_LENGTH_M GENMASK(18, 16)
#define ANA_SG_CONFIG_REG_3_LIST_LENGTH_X(x) (((x) & GENMASK(18, 16)) >> 16)
#define ANA_SG_CONFIG_REG_3_GATE_ENABLE BIT(20)
-#define ANA_SG_CONFIG_REG_3_INIT_IPS(x) (((x) << 24) & GENMASK(27, 24))
-#define ANA_SG_CONFIG_REG_3_INIT_IPS_M GENMASK(27, 24)
-#define ANA_SG_CONFIG_REG_3_INIT_IPS_X(x) (((x) & GENMASK(27, 24)) >> 24)
-#define ANA_SG_CONFIG_REG_3_INIT_GATE_STATE BIT(28)
+#define ANA_SG_CONFIG_REG_3_INIT_IPS(x) (((x) << 21) & GENMASK(24, 21))
+#define ANA_SG_CONFIG_REG_3_INIT_IPS_M GENMASK(24, 21)
+#define ANA_SG_CONFIG_REG_3_INIT_IPS_X(x) (((x) & GENMASK(24, 21)) >> 21)
+#define ANA_SG_CONFIG_REG_3_INIT_GATE_STATE BIT(25)
#define ANA_SG_GCL_GS_CONFIG_RSZ 0x4
--
2.25.1
next prev parent reply other threads:[~2020-10-12 19:08 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-12 19:02 [PATCH AUTOSEL 5.4 01/15] net: lantiq: Add locking for TX DMA channel Sasha Levin
2020-10-12 19:02 ` [PATCH AUTOSEL 5.4 02/15] platform/x86: asus-nb-wmi: Revert "Do not load on Asus T100TA and T200TA" Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 03/15] platform/x86: asus-wmi: Add BATC battery name to the list of supported Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 04/15] drivers/net/wan/x25_asy: Correct the ndo_open and ndo_stop functions Sasha Levin
2020-10-12 19:03 ` Sasha Levin [this message]
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 06/15] net/fsl: quieten expected MDIO access failures Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 07/15] net: usb: ax88179_178a: add Toshiba usb 3.0 adapter Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 08/15] net: usb: ax88179_178a: add MCT " Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 09/15] via-rhine: Fix for the hardware having a reset failure after resume Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 10/15] via-rhine: VTunknown1 device is really VT8251 South Bridge Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 11/15] net: usb: pegasus: Proper error handing when setting pegasus' MAC address Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 12/15] net: usb: rtl8150: set random MAC address when set_ethernet_addr() fails Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 13/15] usermodehelper: reset umask to default before executing user process Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 14/15] arm/arm64: xen: Fix to convert percpu address to gfn correctly Sasha Levin
2020-10-12 19:03 ` [PATCH AUTOSEL 5.4 15/15] net: usb: qmi_wwan: add Cellient MPL200 card Sasha Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201012190313.3279397-5-sashal@kernel.org \
--to=sashal@kernel.org \
--cc=davem@davemloft.net \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=xiaoliang.yang_1@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).