All of lore.kernel.org
 help / color / mirror / Atom feed
* [virtio-comment] [PATCH v3 0/2] Support enabling virtqueue after DRIVER_OK
@ 2023-10-02  5:15 Parav Pandit
  2023-10-02  5:16 ` [virtio-comment] [PATCH v3 1/2] conformance: Add missing virtqueue reset conformance references Parav Pandit
                   ` (2 more replies)
  0 siblings, 3 replies; 48+ messages in thread
From: Parav Pandit @ 2023-10-02  5:15 UTC (permalink / raw)
  To: virtio-comment, mst, cohuck; +Cc: hengqi, xuanzhuo, shahafs, Parav Pandit

Summary:
========
This patch enables driver to create virtqueues after DRIVER_OK
status bit is set.

This patch take the inspiration from the thread [2] with credits to
Eugenio PÃrez.

Details:
========
Currently, a virtqueue must be enabled before driver has set the
DRIVER_OK status bit.

spec citation to section "Driver Requirements: Device Initialization"

"Perform device-specific setup, including discovery of virtqueues
for the device, optional per-bus setup, reading and possibly writing
the device’s virtio configuration space, and population of virtqueues."

This implies that a virtqueue must be enabled before reaching the
DRIVER_OK stage. There was no explicit mention about ability to
enable the virtqueue after DRIVER_OK stage.

In following usecases, creating a virtqueue after DRIVER_OK phase is
desired.

Use cases:
=========
1. Dynamically create aq when administrative commands to be used.
ate the net device tx/rxq when device is
   opened when deploying for a container.
   In a container, number of virtqueues to be used may be <= max queues.
3. Dynamically create flow filter queues of netdevice when
   ARFS or ethtool filters are enabled as listed in [1].
4. Dynamically create rtc functionality related read virtqueue only
   when net device when timestamping to be used.
5. When XDP program is set, one can create additional XDP specific
   queues without affecting existing queues.

Hence, This patch introduces an existing queue enable and disable
(aka reset) facility and a new feature bit to explicitly indicate such
support by the device.

With this feature, drivers can skip optional queues creation during
driver init time. For example, a Linux net device driver
can create/destroy the transmit and receive queues when net device's
ndo_open() and ndo_stop() callbacks are invoked respectively.

[1] https://lists.oasis-open.org/archives/virtio-comment/202308/msg00263.html
[2] https://lists.oasis-open.org/archives/virtio-comment/202306/msg00097.html

Patch summary:
==============
patch-1 fixes to add virtqueue reset conformance references
patch-2 adds VIRTIO_F_RING_DYNAMIC feature bit, requirements

Please review.

Fixes: https://github.com/oasis-tcs/virtio-spec/issues/177

---
changelog:
v2->v3:
- github issue link updated
v1->v2:
- fixed comments from Michael
- reduced device and driver normatives (simplified)
- replace 'a virtqueue' to 'the virtqueues'
- reworded to remove 'interested'
- avoided repeated 'device initialization text', replaced with
  DRIVER_OK status bit language
- avoided confusing text around 'MAY' in the requirements
- replaced 'the queue' to 'specific virtqueues'
- replaced queue to virtqueue
- simplified commit log to talk about msix
v0->v1:
- fixed comments from Xuan
- removed blank lines
- fixed wrong requirement link to device in driver section


Parav Pandit (2):
  conformance: Add missing virtqueue reset conformance references
  content: Support enabling virtqueue after DRIVER_OK stage

 conformance.tex |  4 ++++
 content.tex     | 49 ++++++++++++++++++++++++++++++++++++++++++++++---
 2 files changed, 50 insertions(+), 3 deletions(-)

-- 
2.34.1


This publicly archived list offers a means to provide input to the
OASIS Virtual I/O Device (VIRTIO) TC.

In order to verify user consent to the Feedback License terms and
to minimize spam in the list archive, subscription is required
before posting.

Subscribe: virtio-comment-subscribe@lists.oasis-open.org
Unsubscribe: virtio-comment-unsubscribe@lists.oasis-open.org
List help: virtio-comment-help@lists.oasis-open.org
List archive: https://lists.oasis-open.org/archives/virtio-comment/
Feedback License: https://www.oasis-open.org/who/ipr/feedback_license.pdf
List Guidelines: https://www.oasis-open.org/policies-guidelines/mailing-lists
Committee: https://www.oasis-open.org/committees/virtio/
Join OASIS: https://www.oasis-open.org/join/


^ permalink raw reply	[flat|nested] 48+ messages in thread

end of thread, other threads:[~2023-10-27 11:55 UTC | newest]

Thread overview: 48+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-02  5:15 [virtio-comment] [PATCH v3 0/2] Support enabling virtqueue after DRIVER_OK Parav Pandit
2023-10-02  5:16 ` [virtio-comment] [PATCH v3 1/2] conformance: Add missing virtqueue reset conformance references Parav Pandit
2023-10-05 16:53   ` Eugenio Perez Martin
2023-10-02  5:16 ` [virtio-comment] [PATCH v3 2/2] content: Support enabling virtqueue after DRIVER_OK stage Parav Pandit
2023-10-05 16:53   ` Eugenio Perez Martin
2023-10-12  6:39   ` [virtio-comment] " Xuan Zhuo
2023-10-17 12:25   ` Cornelia Huck
2023-10-17 12:48     ` [virtio-comment] " Parav Pandit
2023-10-18 10:25       ` Cornelia Huck
2023-10-18 10:28         ` Michael S. Tsirkin
2023-10-18 11:03           ` Cornelia Huck
2023-10-18 11:12             ` Michael S. Tsirkin
2023-10-18 11:12             ` Parav Pandit
2023-10-19 13:57               ` Parav Pandit
2023-10-23 13:29                 ` Parav Pandit
2023-10-23 13:57                   ` Cornelia Huck
2023-10-23 14:00                     ` Parav Pandit
2023-10-23 14:27                       ` Cornelia Huck
2023-10-23 14:53                         ` Parav Pandit
2023-10-23 15:01                           ` Cornelia Huck
2023-10-23 15:21                             ` Parav Pandit
2023-10-25  9:55                               ` Parav Pandit
2023-10-25 10:18                                 ` Cornelia Huck
2023-10-25 10:20                                   ` Parav Pandit
2023-10-25 10:24                                 ` Michael S. Tsirkin
2023-10-26  3:30                                   ` Parav Pandit
2023-10-26  5:39                                     ` Michael S. Tsirkin
2023-10-26  6:02                                       ` Parav Pandit
2023-10-26  6:24                                         ` Michael S. Tsirkin
2023-10-26  6:47                                           ` Parav Pandit
2023-10-26  8:27                                         ` Eugenio Perez Martin
2023-10-26  8:38                                           ` Parav Pandit
2023-10-26  9:15                                             ` Michael S. Tsirkin
2023-10-26  9:24                                               ` Parav Pandit
2023-10-26  9:27                                                 ` Michael S. Tsirkin
2023-10-26  9:45                                                   ` Parav Pandit
2023-10-27 10:13                                                     ` Cornelia Huck
2023-10-27 10:28                                                       ` Parav Pandit
2023-10-27 11:46                                                         ` Cornelia Huck
2023-10-27 11:55                                                           ` Parav Pandit
2023-10-26  9:18                                             ` Michael S. Tsirkin
2023-10-26  9:22                                               ` Parav Pandit
2023-10-26  9:26                                                 ` Michael S. Tsirkin
2023-10-02  5:20 ` [virtio-comment] RE: [PATCH v3 0/2] Support enabling virtqueue after DRIVER_OK Parav Pandit
2023-10-10  4:57   ` Parav Pandit
2023-10-16 16:30     ` Parav Pandit
2023-10-17 11:58       ` Cornelia Huck
2023-10-17 12:50         ` Parav Pandit

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.