summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/cli.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/cli.h b/include/cli.h
index ac09c80c78..1bc1ab8035 100644
--- a/include/cli.h
+++ b/include/cli.h
@@ -8,6 +8,7 @@
#define __CLI_H
#include <stdbool.h>
+#include <linux/types.h>
/**
* struct cli_ch_state - state information for reading cmdline characters
@@ -25,6 +26,19 @@ struct cli_ch_state {
};
/**
+ * struct cli_line_state - state of the line editor
+ *
+ * @num: Current cursor position, where 0 is the start
+ * @eol_num: Number of characters in the buffer
+ * @insert: true if in 'insert' mode
+ */
+struct cli_line_state {
+ uint num;
+ uint eol_num;
+ bool insert;
+};
+
+/**
* Go into the command loop
*
* This will return if we get a timeout waiting for a command. See