mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Barebox List <barebox@lists.infradead.org>
Subject: [PATCH 3/4] net: designware: eqos: set mdio bus device node
Date: Tue,  8 Jun 2021 11:36:34 +0200	[thread overview]
Message-ID: <20210608093635.5749-4-s.hauer@pengutronix.de> (raw)
In-Reply-To: <20210608093635.5749-1-s.hauer@pengutronix.de>

When the device node of the ethernet device has a mdio subnode then
attach it to the registered mdio bus. This allows the mdio driver
to handle the reset-gpios propertie in the phy nodes.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 drivers/net/designware_eqos.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/designware_eqos.c b/drivers/net/designware_eqos.c
index e6248d408e..f83ec12714 100644
--- a/drivers/net/designware_eqos.c
+++ b/drivers/net/designware_eqos.c
@@ -862,6 +862,7 @@ int eqos_probe(struct device_d *dev, const struct eqos_ops *ops, void *priv)
 	miibus->read = eqos_mdio_read;
 	miibus->write = eqos_mdio_write;
 	miibus->priv = eqos;
+	miibus->dev.device_node = of_get_child_by_name(dev->device_node, "mdio");
 
 	ret = eqos_init(dev, eqos);
 	if (ret)
-- 
2.29.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


  parent reply	other threads:[~2021-06-08  9:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-08  9:36 [PATCH v2 0/4] Rockchip eqos support Sascha Hauer
2021-06-08  9:36 ` [PATCH 1/4] gpio: allow -gpio suffix for gpio property names Sascha Hauer
2021-06-08  9:36 ` [PATCH 2/4] net: designware: eqos: reset phy Sascha Hauer
2021-06-08  9:36 ` Sascha Hauer [this message]
2021-06-08  9:36 ` [PATCH 4/4] net: eqos: Rockchip support Sascha Hauer

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=20210608093635.5749-4-s.hauer@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --subject='Re: [PATCH 3/4] net: designware: eqos: set mdio bus device node' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox