diff --git a/nshlib/Kconfig b/nshlib/Kconfig index 40d86cbdc..263ab5132 100644 --- a/nshlib/Kconfig +++ b/nshlib/Kconfig @@ -245,10 +245,6 @@ config NSH_DISABLE_CMP bool "Disable cmp" default DEFAULT_SMALL -config NSH_DISABLE_TIMEDATECTL - bool "Disable TIMEDATECTL" - default DEFAULT_SMALL || !LIBC_LOCALTIME || !RTC - config NSH_DISABLE_DATE bool "Disable date" default DEFAULT_SMALL || !RTC @@ -494,6 +490,10 @@ config NSH_DISABLE_TIME bool "Disable time" default DEFAULT_SMALL +config NSH_DISABLE_TIMEDATECTL + bool "Disable timedatectl" + default DEFAULT_SMALL || !LIBC_LOCALTIME || !RTC + config NSH_DISABLE_TEST bool "Disable test" default DEFAULT_SMALL diff --git a/nshlib/nsh_command.c b/nshlib/nsh_command.c index 77423366e..d577e21b1 100644 --- a/nshlib/nsh_command.c +++ b/nshlib/nsh_command.c @@ -154,11 +154,6 @@ static const struct cmdmap_s g_cmdmap[] = { "dirname", cmd_dirname, 2, 2, "" }, #endif -#ifndef CONFIG_NSH_DISABLE_TIMEDATECTL - { "timedatectl", cmd_timedatectl, 1, 3, "[set-timezone TZ]" - }, -#endif - #ifndef CONFIG_NSH_DISABLE_DATE { "date", cmd_date, 1, 4, "[-s \"MMM DD HH:MM:SS YYYY\"] [-u]" }, #endif @@ -537,6 +532,10 @@ static const struct cmdmap_s g_cmdmap[] = { "time", cmd_time, 2, 2, "\"\"" }, #endif +#ifndef CONFIG_NSH_DISABLE_TIMEDATECTL + { "timedatectl", cmd_timedatectl, 1, 3, "[set-timezone TZ]" }, +#endif + #ifndef CONFIG_NSH_DISABLESCRIPT { "true", cmd_true, 1, 1, NULL }, #endif