* [PATCH net-next] net: phy: realtek: replace magic number with register bit macros
@ 2026-04-26 22:23 Aleksander Jan Bajkowski
2026-04-27 23:26 ` Jakub Kicinski
0 siblings, 1 reply; 2+ messages in thread
From: Aleksander Jan Bajkowski @ 2026-04-26 22:23 UTC (permalink / raw)
To: andrew, hkallweit1, linux, davem, edumazet, kuba, pabeni, daniel,
vladimir.oltean, michael, olek2, ih, rmk+kernel, marek.vasut,
netdev, linux-kernel
Replace magic number with register bit macros. The description of the
RTL8211B interrupt register is obtained from the datasheet.
1. RTL8211B(L) Rev. 1.5 Datasheet
Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
---
drivers/net/phy/realtek/realtek_main.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/net/phy/realtek/realtek_main.c b/drivers/net/phy/realtek/realtek_main.c
index 79c867ef64da..9f2a0bc03728 100644
--- a/drivers/net/phy/realtek/realtek_main.c
+++ b/drivers/net/phy/realtek/realtek_main.c
@@ -40,7 +40,12 @@
RTL8201F_ISR_LINK)
#define RTL821x_INER 0x12
-#define RTL8211B_INER_INIT 0x6400
+#define RTL8211B_INER_SPEED BIT(14)
+#define RTL8211B_INER_DUPLEX BIT(13)
+#define RTL8211B_INER_LINK_STATUS BIT(10)
+#define RTL8211B_INER_INIT (RTL8211B_INER_SPEED | \
+ RTL8211B_INER_DUPLEX | \
+ RTL8211B_INER_LINK_STATUS)
#define RTL8211E_INER_LINK_STATUS BIT(10)
#define RTL8211F_INER_PME BIT(7)
#define RTL8211F_INER_LINK_STATUS BIT(4)
--
2.53.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] net: phy: realtek: replace magic number with register bit macros
2026-04-26 22:23 [PATCH net-next] net: phy: realtek: replace magic number with register bit macros Aleksander Jan Bajkowski
@ 2026-04-27 23:26 ` Jakub Kicinski
0 siblings, 0 replies; 2+ messages in thread
From: Jakub Kicinski @ 2026-04-27 23:26 UTC (permalink / raw)
To: Aleksander Jan Bajkowski
Cc: andrew, hkallweit1, linux, davem, edumazet, pabeni, daniel,
vladimir.oltean, michael, ih, rmk+kernel, marek.vasut, netdev,
linux-kernel
On Mon, 27 Apr 2026 00:23:44 +0200 Aleksander Jan Bajkowski wrote:
> Replace magic number with register bit macros. The description of the
> RTL8211B interrupt register is obtained from the datasheet.
net-next wasn't open yet, when you posted.
Please resubmit in a couple of days.
--
pw-bot: defer
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-04-27 23:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-26 22:23 [PATCH net-next] net: phy: realtek: replace magic number with register bit macros Aleksander Jan Bajkowski
2026-04-27 23:26 ` Jakub Kicinski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox