qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 05/24] virtio: core: vq reset feature negotation support


From: Kangjie Xu
Subject: Re: [PATCH v2 05/24] virtio: core: vq reset feature negotation support
Date: Tue, 23 Aug 2022 15:42:12 +0800
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.12.0


在 2022/8/23 15:34, Jason Wang 写道:

在 2022/8/16 09:06, Kangjie Xu 写道:
A a new command line parameter "queue_reset" is added.

Meanwhile, the vq reset feature is disabled for pre-7.1 machines.

Signed-off-by: Kangjie Xu <kangjie.xu@linux.alibaba.com>
Signed-off-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
---
  hw/core/machine.c          | 1 +
  include/hw/virtio/virtio.h | 4 +++-
  2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/hw/core/machine.c b/hw/core/machine.c
index a673302cce..8b22b4647f 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -43,6 +43,7 @@
  GlobalProperty hw_compat_7_0[] = {
      { "arm-gicv3-common", "force-8-bit-prio", "on" },
      { "nvme-ns", "eui64-default", "on"},
+    { "virtio-device", "queue_reset", "false" },


7.1 is about to release so we need to do it for pre-7.2.

Thanks

The current version is 7.0.92, should I wait until 7.1 to be released and submit my patch after that? or just add hw_compat_7_1[] and related support.

Thanks


  };
  const size_t hw_compat_7_0_len = G_N_ELEMENTS(hw_compat_7_0);
  diff --git a/include/hw/virtio/virtio.h b/include/hw/virtio/virtio.h
index 085997d8f3..ed3ecbef80 100644
--- a/include/hw/virtio/virtio.h
+++ b/include/hw/virtio/virtio.h
@@ -295,7 +295,9 @@ typedef struct VirtIORNGConf VirtIORNGConf;
      DEFINE_PROP_BIT64("iommu_platform", _state, _field, \
                        VIRTIO_F_IOMMU_PLATFORM, false), \
      DEFINE_PROP_BIT64("packed", _state, _field, \
-                      VIRTIO_F_RING_PACKED, false)
+                      VIRTIO_F_RING_PACKED, false), \
+    DEFINE_PROP_BIT64("queue_reset", _state, _field, \
+                      VIRTIO_F_RING_RESET, true)
    hwaddr virtio_queue_get_desc_addr(VirtIODevice *vdev, int n);
  bool virtio_queue_enabled_legacy(VirtIODevice *vdev, int n);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]