* [PATCH net-next v3 1/5] dt-bindings: net: Add Maxio MAE0621A PHY
2026-09-26 22:56 [PATCH net-next v3 0/5] net: phy: Add Maxio MAE0621A support Andre Przywara
@ 2026-09-26 22:56 ` Andre Przywara
2026-09-26 22:56 ` [PATCH net-next v3 2/5] net: phy: Add support for the Maxio MAE0621A Andre Przywara
` (3 subsequent siblings)
4 siblings, 0 replies; 10+ messages in thread
From: Andre Przywara @ 2026-09-26 22:56 UTC (permalink / raw)
To: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King
Cc: Junhui Liu, Liu Changjie, Per Larsson, netdev, devicetree, linux-kernel
From: Liu Changjie <liucj1228@outlook.com>
Document the MAE0621A PHY IDs (for the -Q2C and -Q3C variants) and their
optional 125 MHz CLKOUT setting. Boards which do not provide the property
retain the hardware strap or bootloader configuration.
Only the 125 MHz setting is exposed because it is the only setting
exercised on hardware.
Signed-off-by: Liu Changjie <liucj1228@outlook.com>
[Andre: Add PHY-ID for -Q2C variant]
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
---
.../bindings/net/maxio,mae0621a.yaml | 40 +++++++++++++++++++
.../devicetree/bindings/vendor-prefixes.yaml | 2 +
2 files changed, 42 insertions(+)
create mode 100644 Documentation/devicetree/bindings/net/maxio,mae0621a.yaml
diff --git a/Documentation/devicetree/bindings/net/maxio,mae0621a.yaml b/Documentation/devicetree/bindings/net/maxio,mae0621a.yaml
new file mode 100644
index 0000000000000..c4d06c6261681
--- /dev/null
+++ b/Documentation/devicetree/bindings/net/maxio,mae0621a.yaml
@@ -0,0 +1,40 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/net/maxio,mae0621a.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Maxio MAE0621A Ethernet PHY
+
+maintainers:
+ - Liu Changjie <liucj1228@outlook.com>
+
+allOf:
+ - $ref: ethernet-phy.yaml#
+
+properties:
+ compatible:
+ enum:
+ - ethernet-phy-id7b74.4411
+ - ethernet-phy-id7b74.4412
+
+ maxio,clk-out-frequency-hz:
+ description:
+ Selects a 125 MHz clock on the CLKOUT pin. If the property is absent,
+ the hardware strap or bootloader configuration is preserved.
+ const: 125000000
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ mdio {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ ethernet-phy@1 {
+ compatible = "ethernet-phy-id7b74.4412";
+ reg = <1>;
+ maxio,clk-out-frequency-hz = <125000000>;
+ };
+ };
diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
index ba20029693734..8ea4d421719b0 100644
--- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
+++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
@@ -1035,6 +1035,8 @@ patternProperties:
description: MaxBotix Inc.
"^maxim,.*":
description: Maxim Integrated Products
+ "^maxio,.*":
+ description: Maxio Technology (Hangzhou) Co., Ltd.
"^maxlinear,.*":
description: MaxLinear Inc.
"^maxtor,.*":
--
2.46.4
^ permalink raw reply [flat|nested] 10+ messages in thread* [PATCH net-next v3 2/5] net: phy: Add support for the Maxio MAE0621A
2026-09-26 22:56 [PATCH net-next v3 0/5] net: phy: Add Maxio MAE0621A support Andre Przywara
2026-09-26 22:56 ` [PATCH net-next v3 1/5] dt-bindings: net: Add Maxio MAE0621A PHY Andre Przywara
@ 2026-09-26 22:56 ` Andre Przywara
2026-09-27 17:23 ` Andrew Lunn
2026-09-26 22:56 ` [PATCH net-next v3 3/5] net: phy: maxio: prepare for more DT properties Andre Przywara
` (2 subsequent siblings)
4 siblings, 1 reply; 10+ messages in thread
From: Andre Przywara @ 2026-09-26 22:56 UTC (permalink / raw)
To: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King
Cc: Junhui Liu, Liu Changjie, Per Larsson, netdev, devicetree, linux-kernel
From: Liu Changjie <liucj1228@outlook.com>
Add exact PHY ID matching and optional 125 MHz CLKOUT configuration
for the Maxio MAE0621A Gigabit Ethernet PHY. Preserve the existing
hardware configuration when the firmware property is absent.
Signed-off-by: Liu Changjie <liucj1228@outlook.com>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
---
drivers/net/phy/Kconfig | 8 +++
drivers/net/phy/Makefile | 1 +
drivers/net/phy/maxio.c | 103 +++++++++++++++++++++++++++++++++++++++
3 files changed, 112 insertions(+)
create mode 100644 drivers/net/phy/maxio.c
diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index b4ef927fd4a67..eb40276113a57 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -298,6 +298,14 @@ config MARVELL_88X2222_PHY
Support for the Marvell 88X2222 Dual-port Multi-speed Ethernet
Transceiver.
+config MAXIO_PHY
+ tristate "Maxio Ethernet PHYs"
+ help
+ Support for Maxio Ethernet PHYs. Currently this driver supports the
+ MAE0621A Gigabit Ethernet PHY. The driver optionally selects a 125 MHz
+ clock on the CLKOUT pin while preserving the hardware configuration on
+ boards which do not request it.
+
config MAXLINEAR_GPHY
tristate "Maxlinear Ethernet PHYs"
select POLYNOMIAL if HWMON
diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
index 25c4a3c2429f7..9730b8a6fa5b0 100644
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
@@ -72,6 +72,7 @@ obj-$(CONFIG_MARVELL_10G_PHY) += marvell10g.o
obj-$(CONFIG_MARVELL_PHY) += marvell.o
obj-$(CONFIG_MARVELL_88Q2XXX_PHY) += marvell-88q2xxx.o
obj-$(CONFIG_MARVELL_88X2222_PHY) += marvell-88x2222.o
+obj-$(CONFIG_MAXIO_PHY) += maxio.o
obj-$(CONFIG_MAXLINEAR_GPHY) += mxl-gpy.o
obj-$(CONFIG_MAXLINEAR_86110_PHY) += mxl-86110.o
obj-y += mediatek/
diff --git a/drivers/net/phy/maxio.c b/drivers/net/phy/maxio.c
new file mode 100644
index 0000000000000..d2cb238956460
--- /dev/null
+++ b/drivers/net/phy/maxio.c
@@ -0,0 +1,103 @@
+// SPDX-License-Identifier: GPL-2.0-only
+/* Driver for Maxio Ethernet PHYs. */
+
+#include <linux/bitops.h>
+#include <linux/module.h>
+#include <linux/phy.h>
+#include <linux/property.h>
+
+#define MAXIO_MAE0621A_PHY_ID 0x7b744412
+
+#define MAXIO_PAGE_SELECT 0x1f
+#define MAXIO_MAE0621A_PHYCR2_PAGE 0xa43
+#define MAXIO_MAE0621A_PHYCR2 0x19
+#define MAXIO_MAE0621A_CLKOUT_125M BIT(11)
+#define MAXIO_MAE0621A_CLKOUT_ENABLE BIT(0)
+
+struct maxio_priv {
+ bool clk_out_125m;
+};
+
+static int maxio_read_page(struct phy_device *phydev)
+{
+ return __phy_read(phydev, MAXIO_PAGE_SELECT);
+}
+
+static int maxio_write_page(struct phy_device *phydev, int page)
+{
+ return __phy_write(phydev, MAXIO_PAGE_SELECT, page);
+}
+
+static int maxio_mae0621a_probe(struct phy_device *phydev)
+{
+ struct device *dev = &phydev->mdio.dev;
+ struct maxio_priv *priv;
+ u32 frequency;
+ int ret;
+
+ priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
+ if (!priv)
+ return -ENOMEM;
+
+ phydev->priv = priv;
+
+ ret = device_property_read_u32(dev, "maxio,clk-out-frequency-hz",
+ &frequency);
+ if (ret == -EINVAL)
+ return 0;
+ if (ret)
+ return ret;
+
+ if (frequency != 125000000) {
+ phydev_err(phydev, "invalid CLKOUT frequency %u\n", frequency);
+ return -EINVAL;
+ }
+
+ priv->clk_out_125m = true;
+
+ return 0;
+}
+
+static int maxio_mae0621a_config_init(struct phy_device *phydev)
+{
+ struct maxio_priv *priv = phydev->priv;
+ int ret;
+
+ if (!priv->clk_out_125m)
+ return 0;
+
+ ret = phy_modify_paged_changed(phydev, MAXIO_MAE0621A_PHYCR2_PAGE,
+ MAXIO_MAE0621A_PHYCR2,
+ MAXIO_MAE0621A_CLKOUT_ENABLE |
+ MAXIO_MAE0621A_CLKOUT_125M,
+ MAXIO_MAE0621A_CLKOUT_ENABLE |
+ MAXIO_MAE0621A_CLKOUT_125M);
+ if (ret <= 0)
+ return ret;
+
+ return genphy_soft_reset(phydev);
+}
+
+static struct phy_driver maxio_drivers[] = {
+ {
+ PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_PHY_ID),
+ .name = "Maxio MAE0621A",
+ .probe = maxio_mae0621a_probe,
+ .config_init = maxio_mae0621a_config_init,
+ .suspend = genphy_suspend,
+ .resume = genphy_resume,
+ .read_page = maxio_read_page,
+ .write_page = maxio_write_page,
+ },
+};
+module_phy_driver(maxio_drivers);
+
+static const struct mdio_device_id __maybe_unused maxio_tbl[] = {
+ { PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_PHY_ID) },
+ { }
+};
+MODULE_DEVICE_TABLE(mdio, maxio_tbl);
+
+MODULE_AUTHOR("Liu Changjie <liucj1228@outlook.com>");
+MODULE_DESCRIPTION("Maxio Ethernet PHY driver");
+MODULE_LICENSE("GPL");
--
2.46.4
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH net-next v3 2/5] net: phy: Add support for the Maxio MAE0621A
2026-09-26 22:56 ` [PATCH net-next v3 2/5] net: phy: Add support for the Maxio MAE0621A Andre Przywara
@ 2026-09-27 17:23 ` Andrew Lunn
0 siblings, 0 replies; 10+ messages in thread
From: Andrew Lunn @ 2026-09-27 17:23 UTC (permalink / raw)
To: Andre Przywara
Cc: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King, Junhui Liu, Liu Changjie,
Per Larsson, netdev, devicetree, linux-kernel
On Sun, Sep 27, 2026 at 12:56:22AM +0200, Andre Przywara wrote:
> From: Liu Changjie <liucj1228@outlook.com>
>
> Add exact PHY ID matching and optional 125 MHz CLKOUT configuration
> for the Maxio MAE0621A Gigabit Ethernet PHY. Preserve the existing
> hardware configuration when the firmware property is absent.
>
> Signed-off-by: Liu Changjie <liucj1228@outlook.com>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>
I sent a follow up email saying i was withdrawing this
Reviewed-by. Please ensure it has been dropped for the moment.
pw-bot: cr
This is an RGMII PHY. However it totally ignores phydev->interface.
There are four values which we require the PHY driver to act on:
PHY_INTERFACE_MODE_RGMII,
PHY_INTERFACE_MODE_RGMII_ID,
PHY_INTERFACE_MODE_RGMII_RXID,
PHY_INTERFACE_MODE_RGMII_TXID,
Every other RGMII PHY in linux will configure the delays based on
these values. If these values are ignored, bad things will happen.
From what i understand, the delays are currently configured by
strapping. We are going to get into situations where the strapping and
what the MAC requests are different but no errors are reported. DT
developers are already bad with RGMII delays, and this is just going
to make it worse.
So you have some choices:
1) Implement configuring the delays in the PHY driver
2) Find out how the delays are currently configured and return
EOPNOTSUPP if the requested configuration is different to the
current configuration.
3) Always return EOPNOTSUPP for all the RGMII values, and only accept
PHY_INTERFACE_MODE_NA, which means configuration has been performed
using some other mechanism, the PHY driver should not change it.
Additionally, my understanding is this PHY will respond to address 0
as a broadcast address. This is not part of 802.3, and always causes
issues. Please ensure this is turned off.
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH net-next v3 3/5] net: phy: maxio: prepare for more DT properties
2026-09-26 22:56 [PATCH net-next v3 0/5] net: phy: Add Maxio MAE0621A support Andre Przywara
2026-09-26 22:56 ` [PATCH net-next v3 1/5] dt-bindings: net: Add Maxio MAE0621A PHY Andre Przywara
2026-09-26 22:56 ` [PATCH net-next v3 2/5] net: phy: Add support for the Maxio MAE0621A Andre Przywara
@ 2026-09-26 22:56 ` Andre Przywara
2026-09-27 17:31 ` Andrew Lunn
2026-09-26 22:56 ` [PATCH net-next v3 4/5] net: phy: maxio: parse and enable PHY clock from generic DT binding Andre Przywara
2026-09-26 22:56 ` [PATCH net-next v3 5/5] net: phy: maxio: add support for -Q2C variant Andre Przywara
4 siblings, 1 reply; 10+ messages in thread
From: Andre Przywara @ 2026-09-26 22:56 UTC (permalink / raw)
To: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King
Cc: Junhui Liu, Liu Changjie, Per Larsson, netdev, devicetree, linux-kernel
The probe routine for the Maxio PHY returns early if the optional
maxio,clk-out-frequency-hz property is not found. That prevents looking
for other properties.
Refactor the routine to handle the property in an if-clause, to allow
more actions in the probe routine later.
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
drivers/net/phy/maxio.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)
diff --git a/drivers/net/phy/maxio.c b/drivers/net/phy/maxio.c
index d2cb238956460..9ba82c1cd8b13 100644
--- a/drivers/net/phy/maxio.c
+++ b/drivers/net/phy/maxio.c
@@ -43,18 +43,20 @@ static int maxio_mae0621a_probe(struct phy_device *phydev)
ret = device_property_read_u32(dev, "maxio,clk-out-frequency-hz",
&frequency);
- if (ret == -EINVAL)
- return 0;
- if (ret)
- return ret;
-
- if (frequency != 125000000) {
- phydev_err(phydev, "invalid CLKOUT frequency %u\n", frequency);
- return -EINVAL;
+ if (ret) {
+ /* the property is optional, so ignore -EINVAL */
+ if (ret != -EINVAL)
+ return ret;
+ } else {
+ if (frequency != 125000000) {
+ phydev_err(phydev, "invalid CLKOUT frequency %u\n",
+ frequency);
+ return -EINVAL;
+ }
+
+ priv->clk_out_125m = true;
}
- priv->clk_out_125m = true;
-
return 0;
}
--
2.46.4
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH net-next v3 3/5] net: phy: maxio: prepare for more DT properties
2026-09-26 22:56 ` [PATCH net-next v3 3/5] net: phy: maxio: prepare for more DT properties Andre Przywara
@ 2026-09-27 17:31 ` Andrew Lunn
0 siblings, 0 replies; 10+ messages in thread
From: Andrew Lunn @ 2026-09-27 17:31 UTC (permalink / raw)
To: Andre Przywara
Cc: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King, Junhui Liu, Liu Changjie,
Per Larsson, netdev, devicetree, linux-kernel
On Sun, Sep 27, 2026 at 12:56:23AM +0200, Andre Przywara wrote:
> The probe routine for the Maxio PHY returns early if the optional
> maxio,clk-out-frequency-hz property is not found. That prevents looking
> for other properties.
>
> Refactor the routine to handle the property in an if-clause, to allow
> more actions in the probe routine later.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH net-next v3 4/5] net: phy: maxio: parse and enable PHY clock from generic DT binding
2026-09-26 22:56 [PATCH net-next v3 0/5] net: phy: Add Maxio MAE0621A support Andre Przywara
` (2 preceding siblings ...)
2026-09-26 22:56 ` [PATCH net-next v3 3/5] net: phy: maxio: prepare for more DT properties Andre Przywara
@ 2026-09-26 22:56 ` Andre Przywara
2026-09-27 17:29 ` Andrew Lunn
2026-09-26 22:56 ` [PATCH net-next v3 5/5] net: phy: maxio: add support for -Q2C variant Andre Przywara
4 siblings, 1 reply; 10+ messages in thread
From: Andre Przywara @ 2026-09-26 22:56 UTC (permalink / raw)
To: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King
Cc: Junhui Liu, Liu Changjie, Per Larsson, netdev, devicetree, linux-kernel
The generic PHY DT binding features a clocks property, which describes
the clock input to the PHY. Typically this is a crystal oscillator, so
it works without software interaction. But some boards want to save some
pennies on that part, and let a clock fanout pin from the SoC provide this
clock signal. In this case the PHY probe routine needs to enable this
clock explicitly.
Look for a "clocks" property inside the PHY node and enable that clock,
if one is provided.
This allows boards with a SoC-driven PHY clock to use the PHY. Please
note that without the clock enabled, the PHY will not be detected on the
MDIO bus, so the PHY-ID needs to be explicitly named in the PHY
compatible string:
compatible = "ethernet-phy-id7b74.4411";
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
drivers/net/phy/maxio.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/net/phy/maxio.c b/drivers/net/phy/maxio.c
index 9ba82c1cd8b13..266be95b949a8 100644
--- a/drivers/net/phy/maxio.c
+++ b/drivers/net/phy/maxio.c
@@ -2,6 +2,7 @@
/* Driver for Maxio Ethernet PHYs. */
#include <linux/bitops.h>
+#include <linux/clk.h>
#include <linux/module.h>
#include <linux/phy.h>
#include <linux/property.h>
@@ -15,6 +16,7 @@
#define MAXIO_MAE0621A_CLKOUT_ENABLE BIT(0)
struct maxio_priv {
+ struct clk *clk;
bool clk_out_125m;
};
@@ -57,6 +59,11 @@ static int maxio_mae0621a_probe(struct phy_device *phydev)
priv->clk_out_125m = true;
}
+ /* PHY clock from the generic PHY binding */
+ priv->clk = devm_clk_get_optional_enabled(&phydev->mdio.dev, NULL);
+ if (IS_ERR(priv->clk))
+ return PTR_ERR(priv->clk);
+
return 0;
}
--
2.46.4
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH net-next v3 4/5] net: phy: maxio: parse and enable PHY clock from generic DT binding
2026-09-26 22:56 ` [PATCH net-next v3 4/5] net: phy: maxio: parse and enable PHY clock from generic DT binding Andre Przywara
@ 2026-09-27 17:29 ` Andrew Lunn
0 siblings, 0 replies; 10+ messages in thread
From: Andrew Lunn @ 2026-09-27 17:29 UTC (permalink / raw)
To: Andre Przywara
Cc: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King, Junhui Liu, Liu Changjie,
Per Larsson, netdev, devicetree, linux-kernel
> struct maxio_priv {
> + struct clk *clk;
> bool clk_out_125m;
> };
>
> @@ -57,6 +59,11 @@ static int maxio_mae0621a_probe(struct phy_device *phydev)
> priv->clk_out_125m = true;
> }
>
> + /* PHY clock from the generic PHY binding */
> + priv->clk = devm_clk_get_optional_enabled(&phydev->mdio.dev, NULL);
> + if (IS_ERR(priv->clk))
> + return PTR_ERR(priv->clk);
Since clk is not referenced anywhere after this, there is no need to
save it in priv.
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread
* [PATCH net-next v3 5/5] net: phy: maxio: add support for -Q2C variant
2026-09-26 22:56 [PATCH net-next v3 0/5] net: phy: Add Maxio MAE0621A support Andre Przywara
` (3 preceding siblings ...)
2026-09-26 22:56 ` [PATCH net-next v3 4/5] net: phy: maxio: parse and enable PHY clock from generic DT binding Andre Przywara
@ 2026-09-26 22:56 ` Andre Przywara
2026-09-27 17:31 ` Andrew Lunn
4 siblings, 1 reply; 10+ messages in thread
From: Andre Przywara @ 2026-09-26 22:56 UTC (permalink / raw)
To: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King
Cc: Junhui Liu, Liu Changjie, Per Larsson, netdev, devicetree, linux-kernel
Currently the maxio Ethernet PHY driver expects a Maxio MAE0621A-Q3C PHY
matching exactly the one ID provided: 0x7b744412. There exist an earlier
variant of the PHY, still used on some devices, its label differs by using
the -Q2C suffix, and its PHY ID is 0x7b744411.
Some vendor drivers floating around in the web suggest they are somewhat
different, although for now this driver does not deal with any of those
registers, and the 125M clock switch is identical between the two.
Nevertheless prepare for future driver divergence by describing two
drivers, although using the same functions for now.
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
---
drivers/net/phy/maxio.c | 20 ++++++++++++++++----
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/drivers/net/phy/maxio.c b/drivers/net/phy/maxio.c
index 266be95b949a8..8c33c8433b127 100644
--- a/drivers/net/phy/maxio.c
+++ b/drivers/net/phy/maxio.c
@@ -7,7 +7,8 @@
#include <linux/phy.h>
#include <linux/property.h>
-#define MAXIO_MAE0621A_PHY_ID 0x7b744412
+#define MAXIO_MAE0621A_Q2C_PHY_ID 0x7b744411
+#define MAXIO_MAE0621A_Q3C_PHY_ID 0x7b744412
#define MAXIO_PAGE_SELECT 0x1f
#define MAXIO_MAE0621A_PHYCR2_PAGE 0xa43
@@ -89,8 +90,18 @@ static int maxio_mae0621a_config_init(struct phy_device *phydev)
static struct phy_driver maxio_drivers[] = {
{
- PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_PHY_ID),
- .name = "Maxio MAE0621A",
+ PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_Q2C_PHY_ID),
+ .name = "Maxio MAE0621A-Q2C",
+ .probe = maxio_mae0621a_probe,
+ .config_init = maxio_mae0621a_config_init,
+ .suspend = genphy_suspend,
+ .resume = genphy_resume,
+ .read_page = maxio_read_page,
+ .write_page = maxio_write_page,
+ },
+ {
+ PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_Q3C_PHY_ID),
+ .name = "Maxio MAE0621A-Q3C",
.probe = maxio_mae0621a_probe,
.config_init = maxio_mae0621a_config_init,
.suspend = genphy_suspend,
@@ -102,7 +113,8 @@ static struct phy_driver maxio_drivers[] = {
module_phy_driver(maxio_drivers);
static const struct mdio_device_id __maybe_unused maxio_tbl[] = {
- { PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_PHY_ID) },
+ { PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_Q2C_PHY_ID) },
+ { PHY_ID_MATCH_EXACT(MAXIO_MAE0621A_Q3C_PHY_ID) },
{ }
};
MODULE_DEVICE_TABLE(mdio, maxio_tbl);
--
2.46.4
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH net-next v3 5/5] net: phy: maxio: add support for -Q2C variant
2026-09-26 22:56 ` [PATCH net-next v3 5/5] net: phy: maxio: add support for -Q2C variant Andre Przywara
@ 2026-09-27 17:31 ` Andrew Lunn
0 siblings, 0 replies; 10+ messages in thread
From: Andrew Lunn @ 2026-09-27 17:31 UTC (permalink / raw)
To: Andre Przywara
Cc: Andrew Lunn, David S . Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
Heiner Kallweit, Russell King, Junhui Liu, Liu Changjie,
Per Larsson, netdev, devicetree, linux-kernel
On Sun, Sep 27, 2026 at 12:56:25AM +0200, Andre Przywara wrote:
> Currently the maxio Ethernet PHY driver expects a Maxio MAE0621A-Q3C PHY
> matching exactly the one ID provided: 0x7b744412. There exist an earlier
> variant of the PHY, still used on some devices, its label differs by using
> the -Q2C suffix, and its PHY ID is 0x7b744411.
>
> Some vendor drivers floating around in the web suggest they are somewhat
> different, although for now this driver does not deal with any of those
> registers, and the 125M clock switch is identical between the two.
> Nevertheless prepare for future driver divergence by describing two
> drivers, although using the same functions for now.
>
> Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Andrew
^ permalink raw reply [flat|nested] 10+ messages in thread