summaryrefslogtreecommitdiff
path: root/nuttx/arch/arm/src/stm32/stm32_eth.c
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-22 14:44:38 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-22 14:44:38 +0000
commit6bb69076e50b9dec9f3735fa8f9e168e99f6bba7 (patch)
tree5e079fa9b212ae3765b3b14888fd7b1f0b106e2f /nuttx/arch/arm/src/stm32/stm32_eth.c
parent38e599c580d418182a6fc4101686843ff0ae4e18 (diff)
downloadpx4-nuttx-6bb69076e50b9dec9f3735fa8f9e168e99f6bba7.tar.gz
px4-nuttx-6bb69076e50b9dec9f3735fa8f9e168e99f6bba7.tar.bz2
px4-nuttx-6bb69076e50b9dec9f3735fa8f9e168e99f6bba7.zip
Move some PHY initialization logic for Darcy
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5382 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/arm/src/stm32/stm32_eth.c')
-rw-r--r--nuttx/arch/arm/src/stm32/stm32_eth.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/nuttx/arch/arm/src/stm32/stm32_eth.c b/nuttx/arch/arm/src/stm32/stm32_eth.c
index 3054142ce..006f67142 100644
--- a/nuttx/arch/arm/src/stm32/stm32_eth.c
+++ b/nuttx/arch/arm/src/stm32/stm32_eth.c
@@ -2594,6 +2594,17 @@ static int stm32_phyinit(FAR struct stm32_ethmac_s *priv)
}
up_mdelay(PHY_RESET_DELAY);
+ /* Perform any necessary, board-specific PHY initialization */
+
+#ifdef CONFIG_STM32_PHYINIT
+ ret = stm32_phy_boardinitialize(0);
+ if (ret < 0)
+ {
+ ndbg("Failed to initialize the PHY: %d\n", ret);
+ return ret;
+ }
+#endif
+
/* Special workaround for the Davicom DM9161 PHY is required. */
#ifdef CONFIG_PHY_DM9161