Lines Matching refs:cmds
121 int cmd_select(const struct cmd *cmds, int argc, char **argv, in cmd_select() argument
130 if (argc < 1 && cmds[0].func) in cmd_select()
131 return cmds[0].func(argc, argv); in cmd_select()
133 for (i = 0; cmds[i].cmd; i++) { in cmd_select()
134 if (is_prefix(*argv, cmds[i].cmd)) { in cmd_select()
135 if (!cmds[i].func) { in cmd_select()
137 cmds[i].cmd); in cmd_select()
140 return cmds[i].func(argc - 1, argv + 1); in cmd_select()
259 static const struct cmd cmds[] = { variable
364 err = cmd_select(cmds, n_argc, n_argv, do_help); in do_batch()
498 ret = cmd_select(cmds, argc, argv, do_help); in main()