• Home
  • Raw
  • Download

Lines Matching refs:argc

126 int osShellCmdLs(int argc, const char **argv)  in osShellCmdLs()  argument
136 ERROR_OUT_IF(argc > 1, PRINTK("ls or ls [DIRECTORY]\n"), return -1); in osShellCmdLs()
138 if (argc == 0) { in osShellCmdLs()
153 int osShellCmdCd(int argc, const char **argv) in osShellCmdCd() argument
155 if (argc == 0) { in osShellCmdCd()
221 int osShellCmdCat(int argc, const char **argv) in osShellCmdCat() argument
233 ERROR_OUT_IF(argc != 1, PRINTK("cat [FILE]\n"), return -1); in osShellCmdCat()
299 int osShellCmdMount(int argc, const char **argv) in osShellCmdMount() argument
313 ERROR_OUT_IF(argc < 3, print_mount_usage(), return OS_FAIL); in osShellCmdMount()
317 if (argc < 4) { // 4: required number of parameters in osShellCmdMount()
327 if (argc <= 6) { // 6: arguments include uid or gid in osShellCmdMount()
328 … uid = ((argc >= 5) && (argv[4] != NULL)) ? (unsigned int)strtoul(argv[4], (char **)NULL, 0) : 0; in osShellCmdMount()
329 … gid = ((argc == 6) && (argv[5] != NULL)) ? (unsigned int)strtoul(argv[5], (char **)NULL, 0) : 0; in osShellCmdMount()
344 filessystemtype = (argc >= 4) ? (char *)argv[3] : NULL; /* 4: specify fs type, 3: fs type */ in osShellCmdMount()
345 mountfalgs = (argc >= 5) ? get_mountflags((const char *)argv[4]) : 0; /* 4: usr option */ in osShellCmdMount()
346 … data = (argc >= 6) ? (char *)argv[5] : NULL; /* 5: usr option data, 6: six args needed for data */ in osShellCmdMount()
364 if (argc <= 5) { // 5: arguments include gid and uid in osShellCmdMount()
365 … uid = ((argc >= 4) && (argv[3] != NULL)) ? (unsigned int)strtoul(argv[3], (char **)NULL, 0) : 0; in osShellCmdMount()
366 … gid = ((argc == 5) && (argv[4] != NULL)) ? (unsigned int)strtoul(argv[4], (char **)NULL, 0) : 0; in osShellCmdMount()
385 mountfalgs = (argc >= 4) ? get_mountflags((const char *)argv[3]) : 0; /* 3: usr option */ in osShellCmdMount()
386 …data = (argc >= 5) ? (char *)argv[4] : NULL; /* 4: usr option data, 5: number of args needed for d… in osShellCmdMount()
404 int osShellCmdUmount(int argc, const char **argv) in osShellCmdUmount() argument
418 ERROR_OUT_IF(argc == 0, PRINTK("umount [PATH]\n"), return 0); in osShellCmdUmount()
448 int osShellCmdMkdir(int argc, const char **argv) in osShellCmdMkdir() argument
458 ERROR_OUT_IF(argc != 1, PRINTK("mkdir [DIRECTORY]\n"), return 0); in osShellCmdMkdir()
472 int osShellCmdPwd(int argc, const char **argv) in osShellCmdPwd() argument
481 ERROR_OUT_IF(argc > 0, PRINTK("\nUsage: pwd\n"), return -1); in osShellCmdPwd()
512 int osShellCmdStatfs(int argc, const char **argv) in osShellCmdStatfs() argument
524 ERROR_OUT_IF(argc != 1, PRINTK("statfs failed! Invalid argument!\n"), return -1); in osShellCmdStatfs()
552 int osShellCmdTouch(int argc, const char **argv) in osShellCmdTouch() argument
563 ERROR_OUT_IF(argc != 1, PRINTK("touch [FILE]\n"), return -1); in osShellCmdTouch()
1006 int osShellCmdCp(int argc, const char **argv) in osShellCmdCp() argument
1020 ERROR_OUT_IF(argc < 2, PRINTK("cp [SOURCEFILE] [DESTFILE]\n"), return -1); in osShellCmdCp()
1099 int osShellCmdRm(int argc, const char **argv) in osShellCmdRm() argument
1109 ERROR_OUT_IF(argc != 1 && argc != 2, print_rm_usage(), return -1); in osShellCmdRm()
1111 if (argc == 2) { // 2: arguments include "-r" or "-R" in osShellCmdRm()
1141 int osShellCmdRmdir(int argc, const char **argv) in osShellCmdRmdir() argument
1151 ERROR_OUT_IF(argc == 0, PRINTK("rmdir [DIRECTORY]\n"), return -1); in osShellCmdRmdir()
1170 int osShellCmdSync(int argc, const char **argv) in osShellCmdSync() argument
1172 ERROR_OUT_IF(argc > 0, PRINTK("\nUsage: sync\n"), return -1); in osShellCmdSync()
1178 int osShellCmdLsfd(int argc, const char **argv) in osShellCmdLsfd() argument
1180 ERROR_OUT_IF(argc > 0, PRINTK("\nUsage: lsfd\n"), return -1); in osShellCmdLsfd()
1207 int osShellCmdSu(int argc, const char **argv) in osShellCmdSu() argument
1212 if (argc == 0) { in osShellCmdSu()
1218 ERROR_OUT_IF((argc != 2), PRINTK("su [uid_num] [gid_num]\n"), return -1); in osShellCmdSu()
1235 int osShellCmdChmod(int argc, const char **argv) in osShellCmdChmod() argument
1247 ERROR_OUT_IF((argc != 2), PRINTK("Usage: chmod <MODE> [FILE]\n"), return -1); in osShellCmdChmod()
1281 int osShellCmdChown(int argc, const char **argv) in osShellCmdChown() argument
1291 …ERROR_OUT_IF(((argc != 2) && (argc != 3)), PRINTK("Usage: chown [OWNER] [GROUP] FILE\n"), return -… in osShellCmdChown()
1292 if (argc == 2) { // 2: chown owner of file in osShellCmdChown()
1297 if (argc == 3) { // 3: chown both owner and group in osShellCmdChown()
1332 int osShellCmdChgrp(int argc, const char **argv) in osShellCmdChgrp() argument
1340 ERROR_OUT_IF((argc != 2), PRINTK("Usage: chgrp GROUP FILE\n"), return -1); in osShellCmdChgrp()