Pass the -f option to mkfs.f2fs when it appears to support it. This is required by f2fs-tools v1.9 and later in order to format the filesystem even when an existing filesystem is detected. But earlier versions did not accept this option. Signed-off-by: Eric Biggers <ebiggers@xxxxxxxxxx> --- kvm-xfstests/test-appliance/files/root/fs/f2fs/config | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/kvm-xfstests/test-appliance/files/root/fs/f2fs/config b/kvm-xfstests/test-appliance/files/root/fs/f2fs/config index 45fb2dd..0efcb76 100644 --- a/kvm-xfstests/test-appliance/files/root/fs/f2fs/config +++ b/kvm-xfstests/test-appliance/files/root/fs/f2fs/config @@ -20,6 +20,10 @@ function format_filesystem() local dev="$1" local opts="$2" + if grep -q 'force overwrite' /sbin/mkfs.f2fs; then + # f2fs-tools v1.9+ + opts+=" -f" + fi /sbin/mkfs.f2fs -q $opts "$dev" return $? } -- 2.17.0.484.g0c8726318c-goog -- To unsubscribe from this list: send the line "unsubscribe fstests" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html