45 perror(
"format error");
47 PRINTK(
" format <dev_vnodename> <sectors> <option> <label>\n");
48 PRINTK(
" dev_vnodename : the name of dev\n");
49 PRINTK(
" sectors : Size of allocation unit in unit of byte or sector, ");
50 PRINTK(
"0 instead of default size\n");
51 PRINTK(
" options : Index of filesystem. 1 for FAT filesystem, ");
52 PRINTK(
"2 for FAT32 filesystem, 7 for any, 8 for erase\n");
53 PRINTK(
" label : The volume of device. It will be emptyed when this parameter is null\n");
55 PRINTK(
" format /dev/mmcblk0 128 2\n");
63 if (strncmp(argv[3],
"NULL", strlen(argv[3])) == 0 || strncmp(argv[3],
"null", strlen(argv[3])) == 0) {
70 if (
format(argv[0], atoi(argv[1]), atoi(argv[2])) == 0) {
71 PRINTK(
"format %s Success \n", argv[0]);
73 perror(
"format error");