]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
oeqa/qemurunner: implement vmdk images support
authorSergei Zhmylev <s.zhmylev@yadro.com>
Fri, 18 Nov 2022 13:30:20 +0000 (16:30 +0300)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 22 Nov 2022 12:16:32 +0000 (12:16 +0000)
Qemurunner should not pass rootfs to runqemu in case
rootfs is not a filesystem itself.  Some images could
be built into some disk format like vmdk and this
commit makes qemurunner handle such images properly.

Signed-off-by: Sergei Zhmylev <s.zhmylev@yadro.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
meta/lib/oeqa/utils/qemurunner.py

index f175f8a1ded62619a1ee18a3913bf4718f0cd5d9..df546c7bdd94fa8df416d171ecef92b8468abf5a 100644 (file)
@@ -177,7 +177,11 @@ class QemuRunner:
                 launch_cmd += ' slirp'
             if self.use_ovmf:
                 launch_cmd += ' ovmf'
-            launch_cmd += ' %s %s %s' % (runqemuparams, self.machine, self.rootfs)
+            launch_cmd += ' %s %s' % (runqemuparams, self.machine)
+            if self.rootfs.endswith('.vmdk'):
+                self.logger.debug('Bypassing VMDK rootfs for runqemu')
+            else:
+                launch_cmd += ' %s' % (self.rootfs)
 
         return self.launch(launch_cmd, qemuparams=qemuparams, get_ip=get_ip, extra_bootparams=extra_bootparams, env=env)