summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/telnetd.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2018-10-09 14:47:02 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2018-10-10 14:06:27 +0200
commit629faf95046cddedc161ba9bc43fda925ca04ee5 (patch)
treed8bfd198d8814ac4a78c5c949f25cad937ddad33 /cpukit/include/rtems/telnetd.h
parentbuild: Remove local.am (diff)
downloadrtems-629faf95046cddedc161ba9bc43fda925ca04ee5.tar.bz2
telnetd: Remove keep stdio feature
The Telnet service started via rtems_telnetd_start() had a keep stdio feature. This just created a task and executed the command function in a loop. For this kind of service we do not library support. This can be done by an application task on its own. Remove this feature and provide only the real Telnet server functionality. Use syslog() for error and status messages. Add test program for the Telnet server. Close #3542.
Diffstat (limited to 'cpukit/include/rtems/telnetd.h')
-rw-r--r--cpukit/include/rtems/telnetd.h23
1 files changed, 15 insertions, 8 deletions
diff --git a/cpukit/include/rtems/telnetd.h b/cpukit/include/rtems/telnetd.h
index 2339bad8b6..e662874a81 100644
--- a/cpukit/include/rtems/telnetd.h
+++ b/cpukit/include/rtems/telnetd.h
@@ -59,13 +59,14 @@ typedef struct {
/**
* @brief Task priority.
*
- * If this parameter is equal to zero, then the priority of network task is
- * used or 100 if this priority is less than two.
+ * Use 0 for the default value.
*/
rtems_task_priority priority;
/**
* @brief Task stack size.
+ *
+ * Use 0 for the default value.
*/
size_t stack_size;
@@ -77,12 +78,10 @@ typedef struct {
rtems_shell_login_check_t login_check;
/**
- * @brief Keep standard IO of the caller.
+ * @brief This is an obsolete configuration option.
*
- * Telnet takes over the standard input, output and error associated with
- * task, if this parameter is set to @c true. In this case, it will @b not
- * listen on any sockets. When this parameter is @c false, Telnet will
- * create other tasks for the shell which listen on sockets.
+ * It must be set to false, otherwise rtems_telnetd_start() will do nothing
+ * and returns with a status of RTEMS_NOT_IMPLEMENTED.
*/
bool keep_stdio;
@@ -96,7 +95,15 @@ typedef struct {
} rtems_telnetd_config_table;
/**
- * @brief Start the Telnet subsystem with the provided configuration.
+ * @brief Starts the Telnet server using the provided configuration.
+ *
+ * @retval RTEMS_SUCCESSFUL Successful operation.
+ * @retval RTEMS_INVALID_ADDRESS The command function in the configuration is
+ * @c NULL.
+ * @retval RTEMS_RESOURCE_IN_USE The Telnet server was already started.
+ * @retval RTEMS_NOT_IMPLEMENTED The keep stdio configuration option is true.
+ * @retval RTEMS_UNSATISFIED Not enough resources to start the Telnet server or
+ * task priority in configuration is invalid.
*/
rtems_status_code rtems_telnetd_start(const rtems_telnetd_config_table *config);