apps: add rptun /dev/rptun/xx panic cmd
Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
parent
de61706552
commit
c57677c3ce
@ -470,7 +470,7 @@ static const struct cmdmap_s g_cmdmap[] =
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_RPTUN) && !defined(CONFIG_NSH_DISABLE_RPTUN)
|
||||
{ "rptun", cmd_rptun, 3, 3, "start|stop <dev-path>" },
|
||||
{ "rptun", cmd_rptun, 3, 3, "start|stop|panic <dev-path>" },
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_NSH_DISABLE_SET
|
||||
|
@ -363,6 +363,10 @@ int cmd_rptun(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv)
|
||||
{
|
||||
cmd = RPTUNIOC_STOP;
|
||||
}
|
||||
else if (strcmp(argv[1], "panic") == 0)
|
||||
{
|
||||
cmd = RPTUNIOC_PANIC;
|
||||
}
|
||||
else
|
||||
{
|
||||
nsh_output(vtbl, g_fmtarginvalid, argv[1]);
|
||||
|
Loading…
Reference in New Issue
Block a user