From 559b46f37de682190bb3f3b4bbc5622e65b62ddf Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Thu, 3 Nov 2016 21:59:54 -0400 Subject: [PATCH] shell: move shell Kconfig to drivers/console/shells Cleanup some unneeded ifdefs in C files. Change-Id: Icd1f34f2d24b531ad5320e3436cce048d236a4f0 Signed-off-by: Anas Nashif --- drivers/console/Kconfig | 3 +++ drivers/console/shells/Kconfig | 9 +++++++++ drivers/console/shells/shell_service.c | 5 ----- misc/Kconfig | 8 -------- 4 files changed, 12 insertions(+), 13 deletions(-) create mode 100644 drivers/console/shells/Kconfig diff --git a/drivers/console/Kconfig b/drivers/console/Kconfig index 4694ac2dc74..269a400432a 100644 --- a/drivers/console/Kconfig +++ b/drivers/console/Kconfig @@ -158,4 +158,7 @@ config UART_PIPE_ON_DEV_NAME This option specifies the name of UART device to be used for pipe UART. +source "drivers/console/shells/Kconfig" + + endif diff --git a/drivers/console/shells/Kconfig b/drivers/console/shells/Kconfig new file mode 100644 index 00000000000..0f194ae32d3 --- /dev/null +++ b/drivers/console/shells/Kconfig @@ -0,0 +1,9 @@ + +config ENABLE_SHELL + bool + prompt "Shell support" + default n + help + Enabling shell services. If it is enabled, kernel shell commands are + also available for use. + diff --git a/drivers/console/shells/shell_service.c b/drivers/console/shells/shell_service.c index a002ee71ee3..848ae6c4fe3 100644 --- a/drivers/console/shells/shell_service.c +++ b/drivers/console/shells/shell_service.c @@ -22,9 +22,6 @@ * Includes also adding basic framework commands to shell commands. */ -#ifndef _SHELLSERVICE_H -#define _SHELLSERVICE_H - #include #include #include @@ -61,5 +58,3 @@ int shell_run(struct device *dev) SYS_INIT(shell_run, APPLICATION, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT); - -#endif /* SHELLSERVICE_H */ diff --git a/misc/Kconfig b/misc/Kconfig index eabee6965ef..14a80176fa0 100644 --- a/misc/Kconfig +++ b/misc/Kconfig @@ -242,14 +242,6 @@ config OMIT_FRAME_POINTER trace. Recommended only for production builds which do not need to be debugged. -config ENABLE_SHELL - bool - prompt "Shell support" - default n - help - Enabling shell services. If it is enabled, kernel shell commands are - also available for use. - source "misc/debug/Kconfig" endmenu