Home
last modified time | relevance | path

Searched refs:shellCB (Results 1 – 14 of 14) sorted by relevance

/kernel/liteos_a/apps/shell/src/
Dshmsg.c52 char *GetCmdline(ShellCB *shellCB) in GetCmdline() argument
54 CmdKeyLink *cmdkey = shellCB->cmdKeyLink; in GetCmdline()
57 (void)pthread_mutex_lock(&shellCB->keyMutex); in GetCmdline()
59 (void)pthread_mutex_unlock(&shellCB->keyMutex); in GetCmdline()
65 (void)pthread_mutex_unlock(&shellCB->keyMutex); in GetCmdline()
70 (void)pthread_mutex_unlock(&shellCB->keyMutex); in GetCmdline()
80 static void ShellSaveHistoryCmd(char *string, ShellCB *shellCB) in ShellSaveHistoryCmd() argument
82 CmdKeyLink *cmdHistory = shellCB->cmdHistoryKeyLink; in ShellSaveHistoryCmd()
91 (void)pthread_mutex_lock(&shellCB->historyMutex); in ShellSaveHistoryCmd()
96 (void)pthread_mutex_unlock(&shellCB->historyMutex); in ShellSaveHistoryCmd()
[all …]
Dmain.c52 static void ShellDeinit(ShellCB *shellCB) in ShellDeinit() argument
54 (void)pthread_mutex_destroy(&shellCB->historyMutex); in ShellDeinit()
55 (void)pthread_mutex_destroy(&shellCB->keyMutex); in ShellDeinit()
56 OsShellKeyDeInit((CmdKeyLink *)shellCB->cmdKeyLink); in ShellDeinit()
57 OsShellKeyDeInit((CmdKeyLink *)shellCB->cmdHistoryKeyLink); in ShellDeinit()
58 (void)free(shellCB); in ShellDeinit()
61 static int OsShellCreateTask(ShellCB *shellCB) in OsShellCreateTask() argument
78 ret = ShellTaskInit(shellCB); in OsShellCreateTask()
83 shellCB->shellEntryHandle = pthread_self(); in OsShellCreateTask()
134 ShellCB *shellCB = NULL; in main() local
[all …]
Dshcmd.c464 unsigned int OsShellKeyInit(ShellCB *shellCB) in OsShellKeyInit() argument
469 if (shellCB == NULL) { in OsShellKeyInit()
487 shellCB->cmdKeyLink = (void *)cmdKeyLink; in OsShellKeyInit()
491 shellCB->cmdHistoryKeyLink = (void *)cmdHistoryLink; in OsShellKeyInit()
492 shellCB->cmdMaskKeyLink = (void *)cmdHistoryLink; in OsShellKeyInit()
539 void OsShellHistoryShow(unsigned int value, ShellCB *shellCB) in OsShellHistoryShow() argument
542 CmdKeyLink *cmdNode = shellCB->cmdHistoryKeyLink; in OsShellHistoryShow()
543 CmdKeyLink *cmdMask = shellCB->cmdMaskKeyLink; in OsShellHistoryShow()
546 (void)pthread_mutex_lock(&shellCB->historyMutex); in OsShellHistoryShow()
567 while (shellCB->shellBufOffset--) { in OsShellHistoryShow()
[all …]
/kernel/liteos_a/shell/full/src/base/
Dshmsg.c50 CHAR *ShellGetInputBuf(ShellCB *shellCB) in ShellGetInputBuf() argument
52 CmdKeyLink *cmdkey = shellCB->cmdKeyLink; in ShellGetInputBuf()
55 (VOID)pthread_mutex_lock(&shellCB->keyMutex); in ShellGetInputBuf()
57 (VOID)pthread_mutex_unlock(&shellCB->keyMutex); in ShellGetInputBuf()
63 (VOID)pthread_mutex_unlock(&shellCB->keyMutex); in ShellGetInputBuf()
68 STATIC VOID ShellSaveHistoryCmd(const CHAR *string, ShellCB *shellCB) in ShellSaveHistoryCmd() argument
70 CmdKeyLink *cmdHistory = shellCB->cmdHistoryKeyLink; in ShellSaveHistoryCmd()
78 (VOID)pthread_mutex_lock(&shellCB->historyMutex); in ShellSaveHistoryCmd()
83 (VOID)pthread_mutex_unlock(&shellCB->historyMutex); in ShellSaveHistoryCmd()
93 (VOID)pthread_mutex_unlock(&shellCB->historyMutex); in ShellSaveHistoryCmd()
[all …]
Dshow.c50 STATIC UINT32 OsShellCreateTask(ShellCB *shellCB) in OsShellCreateTask() argument
52 UINT32 ret = ShellTaskInit(shellCB); in OsShellCreateTask()
57 return ShellEntryInit(shellCB); in OsShellCreateTask()
71 ShellCB *shellCB = (ShellCB *)consoleCB->shellHandle; local
72 if (memset_s(shellCB, sizeof(ShellCB), 0, sizeof(ShellCB)) != EOK) {
76 shellCB->consoleID = (UINT32)consoleId;
77 ret = (UINT32)pthread_mutex_init(&shellCB->keyMutex, NULL);
81 ret = (UINT32)pthread_mutex_init(&shellCB->historyMutex, NULL);
86 ret = OsShellKeyInit(shellCB);
90 if (strncpy_s(shellCB->shellWorkingDirectory, PATH_MAX, "/", 2) != EOK) { /* 2:space for "/" */
[all …]
Dshcmd.c595 LITE_OS_SEC_TEXT_MINOR UINT32 OsShellKeyInit(ShellCB *shellCB) in OsShellKeyInit() argument
600 if (shellCB == NULL) { in OsShellKeyInit()
617 shellCB->cmdKeyLink = (VOID *)cmdKeyLink; in OsShellKeyInit()
621 shellCB->cmdHistoryKeyLink = (VOID *)cmdHistoryLink; in OsShellKeyInit()
622 shellCB->cmdMaskKeyLink = (VOID *)cmdHistoryLink; in OsShellKeyInit()
691 LITE_OS_SEC_TEXT_MINOR VOID OsShellHistoryShow(UINT32 value, ShellCB *shellCB) in OsShellHistoryShow() argument
694 CmdKeyLink *cmdNode = shellCB->cmdHistoryKeyLink; in OsShellHistoryShow()
695 CmdKeyLink *cmdMask = shellCB->cmdMaskKeyLink; in OsShellHistoryShow()
698 (VOID)pthread_mutex_lock(&shellCB->historyMutex); in OsShellHistoryShow()
719 while (shellCB->shellBufOffset--) { in OsShellHistoryShow()
[all …]
/kernel/liteos_m/components/shell/src/base/
Dshcmd.c241 LITE_OS_SEC_TEXT_MINOR UINT32 OsShellKeyInit(ShellCB *shellCB) in OsShellKeyInit() argument
246 if (shellCB == NULL) { in OsShellKeyInit()
263 shellCB->cmdKeyLink = (VOID *)cmdKeyLink; in OsShellKeyInit()
267 shellCB->cmdHistoryKeyLink = (VOID *)cmdHistoryLink; in OsShellKeyInit()
268 shellCB->cmdMaskKeyLink = (VOID *)cmdHistoryLink; in OsShellKeyInit()
361 ShellCB *shellCB = NULL; in OsShellCBInit() local
363 shellCB = (ShellCB *)malloc(sizeof(ShellCB)); in OsShellCBInit()
364 if (shellCB == NULL) { in OsShellCBInit()
367 ret = memset_s(shellCB, sizeof(ShellCB), 0, sizeof(ShellCB)); in OsShellCBInit()
372 ret = (INT32)OsShellKeyInit(shellCB); in OsShellCBInit()
[all …]
/kernel/liteos_a/shell/full/include/
Dshmsg.h46 extern UINT32 ShellTaskInit(ShellCB *shellCB);
47 extern UINT32 ShellEntryInit(ShellCB *shellCB);
48 extern VOID ShellCmdLineParse(CHAR c, pf_OUTPUT outputFunc, ShellCB *shellCB);
Dshcmd.h97 extern VOID OsShellHistoryShow(UINT32 value, ShellCB *shellCB);
98 extern UINT32 OsShellKeyInit(ShellCB *shellCB);
/kernel/liteos_a/apps/shell/include/
Dshmsg.h64 extern int ShellTaskInit(ShellCB *shellCB);
66 extern void ShellCmdLineParse(char c, OutputFunc outputFunc, ShellCB *shellCB);
67 extern int ShellNotify(ShellCB *shellCB);
Dshcmd.h62 extern void OsShellHistoryShow(unsigned int value, ShellCB *shellCB);
63 extern unsigned int OsShellKeyInit(ShellCB *shellCB);
Dshell_pri.h43 extern void ShellEntry(ShellCB *shellCB);
Dshow.h47 extern int OsShellDeinit(ShellCB *shellCB);
/kernel/liteos_m/components/shell/include/
Dshcmd.h90 extern UINT32 OsShellKeyInit(ShellCB *shellCB);