From: "Russell King (Oracle)" <rmk+kernel@armlinux.org.uk>
To: Andrew Lunn <andrew@lunn.ch>, Heiner Kallweit <hkallweit1@gmail.com>
Cc: Alexandre Torgue <alexandre.torgue@foss.st.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
AngeloGioacchino Del Regno
<angelogioacchino.delregno@collabora.com>,
"David S. Miller" <davem@davemloft.net>,
Emil Renner Berthing <kernel@esmil.dk>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>,
Keguang Zhang <keguang.zhang@gmail.com>,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, linux-mips@vger.kernel.org,
linux-stm32@st-md-mailman.stormreply.com,
Matthias Brugger <matthias.bgg@gmail.com>,
Maxime Coquelin <mcoquelin.stm32@gmail.com>,
Minda Chen <minda.chen@starfivetech.com>,
netdev@vger.kernel.org,
Nobuhiro Iwamatsu <nobuhiro.iwamatsu.x90@mail.toshiba>,
Paolo Abeni <pabeni@redhat.com>
Subject: [PATCH net-next v2 12/13] net: stmmac: visconti: use PHY_INTF_SEL_x to select PHY interface
Date: Tue, 11 Nov 2025 08:12:43 +0000 [thread overview]
Message-ID: <E1vIjUZ-0000000Dqu5-2sDI@rmk-PC.armlinux.org.uk> (raw)
In-Reply-To: <aRLvrfx6tOa-RhrY@shell.armlinux.org.uk>
Convert dwmac-visconti to use the PHY_INTF_SEL_x definitions. The
original definitions used constant 0, BIT(0) (==1) and BIT(2) (==4)
to define these, but the values of the bits corresponds with the
PHY_INTF_SEL_x values, so it is highly likely that these are not
individual bits, but the PHY_INTF_SEL_x bitfield.
This removes this incorrect use of BIT().
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
---
drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c
index bd65d4239054..7b6b048e1be0 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-visconti.c
@@ -42,9 +42,9 @@
#define ETHER_CLK_SEL_RX_TX_CLK_EN (ETHER_CLK_SEL_RX_CLK_EN | ETHER_CLK_SEL_TX_CLK_EN)
-#define ETHER_CONFIG_INTF_MII 0
-#define ETHER_CONFIG_INTF_RGMII BIT(0)
-#define ETHER_CONFIG_INTF_RMII BIT(2)
+#define ETHER_CONFIG_INTF_MII PHY_INTF_SEL_GMII_MII
+#define ETHER_CONFIG_INTF_RGMII PHY_INTF_SEL_RGMII
+#define ETHER_CONFIG_INTF_RMII PHY_INTF_SEL_RMII
struct visconti_eth {
void __iomem *reg;
--
2.47.3
next prev parent reply other threads:[~2025-11-11 8:13 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-11 8:11 [PATCH net-next v2 00/13] net: stmmac: convert glue drivers to use stmmac_get_phy_intf_sel() Russell King (Oracle)
2025-11-11 8:11 ` [PATCH net-next v2 01/13] net: stmmac: loongson1: use PHY_INTF_SEL_x Russell King (Oracle)
2025-11-12 15:46 ` Maxime Chevallier
2025-11-11 8:11 ` [PATCH net-next v2 02/13] net: stmmac: loongson1: use PHY_INTF_SEL_x directly Russell King (Oracle)
2025-11-12 15:47 ` Maxime Chevallier
2025-11-11 8:11 ` [PATCH net-next v2 03/13] net: stmmac: loongson1: use stmmac_get_phy_intf_sel() Russell King (Oracle)
2025-11-12 15:47 ` Maxime Chevallier
2025-11-11 8:12 ` [PATCH net-next v2 04/13] net: stmmac: mediatek: use PHY_INTF_SEL_x Russell King (Oracle)
2025-11-12 15:48 ` Maxime Chevallier
2025-11-11 8:12 ` [PATCH net-next v2 05/13] net: stmmac: mediatek: use stmmac_get_phy_intf_sel() Russell King (Oracle)
2025-11-12 15:50 ` Maxime Chevallier
2025-11-11 8:12 ` [PATCH net-next v2 06/13] net: stmmac: mediatek: simplify set_interface() methods Russell King (Oracle)
2025-11-12 15:52 ` Maxime Chevallier
2025-11-11 8:12 ` [PATCH net-next v2 07/13] net: stmmac: starfive: use PHY_INTF_SEL_x to select PHY interface Russell King (Oracle)
2025-11-12 11:42 ` Emil Renner Berthing
2025-11-11 8:12 ` [PATCH net-next v2 08/13] net: stmmac: starfive: use stmmac_get_phy_intf_sel() Russell King (Oracle)
2025-11-12 11:43 ` Emil Renner Berthing
2025-11-11 8:12 ` [PATCH net-next v2 09/13] net: stmmac: stm32: use PHY_INTF_SEL_x to select PHY interface Russell King (Oracle)
2025-11-11 8:12 ` [PATCH net-next v2 10/13] net: stmmac: stm32: use PHY_INTF_SEL_x directly Russell King (Oracle)
2025-11-11 8:12 ` [PATCH net-next v2 11/13] net: stmmac: stm32: use stmmac_get_phy_intf_sel() Russell King (Oracle)
2025-11-11 8:12 ` Russell King (Oracle) [this message]
2025-11-11 8:12 ` [PATCH net-next v2 13/13] net: stmmac: visconti: " Russell King (Oracle)
2025-11-13 2:20 ` [PATCH net-next v2 00/13] net: stmmac: convert glue drivers to " patchwork-bot+netdevbpf
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=E1vIjUZ-0000000Dqu5-2sDI@rmk-PC.armlinux.org.uk \
--to=rmk+kernel@armlinux.org.uk \
--cc=alexandre.torgue@foss.st.com \
--cc=andrew+netdev@lunn.ch \
--cc=andrew@lunn.ch \
--cc=angelogioacchino.delregno@collabora.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=keguang.zhang@gmail.com \
--cc=kernel@esmil.dk \
--cc=kuba@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-mips@vger.kernel.org \
--cc=linux-stm32@st-md-mailman.stormreply.com \
--cc=matthias.bgg@gmail.com \
--cc=mcoquelin.stm32@gmail.com \
--cc=minda.chen@starfivetech.com \
--cc=netdev@vger.kernel.org \
--cc=nobuhiro.iwamatsu.x90@mail.toshiba \
--cc=pabeni@redhat.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).