From nobody Sat May  3 01:54:49 2025
Delivered-To: importer@patchew.org
Authentication-Results: mx.zohomail.com;
	dkim=fail;
	spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as
 permitted sender)
  smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org;
	dmarc=fail(p=none dis=none)  header.from=redhat.com
Return-Path: <qemu-devel-bounces+importer=patchew.org@nongnu.org>
Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by
 mx.zohomail.com
	with SMTPS id 1625750096456926.5687711155125;
 Thu, 8 Jul 2021 06:14:56 -0700 (PDT)
Received: from localhost ([::1]:45946 helo=lists1p.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.90_1)
	(envelope-from <qemu-devel-bounces+importer=patchew.org@nongnu.org>)
	id 1m1Trj-0006W6-BN
	for importer@patchew.org; Thu, 08 Jul 2021 09:14:55 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:47656)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <stefanha@redhat.com>)
 id 1m1TpA-0002A7-PQ
 for qemu-devel@nongnu.org; Thu, 08 Jul 2021 09:12:16 -0400
Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:60458)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <stefanha@redhat.com>)
 id 1m1Tp0-0000ew-MK
 for qemu-devel@nongnu.org; Thu, 08 Jul 2021 09:12:16 -0400
Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com
 [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id
 us-mta-280-QSS9pzt6ONSKCU2HeKaifQ-1; Thu, 08 Jul 2021 09:11:58 -0400
Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com
 [10.5.11.16])
 (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))
 (No client certificate requested)
 by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E5CE31098482;
 Thu,  8 Jul 2021 13:11:56 +0000 (UTC)
Received: from localhost (ovpn-114-141.ams2.redhat.com [10.36.114.141])
 by smtp.corp.redhat.com (Postfix) with ESMTP id 608435C1C2;
 Thu,  8 Jul 2021 13:11:56 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;
 s=mimecast20190719; t=1625749919;
 h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
 to:to:cc:cc:mime-version:mime-version:content-type:content-type:
 content-transfer-encoding:content-transfer-encoding:
 in-reply-to:in-reply-to:references:references;
 bh=4s7MghzgqrKMPDRKf8MAQPA2CmurX7SMUV6DY1AtBBw=;
 b=EcKh5d1qFulFPMRh855b6skpXO3NPWRMXCdBf/oSI+E1zpRI+4o+cDrVTS7vYoDKXoXDgI
 s2FNCTfbh0J67NrpFziynzafEYVRYh9/gfZHQp1utX9UYBYb3uz38G7R+GM2565zzx0+bg
 /wH1hQKcqMxsuORGGZH7ujEpbx/BhsU=
X-MC-Unique: QSS9pzt6ONSKCU2HeKaifQ-1
From: Stefan Hajnoczi <stefanha@redhat.com>
To: qemu-devel@nongnu.org,
	Peter Maydell <peter.maydell@linaro.org>
Subject: [PULL 4/5] block: Add backend_defaults property
Date: Thu,  8 Jul 2021 14:11:42 +0100
Message-Id: <20210708131143.240647-5-stefanha@redhat.com>
In-Reply-To: <20210708131143.240647-1-stefanha@redhat.com>
References: <20210708131143.240647-1-stefanha@redhat.com>
MIME-Version: 1.0
X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16
Authentication-Results: relay.mimecast.com;
 auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=stefanha@redhat.com
X-Mimecast-Spam-Score: 0
X-Mimecast-Originator: redhat.com
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17
 as permitted sender) client-ip=209.51.188.17;
 envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org;
 helo=lists.gnu.org;
Received-SPF: pass client-ip=170.10.133.124;
 envelope-from=stefanha@redhat.com;
 helo=us-smtp-delivery-124.mimecast.com
X-Spam_score_int: -14
X-Spam_score: -1.5
X-Spam_bar: -
X-Spam_report: (-1.5 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.45,
 DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 MIME_BASE64_TEXT=1.741, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001,
 RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no
X-Spam_action: no action
X-BeenThere: qemu-devel@nongnu.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: <qemu-devel.nongnu.org>
List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>,
 <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>
List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel>
List-Post: <mailto:qemu-devel@nongnu.org>
List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help>
List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>,
 <mailto:qemu-devel-request@nongnu.org?subject=subscribe>
Cc: Fam Zheng <fam@euphon.net>, Kevin Wolf <kwolf@redhat.com>,
 Akihiko Odaki <akihiko.odaki@gmail.com>, qemu-block@nongnu.org,
 Max Reitz <mreitz@redhat.com>, Stefan Hajnoczi <stefanha@redhat.com>,
 Paolo Bonzini <pbonzini@redhat.com>, John Snow <jsnow@redhat.com>
Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org
Sender: "Qemu-devel" <qemu-devel-bounces+importer=patchew.org@nongnu.org>
X-ZohoMail-DKIM: fail (Header signature does not verify)
X-ZM-MESSAGEID: 1625750096963100001
Content-Type: text/plain; charset="utf-8"

From: Akihiko Odaki <akihiko.odaki@gmail.com>

backend_defaults property allow users to control if default block
properties should be decided with backend information.

If it is off, any backend information will be discarded, which is
suitable if you plan to perform live migration to a different disk backend.

If it is on, a block device may utilize backend information more
aggressively.

By default, it is auto, which uses backend information for block
sizes and ignores the others, which is consistent with the older
versions.

Signed-off-by: Akihiko Odaki <akihiko.odaki@gmail.com>
Message-id: 20210705130458.97642-2-akihiko.odaki@gmail.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
 include/hw/block/block.h   |  3 +++
 hw/block/block.c           | 42 ++++++++++++++++++++++++++++++++++----
 tests/qemu-iotests/172.out | 38 ++++++++++++++++++++++++++++++++++
 3 files changed, 79 insertions(+), 4 deletions(-)

diff --git a/include/hw/block/block.h b/include/hw/block/block.h
index c172cbe65f..5902c0440a 100644
--- a/include/hw/block/block.h
+++ b/include/hw/block/block.h
@@ -19,6 +19,7 @@
=20
 typedef struct BlockConf {
     BlockBackend *blk;
+    OnOffAuto backend_defaults;
     uint32_t physical_block_size;
     uint32_t logical_block_size;
     uint32_t min_io_size;
@@ -48,6 +49,8 @@ static inline unsigned int get_physical_block_exp(BlockCo=
nf *conf)
 }
=20
 #define DEFINE_BLOCK_PROPERTIES_BASE(_state, _conf)                     \
+    DEFINE_PROP_ON_OFF_AUTO("backend_defaults", _state,                 \
+                            _conf.backend_defaults, ON_OFF_AUTO_AUTO),  \
     DEFINE_PROP_BLOCKSIZE("logical_block_size", _state,                 \
                           _conf.logical_block_size),                    \
     DEFINE_PROP_BLOCKSIZE("physical_block_size", _state,                \
diff --git a/hw/block/block.c b/hw/block/block.c
index 1e34573da7..d47ebf005a 100644
--- a/hw/block/block.c
+++ b/hw/block/block.c
@@ -65,24 +65,58 @@ bool blkconf_blocksizes(BlockConf *conf, Error **errp)
 {
     BlockBackend *blk =3D conf->blk;
     BlockSizes blocksizes;
-    int backend_ret;
+    BlockDriverState *bs;
+    bool use_blocksizes;
+    bool use_bs;
+
+    switch (conf->backend_defaults) {
+    case ON_OFF_AUTO_AUTO:
+        use_blocksizes =3D !blk_probe_blocksizes(blk, &blocksizes);
+        use_bs =3D false;
+        break;
+
+    case ON_OFF_AUTO_ON:
+        use_blocksizes =3D !blk_probe_blocksizes(blk, &blocksizes);
+        bs =3D blk_bs(blk);
+        use_bs =3D bs;
+        break;
+
+    case ON_OFF_AUTO_OFF:
+        use_blocksizes =3D false;
+        use_bs =3D false;
+        break;
+
+    default:
+        abort();
+    }
=20
-    backend_ret =3D blk_probe_blocksizes(blk, &blocksizes);
     /* fill in detected values if they are not defined via qemu command li=
ne */
     if (!conf->physical_block_size) {
-        if (!backend_ret) {
+        if (use_blocksizes) {
            conf->physical_block_size =3D blocksizes.phys;
         } else {
             conf->physical_block_size =3D BDRV_SECTOR_SIZE;
         }
     }
     if (!conf->logical_block_size) {
-        if (!backend_ret) {
+        if (use_blocksizes) {
             conf->logical_block_size =3D blocksizes.log;
         } else {
             conf->logical_block_size =3D BDRV_SECTOR_SIZE;
         }
     }
+    if (use_bs) {
+        if (!conf->opt_io_size) {
+            conf->opt_io_size =3D bs->bl.opt_transfer;
+        }
+        if (conf->discard_granularity =3D=3D -1) {
+            if (bs->bl.pdiscard_alignment) {
+                conf->discard_granularity =3D bs->bl.pdiscard_alignment;
+            } else if (bs->bl.request_alignment !=3D 1) {
+                conf->discard_granularity =3D bs->bl.request_alignment;
+            }
+        }
+    }
=20
     if (conf->logical_block_size > conf->physical_block_size) {
         error_setg(errp,
diff --git a/tests/qemu-iotests/172.out b/tests/qemu-iotests/172.out
index d53f61d0de..4cf4d536b4 100644
--- a/tests/qemu-iotests/172.out
+++ b/tests/qemu-iotests/172.out
@@ -21,6 +21,7 @@ Testing:
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -48,6 +49,7 @@ Testing: -fda TEST_DIR/t.qcow2
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -85,6 +87,7 @@ Testing: -fdb TEST_DIR/t.qcow2
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -96,6 +99,7 @@ Testing: -fdb TEST_DIR/t.qcow2
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -137,6 +141,7 @@ Testing: -fda TEST_DIR/t.qcow2 -fdb TEST_DIR/t.qcow2.2
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -148,6 +153,7 @@ Testing: -fda TEST_DIR/t.qcow2 -fdb TEST_DIR/t.qcow2.2
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -190,6 +196,7 @@ Testing: -fdb
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -201,6 +208,7 @@ Testing: -fdb
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -228,6 +236,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -265,6 +274,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2,ind=
ex=3D1
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -276,6 +286,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2,ind=
ex=3D1
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -317,6 +328,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dfloppy,file=3DTEST_DIR/t
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -328,6 +340,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dfloppy,file=3DTEST_DIR/t
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -373,6 +386,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -devi=
ce floppy,drive=3Dnone0
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -410,6 +424,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -devi=
ce floppy,drive=3Dnone0,unit=3D1
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -447,6 +462,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -driv=
e if=3Dnone,file=3DTEST_DIR/t.qco
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -458,6 +474,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -driv=
e if=3Dnone,file=3DTEST_DIR/t.qco
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -509,6 +526,7 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -520,6 +538,7 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -562,6 +581,7 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -573,6 +593,7 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -615,6 +636,7 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -626,6 +648,7 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -668,6 +691,7 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -679,6 +703,7 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=3Dnone,file=3D=
TEST_DIR/t.qcow2.2 -device fl
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "floppy1"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -730,6 +755,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dnone,file=3DTEST_DIR/t.q
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -741,6 +767,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dnone,file=3DTEST_DIR/t.q
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -783,6 +810,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dnone,file=3DTEST_DIR/t.q
               dev: floppy, id ""
                 unit =3D 1 (0x1)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -794,6 +822,7 @@ Testing: -drive if=3Dfloppy,file=3DTEST_DIR/t.qcow2 -dr=
ive if=3Dnone,file=3DTEST_DIR/t.q
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "floppy0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -842,6 +871,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -glob=
al floppy.drive=3Dnone0 -device
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -909,6 +939,7 @@ Testing: -device floppy
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D ""
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -933,6 +964,7 @@ Testing: -device floppy,drive-type=3D120
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D ""
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -957,6 +989,7 @@ Testing: -device floppy,drive-type=3D144
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D ""
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -981,6 +1014,7 @@ Testing: -device floppy,drive-type=3D288
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D ""
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -1008,6 +1042,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -de=
vice floppy,drive=3Dnone0,drive-t
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -1045,6 +1080,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -de=
vice floppy,drive=3Dnone0,drive-t
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -1085,6 +1121,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -de=
vice floppy,drive=3Dnone0,logical
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
@@ -1122,6 +1159,7 @@ Testing: -drive if=3Dnone,file=3DTEST_DIR/t.qcow2 -de=
vice floppy,drive=3Dnone0,physica
               dev: floppy, id ""
                 unit =3D 0 (0x0)
                 drive =3D "none0"
+                backend_defaults =3D "auto"
                 logical_block_size =3D 512 (512 B)
                 physical_block_size =3D 512 (512 B)
                 min_io_size =3D 0 (0 B)
--=20
2.31.1