Skip to contentSkip to conversation

net: ftgmac100: Add support for board specific PHY interface address

PATCH New Thirupathaiah Annapureddy 3 participants 4 messages Aug 18, 2020 – Oct 1, 2020 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: ftgmac100: Add support for board specific PHY interface address

ftgmac100 driver is using hard-coded PHY interface address of zero. Each board can have different PHY interface address (phy_addr). This commit modifies the driver to make use of board specific address by leveraging CONFIG_PHY_ADDR.

---
 drivers/net/ftgmac100.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/net/ftgmac100.c +4 -0
index 5676a5b3ba..00bda24f1f 100644
@@ -551,6 +551,10 @@ static int ftgmac100_probe(struct udevice *dev)
 	priv->max_speed = pdata->max_speed;
 	priv->phy_addr = 0;
 
+#ifdef CONFIG_PHY_ADDR
+	priv->phy_addr = CONFIG_PHY_ADDR;
+#endif
+
 	ret = clk_enable_bulk(&priv->clks);
 	if (ret)
 		goto out;
Signature · 1 line
2.25.2
#1 lore raw

PATCH 1/1 net: ftgmac100: Add support for board specific PHY interface address

Quoted 6 lines · Thirupathaiah Annapureddy

ftgmac100 driver is using hard-coded PHY interface address of zero. Each board can have different PHY interface address (phy_addr). This commit modifies the driver to make use of board specific address by leveraging CONFIG_PHY_ADDR.

Thanks,

C.

Quoted 20 lines
---
 drivers/net/ftgmac100.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/net/ftgmac100.c +4 -0
index 5676a5b3ba..00bda24f1f 100644
@@ -551,6 +551,10 @@ static int ftgmac100_probe(struct udevice *dev)
 	priv->max_speed = pdata->max_speed;
 	priv->phy_addr = 0;
 
+#ifdef CONFIG_PHY_ADDR
+	priv->phy_addr = CONFIG_PHY_ADDR;
+#endif
+
 	ret = clk_enable_bulk(&priv->clks);
 	if (ret)
 		goto out;
#2 lore raw

PATCH 1/1 net: ftgmac100: Add support for board specific PHY interface address

In reply to Thirupathaiah Annapureddy

Hi Tom/Joe,

Is this going to be applied to u-boot/next or u-boot-net?

Best Regards,
Thiru

Quoted 26 lines · Thirupathaiah Annapureddy

ftgmac100 driver is using hard-coded PHY interface address of zero. Each board can have different PHY interface address (phy_addr). This commit modifies the driver to make use of board specific address by leveraging CONFIG_PHY_ADDR.

---
 drivers/net/ftgmac100.c | 4 ++++
 1 file changed, 4 insertions(+)
drivers/net/ftgmac100.c +4 -0
index 5676a5b3ba..00bda24f1f 100644
@@ -551,6 +551,10 @@ static int ftgmac100_probe(struct udevice *dev)
 	priv->max_speed = pdata->max_speed;
 	priv->phy_addr = 0;
 
+#ifdef CONFIG_PHY_ADDR
+	priv->phy_addr = CONFIG_PHY_ADDR;
+#endif
+
 	ret = clk_enable_bulk(&priv->clks);
 	if (ret)
 		goto out;
#3 lore raw

PATCH 1/1 net: ftgmac100: Add support for board specific PHY interface address

In reply to Thirupathaiah Annapureddy
Quoted 7 lines · Thirupathaiah Annapureddy

ftgmac100 driver is using hard-coded PHY interface address of zero. Each board can have different PHY interface address (phy_addr). This commit modifies the driver to make use of board specific address by leveraging CONFIG_PHY_ADDR.

Applied to u-boot/next, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20201001/cad894af/attachment.sig>