summaryrefslogtreecommitdiff
path: root/net/eth_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/eth_common.c')
-rw-r--r--net/eth_common.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/net/eth_common.c b/net/eth_common.c
new file mode 100644
index 0000000000..ee0b6df376
--- /dev/null
+++ b/net/eth_common.c
@@ -0,0 +1,23 @@
+/*
+ * (C) Copyright 2001-2015
+ * Wolfgang Denk, DENX Software Engineering, wd@denx.de.
+ * Joe Hershberger, National Instruments
+ *
+ * SPDX-License-Identifier: GPL-2.0+
+ */
+
+#include <common.h>
+#include <miiphy.h>
+#include "eth_internal.h"
+
+void eth_common_init(void)
+{
+ bootstage_mark(BOOTSTAGE_ID_NET_ETH_START);
+#if defined(CONFIG_MII) || defined(CONFIG_CMD_MII) || defined(CONFIG_PHYLIB)
+ miiphy_init();
+#endif
+
+#ifdef CONFIG_PHYLIB
+ phy_init();
+#endif
+}