From: "Michael S. Tsirkin" <mst@redhat.com>
To: Parav Pandit <parav@nvidia.com>
Cc: Max Gurtovoy <mgurtovoy@nvidia.com>,
"virtio-comment@lists.oasis-open.org"
<virtio-comment@lists.oasis-open.org>,
"virtio-dev@lists.oasis-open.org"
<virtio-dev@lists.oasis-open.org>,
"jasowang@redhat.com" <jasowang@redhat.com>,
"cohuck@redhat.com" <cohuck@redhat.com>,
"sgarzare@redhat.com" <sgarzare@redhat.com>,
"stefanha@redhat.com" <stefanha@redhat.com>,
"nrupal.jani@intel.com" <nrupal.jani@intel.com>,
"Piotr.Uminski@intel.com" <Piotr.Uminski@intel.com>,
"hang.yuan@intel.com" <hang.yuan@intel.com>,
"virtio@lists.oasis-open.org" <virtio@lists.oasis-open.org>,
Jiri Pirko <jiri@nvidia.com>,
Zhu Lingshan <lingshan.zhu@intel.com>,
"pasic@linux.ibm.com" <pasic@linux.ibm.com>,
Shahaf Shuler <shahafs@nvidia.com>
Subject: [virtio-dev] Re: [PATCH v12 05/10] pci: add admin vq registers to virtio over pci
Date: Fri, 5 May 2023 11:12:01 -0400 [thread overview]
Message-ID: <20230505111144-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <PH0PR12MB54819792ED9279E66B63AC26DC6A9@PH0PR12MB5481.namprd12.prod.outlook.com>
On Thu, Apr 27, 2023 at 12:11:31AM +0000, Parav Pandit wrote:
>
> > From: Max Gurtovoy <mgurtovoy@nvidia.com>
> > Sent: Wednesday, April 26, 2023 6:31 PM
> > >>>
> > >>>>> +If VIRTIO_F_ADMIN_VQ has been negotiated, and if the driver
> > >>>>> +configures any administration virtqueues, the driver MUST
> > >>>>> +configure the administration virtqueues using the index in the
> > >>>>> +range \field{admin_queue_index} to \field{admin_queue_index} +
> > >>>>> +\field{admin_queue_num} - 1 inclusive.
> > >>>>> +The driver MAY configure less administration virtqueues than
> > >>>>> +supported by the device.
> > >>>>
> > >>>> we need to say something about other virtq's indexes.
> > >>>> For example, if aq index = 0 then for the vblk device the request
> > >>>> queues would start from index = 1.
> > >>>>
> > >>>> can we address this ?
> > >>>
> > >>> It may slightly complicate the device implementation when device
> > >>> dynamically changes the VQ indices based on the negotiation of the
> > >>> feature bit.
> > >>> Also the drivers with and without need a different VQ index handling.
> > >>>
> > >>> I am thinking that aq index should not overlap with the vq index in
> > >>> range exposed by num_queues field.
> > >>>
> > >>> This also aligns to the exclusion of aq count from num_queues field.
> > >>
> > >> The namespace of the aq and other vq index is the same.
> > >> And the configuration is done using the same queue_select and other
> > registers.
> > >> Thus, we need to address the above comment otherwise all the device
> > >> virtqueues chapters are wrong.
> > >
> > > Michael has added below line in this patch in num_queues description so it
> > covers the exclusion part.
> > >
> > > + This excludes administration virtqueues if any are supported.
> > >
> >
> > This is not related to what I was talking about.
> >
> > For example if vnet device:
> >
> > 0 receiveq1
> > 1 transmitq1
> > ...
> > 2(N-1) receiveqN
> > 2(N-1)+1 transmitqN
> > 2N controlq
> > N=1 if neither VIRTIO_NET_F_MQ nor VIRTIO_NET_F_RSS are negotiated,
> > otherwise N is set by max_- virtqueue_pairs.
> > controlq only exists if VIRTIO_NET_F_CTRL_VQ set
> >
> > and in vfs device:
> >
> > 0 hiprio
> > 1...n request queues
> >
> > So if one device will expose adminq that will be with index 0 the above is wrong
> > description.
> >
> > Agree that this should be addressed ?
>
> Oh yes, I agree.
> In response [1] I acked it as,
>
> "I am thinking that aq index should not overlap with the vq index in range exposed by num_queues field."
>
> So, admin_queue_index description needs to have description like below.
>
> admin_queue_index must be greater than or equal to the value of num_queues.
>
> Yes?
>
> [1] https://lore.kernel.org/virtio-dev/a4b1596c-2132-714a-7557-fa5249a55945@nvidia.com/
this is present in the conformance clause patch:
+If VIRTIO_F_ADMIN_VQ has been negotiated, the value
+\field{admin_queue_index} MUST be equal to, or bigger than
+\field{num_queues}; also, \field{admin_queue_num} MUST be
+smaller than, or equal to 0x10000 - \field{admin_queue_index},
+to ensure that indices of valid admin queues fit into
+a 16 bit range beyond all other virtqueues.
---------------------------------------------------------------------
To unsubscribe, e-mail: virtio-dev-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: virtio-dev-help@lists.oasis-open.org
next prev parent reply other threads:[~2023-05-05 15:12 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-24 16:44 [virtio-dev] [PATCH v12 00/10] Introduce device group and device management Michael S. Tsirkin
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 01/10] virtio: document forward compatibility guarantees Michael S. Tsirkin
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 02/10] admin: introduce device group and related concepts Michael S. Tsirkin
2023-04-24 21:47 ` [virtio-dev] " Parav Pandit
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 03/10] admin: introduce group administration commands Michael S. Tsirkin
[not found] ` <d9b0454c-747a-4ac9-b00d-005e066fa3e4@nvidia.com>
2023-04-24 21:33 ` [virtio-dev] " Michael S. Tsirkin
2023-04-24 22:07 ` Parav Pandit
2023-04-25 6:20 ` Michael S. Tsirkin
2023-04-25 13:25 ` [virtio-dev] " Parav Pandit
2023-04-25 13:31 ` [virtio-dev] " Michael S. Tsirkin
2023-04-25 13:38 ` [virtio-dev] " Parav Pandit
2023-04-25 20:04 ` [virtio-dev] " Michael S. Tsirkin
2023-04-25 20:18 ` [virtio-dev] " Parav Pandit
2023-04-25 20:55 ` [virtio-dev] " Michael S. Tsirkin
2023-04-26 18:18 ` [virtio-dev] RE: [virtio-comment] " Parav Pandit
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 04/10] admin: introduce virtio admin virtqueues Michael S. Tsirkin
2023-04-24 22:32 ` [virtio-dev] " Parav Pandit
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 05/10] pci: add admin vq registers to virtio over pci Michael S. Tsirkin
[not found] ` <5858e2e6-0b50-c155-85e9-eea6dfb533e1@nvidia.com>
2023-04-24 22:14 ` [virtio-dev] " Parav Pandit
[not found] ` <5cb79b37-a066-283c-eee7-afd26146d988@nvidia.com>
2023-04-26 22:11 ` [virtio-dev] " Parav Pandit
[not found] ` <b7addd39-d913-700f-ac67-1412825d580b@nvidia.com>
2023-04-27 0:11 ` Parav Pandit
2023-05-05 15:12 ` Michael S. Tsirkin [this message]
2023-05-05 15:14 ` Parav Pandit
2023-04-27 17:57 ` [virtio-dev] " Michael S. Tsirkin
2023-05-05 15:22 ` Michael S. Tsirkin
2023-05-05 15:25 ` [virtio-dev] " Parav Pandit
2023-04-24 22:29 ` [virtio-dev] " Parav Pandit
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 06/10] mmio: document ADMIN_VQ as reserved Michael S. Tsirkin
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 07/10] ccw: " Michael S. Tsirkin
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 08/10] admin: command list discovery Michael S. Tsirkin
2023-04-24 22:27 ` [virtio-dev] " Parav Pandit
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 09/10] admin: conformance clauses Michael S. Tsirkin
2023-04-24 16:44 ` [virtio-dev] [PATCH v12 10/10] ccw: document more reserved features Michael S. Tsirkin
2023-04-24 22:17 ` [virtio-dev] " Parav Pandit
2023-04-24 21:34 ` [virtio-dev] Re: [PATCH v12 00/10] Introduce device group and device management Parav Pandit
2023-05-02 7:51 ` [virtio-dev] Re: [virtio] " David Edmondson
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=20230505111144-mutt-send-email-mst@kernel.org \
--to=mst@redhat.com \
--cc=Piotr.Uminski@intel.com \
--cc=cohuck@redhat.com \
--cc=hang.yuan@intel.com \
--cc=jasowang@redhat.com \
--cc=jiri@nvidia.com \
--cc=lingshan.zhu@intel.com \
--cc=mgurtovoy@nvidia.com \
--cc=nrupal.jani@intel.com \
--cc=parav@nvidia.com \
--cc=pasic@linux.ibm.com \
--cc=sgarzare@redhat.com \
--cc=shahafs@nvidia.com \
--cc=stefanha@redhat.com \
--cc=virtio-comment@lists.oasis-open.org \
--cc=virtio-dev@lists.oasis-open.org \
--cc=virtio@lists.oasis-open.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox