diff options
author | San Mehat | 2009-07-06 13:33:45 -0500 |
---|---|---|
committer | San Mehat | 2009-07-06 13:33:45 -0500 |
commit | b3edd0720ea26ef02763e7446d1bafb85546b38e (patch) | |
tree | aecfb506b4ca75c3f421ed0724c69727869c6e17 | |
parent | 72eead43c7711ca97b2d7f578e6b8854a2856ce0 (diff) | |
download | platform-system-core-b3edd0720ea26ef02763e7446d1bafb85546b38e.tar.gz platform-system-core-b3edd0720ea26ef02763e7446d1bafb85546b38e.tar.xz platform-system-core-b3edd0720ea26ef02763e7446d1bafb85546b38e.zip |
vold: Change the disk formatter we use + fix commandline argument creation
Signed-off-by: San Mehat <san@google.com>
-rwxr-xr-x | vold/format.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/vold/format.c b/vold/format.c index d4e2327bf..cd401972f 100755 --- a/vold/format.c +++ b/vold/format.c | |||
@@ -26,7 +26,7 @@ | |||
26 | #include "diskmbr.h" | 26 | #include "diskmbr.h" |
27 | #include "logwrapper.h" | 27 | #include "logwrapper.h" |
28 | 28 | ||
29 | static char MKDOSFS_PATH[] = "/system/bin/mkdosfs"; | 29 | static char MKDOSFS_PATH[] = "/system/bin/newfs_msdos"; |
30 | static char MKE2FS_PATH[] = "/system/bin/mke2fs"; | 30 | static char MKE2FS_PATH[] = "/system/bin/mke2fs"; |
31 | 31 | ||
32 | int format_partition(blkdev_t *part, char *type) | 32 | int format_partition(blkdev_t *part, char *type) |
@@ -37,15 +37,17 @@ int format_partition(blkdev_t *part, char *type) | |||
37 | devpath = blkdev_get_devpath(part); | 37 | devpath = blkdev_get_devpath(part); |
38 | 38 | ||
39 | if (!strcmp(type, FORMAT_TYPE_FAT32)) { | 39 | if (!strcmp(type, FORMAT_TYPE_FAT32)) { |
40 | char *args[6]; | 40 | char *args[9]; |
41 | args[0] = MKDOSFS_PATH; | 41 | args[0] = MKDOSFS_PATH; |
42 | args[1] = "-F 32"; | 42 | args[1] = "-F"; |
43 | args[2] = "-c 32"; | 43 | args[2] = "32"; |
44 | args[3] = "-n 2"; | 44 | args[3] = "-c"; |
45 | args[4] = "-O android"; | 45 | args[4] = "16"; |
46 | args[5] = devpath; | 46 | args[5] = "-O"; |
47 | args[6] = NULL; | 47 | args[6] = "android"; |
48 | rc = logwrap(6, args, 1); | 48 | args[7] = devpath; |
49 | args[8] = NULL; | ||
50 | rc = logwrap(8, args, 1); | ||
49 | } else { | 51 | } else { |
50 | char *args[7]; | 52 | char *args[7]; |
51 | args[0] = MKE2FS_PATH; | 53 | args[0] = MKE2FS_PATH; |