support/testing/tests/fs/test_ext: add missing "format" option for Qemu
authorThomas Petazzoni <thomas.petazzoni@bootlin.com>
Mon, 21 Jun 2021 20:25:46 +0000 (22:25 +0200)
committerYann E. MORIN <yann.morin.1998@free.fr>
Sat, 26 Jun 2021 20:17:07 +0000 (22:17 +0200)
Will avoid the following warning:

   WARNING: Image format was not specified for
   '/home/thomas/projets/outputs/TestExt3/images/rootfs.ext3' and
   probing guessed raw. Automatically detecting the format is
   dangerous for raw images, write operations on block 0 will be
   restricted. Specify the 'raw' format explicitly to remove the
   restrictions.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
support/testing/tests/fs/test_ext.py

index 0fe8af7e6d079b3549e4493f6e29ad97cf79202f..2a6e0c4274d4d334c75735ccacb6bea8b11d438e 100644 (file)
@@ -31,7 +31,7 @@ def boot_img_and_check_fs_type(emulator, builddir, fs_type):
                   kernel="builtin",
                   kernel_cmdline=["root=/dev/mmcblk0",
                                   "rootfstype={}".format(fs_type)],
-                  options=["-drive", "file={},if=sd".format(img)])
+                  options=["-drive", "file={},if=sd,format=raw".format(img)])
     emulator.login()
     _, exit_code = emulator.run(CHECK_FS_TYPE_CMD.format(fs_type))
     return exit_code