aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorSimon Glass2021-08-08 12:20:31 -0600
committerTom Rini2021-09-04 12:51:47 -0400
commit9f6649209f09adcdcec4f194cbca9bdcf9c43bef (patch)
treebc6e51a4c759f59065d86c25ab0bb110addd28aa /net
parent5ed16a9511d735feea74d6b4ea940f5e6b5dd8fc (diff)
net: Move network rules to drivers/net
The code under drivers/net is related to ethernet networking drivers, in some fashion or another. Drop these from the top-level Makefile and also move the phy rule into drivers/net/Makefile which is where it belongs. Make the new rule for drivers/net check for the build-stage relevant ETH symbol. Fix up some Kconfig dependencies while we're here to mirror how the Makefile logic now works. Signed-off-by: Simon Glass <sjg@chromium.org> [trini: Introduce ETH, Kconfig dependency changes, am43xx fix] Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'net')
-rw-r--r--net/eth_common.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/eth_common.c b/net/eth_common.c
index 58f899a0240..82d527abba6 100644
--- a/net/eth_common.c
+++ b/net/eth_common.c
@@ -32,6 +32,7 @@ int eth_env_set_enetaddr_by_index(const char *base_name, int index,
void eth_common_init(void)
{
bootstage_mark(BOOTSTAGE_ID_NET_ETH_START);
+#if CONFIG_IS_ENABLED(ETH)
#if defined(CONFIG_MII) || defined(CONFIG_CMD_MII) || defined(CONFIG_PHYLIB)
miiphy_init();
#endif
@@ -39,6 +40,7 @@ void eth_common_init(void)
#ifdef CONFIG_PHYLIB
phy_init();
#endif
+#endif
}
int eth_mac_skip(int index)