qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Sam Li <faithilikerun@gmail.com>
To: qemu-devel@nongnu.org
Cc: Paolo Bonzini <pbonzini@redhat.com>,
	Eric Blake <eblake@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	Markus Armbruster <armbru@redhat.com>,
	Raphael Norwitz <raphael.norwitz@nutanix.com>,
	Stefan Hajnoczi <stefanha@redhat.com>,
	Hanna Reitz <hreitz@redhat.com>,
	Cornelia Huck <cohuck@redhat.com>,
	dmitry.fomichev@wdc.com, kvm@vger.kernel.org,
	damien.lemoal@opensource.wdc.com, hare@suse.de,
	Kevin Wolf <kwolf@redhat.com>,
	qemu-block@nongnu.org, Sam Li <faithilikerun@gmail.com>
Subject: [PATCH v9 5/5] docs/zoned-storage:add zoned emulation use case
Date: Mon, 27 Mar 2023 22:45:53 +0800	[thread overview]
Message-ID: <20230327144553.4315-6-faithilikerun@gmail.com> (raw)
In-Reply-To: <20230327144553.4315-1-faithilikerun@gmail.com>

Add the documentation about the example of using virtio-blk driver
to pass the zoned block devices through to the guest.

Signed-off-by: Sam Li <faithilikerun@gmail.com>
---
 docs/devel/zoned-storage.rst | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/docs/devel/zoned-storage.rst b/docs/devel/zoned-storage.rst
index 6a36133e51..05ecf3729c 100644
--- a/docs/devel/zoned-storage.rst
+++ b/docs/devel/zoned-storage.rst
@@ -41,3 +41,20 @@ APIs for zoned storage emulation or testing.
 For example, to test zone_report on a null_blk device using qemu-io is:
 $ path/to/qemu-io --image-opts -n driver=host_device,filename=/dev/nullb0
 -c "zrp offset nr_zones"
+
+To expose the host's zoned block device through virtio-blk, the command line
+can be (includes the -device parameter):
+    -blockdev node-name=drive0,driver=host_device,filename=/dev/nullb0,
+    cache.direct=on \
+    -device virtio-blk-pci,drive=drive0
+Or only use the -drive parameter:
+    -driver driver=host_device,file=/dev/nullb0,if=virtio,cache.direct=on
+
+Additionally, QEMU has several ways of supporting zoned storage, including:
+(1) Using virtio-scsi: --device scsi-block allows for the passing through of
+SCSI ZBC devices, enabling the attachment of ZBC or ZAC HDDs to QEMU.
+(2) PCI device pass-through: While NVMe ZNS emulation is available for testing
+purposes, it cannot yet pass through a zoned device from the host. To pass on
+the NVMe ZNS device to the guest, use VFIO PCI pass the entire NVMe PCI adapter
+through to the guest. Likewise, an HDD HBA can be passed on to QEMU all HDDs
+attached to the HBA.
-- 
2.39.2



  parent reply	other threads:[~2023-03-27 14:47 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-27 14:45 [PATCH v9 0/5] Add zoned storage emulation to virtio-blk driver Sam Li
2023-03-27 14:45 ` [PATCH v9 1/5] include: update virtio_blk headers to v6.3-rc1 Sam Li
2023-03-27 14:45 ` [PATCH v9 2/5] virtio-blk: add zoned storage emulation for zoned devices Sam Li
2023-03-27 14:45 ` [PATCH v9 3/5] block: add accounting for zone append operation Sam Li
2023-03-27 14:45 ` [PATCH v9 4/5] virtio-blk: add some trace events for zoned emulation Sam Li
2023-03-27 14:45 ` Sam Li [this message]
2023-03-29  5:00 ` [PATCH v9 0/5] Add zoned storage emulation to virtio-blk driver Michael S. Tsirkin
2023-04-03 12:18   ` Stefan Hajnoczi
2023-04-04 15:46     ` Sam Li
2023-04-04 20:58       ` Stefan Hajnoczi
  -- strict thread matches above, loose matches on Subject: below --
2023-03-24 10:54 [PATCH v9 4/5] virtio-blk: add some trace events for zoned emulation Sam Li
2023-03-24 10:54 ` [PATCH v9 5/5] docs/zoned-storage:add zoned emulation use case Sam Li
2023-03-24 12:05   ` Sam Li

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=20230327144553.4315-6-faithilikerun@gmail.com \
    --to=faithilikerun@gmail.com \
    --cc=armbru@redhat.com \
    --cc=cohuck@redhat.com \
    --cc=damien.lemoal@opensource.wdc.com \
    --cc=dmitry.fomichev@wdc.com \
    --cc=eblake@redhat.com \
    --cc=hare@suse.de \
    --cc=hreitz@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=kwolf@redhat.com \
    --cc=mst@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=raphael.norwitz@nutanix.com \
    --cc=stefanha@redhat.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).