From: "Michael S. Tsirkin" <mst@redhat.com>
To: virtualization@lists.linux-foundation.org
Subject: [PATCH] virtio-spec: add field for scsi command size
Date: Thu, 14 Mar 2013 13:10:20 +0200 [thread overview]
Message-ID: <20130314111020.GA18050@redhat.com> (raw)
Add field for guest to specify command size for virtio-blk.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
---
virtio-spec.lyx | 83 +++++++++++++++++++++++++++++++++++++++++++++++++++++----
1 file changed, 78 insertions(+), 5 deletions(-)
diff --git a/virtio-spec.lyx b/virtio-spec.lyx
index a8ce3f9..fea97ed 100644
--- a/virtio-spec.lyx
+++ b/virtio-spec.lyx
@@ -5826,6 +5826,16 @@ VIRTIO_BLK_F_TOPOLOGY (10) Device exports information on optimal I/O alignment.
\change_inserted 1531152142 1341302349
VIRTIO_BLK_F_CONFIG_WCE (11) Device can toggle its cache between writeback
and writethrough modes.
+\change_inserted 1986246365 1363257418
+
+\end_layout
+
+\begin_layout Description
+
+\change_inserted 1986246365 1363258629
+VIRTIO_BLK_F_CMD_SIZE (12) cmd_size field is valid.
+\change_inserted 1531152142 1341302349
+
\end_layout
\end_deeper
@@ -5994,6 +6004,30 @@ struct virtio_blk_config {
\change_inserted 1531152142 1341301918
u8 writeback;
+\change_inserted 1986246365 1363257385
+
+\end_layout
+
+\begin_layout Plain Layout
+
+\change_inserted 1986246365 1363258610
+
+ u8 reserved[3];
+\end_layout
+
+\begin_layout Plain Layout
+
+\change_inserted 1986246365 1363259147
+
+ // buffer length for cmd field in requests.
+ reset value 0.
+\end_layout
+
+\begin_layout Plain Layout
+
+\change_inserted 1986246365 1363257810
+
+ u32 cmd_size;
\change_unchanged
\end_layout
@@ -6085,6 +6119,21 @@ Until version 1.1, QEMU remained in writeback mode even after a guest announced
\end_inset
.
+\change_inserted 1986246365 1363258989
+
+\end_layout
+
+\begin_layout Enumerate
+
+\change_inserted 1986246365 1363259237
+If VIRTIO_BLK_F_SCSI_CMD_SIZE is negotiated, Guest should set the desired
+ size for scsi commands to the
+\emph on
+cmd_size
+\emph default
+field.
+\change_unchanged
+
\end_layout
\begin_layout Section*
@@ -6369,8 +6418,33 @@ cmd
\emph default
field is only present for scsi packet command requests, and indicates the
command to perform.
- This field must reside in a single, separate read-only buffer; command
- length can be derived from the length of this buffer.
+
+\change_inserted 1986246365 1363258881
+If VIRTIO_BLK_F_SCSI_CMD_SIZE feature bit is negotiated, Guest must set
+ the command length by writing it to the cmd_size field in configuration
+ space
+\begin_inset Foot
+status open
+
+\begin_layout Plain Layout
+
+\change_inserted 1986246365 1363258931
+Guest should always set cmd_size during initialization.
+\change_unchanged
+
+\end_layout
+
+\end_inset
+
+.
+ If VIRTIO_BLK_F_SCSI_CMD_SIZE is not negotiated,
+\change_deleted 1986246365 1363258703
+T
+\change_inserted 1986246365 1363258703
+t
+\change_unchanged
+his field must reside in a single, separate read-only buffer; command length
+ can be derived from the length of this buffer.
\end_layout
--
MST
next reply other threads:[~2013-03-14 11:10 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-14 11:10 Michael S. Tsirkin [this message]
2013-03-14 15:15 ` [PATCH] virtio-spec: add field for scsi command size Paolo Bonzini
2013-03-14 17:39 ` Michael S. Tsirkin
2013-03-17 9:26 ` Michael S. Tsirkin
2013-06-13 4:42 ` Rusty Russell
2013-06-13 7:33 ` Michael S. Tsirkin
2013-06-13 8:02 ` Michael S. Tsirkin
2013-06-13 8:10 ` Michael S. Tsirkin
2013-06-17 6:37 ` Michael S. Tsirkin
2013-06-19 4:46 ` Rusty Russell
2013-06-19 8:24 ` Michael S. Tsirkin
2013-06-19 8:28 ` Paolo Bonzini
2013-06-19 9:21 ` Michael S. Tsirkin
2013-06-20 2:40 ` Rusty Russell
2013-06-20 9:26 ` Paolo Bonzini
2013-06-30 23:47 ` Rusty Russell
2013-07-01 11:57 ` Paolo Bonzini
2013-07-02 6:04 ` Rusty Russell
2013-07-04 7:49 ` Michael S. Tsirkin
2013-07-07 11:31 ` Michael S. Tsirkin
2013-07-08 1:21 ` Rusty Russell
2013-07-08 5:44 ` Michael S. Tsirkin
2013-07-09 1:19 ` Rusty Russell
2013-07-04 7:39 ` Michael S. Tsirkin
2013-07-04 9:05 ` Paolo Bonzini
2013-07-08 4:28 ` Rusty Russell
2013-07-04 7:38 ` Michael S. Tsirkin
2013-06-20 2:45 ` Rusty Russell
2013-03-18 21:47 ` Michael S. Tsirkin
2013-03-19 1:21 ` Rusty Russell
2013-03-19 7:58 ` Michael S. Tsirkin
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=20130314111020.GA18050@redhat.com \
--to=mst@redhat.com \
--cc=virtualization@lists.linux-foundation.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.