linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver
@ 2020-02-21 13:28 Ansuel Smith
  2020-02-21 13:28 ` [PATCH v4 2/2] Documentation: devictree: Add ipq806x mdio bindings Ansuel Smith
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Ansuel Smith @ 2020-02-21 13:28 UTC (permalink / raw)
  Cc: Ansuel Smith, Andy Gross, Bjorn Andersson, David S. Miller,
	Rob Herring, Mark Rutland, Andrew Lunn, Florian Fainelli,
	Heiner Kallweit, Russell King, linux-arm-msm, netdev, devicetree,
	linux-kernel

Currently ipq806x soc use generi bitbang driver to
comunicate with the gmac ethernet interface.
Add a dedicated driver created by chunkeey to fix this.

Christian Lamparter <chunkeey@gmail.com>
Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
---
 drivers/net/phy/Kconfig        |   8 ++
 drivers/net/phy/Makefile       |   1 +
 drivers/net/phy/mdio-ipq8064.c | 166 +++++++++++++++++++++++++++++++++
 3 files changed, 175 insertions(+)
 create mode 100644 drivers/net/phy/mdio-ipq8064.c

diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index 9dabe03a668c..ec2a5493a7e8 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -157,6 +157,14 @@ config MDIO_I2C
 
 	  This is library mode.
 
+config MDIO_IPQ8064
+	tristate "Qualcomm IPQ8064 MDIO interface support"
+	depends on HAS_IOMEM && OF_MDIO
+	depends on MFD_SYSCON
+	help
+	  This driver supports the MDIO interface found in the network
+	  interface units of the IPQ8064 SoC
+
 config MDIO_MOXART
 	tristate "MOXA ART MDIO interface support"
 	depends on ARCH_MOXART || COMPILE_TEST
diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
index fe5badf13b65..8f02bd2089f3 100644
--- a/drivers/net/phy/Makefile
+++ b/drivers/net/phy/Makefile
@@ -36,6 +36,7 @@ obj-$(CONFIG_MDIO_CAVIUM)	+= mdio-cavium.o
 obj-$(CONFIG_MDIO_GPIO)		+= mdio-gpio.o
 obj-$(CONFIG_MDIO_HISI_FEMAC)	+= mdio-hisi-femac.o
 obj-$(CONFIG_MDIO_I2C)		+= mdio-i2c.o
+obj-$(CONFIG_MDIO_IPQ8064)	+= mdio-ipq8064.o
 obj-$(CONFIG_MDIO_MOXART)	+= mdio-moxart.o
 obj-$(CONFIG_MDIO_MSCC_MIIM)	+= mdio-mscc-miim.o
 obj-$(CONFIG_MDIO_OCTEON)	+= mdio-octeon.o
diff --git a/drivers/net/phy/mdio-ipq8064.c b/drivers/net/phy/mdio-ipq8064.c
new file mode 100644
index 000000000000..fd856b798194
--- /dev/null
+++ b/drivers/net/phy/mdio-ipq8064.c
@@ -0,0 +1,166 @@
+// SPDX-License-Identifier: GPL-2.0
+//
+// Qualcomm IPQ8064 MDIO interface driver
+//
+// Copyright (C) 2019 Christian Lamparter <chunkeey@gmail.com>
+
+#include <linux/delay.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/regmap.h>
+#include <linux/of_mdio.h>
+#include <linux/phy.h>
+#include <linux/platform_device.h>
+#include <linux/mfd/syscon.h>
+
+/* MII address register definitions */
+#define MII_ADDR_REG_ADDR                       0x10
+#define MII_BUSY                                BIT(0)
+#define MII_WRITE                               BIT(1)
+#define MII_CLKRANGE_60_100M                    (0 << 2)
+#define MII_CLKRANGE_100_150M                   (1 << 2)
+#define MII_CLKRANGE_20_35M                     (2 << 2)
+#define MII_CLKRANGE_35_60M                     (3 << 2)
+#define MII_CLKRANGE_150_250M                   (4 << 2)
+#define MII_CLKRANGE_250_300M                   (5 << 2)
+#define MII_CLKRANGE_MASK			GENMASK(4, 2)
+#define MII_REG_SHIFT				6
+#define MII_REG_MASK				GENMASK(10, 6)
+#define MII_ADDR_SHIFT				11
+#define MII_ADDR_MASK				GENMASK(15, 11)
+
+#define MII_DATA_REG_ADDR                       0x14
+
+#define MII_MDIO_DELAY                          (1000)
+#define MII_MDIO_RETRY                          (10)
+
+struct ipq8064_mdio {
+	struct regmap *base; /* NSS_GMAC0_BASE */
+};
+
+static int
+ipq8064_mdio_wait_busy(struct ipq8064_mdio *priv)
+{
+	u32 busy;
+
+	return regmap_read_poll_timeout(priv->base, MII_ADDR_REG_ADDR, busy,
+				   !(busy & MII_BUSY), MII_MDIO_DELAY,
+				   MII_MDIO_RETRY * USEC_PER_MSEC);
+}
+
+static int
+ipq8064_mdio_read(struct mii_bus *bus, int phy_addr, int reg_offset)
+{
+	struct ipq8064_mdio *priv = bus->priv;
+	u32 miiaddr = MII_BUSY | MII_CLKRANGE_250_300M;
+	u32 ret_val;
+	int err;
+
+	/* Reject clause 45 */
+	if (reg_offset & MII_ADDR_C45)
+		return -EOPNOTSUPP;
+
+	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
+		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
+
+	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
+	usleep_range(10, 20);
+
+	err = ipq8064_mdio_wait_busy(priv);
+	if (err)
+		return err;
+
+	regmap_read(priv->base, MII_DATA_REG_ADDR, &ret_val);
+	return (int)ret_val;
+}
+
+static int
+ipq8064_mdio_write(struct mii_bus *bus, int phy_addr, int reg_offset, u16 data)
+{
+	struct ipq8064_mdio *priv = bus->priv;
+	u32 miiaddr = MII_WRITE | MII_BUSY | MII_CLKRANGE_250_300M;
+
+	/* Reject clause 45 */
+	if (reg_offset & MII_ADDR_C45)
+		return -EOPNOTSUPP;
+
+	regmap_write(priv->base, MII_DATA_REG_ADDR, data);
+
+	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
+		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
+
+	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
+	usleep_range(10, 20);
+
+	return ipq8064_mdio_wait_busy(priv);
+}
+
+static int
+ipq8064_mdio_probe(struct platform_device *pdev)
+{
+	struct device_node *np = pdev->dev.of_node;
+	struct ipq8064_mdio *priv;
+	struct mii_bus *bus;
+	int ret;
+
+	bus = devm_mdiobus_alloc_size(&pdev->dev, sizeof(*priv));
+	if (!bus)
+		return -ENOMEM;
+
+	bus->name = "ipq8064_mdio_bus";
+	bus->read = ipq8064_mdio_read;
+	bus->write = ipq8064_mdio_write;
+	snprintf(bus->id, MII_BUS_ID_SIZE, "%s-mii", dev_name(&pdev->dev));
+	bus->parent = &pdev->dev;
+
+	priv = bus->priv;
+	priv->base = syscon_node_to_regmap(np);
+	if (IS_ERR(priv->base) && priv->base != ERR_PTR(-EPROBE_DEFER))
+		priv->base = syscon_regmap_lookup_by_phandle(np, "master");
+
+	if (priv->base == ERR_PTR(-EPROBE_DEFER)) {
+		return -EPROBE_DEFER;
+	} else if (IS_ERR(priv->base)) {
+		dev_err(&pdev->dev, "error getting syscon regmap, error=%ld\n",
+			PTR_ERR(priv->base));
+		return PTR_ERR(priv->base);
+	}
+
+	ret = of_mdiobus_register(bus, np);
+	if (ret)
+		return ret;
+
+	platform_set_drvdata(pdev, bus);
+	return 0;
+}
+
+static int
+ipq8064_mdio_remove(struct platform_device *pdev)
+{
+	struct mii_bus *bus = platform_get_drvdata(pdev);
+
+	mdiobus_unregister(bus);
+
+	return 0;
+}
+
+static const struct of_device_id ipq8064_mdio_dt_ids[] = {
+	{ .compatible = "qcom,ipq8064-mdio" },
+	{ }
+};
+MODULE_DEVICE_TABLE(of, ipq8064_mdio_dt_ids);
+
+static struct platform_driver ipq8064_mdio_driver = {
+	.probe = ipq8064_mdio_probe,
+	.remove = ipq8064_mdio_remove,
+	.driver = {
+		.name = "ipq8064-mdio",
+		.of_match_table = ipq8064_mdio_dt_ids,
+	},
+};
+
+module_platform_driver(ipq8064_mdio_driver);
+
+MODULE_DESCRIPTION("Qualcomm IPQ8064 MDIO interface driver");
+MODULE_AUTHOR("Christian Lamparter <chunkeey@gmail.com>");
+MODULE_LICENSE("GPL");
-- 
2.25.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH v4 2/2] Documentation: devictree: Add ipq806x mdio bindings
  2020-02-21 13:28 [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Ansuel Smith
@ 2020-02-21 13:28 ` Ansuel Smith
  2020-02-21 13:53 ` [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Russell King - ARM Linux admin
  2020-02-21 16:31 ` Florian Fainelli
  2 siblings, 0 replies; 6+ messages in thread
From: Ansuel Smith @ 2020-02-21 13:28 UTC (permalink / raw)
  Cc: Ansuel Smith, Andy Gross, Bjorn Andersson, David S. Miller,
	Rob Herring, Mark Rutland, Andrew Lunn, Florian Fainelli,
	Heiner Kallweit, Russell King, linux-arm-msm, netdev, devicetree,
	linux-kernel

Add documentations for ipq806x mdio driver.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
---
 .../bindings/net/qcom,ipq8064-mdio.yaml       | 55 +++++++++++++++++++
 1 file changed, 55 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/net/qcom,ipq8064-mdio.yaml

diff --git a/Documentation/devicetree/bindings/net/qcom,ipq8064-mdio.yaml b/Documentation/devicetree/bindings/net/qcom,ipq8064-mdio.yaml
new file mode 100644
index 000000000000..d2254a5ff2ad
--- /dev/null
+++ b/Documentation/devicetree/bindings/net/qcom,ipq8064-mdio.yaml
@@ -0,0 +1,55 @@
+# SPDX-License-Identifier: GPL-2.0-or-later
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/net/qcom,ipq8064-mdio.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm ipq806x MDIO bus controller
+
+maintainers:
+  - Ansuel Smith <ansuelsmth@gmail.com>
+
+description: |+
+  The ipq806x soc have a MDIO dedicated controller that is
+  used to comunicate with the gmac phy conntected.
+  Child nodes of this MDIO bus controller node are standard
+  Ethernet PHY device nodes as described in
+  Documentation/devicetree/bindings/net/phy.txt
+
+allOf:
+  - $ref: "mdio.yaml#"
+
+properties:
+  compatible:
+    const: qcom,ipq8064-mdio
+  reg:
+    maxItems: 1
+    description: address and length of the register set for the device
+  clocks:
+    maxItems: 1
+    description: A reference to the clock supplying the MDIO bus controller
+
+required:
+  - compatible
+  - reg
+  - clocks
+  - "#address-cells"
+  - "#size-cells"
+
+examples:
+  - |
+    mdio0: mdio@37000000 {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        compatible = "qcom,ipq8064-mdio", "syscon";
+        reg = <0x37000000 0x200000>;
+        resets = <&gcc GMAC_CORE1_RESET>;
+        reset-names = "stmmaceth";
+        clocks = <&gcc GMAC_CORE1_CLK>;
+
+        switch@10 {
+            compatible = "qca,qca8337";
+            ...
+        }
+    };
-- 
2.25.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver
  2020-02-21 13:28 [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Ansuel Smith
  2020-02-21 13:28 ` [PATCH v4 2/2] Documentation: devictree: Add ipq806x mdio bindings Ansuel Smith
@ 2020-02-21 13:53 ` Russell King - ARM Linux admin
  2020-02-21 13:58   ` R: " ansuelsmth
  2020-02-21 16:31 ` Florian Fainelli
  2 siblings, 1 reply; 6+ messages in thread
From: Russell King - ARM Linux admin @ 2020-02-21 13:53 UTC (permalink / raw)
  To: Ansuel Smith
  Cc: Andy Gross, Bjorn Andersson, David S. Miller, Rob Herring,
	Mark Rutland, Andrew Lunn, Florian Fainelli, Heiner Kallweit,
	linux-arm-msm, netdev, devicetree, linux-kernel

On Fri, Feb 21, 2020 at 02:28:31PM +0100, Ansuel Smith wrote:
> Currently ipq806x soc use generi bitbang driver to
> comunicate with the gmac ethernet interface.
> Add a dedicated driver created by chunkeey to fix this.
> 
> Christian Lamparter <chunkeey@gmail.com>
> Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
> ---
>  drivers/net/phy/Kconfig        |   8 ++
>  drivers/net/phy/Makefile       |   1 +
>  drivers/net/phy/mdio-ipq8064.c | 166 +++++++++++++++++++++++++++++++++
>  3 files changed, 175 insertions(+)
>  create mode 100644 drivers/net/phy/mdio-ipq8064.c
> 
> diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
> index 9dabe03a668c..ec2a5493a7e8 100644
> --- a/drivers/net/phy/Kconfig
> +++ b/drivers/net/phy/Kconfig
> @@ -157,6 +157,14 @@ config MDIO_I2C
>  
>  	  This is library mode.
>  
> +config MDIO_IPQ8064
> +	tristate "Qualcomm IPQ8064 MDIO interface support"
> +	depends on HAS_IOMEM && OF_MDIO
> +	depends on MFD_SYSCON
> +	help
> +	  This driver supports the MDIO interface found in the network
> +	  interface units of the IPQ8064 SoC
> +
>  config MDIO_MOXART
>  	tristate "MOXA ART MDIO interface support"
>  	depends on ARCH_MOXART || COMPILE_TEST
> diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
> index fe5badf13b65..8f02bd2089f3 100644
> --- a/drivers/net/phy/Makefile
> +++ b/drivers/net/phy/Makefile
> @@ -36,6 +36,7 @@ obj-$(CONFIG_MDIO_CAVIUM)	+= mdio-cavium.o
>  obj-$(CONFIG_MDIO_GPIO)		+= mdio-gpio.o
>  obj-$(CONFIG_MDIO_HISI_FEMAC)	+= mdio-hisi-femac.o
>  obj-$(CONFIG_MDIO_I2C)		+= mdio-i2c.o
> +obj-$(CONFIG_MDIO_IPQ8064)	+= mdio-ipq8064.o
>  obj-$(CONFIG_MDIO_MOXART)	+= mdio-moxart.o
>  obj-$(CONFIG_MDIO_MSCC_MIIM)	+= mdio-mscc-miim.o
>  obj-$(CONFIG_MDIO_OCTEON)	+= mdio-octeon.o
> diff --git a/drivers/net/phy/mdio-ipq8064.c b/drivers/net/phy/mdio-ipq8064.c
> new file mode 100644
> index 000000000000..fd856b798194
> --- /dev/null
> +++ b/drivers/net/phy/mdio-ipq8064.c
> @@ -0,0 +1,166 @@
> +// SPDX-License-Identifier: GPL-2.0
> +//
> +// Qualcomm IPQ8064 MDIO interface driver
> +//
> +// Copyright (C) 2019 Christian Lamparter <chunkeey@gmail.com>
> +
> +#include <linux/delay.h>
> +#include <linux/kernel.h>
> +#include <linux/module.h>
> +#include <linux/regmap.h>
> +#include <linux/of_mdio.h>
> +#include <linux/phy.h>
> +#include <linux/platform_device.h>
> +#include <linux/mfd/syscon.h>
> +
> +/* MII address register definitions */
> +#define MII_ADDR_REG_ADDR                       0x10
> +#define MII_BUSY                                BIT(0)
> +#define MII_WRITE                               BIT(1)
> +#define MII_CLKRANGE_60_100M                    (0 << 2)
> +#define MII_CLKRANGE_100_150M                   (1 << 2)
> +#define MII_CLKRANGE_20_35M                     (2 << 2)
> +#define MII_CLKRANGE_35_60M                     (3 << 2)
> +#define MII_CLKRANGE_150_250M                   (4 << 2)
> +#define MII_CLKRANGE_250_300M                   (5 << 2)
> +#define MII_CLKRANGE_MASK			GENMASK(4, 2)
> +#define MII_REG_SHIFT				6
> +#define MII_REG_MASK				GENMASK(10, 6)
> +#define MII_ADDR_SHIFT				11
> +#define MII_ADDR_MASK				GENMASK(15, 11)
> +
> +#define MII_DATA_REG_ADDR                       0x14
> +
> +#define MII_MDIO_DELAY                          (1000)
> +#define MII_MDIO_RETRY                          (10)

You've missed my comments on these.

> +
> +struct ipq8064_mdio {
> +	struct regmap *base; /* NSS_GMAC0_BASE */
> +};
> +
> +static int
> +ipq8064_mdio_wait_busy(struct ipq8064_mdio *priv)
> +{
> +	u32 busy;
> +
> +	return regmap_read_poll_timeout(priv->base, MII_ADDR_REG_ADDR, busy,
> +				   !(busy & MII_BUSY), MII_MDIO_DELAY,
> +				   MII_MDIO_RETRY * USEC_PER_MSEC);
> +}
> +
> +static int
> +ipq8064_mdio_read(struct mii_bus *bus, int phy_addr, int reg_offset)
> +{
> +	struct ipq8064_mdio *priv = bus->priv;
> +	u32 miiaddr = MII_BUSY | MII_CLKRANGE_250_300M;
> +	u32 ret_val;
> +	int err;
> +
> +	/* Reject clause 45 */
> +	if (reg_offset & MII_ADDR_C45)
> +		return -EOPNOTSUPP;
> +
> +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> +
> +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> +	usleep_range(10, 20);
> +
> +	err = ipq8064_mdio_wait_busy(priv);
> +	if (err)
> +		return err;
> +
> +	regmap_read(priv->base, MII_DATA_REG_ADDR, &ret_val);
> +	return (int)ret_val;
> +}
> +
> +static int
> +ipq8064_mdio_write(struct mii_bus *bus, int phy_addr, int reg_offset, u16 data)
> +{
> +	struct ipq8064_mdio *priv = bus->priv;
> +	u32 miiaddr = MII_WRITE | MII_BUSY | MII_CLKRANGE_250_300M;
> +
> +	/* Reject clause 45 */
> +	if (reg_offset & MII_ADDR_C45)
> +		return -EOPNOTSUPP;
> +
> +	regmap_write(priv->base, MII_DATA_REG_ADDR, data);
> +
> +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> +
> +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> +	usleep_range(10, 20);
> +
> +	return ipq8064_mdio_wait_busy(priv);
> +}
> +
> +static int
> +ipq8064_mdio_probe(struct platform_device *pdev)
> +{
> +	struct device_node *np = pdev->dev.of_node;
> +	struct ipq8064_mdio *priv;
> +	struct mii_bus *bus;
> +	int ret;
> +
> +	bus = devm_mdiobus_alloc_size(&pdev->dev, sizeof(*priv));
> +	if (!bus)
> +		return -ENOMEM;
> +
> +	bus->name = "ipq8064_mdio_bus";
> +	bus->read = ipq8064_mdio_read;
> +	bus->write = ipq8064_mdio_write;
> +	snprintf(bus->id, MII_BUS_ID_SIZE, "%s-mii", dev_name(&pdev->dev));
> +	bus->parent = &pdev->dev;
> +
> +	priv = bus->priv;
> +	priv->base = syscon_node_to_regmap(np);
> +	if (IS_ERR(priv->base) && priv->base != ERR_PTR(-EPROBE_DEFER))
> +		priv->base = syscon_regmap_lookup_by_phandle(np, "master");
> +
> +	if (priv->base == ERR_PTR(-EPROBE_DEFER)) {
> +		return -EPROBE_DEFER;
> +	} else if (IS_ERR(priv->base)) {
> +		dev_err(&pdev->dev, "error getting syscon regmap, error=%ld\n",
> +			PTR_ERR(priv->base));

Why not %pe as I suggested, which is documented in printk-formats to
optionally give a symbolic error string.

> +		return PTR_ERR(priv->base);
> +	}

And have you even tested the above - you haven't said whether you have
or not...

> +
> +	ret = of_mdiobus_register(bus, np);
> +	if (ret)
> +		return ret;
> +
> +	platform_set_drvdata(pdev, bus);
> +	return 0;
> +}
> +
> +static int
> +ipq8064_mdio_remove(struct platform_device *pdev)
> +{
> +	struct mii_bus *bus = platform_get_drvdata(pdev);
> +
> +	mdiobus_unregister(bus);
> +
> +	return 0;
> +}
> +
> +static const struct of_device_id ipq8064_mdio_dt_ids[] = {
> +	{ .compatible = "qcom,ipq8064-mdio" },
> +	{ }
> +};
> +MODULE_DEVICE_TABLE(of, ipq8064_mdio_dt_ids);
> +
> +static struct platform_driver ipq8064_mdio_driver = {
> +	.probe = ipq8064_mdio_probe,
> +	.remove = ipq8064_mdio_remove,
> +	.driver = {
> +		.name = "ipq8064-mdio",
> +		.of_match_table = ipq8064_mdio_dt_ids,
> +	},
> +};
> +
> +module_platform_driver(ipq8064_mdio_driver);
> +
> +MODULE_DESCRIPTION("Qualcomm IPQ8064 MDIO interface driver");
> +MODULE_AUTHOR("Christian Lamparter <chunkeey@gmail.com>");
> +MODULE_LICENSE("GPL");
> -- 
> 2.25.0
> 
> 

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to speedtest.net: 11.9Mbps down 500kbps up

^ permalink raw reply	[flat|nested] 6+ messages in thread

* R: [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver
  2020-02-21 13:53 ` [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Russell King - ARM Linux admin
@ 2020-02-21 13:58   ` ansuelsmth
  2020-02-21 14:00     ` Russell King - ARM Linux admin
  0 siblings, 1 reply; 6+ messages in thread
From: ansuelsmth @ 2020-02-21 13:58 UTC (permalink / raw)
  To: 'Russell King - ARM Linux admin'
  Cc: 'Andy Gross', 'Bjorn Andersson',
	'David S. Miller', 'Rob Herring',
	'Mark Rutland', 'Andrew Lunn',
	'Florian Fainelli', 'Heiner Kallweit',
	linux-arm-msm, netdev, devicetree, linux-kernel

> On Fri, Feb 21, 2020 at 02:28:31PM +0100, Ansuel Smith wrote:
> > Currently ipq806x soc use generi bitbang driver to
> > comunicate with the gmac ethernet interface.
> > Add a dedicated driver created by chunkeey to fix this.
> >
> > Christian Lamparter <chunkeey@gmail.com>
> > Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
> > ---
> >  drivers/net/phy/Kconfig        |   8 ++
> >  drivers/net/phy/Makefile       |   1 +
> >  drivers/net/phy/mdio-ipq8064.c | 166
> +++++++++++++++++++++++++++++++++
> >  3 files changed, 175 insertions(+)
> >  create mode 100644 drivers/net/phy/mdio-ipq8064.c
> >
> > diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
> > index 9dabe03a668c..ec2a5493a7e8 100644
> > --- a/drivers/net/phy/Kconfig
> > +++ b/drivers/net/phy/Kconfig
> > @@ -157,6 +157,14 @@ config MDIO_I2C
> >
> >  	  This is library mode.
> >
> > +config MDIO_IPQ8064
> > +	tristate "Qualcomm IPQ8064 MDIO interface support"
> > +	depends on HAS_IOMEM && OF_MDIO
> > +	depends on MFD_SYSCON
> > +	help
> > +	  This driver supports the MDIO interface found in the network
> > +	  interface units of the IPQ8064 SoC
> > +
> >  config MDIO_MOXART
> >  	tristate "MOXA ART MDIO interface support"
> >  	depends on ARCH_MOXART || COMPILE_TEST
> > diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
> > index fe5badf13b65..8f02bd2089f3 100644
> > --- a/drivers/net/phy/Makefile
> > +++ b/drivers/net/phy/Makefile
> > @@ -36,6 +36,7 @@ obj-$(CONFIG_MDIO_CAVIUM)	+= mdio-
> cavium.o
> >  obj-$(CONFIG_MDIO_GPIO)		+= mdio-gpio.o
> >  obj-$(CONFIG_MDIO_HISI_FEMAC)	+= mdio-hisi-femac.o
> >  obj-$(CONFIG_MDIO_I2C)		+= mdio-i2c.o
> > +obj-$(CONFIG_MDIO_IPQ8064)	+= mdio-ipq8064.o
> >  obj-$(CONFIG_MDIO_MOXART)	+= mdio-moxart.o
> >  obj-$(CONFIG_MDIO_MSCC_MIIM)	+= mdio-mscc-miim.o
> >  obj-$(CONFIG_MDIO_OCTEON)	+= mdio-octeon.o
> > diff --git a/drivers/net/phy/mdio-ipq8064.c b/drivers/net/phy/mdio-
> ipq8064.c
> > new file mode 100644
> > index 000000000000..fd856b798194
> > --- /dev/null
> > +++ b/drivers/net/phy/mdio-ipq8064.c
> > @@ -0,0 +1,166 @@
> > +// SPDX-License-Identifier: GPL-2.0
> > +//
> > +// Qualcomm IPQ8064 MDIO interface driver
> > +//
> > +// Copyright (C) 2019 Christian Lamparter <chunkeey@gmail.com>
> > +
> > +#include <linux/delay.h>
> > +#include <linux/kernel.h>
> > +#include <linux/module.h>
> > +#include <linux/regmap.h>
> > +#include <linux/of_mdio.h>
> > +#include <linux/phy.h>
> > +#include <linux/platform_device.h>
> > +#include <linux/mfd/syscon.h>
> > +
> > +/* MII address register definitions */
> > +#define MII_ADDR_REG_ADDR                       0x10
> > +#define MII_BUSY                                BIT(0)
> > +#define MII_WRITE                               BIT(1)
> > +#define MII_CLKRANGE_60_100M                    (0 << 2)
> > +#define MII_CLKRANGE_100_150M                   (1 << 2)
> > +#define MII_CLKRANGE_20_35M                     (2 << 2)
> > +#define MII_CLKRANGE_35_60M                     (3 << 2)
> > +#define MII_CLKRANGE_150_250M                   (4 << 2)
> > +#define MII_CLKRANGE_250_300M                   (5 << 2)
> > +#define MII_CLKRANGE_MASK			GENMASK(4, 2)
> > +#define MII_REG_SHIFT				6
> > +#define MII_REG_MASK				GENMASK(10, 6)
> > +#define MII_ADDR_SHIFT				11
> > +#define MII_ADDR_MASK				GENMASK(15, 11)
> > +
> > +#define MII_DATA_REG_ADDR                       0x14
> > +
> > +#define MII_MDIO_DELAY                          (1000)
> > +#define MII_MDIO_RETRY                          (10)
> 
> You've missed my comments on these.
> 
> > +
> > +struct ipq8064_mdio {
> > +	struct regmap *base; /* NSS_GMAC0_BASE */
> > +};
> > +
> > +static int
> > +ipq8064_mdio_wait_busy(struct ipq8064_mdio *priv)
> > +{
> > +	u32 busy;
> > +
> > +	return regmap_read_poll_timeout(priv->base,
> MII_ADDR_REG_ADDR, busy,
> > +				   !(busy & MII_BUSY), MII_MDIO_DELAY,
> > +				   MII_MDIO_RETRY * USEC_PER_MSEC);
> > +}
> > +
> > +static int
> > +ipq8064_mdio_read(struct mii_bus *bus, int phy_addr, int reg_offset)
> > +{
> > +	struct ipq8064_mdio *priv = bus->priv;
> > +	u32 miiaddr = MII_BUSY | MII_CLKRANGE_250_300M;
> > +	u32 ret_val;
> > +	int err;
> > +
> > +	/* Reject clause 45 */
> > +	if (reg_offset & MII_ADDR_C45)
> > +		return -EOPNOTSUPP;
> > +
> > +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> > +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> > +
> > +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> > +	usleep_range(10, 20);
> > +
> > +	err = ipq8064_mdio_wait_busy(priv);
> > +	if (err)
> > +		return err;
> > +
> > +	regmap_read(priv->base, MII_DATA_REG_ADDR, &ret_val);
> > +	return (int)ret_val;
> > +}
> > +
> > +static int
> > +ipq8064_mdio_write(struct mii_bus *bus, int phy_addr, int reg_offset,
> u16 data)
> > +{
> > +	struct ipq8064_mdio *priv = bus->priv;
> > +	u32 miiaddr = MII_WRITE | MII_BUSY | MII_CLKRANGE_250_300M;
> > +
> > +	/* Reject clause 45 */
> > +	if (reg_offset & MII_ADDR_C45)
> > +		return -EOPNOTSUPP;
> > +
> > +	regmap_write(priv->base, MII_DATA_REG_ADDR, data);
> > +
> > +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> > +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> > +
> > +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> > +	usleep_range(10, 20);
> > +
> > +	return ipq8064_mdio_wait_busy(priv);
> > +}
> > +
> > +static int
> > +ipq8064_mdio_probe(struct platform_device *pdev)
> > +{
> > +	struct device_node *np = pdev->dev.of_node;
> > +	struct ipq8064_mdio *priv;
> > +	struct mii_bus *bus;
> > +	int ret;
> > +
> > +	bus = devm_mdiobus_alloc_size(&pdev->dev, sizeof(*priv));
> > +	if (!bus)
> > +		return -ENOMEM;
> > +
> > +	bus->name = "ipq8064_mdio_bus";
> > +	bus->read = ipq8064_mdio_read;
> > +	bus->write = ipq8064_mdio_write;
> > +	snprintf(bus->id, MII_BUS_ID_SIZE, "%s-mii", dev_name(&pdev-
> >dev));
> > +	bus->parent = &pdev->dev;
> > +
> > +	priv = bus->priv;
> > +	priv->base = syscon_node_to_regmap(np);
> > +	if (IS_ERR(priv->base) && priv->base != ERR_PTR(-EPROBE_DEFER))
> > +		priv->base = syscon_regmap_lookup_by_phandle(np,
> "master");
> > +
> > +	if (priv->base == ERR_PTR(-EPROBE_DEFER)) {
> > +		return -EPROBE_DEFER;
> > +	} else if (IS_ERR(priv->base)) {
> > +		dev_err(&pdev->dev, "error getting syscon regmap,
> error=%ld\n",
> > +			PTR_ERR(priv->base));
> 
> Why not %pe as I suggested, which is documented in printk-formats to
> optionally give a symbolic error string.
> 
I thought that print the error code was better than error=(ptrval)
If I need to follow the documentation then sorry, I will restore %pe
> > +		return PTR_ERR(priv->base);
> > +	}
> 
> And have you even tested the above - you haven't said whether you have
> or not...
> 
Yes I tested the changes, it does errors correctly.
> > +
> > +	ret = of_mdiobus_register(bus, np);
> > +	if (ret)
> > +		return ret;
> > +
> > +	platform_set_drvdata(pdev, bus);
> > +	return 0;
> > +}
> > +
> > +static int
> > +ipq8064_mdio_remove(struct platform_device *pdev)
> > +{
> > +	struct mii_bus *bus = platform_get_drvdata(pdev);
> > +
> > +	mdiobus_unregister(bus);
> > +
> > +	return 0;
> > +}
> > +
> > +static const struct of_device_id ipq8064_mdio_dt_ids[] = {
> > +	{ .compatible = "qcom,ipq8064-mdio" },
> > +	{ }
> > +};
> > +MODULE_DEVICE_TABLE(of, ipq8064_mdio_dt_ids);
> > +
> > +static struct platform_driver ipq8064_mdio_driver = {
> > +	.probe = ipq8064_mdio_probe,
> > +	.remove = ipq8064_mdio_remove,
> > +	.driver = {
> > +		.name = "ipq8064-mdio",
> > +		.of_match_table = ipq8064_mdio_dt_ids,
> > +	},
> > +};
> > +
> > +module_platform_driver(ipq8064_mdio_driver);
> > +
> > +MODULE_DESCRIPTION("Qualcomm IPQ8064 MDIO interface driver");
> > +MODULE_AUTHOR("Christian Lamparter <chunkeey@gmail.com>");
> > +MODULE_LICENSE("GPL");
> > --
> > 2.25.0
> >
> >
> 
> --
> RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
> FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down
> 622kbps up
> According to speedtest.net: 11.9Mbps down 500kbps up


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: R: [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver
  2020-02-21 13:58   ` R: " ansuelsmth
@ 2020-02-21 14:00     ` Russell King - ARM Linux admin
  0 siblings, 0 replies; 6+ messages in thread
From: Russell King - ARM Linux admin @ 2020-02-21 14:00 UTC (permalink / raw)
  To: ansuelsmth
  Cc: 'Andy Gross', 'Bjorn Andersson',
	'David S. Miller', 'Rob Herring',
	'Mark Rutland', 'Andrew Lunn',
	'Florian Fainelli', 'Heiner Kallweit',
	linux-arm-msm, netdev, devicetree, linux-kernel

On Fri, Feb 21, 2020 at 02:58:55PM +0100, ansuelsmth@gmail.com wrote:
> > On Fri, Feb 21, 2020 at 02:28:31PM +0100, Ansuel Smith wrote:
> > > Currently ipq806x soc use generi bitbang driver to
> > > comunicate with the gmac ethernet interface.
> > > Add a dedicated driver created by chunkeey to fix this.
> > >
> > > Christian Lamparter <chunkeey@gmail.com>
> > > Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
> > > ---
> > >  drivers/net/phy/Kconfig        |   8 ++
> > >  drivers/net/phy/Makefile       |   1 +
> > >  drivers/net/phy/mdio-ipq8064.c | 166
> > +++++++++++++++++++++++++++++++++
> > >  3 files changed, 175 insertions(+)
> > >  create mode 100644 drivers/net/phy/mdio-ipq8064.c
> > >
> > > diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
> > > index 9dabe03a668c..ec2a5493a7e8 100644
> > > --- a/drivers/net/phy/Kconfig
> > > +++ b/drivers/net/phy/Kconfig
> > > @@ -157,6 +157,14 @@ config MDIO_I2C
> > >
> > >  	  This is library mode.
> > >
> > > +config MDIO_IPQ8064
> > > +	tristate "Qualcomm IPQ8064 MDIO interface support"
> > > +	depends on HAS_IOMEM && OF_MDIO
> > > +	depends on MFD_SYSCON
> > > +	help
> > > +	  This driver supports the MDIO interface found in the network
> > > +	  interface units of the IPQ8064 SoC
> > > +
> > >  config MDIO_MOXART
> > >  	tristate "MOXA ART MDIO interface support"
> > >  	depends on ARCH_MOXART || COMPILE_TEST
> > > diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
> > > index fe5badf13b65..8f02bd2089f3 100644
> > > --- a/drivers/net/phy/Makefile
> > > +++ b/drivers/net/phy/Makefile
> > > @@ -36,6 +36,7 @@ obj-$(CONFIG_MDIO_CAVIUM)	+= mdio-
> > cavium.o
> > >  obj-$(CONFIG_MDIO_GPIO)		+= mdio-gpio.o
> > >  obj-$(CONFIG_MDIO_HISI_FEMAC)	+= mdio-hisi-femac.o
> > >  obj-$(CONFIG_MDIO_I2C)		+= mdio-i2c.o
> > > +obj-$(CONFIG_MDIO_IPQ8064)	+= mdio-ipq8064.o
> > >  obj-$(CONFIG_MDIO_MOXART)	+= mdio-moxart.o
> > >  obj-$(CONFIG_MDIO_MSCC_MIIM)	+= mdio-mscc-miim.o
> > >  obj-$(CONFIG_MDIO_OCTEON)	+= mdio-octeon.o
> > > diff --git a/drivers/net/phy/mdio-ipq8064.c b/drivers/net/phy/mdio-
> > ipq8064.c
> > > new file mode 100644
> > > index 000000000000..fd856b798194
> > > --- /dev/null
> > > +++ b/drivers/net/phy/mdio-ipq8064.c
> > > @@ -0,0 +1,166 @@
> > > +// SPDX-License-Identifier: GPL-2.0
> > > +//
> > > +// Qualcomm IPQ8064 MDIO interface driver
> > > +//
> > > +// Copyright (C) 2019 Christian Lamparter <chunkeey@gmail.com>
> > > +
> > > +#include <linux/delay.h>
> > > +#include <linux/kernel.h>
> > > +#include <linux/module.h>
> > > +#include <linux/regmap.h>
> > > +#include <linux/of_mdio.h>
> > > +#include <linux/phy.h>
> > > +#include <linux/platform_device.h>
> > > +#include <linux/mfd/syscon.h>
> > > +
> > > +/* MII address register definitions */
> > > +#define MII_ADDR_REG_ADDR                       0x10
> > > +#define MII_BUSY                                BIT(0)
> > > +#define MII_WRITE                               BIT(1)
> > > +#define MII_CLKRANGE_60_100M                    (0 << 2)
> > > +#define MII_CLKRANGE_100_150M                   (1 << 2)
> > > +#define MII_CLKRANGE_20_35M                     (2 << 2)
> > > +#define MII_CLKRANGE_35_60M                     (3 << 2)
> > > +#define MII_CLKRANGE_150_250M                   (4 << 2)
> > > +#define MII_CLKRANGE_250_300M                   (5 << 2)
> > > +#define MII_CLKRANGE_MASK			GENMASK(4, 2)
> > > +#define MII_REG_SHIFT				6
> > > +#define MII_REG_MASK				GENMASK(10, 6)
> > > +#define MII_ADDR_SHIFT				11
> > > +#define MII_ADDR_MASK				GENMASK(15, 11)
> > > +
> > > +#define MII_DATA_REG_ADDR                       0x14
> > > +
> > > +#define MII_MDIO_DELAY                          (1000)
> > > +#define MII_MDIO_RETRY                          (10)
> > 
> > You've missed my comments on these.

And did you miss this again?

> > 
> > > +
> > > +struct ipq8064_mdio {
> > > +	struct regmap *base; /* NSS_GMAC0_BASE */
> > > +};
> > > +
> > > +static int
> > > +ipq8064_mdio_wait_busy(struct ipq8064_mdio *priv)
> > > +{
> > > +	u32 busy;
> > > +
> > > +	return regmap_read_poll_timeout(priv->base,
> > MII_ADDR_REG_ADDR, busy,
> > > +				   !(busy & MII_BUSY), MII_MDIO_DELAY,
> > > +				   MII_MDIO_RETRY * USEC_PER_MSEC);
> > > +}
> > > +
> > > +static int
> > > +ipq8064_mdio_read(struct mii_bus *bus, int phy_addr, int reg_offset)
> > > +{
> > > +	struct ipq8064_mdio *priv = bus->priv;
> > > +	u32 miiaddr = MII_BUSY | MII_CLKRANGE_250_300M;
> > > +	u32 ret_val;
> > > +	int err;
> > > +
> > > +	/* Reject clause 45 */
> > > +	if (reg_offset & MII_ADDR_C45)
> > > +		return -EOPNOTSUPP;
> > > +
> > > +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> > > +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> > > +
> > > +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> > > +	usleep_range(10, 20);
> > > +
> > > +	err = ipq8064_mdio_wait_busy(priv);
> > > +	if (err)
> > > +		return err;
> > > +
> > > +	regmap_read(priv->base, MII_DATA_REG_ADDR, &ret_val);
> > > +	return (int)ret_val;
> > > +}
> > > +
> > > +static int
> > > +ipq8064_mdio_write(struct mii_bus *bus, int phy_addr, int reg_offset,
> > u16 data)
> > > +{
> > > +	struct ipq8064_mdio *priv = bus->priv;
> > > +	u32 miiaddr = MII_WRITE | MII_BUSY | MII_CLKRANGE_250_300M;
> > > +
> > > +	/* Reject clause 45 */
> > > +	if (reg_offset & MII_ADDR_C45)
> > > +		return -EOPNOTSUPP;
> > > +
> > > +	regmap_write(priv->base, MII_DATA_REG_ADDR, data);
> > > +
> > > +	miiaddr |= ((phy_addr << MII_ADDR_SHIFT) & MII_ADDR_MASK) |
> > > +		   ((reg_offset << MII_REG_SHIFT) & MII_REG_MASK);
> > > +
> > > +	regmap_write(priv->base, MII_ADDR_REG_ADDR, miiaddr);
> > > +	usleep_range(10, 20);
> > > +
> > > +	return ipq8064_mdio_wait_busy(priv);
> > > +}
> > > +
> > > +static int
> > > +ipq8064_mdio_probe(struct platform_device *pdev)
> > > +{
> > > +	struct device_node *np = pdev->dev.of_node;
> > > +	struct ipq8064_mdio *priv;
> > > +	struct mii_bus *bus;
> > > +	int ret;
> > > +
> > > +	bus = devm_mdiobus_alloc_size(&pdev->dev, sizeof(*priv));
> > > +	if (!bus)
> > > +		return -ENOMEM;
> > > +
> > > +	bus->name = "ipq8064_mdio_bus";
> > > +	bus->read = ipq8064_mdio_read;
> > > +	bus->write = ipq8064_mdio_write;
> > > +	snprintf(bus->id, MII_BUS_ID_SIZE, "%s-mii", dev_name(&pdev-
> > >dev));
> > > +	bus->parent = &pdev->dev;
> > > +
> > > +	priv = bus->priv;
> > > +	priv->base = syscon_node_to_regmap(np);
> > > +	if (IS_ERR(priv->base) && priv->base != ERR_PTR(-EPROBE_DEFER))
> > > +		priv->base = syscon_regmap_lookup_by_phandle(np,
> > "master");
> > > +
> > > +	if (priv->base == ERR_PTR(-EPROBE_DEFER)) {
> > > +		return -EPROBE_DEFER;
> > > +	} else if (IS_ERR(priv->base)) {
> > > +		dev_err(&pdev->dev, "error getting syscon regmap,
> > error=%ld\n",
> > > +			PTR_ERR(priv->base));
> > 
> > Why not %pe as I suggested, which is documented in printk-formats to
> > optionally give a symbolic error string.
> > 
> I thought that print the error code was better than error=(ptrval)
> If I need to follow the documentation then sorry, I will restore %pe
> > > +		return PTR_ERR(priv->base);
> > > +	}
> > 
> > And have you even tested the above - you haven't said whether you have
> > or not...
> > 
> Yes I tested the changes, it does errors correctly.
> > > +
> > > +	ret = of_mdiobus_register(bus, np);
> > > +	if (ret)
> > > +		return ret;
> > > +
> > > +	platform_set_drvdata(pdev, bus);
> > > +	return 0;
> > > +}
> > > +
> > > +static int
> > > +ipq8064_mdio_remove(struct platform_device *pdev)
> > > +{
> > > +	struct mii_bus *bus = platform_get_drvdata(pdev);
> > > +
> > > +	mdiobus_unregister(bus);
> > > +
> > > +	return 0;
> > > +}
> > > +
> > > +static const struct of_device_id ipq8064_mdio_dt_ids[] = {
> > > +	{ .compatible = "qcom,ipq8064-mdio" },
> > > +	{ }
> > > +};
> > > +MODULE_DEVICE_TABLE(of, ipq8064_mdio_dt_ids);
> > > +
> > > +static struct platform_driver ipq8064_mdio_driver = {
> > > +	.probe = ipq8064_mdio_probe,
> > > +	.remove = ipq8064_mdio_remove,
> > > +	.driver = {
> > > +		.name = "ipq8064-mdio",
> > > +		.of_match_table = ipq8064_mdio_dt_ids,
> > > +	},
> > > +};
> > > +
> > > +module_platform_driver(ipq8064_mdio_driver);
> > > +
> > > +MODULE_DESCRIPTION("Qualcomm IPQ8064 MDIO interface driver");
> > > +MODULE_AUTHOR("Christian Lamparter <chunkeey@gmail.com>");
> > > +MODULE_LICENSE("GPL");
> > > --
> > > 2.25.0
> > >
> > >
> > 
> > --
> > RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
> > FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down
> > 622kbps up
> > According to speedtest.net: 11.9Mbps down 500kbps up
> 
> 

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
According to speedtest.net: 11.9Mbps down 500kbps up

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver
  2020-02-21 13:28 [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Ansuel Smith
  2020-02-21 13:28 ` [PATCH v4 2/2] Documentation: devictree: Add ipq806x mdio bindings Ansuel Smith
  2020-02-21 13:53 ` [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Russell King - ARM Linux admin
@ 2020-02-21 16:31 ` Florian Fainelli
  2 siblings, 0 replies; 6+ messages in thread
From: Florian Fainelli @ 2020-02-21 16:31 UTC (permalink / raw)
  To: Ansuel Smith
  Cc: Andy Gross, Bjorn Andersson, David S. Miller, Rob Herring,
	Mark Rutland, Andrew Lunn, Heiner Kallweit, Russell King,
	linux-arm-msm, netdev, devicetree, linux-kernel



On 2/21/2020 5:28 AM, Ansuel Smith wrote:
> Currently ipq806x soc use generi bitbang driver to

generic

> comunicate with the gmac ethernet interface.
> Add a dedicated driver created by chunkeey to fix this.

Since chunkeey refers to himself as Christian Lamparter and we got an
email how about making this:

Co-developped-by: Christian Lamparter <chunkeey@gmail.com>
-- 
Florian

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-02-21 16:31 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-21 13:28 [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Ansuel Smith
2020-02-21 13:28 ` [PATCH v4 2/2] Documentation: devictree: Add ipq806x mdio bindings Ansuel Smith
2020-02-21 13:53 ` [PATCH v4 1/2] net: mdio: add ipq8064 mdio driver Russell King - ARM Linux admin
2020-02-21 13:58   ` R: " ansuelsmth
2020-02-21 14:00     ` Russell King - ARM Linux admin
2020-02-21 16:31 ` Florian Fainelli

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).