summaryrefslogtreecommitdiff
path: root/scripts/lib/wic
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2017-03-30 17:14:22 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-31 12:12:21 +0100
commitb6243a03ced9a719a5801afcee014b03313cc43c (patch)
tree30eb40c27a1fcbbe4f0807085d063d019b4e0369 /scripts/lib/wic
parentf06c507078da72f616f45effe5005cc01615a17c (diff)
downloadopenembedded-core-b6243a03ced9a719a5801afcee014b03313cc43c.tar.gz
openembedded-core-b6243a03ced9a719a5801afcee014b03313cc43c.tar.bz2
openembedded-core-b6243a03ced9a719a5801afcee014b03313cc43c.zip
wic: set FAT 16 for msdos partitions
Used '-F 16' parameter for mkdosfs to create FAT16 partitions for 'msdos' partition type. [YOCTO #11137] Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Diffstat (limited to 'scripts/lib/wic')
-rw-r--r--scripts/lib/wic/partition.py14
1 files changed, 12 insertions, 2 deletions
diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index d59351c500..6f324ad5b3 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -305,7 +305,12 @@ class Partition():
if self.label:
label_str = "-n %s" % self.label
- dosfs_cmd = "mkdosfs %s -S 512 -C %s %d" % (label_str, rootfs, rootfs_size)
+ size_str = ""
+ if self.fstype == 'msdos':
+ size_str = "-F 16" # FAT 16
+
+ dosfs_cmd = "mkdosfs %s -S 512 %s -C %s %d" % (label_str, size_str,
+ rootfs, rootfs_size)
exec_native_cmd(dosfs_cmd, native_sysroot)
mcopy_cmd = "mcopy -i %s -s %s/* ::/" % (rootfs, rootfs_dir)
@@ -372,7 +377,12 @@ class Partition():
if self.label:
label_str = "-n %s" % self.label
- dosfs_cmd = "mkdosfs %s -S 512 -C %s %d" % (label_str, rootfs, blocks)
+ size_str = ""
+ if self.fstype == 'msdos':
+ size_str = "-F 16" # FAT 16
+
+ dosfs_cmd = "mkdosfs %s -S 512 %s -C %s %d" % (label_str, size_str,
+ rootfs, blocks)
exec_native_cmd(dosfs_cmd, native_sysroot)
chmod_cmd = "chmod 644 %s" % rootfs