]> code.ossystems Code Review - openembedded-core.git/commitdiff
wic: fix empty btrfs partitions
authorAlexandre Belloni <alexandre.belloni@free-electrons.com>
Mon, 9 Feb 2015 23:46:41 +0000 (00:46 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 14 Feb 2015 08:40:35 +0000 (08:40 +0000)
btrfs emtpy partition creation is currently not working because of the
usage of the non existant variables rootfs ans extra_imagecmd. It also
as an incorrect size.

Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
scripts/lib/wic/kickstart/custom_commands/partition.py

index 44df20c58a25567b4f581baa24485dedc1a57cbc..315c6128849d4391a04b3beb6eb361378cde29b0 100644 (file)
@@ -425,12 +425,7 @@ class Wic_PartData(Mic_PartData):
             (fs, self.size)
         exec_cmd(dd_cmd)
 
-        mkfs_cmd = "mkfs.%s -b %d %s" % (self.fstype, self.size, rootfs)
-        (rc, out) = exec_native_cmd(mkfs_cmd, native_sysroot)
-        if rc:
-            msger.error("ERROR: mkfs.%s returned '%s' instead of 0 (which you probably don't want to ignore, use --debug for details)" % (self.fstype, rc))
-
-        mkfs_cmd = "mkfs.%s -F %s %s" % (self.fstype, extra_imagecmd, fs)
+        mkfs_cmd = "mkfs.%s -b %d %s" % (self.fstype, self.size * 1024, fs)
         (rc, out) = exec_native_cmd(mkfs_cmd, native_sysroot)
         if rc:
             msger.error("ERROR: mkfs.%s returned '%s' instead of 0 (which you probably don't want to ignore, use --debug for details)" % (self.fstype, rc))