You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by bt...@apache.org on 2020/07/27 04:50:05 UTC
[incubator-nuttx] 01/02: arch: imxrt: Fix auto negotiation for
KSZ8081 PHY
This is an automated email from the ASF dual-hosted git repository.
btashton pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 9079d48646d5fed9ff58466804895d1fe10d1037
Author: Masayuki Ishikawa <ma...@gmail.com>
AuthorDate: Fri Jul 24 06:49:36 2020 +0900
arch: imxrt: Fix auto negotiation for KSZ8081 PHY
Signed-off-by: Masayuki Ishikawa <Ma...@jp.sony.com>
---
arch/arm/src/imxrt/imxrt_enet.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/arch/arm/src/imxrt/imxrt_enet.c b/arch/arm/src/imxrt/imxrt_enet.c
index 6d02134..6aa70a8 100644
--- a/arch/arm/src/imxrt/imxrt_enet.c
+++ b/arch/arm/src/imxrt/imxrt_enet.c
@@ -2144,6 +2144,13 @@ static inline int imxrt_initphy(struct imxrt_driver_s *priv, bool renogphy)
imxrt_writemii(priv, phyaddr, MII_KSZ8081_PHYCTRL2,
(phydata | (1 << 4)));
+ imxrt_writemii(priv, phyaddr, MII_ADVERTISE,
+ MII_ADVERTISE_100BASETXFULL |
+ MII_ADVERTISE_100BASETXHALF |
+ MII_ADVERTISE_10BASETXFULL |
+ MII_ADVERTISE_10BASETXHALF |
+ MII_ADVERTISE_CSMA);
+
#elif defined (CONFIG_ETH0_PHY_LAN8720)
/* Make sure that PHY comes up in correct mode when it's reset */