From c04faffcd95f4bbd67e0beb34ccf398107715ce4 Mon Sep 17 00:00:00 2001 From: rusty Date: Wed, 30 Oct 2013 06:14:00 +0000 Subject: virtio-ccw: split descriptor/available/used rings (alternate) Extend vq_info_block so that the addresses for descriptor table, available ring and used ring may be transmitted independently. VIRTIO-23 Signed-off-by: Cornelia Huck Signed-off-by: Rusty Russell git-svn-id: https://tools.oasis-open.org/version-control/svn/virtio@70 0c8fb4dd-22a2-4bb5-bc14-6c75a5f43652 --- virtio-v1.0-wd01-part1-specification.txt | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/virtio-v1.0-wd01-part1-specification.txt b/virtio-v1.0-wd01-part1-specification.txt index a2d3059..c26fea2 100644 --- a/virtio-v1.0-wd01-part1-specification.txt +++ b/virtio-v1.0-wd01-part1-specification.txt @@ -1812,15 +1812,34 @@ host about the location used for its queue. The transmitted structure is struct vq_info_block { + __u64 desc; + __u32 res0; + __u16 index; + __u16 num; + __u64 avail; + __u64 used; +} __attribute__ ((packed)); + +desc, avail and used contain the guest addresses for the descriptor table, +available ring and used ring for queue index, respectively. The actual +virtqueue size (number of allocated buffers) is transmitted in num. +res0 is reserved and must be ignored by the device. + +2.3.3.2.2.1. Legacy Interface: A Note on Configuring a Virtqueue +---------------------------------------------------------------- + +For a legacy driver or for a driver that selected revision 0, +CCW_CMD_SET_VQ uses the following communication block: + +struct vq_info_block_legacy { __u64 queue; __u32 align; __u16 index; __u16 num; } __attribute__ ((packed)); -queue contains the guest address for queue index. The actual -number of allocated buffers is transmitted in num and their -alignment in align. +queue contains the guest address for queue index, num the number of buffers +and align the alignment. 100.3.3.2.2. Virtqueue Layout ------------------------------ -- cgit v1.2.3