From: Alberto Faria <afaria@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Eduardo Habkost" <eduardo@habkost.net>,
"Philippe Mathieu-Daudé" <philmd@linaro.org>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Marcel Apfelbaum" <marcel.apfelbaum@gmail.com>,
qemu-block@nongnu.org, "Kevin Wolf" <kwolf@redhat.com>,
"Fam Zheng" <fam@euphon.net>,
"Yanan Wang" <wangyanan55@huawei.com>,
"Zhao Liu" <zhao1.liu@intel.com>,
"Alberto Faria" <afaria@redhat.com>
Subject: [PATCH v2 2/2] scsi-disk: Advertise FUA support by default
Date: Fri, 11 Apr 2025 12:30:36 +0100 [thread overview]
Message-ID: <20250411113036.786841-3-afaria@redhat.com> (raw)
In-Reply-To: <20250411113036.786841-1-afaria@redhat.com>
Allow the guest to submit FUA requests directly, instead of forcing it
to emulate them using a regular flush.
Signed-off-by: Alberto Faria <afaria@redhat.com>
---
hw/core/machine.c | 1 +
hw/scsi/scsi-disk.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/hw/core/machine.c b/hw/core/machine.c
index 63c6ef93d2..e4e6474a4e 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -46,6 +46,7 @@ GlobalProperty hw_compat_9_2[] = {
{ "migration", "multifd-clean-tls-termination", "false" },
{ "migration", "send-switchover-start", "off"},
{ "vfio-pci", "x-migration-multifd-transfer", "off" },
+ { "scsi-disk", "dpofua", "off" },
};
const size_t hw_compat_9_2_len = G_N_ELEMENTS(hw_compat_9_2);
diff --git a/hw/scsi/scsi-disk.c b/hw/scsi/scsi-disk.c
index f62dcded64..2f62f6069d 100644
--- a/hw/scsi/scsi-disk.c
+++ b/hw/scsi/scsi-disk.c
@@ -3192,7 +3192,7 @@ static const Property scsi_hd_properties[] = {
DEFINE_PROP_BIT("removable", SCSIDiskState, features,
SCSI_DISK_F_REMOVABLE, false),
DEFINE_PROP_BIT("dpofua", SCSIDiskState, features,
- SCSI_DISK_F_DPOFUA, false),
+ SCSI_DISK_F_DPOFUA, true),
DEFINE_PROP_UINT64("wwn", SCSIDiskState, qdev.wwn, 0),
DEFINE_PROP_UINT64("port_wwn", SCSIDiskState, qdev.port_wwn, 0),
DEFINE_PROP_UINT16("port_index", SCSIDiskState, port_index, 0),
--
2.49.0
next prev parent reply other threads:[~2025-04-11 11:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-11 11:30 [PATCH v2 0/2] scsi-disk: Add FUA write support Alberto Faria
2025-04-11 11:30 ` [PATCH v2 1/2] scsi-disk: Add native " Alberto Faria
2025-04-25 15:02 ` Kevin Wolf
2025-04-11 11:30 ` Alberto Faria [this message]
2025-04-25 15:05 ` [PATCH v2 2/2] scsi-disk: Advertise FUA support by default Kevin Wolf
2025-05-02 12:12 ` Alberto Faria
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250411113036.786841-3-afaria@redhat.com \
--to=afaria@redhat.com \
--cc=eduardo@habkost.net \
--cc=fam@euphon.net \
--cc=kwolf@redhat.com \
--cc=marcel.apfelbaum@gmail.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=wangyanan55@huawei.com \
--cc=zhao1.liu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).