From 3b3ea2c56ec4bc5588281fd103c744e608f8b25c Mon Sep 17 00:00:00 2001 From: Michal Simek Date: Mon, 26 Feb 2018 16:01:02 +0100 Subject: Kconfig: cmd: Make networking command dependent on NET Enable networking command only when NET is enabled. And remove selecting NET for CMD_NET Signed-off-by: Michal Simek Signed-off-by: Tom Rini --- cmd/Kconfig | 7 ++++++- cmd/bootefi.c | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) (limited to 'cmd') diff --git a/cmd/Kconfig b/cmd/Kconfig index 18aac7f7d4..136836d146 100644 --- a/cmd/Kconfig +++ b/cmd/Kconfig @@ -1012,9 +1012,10 @@ endmenu menu "Network commands" +if NET + config CMD_NET bool "bootp, tftpboot" - select NET default y help Network commands. @@ -1038,11 +1039,13 @@ config CMD_RARP config CMD_DHCP bool "dhcp" + depends on CMD_NET help Boot image via network using DHCP/TFTP protocol config CMD_PXE bool "pxe" + depends on CMD_NET select MENU help Boot image via network using PXE protocol @@ -1091,6 +1094,8 @@ config CMD_ETHSW operations such as enabling / disabling a port and viewing/maintaining the filtering database (FDB) +endif + endmenu menu "Misc commands" diff --git a/cmd/bootefi.c b/cmd/bootefi.c index 2106ed9c8c..c17fa2ca23 100644 --- a/cmd/bootefi.c +++ b/cmd/bootefi.c @@ -42,7 +42,7 @@ static void efi_init_obj_list(void) #if defined(CONFIG_LCD) || defined(CONFIG_DM_VIDEO) efi_gop_register(); #endif -#ifdef CONFIG_NET +#ifdef CONFIG_CMD_NET efi_net_register(); #endif #ifdef CONFIG_GENERATE_SMBIOS_TABLE @@ -450,7 +450,7 @@ void efi_set_bootdev(const char *dev, const char *devnr, const char *path) bootefi_device_path = efi_dp_from_part(desc, part); } else { -#ifdef CONFIG_NET +#ifdef CONFIG_CMD_NET bootefi_device_path = efi_dp_from_eth(); #endif } -- cgit v1.2.3