summaryrefslogtreecommitdiffstats
path: root/scripts/lib/wic/partition.py
diff options
context:
space:
mode:
authorEd Bartosh <ed.bartosh@linux.intel.com>2017-03-30 13:37:15 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-04-01 08:14:57 +0100
commit54cd064c669b42d498a5f47a1e4f79d17b3fe3ba (patch)
tree0edb825f60b3f9142441aac43eaf95a04419a488 /scripts/lib/wic/partition.py
parent09548406e156f1b120a82dd13464d29306c63606 (diff)
downloadpoky-54cd064c669b42d498a5f47a1e4f79d17b3fe3ba.tar.gz
wic: allow only supported fstypes
Restricted possible values of --fstype to the list of supported types. This should catch incorrect values when .wks file is being parsed. Removed checks for empty fstype and mentioning of unsupported fstype 'ontrackdm6aux3'. (From OE-Core rev: 21af89a6d44ccea6aef975ffd2483a8fad1231de) Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/lib/wic/partition.py')
-rw-r--r--scripts/lib/wic/partition.py8
1 files changed, 2 insertions, 6 deletions
diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index 647a6fb3a7..f0e88fb4e8 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -136,11 +136,11 @@ class Partition():
136 "specify a non-zero --size/--fixed-size for that " 136 "specify a non-zero --size/--fixed-size for that "
137 "partition." % self.mountpoint) 137 "partition." % self.mountpoint)
138 138
139 if self.fstype and self.fstype == "swap": 139 if self.fstype == "swap":
140 self.prepare_swap_partition(cr_workdir, oe_builddir, 140 self.prepare_swap_partition(cr_workdir, oe_builddir,
141 native_sysroot) 141 native_sysroot)
142 self.source_file = "%s/fs.%s" % (cr_workdir, self.fstype) 142 self.source_file = "%s/fs.%s" % (cr_workdir, self.fstype)
143 elif self.fstype: 143 else:
144 rootfs = "%s/fs_%s.%s.%s" % (cr_workdir, self.label, 144 rootfs = "%s/fs_%s.%s.%s" % (cr_workdir, self.label,
145 self.lineno, self.fstype) 145 self.lineno, self.fstype)
146 if os.path.isfile(rootfs): 146 if os.path.isfile(rootfs):
@@ -217,10 +217,6 @@ class Partition():
217 if os.path.isfile(rootfs): 217 if os.path.isfile(rootfs):
218 os.remove(rootfs) 218 os.remove(rootfs)
219 219
220 if not self.fstype:
221 raise WicError("File system for partition %s not specified in "
222 "kickstart, use --fstype option" % self.mountpoint)
223
224 # Get rootfs size from bitbake variable if it's not set in .ks file 220 # Get rootfs size from bitbake variable if it's not set in .ks file
225 if not self.size: 221 if not self.size:
226 # Bitbake variable ROOTFS_SIZE is calculated in 222 # Bitbake variable ROOTFS_SIZE is calculated in