diff mbox series

[net-next,1/4] net: stmmac: dwmac4: Fix MTL_OP_MODE_RTC mask and shift macros

Message ID 20241015065708.3465151-2-leyfoon.tan@starfivetech.com (mailing list archive)
State Changes Requested
Delegated to: Netdev Maintainers
Headers show
Series net: stmmac: dwmac4: Fixes and improvements | expand

Checks

Context Check Description
netdev/series_format success Posting correctly formatted
netdev/tree_selection success Clearly marked for net-next
netdev/ynl success Generated files up to date; no warnings/errors; no diff in generated;
netdev/fixes_present success Fixes tag not required for -next series
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 5 this patch: 5
netdev/build_tools success No tools touched, skip
netdev/cc_maintainers fail 1 blamed authors not CCed: peppe.cavallaro@st.com; 4 maintainers not CCed: mcoquelin.stm32@gmail.com linux-arm-kernel@lists.infradead.org linux-stm32@st-md-mailman.stormreply.com peppe.cavallaro@st.com
netdev/build_clang success Errors and warnings before: 3 this patch: 3
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/deprecated_api success None detected
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes fail Problems with Fixes tag: 1
netdev/build_allmodconfig_warn success Errors and warnings before: 6 this patch: 6
netdev/checkpatch success total: 0 errors, 0 warnings, 0 checks, 10 lines checked
netdev/build_clang_rust success No Rust files in patch. Skipping build
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Ley Foon Tan Oct. 15, 2024, 6:57 a.m. UTC
RTC fields are located in bits [1:0]. Correct the _MASK and _SHIFT
macros to use the appropriate mask and shift.

Fixes: 35f74c0c5dce ("stmmac: add GMAC4 DMA/CORE Header File")

Signed-off-by: Ley Foon Tan <leyfoon.tan@starfivetech.com>
---
 drivers/net/ethernet/stmicro/stmmac/dwmac4.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Jakub Kicinski Oct. 16, 2024, 2:10 a.m. UTC | #1
On Tue, 15 Oct 2024 14:57:05 +0800 Ley Foon Tan wrote:
> RTC fields are located in bits [1:0]. Correct the _MASK and _SHIFT
> macros to use the appropriate mask and shift.
> 
> Fixes: 35f74c0c5dce ("stmmac: add GMAC4 DMA/CORE Header File")
> 
> Signed-off-by: Ley Foon Tan <leyfoon.tan@starfivetech.com>

no empty line between Fixes and Signed-off-by lines, please.

Please fix and resend with [PATCH net] in the title.
All fixes which are needed in current Linus's tree need to go to net,
rather than net-next, see:
https://www.kernel.org/doc/html/next/process/maintainer-netdev.html#git-trees-and-patch-flow
diff mbox series

Patch

diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac4.h b/drivers/net/ethernet/stmicro/stmmac/dwmac4.h
index 93a78fd0737b..acbe5a027c85 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac4.h
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac4.h
@@ -389,8 +389,8 @@  static inline u32 mtl_chanx_base_addr(const struct dwmac4_addrs *addrs,
 
 #define MTL_OP_MODE_EHFC		BIT(7)
 
-#define MTL_OP_MODE_RTC_MASK		0x18
-#define MTL_OP_MODE_RTC_SHIFT		3
+#define MTL_OP_MODE_RTC_MASK		GENMASK(1, 0)
+#define MTL_OP_MODE_RTC_SHIFT		0
 
 #define MTL_OP_MODE_RTC_32		(1 << MTL_OP_MODE_RTC_SHIFT)
 #define MTL_OP_MODE_RTC_64		0