Make NSH net-initialization be a configuration option

Signed-off-by: Marten Svanfeldt <marten@intuitiveaerial.com>
This commit is contained in:
Marten Svanfeldt 2015-10-19 12:05:17 +08:00
parent 7fff9a000a
commit 33c6a6bb75
3 changed files with 13 additions and 3 deletions

View File

@ -942,6 +942,15 @@ config NSH_ARCHINIT
menu "Networking Configuration"
depends on NET
config NSH_NETINIT
bool "Network initialization"
default y
depends on NET
---help---
This option enables/disables all network initialization in NSH.
if NSH_NETINIT
config NSH_NETINIT_THREAD
bool "Network initialization thread"
default n
@ -1389,6 +1398,7 @@ config NSH_MACADDR
MAC address must provided with this selection.
endif # NSH_NOMAC
endif # NSH_NETINIT
config NSH_MAX_ROUNDTRIP
int "Max Ping Round-Trip (DSEC)"

View File

@ -843,7 +843,7 @@ int nsh_romfsetc(void);
# define nsh_romfsetc() (-ENOSYS)
#endif
#ifdef CONFIG_NET
#ifdef CONFIG_NSH_NETINIT
int nsh_netinit(void);
#else
# define nsh_netinit() (-ENOSYS)

View File

@ -74,7 +74,7 @@
#include "nsh.h"
#ifdef CONFIG_NET
#ifdef CONFIG_NSH_NETINIT
/****************************************************************************
* Pre-processor Definitions
@ -689,4 +689,4 @@ int nsh_netinit(void)
#endif
}
#endif /* CONFIG_NET */
#endif /* CONFIG_NSH_NETINIT */