Displaying 20 results from an estimated 85 matches for "queue_notify_off".
2013 May 29
0
[PATCH RFC] virtio-pci: new config layout: using memory BAR
...assert(size == sizeof cfg.queue_msix_vector);
return virtio_queue_vector(vdev, vdev->queue_sel);
case offsetof(struct virtio_pci_common_cfg, queue_enable):
+ assert(size == sizeof cfg.queue_enable);
/* TODO */
return 0;
case offsetof(struct virtio_pci_common_cfg, queue_notify_off):
+ assert(size == sizeof cfg.queue_notify_off);
return vdev->queue_sel;
case offsetof(struct virtio_pci_common_cfg, queue_desc):
+ assert(size == 4);
return virtio_queue_get_desc_addr(vdev, vdev->queue_sel) & low;
case offsetof(struct virtio_pci_...
2013 May 29
6
[PATCH RFC] virtio-pci: new config layout: using memory BAR
Anthony Liguori <aliguori at us.ibm.com> writes:
> "Michael S. Tsirkin" <mst at redhat.com> writes:
>> + case offsetof(struct virtio_pci_common_cfg, device_feature_select):
>> + return proxy->device_feature_select;
>
> Oh dear no... Please use defines like the rest of QEMU.
It is pretty ugly.
Yet the structure definitions are descriptive,
2013 May 29
6
[PATCH RFC] virtio-pci: new config layout: using memory BAR
Anthony Liguori <aliguori at us.ibm.com> writes:
> "Michael S. Tsirkin" <mst at redhat.com> writes:
>> + case offsetof(struct virtio_pci_common_cfg, device_feature_select):
>> + return proxy->device_feature_select;
>
> Oh dear no... Please use defines like the rest of QEMU.
It is pretty ugly.
Yet the structure definitions are descriptive,
2014 Dec 30
0
[PATCH RFC v2 4/7] virtio-pci: define layout for virtio 1.0
...+ __le32 length; /* Length. */
+};
+
+#define VIRTIO_PCI_CAP_BAR_SHIFT 5
+#define VIRTIO_PCI_CAP_BAR_MASK 0x7
+#define VIRTIO_PCI_CAP_TYPE_SHIFT 0
+#define VIRTIO_PCI_CAP_TYPE_MASK 0x7
+
+struct virtio_pci_notify_cap {
+ struct virtio_pci_cap cap;
+ __le32 notify_off_multiplier; /* Multiplier for queue_notify_off. */
+};
+
+/* Fields in VIRTIO_PCI_CAP_COMMON_CFG: */
+struct virtio_pci_common_cfg {
+ /* About the whole device. */
+ __le32 device_feature_select; /* read-write */
+ __le32 device_feature; /* read-only */
+ __le32 guest_feature_select; /* read-write */
+ __le32 guest_feature; /* read-write */...
2014 Dec 30
0
[PATCH RFC v2 4/7] virtio-pci: define layout for virtio 1.0
...+ __le32 length; /* Length. */
+};
+
+#define VIRTIO_PCI_CAP_BAR_SHIFT 5
+#define VIRTIO_PCI_CAP_BAR_MASK 0x7
+#define VIRTIO_PCI_CAP_TYPE_SHIFT 0
+#define VIRTIO_PCI_CAP_TYPE_MASK 0x7
+
+struct virtio_pci_notify_cap {
+ struct virtio_pci_cap cap;
+ __le32 notify_off_multiplier; /* Multiplier for queue_notify_off. */
+};
+
+/* Fields in VIRTIO_PCI_CAP_COMMON_CFG: */
+struct virtio_pci_common_cfg {
+ /* About the whole device. */
+ __le32 device_feature_select; /* read-write */
+ __le32 device_feature; /* read-only */
+ __le32 guest_feature_select; /* read-write */
+ __le32 guest_feature; /* read-write */...
2023 Aug 28
1
[PATCH net] virtio: kdoc for struct virtio_pci_modern_device
...cal base of vq notifications
+ * @isr: Where to read and clear interrupt
+ * @notify_len: So we can sanity-check accesses
+ * @device_len: So we can sanity-check accesses
+ * @notify_map_cap: Capability for when we need to map notifications per-vq
+ * @notify_offset_multiplier: Multiply queue_notify_off by this value
+ * (non-legacy mode).
+ * @modern_bars: Bitmask of BARs
+ * @id: Device and vendor id
+ * @device_id_check: Callback defined before vp_modern_probe() to be used to
+ * verify the PCI device is a vendor's expected device rather
+ * than...
2013 May 28
3
[PATCH RFC] virtio-pci: new config layout: using memory BAR
...um(vdev, vdev->queue_sel);
+ case offsetof(struct virtio_pci_common_cfg, queue_msix_vector):
+ return virtio_queue_vector(vdev, vdev->queue_sel);
+ case offsetof(struct virtio_pci_common_cfg, queue_enable):
+ /* TODO */
+ return 0;
+ case offsetof(struct virtio_pci_common_cfg, queue_notify_off):
+ return vdev->queue_sel;
+ case offsetof(struct virtio_pci_common_cfg, queue_desc):
+ return virtio_queue_get_desc_addr(vdev, vdev->queue_sel) & low;
+ case offsetof(struct virtio_pci_common_cfg, queue_desc) + 4:
+ return virtio_queue_get_desc_addr(vdev, vdev...
2013 May 28
3
[PATCH RFC] virtio-pci: new config layout: using memory BAR
...um(vdev, vdev->queue_sel);
+ case offsetof(struct virtio_pci_common_cfg, queue_msix_vector):
+ return virtio_queue_vector(vdev, vdev->queue_sel);
+ case offsetof(struct virtio_pci_common_cfg, queue_enable):
+ /* TODO */
+ return 0;
+ case offsetof(struct virtio_pci_common_cfg, queue_notify_off):
+ return vdev->queue_sel;
+ case offsetof(struct virtio_pci_common_cfg, queue_desc):
+ return virtio_queue_get_desc_addr(vdev, vdev->queue_sel) & low;
+ case offsetof(struct virtio_pci_common_cfg, queue_desc) + 4:
+ return virtio_queue_get_desc_addr(vdev, vdev...
2013 May 28
1
[PATCH] virtio_pci: fix capability format, comments
...ci_common_cfg {
/* About a specific virtqueue. */
__le16 queue_select; /* read-write */
- __le16 queue_size; /* read-write, power of 2. */
+ __le16 queue_size; /* read-write, power of 2, or 0. */
__le16 queue_msix_vector; /* read-write */
__le16 queue_enable; /* read-write */
__le16 queue_notify_off; /* read-only */
--
MST
2013 May 29
1
[RFC 7/11] virtio_pci: new, capability-aware driver.
On Wed, May 29, 2013 at 10:47:52AM +0930, Rusty Russell wrote:
> "Michael S. Tsirkin" <mst at redhat.com> writes:
>
> > On Mon, Dec 12, 2011 at 01:49:13PM +0200, Michael S. Tsirkin wrote:
> >> On Mon, Dec 12, 2011 at 09:15:03AM +1030, Rusty Russell wrote:
> >> > On Sun, 11 Dec 2011 11:42:56 +0200, "Michael S. Tsirkin" <mst at
2013 May 28
0
[PATCH RFC] virtio-pci: new config layout: using memory BAR
...> + case offsetof(struct virtio_pci_common_cfg, queue_msix_vector):
> + return virtio_queue_vector(vdev, vdev->queue_sel);
> + case offsetof(struct virtio_pci_common_cfg, queue_enable):
> + /* TODO */
> + return 0;
> + case offsetof(struct virtio_pci_common_cfg, queue_notify_off):
> + return vdev->queue_sel;
> + case offsetof(struct virtio_pci_common_cfg, queue_desc):
> + return virtio_queue_get_desc_addr(vdev, vdev->queue_sel) & low;
> + case offsetof(struct virtio_pci_common_cfg, queue_desc) + 4:
> + return virtio_queue...
2014 Dec 11
6
[PATCH RFC 0/5] virtio_pci: modern driver
Based on Rusty's patches.
Coding style and funny jokes are his.
Bugs and a star wars reference (should be easy to spot) are mine.
Untested, but useful as basis for beginning the qemu work.
TODO:
= simplify probing: use a common probe function, probe with modern driver
first, if that fails - probe with legacy driver.
BUGS: ATM legacy driver can win and drive a transitional device
2014 Dec 11
6
[PATCH RFC 0/5] virtio_pci: modern driver
Based on Rusty's patches.
Coding style and funny jokes are his.
Bugs and a star wars reference (should be easy to spot) are mine.
Untested, but useful as basis for beginning the qemu work.
TODO:
= simplify probing: use a common probe function, probe with modern driver
first, if that fails - probe with legacy driver.
BUGS: ATM legacy driver can win and drive a transitional device
2015 Jan 21
9
[PATCH post-squash 0/9] virtio 1.0: virtio-pci fixup
This is just repost of all patches with fixups squashed in - convenient
if you just want to remove old ones from queue and apply new ones.
I also tweaked commit log for patch
"virtio_pci: modern driver"
I also included Gerd's tag:
Tested-by: Gerd Hoffmann <kraxel at redhat.com>
You can find it all before the rebase -i --autosquash in my tree:
2015 Jan 21
9
[PATCH post-squash 0/9] virtio 1.0: virtio-pci fixup
This is just repost of all patches with fixups squashed in - convenient
if you just want to remove old ones from queue and apply new ones.
I also tweaked commit log for patch
"virtio_pci: modern driver"
I also included Gerd's tag:
Tested-by: Gerd Hoffmann <kraxel at redhat.com>
You can find it all before the rebase -i --autosquash in my tree:
2015 Jun 24
1
[PATCH] virtio-pci: alloc only resources actually used.
...i_dev);
pci_disable_device(pci_dev);
}
diff --git a/drivers/virtio/virtio_pci_common.h b/drivers/virtio/virtio_pci_common.h
index 28ee4e5..b976d96 100644
--- a/drivers/virtio/virtio_pci_common.h
+++ b/drivers/virtio/virtio_pci_common.h
@@ -75,6 +75,8 @@ struct virtio_pci_device {
/* Multiply queue_notify_off by this value. (non-legacy mode). */
u32 notify_offset_multiplier;
+ int modern_bars;
+
/* Legacy only field */
/* the IO mapping for the PCI config space */
void __iomem *ioaddr;
diff --git a/drivers/virtio/virtio_pci_legacy.c b/drivers/virtio/virtio_pci_legacy.c
index 256a527..48bc979 1...
2015 Jun 24
1
[PATCH] virtio-pci: alloc only resources actually used.
...i_dev);
pci_disable_device(pci_dev);
}
diff --git a/drivers/virtio/virtio_pci_common.h b/drivers/virtio/virtio_pci_common.h
index 28ee4e5..b976d96 100644
--- a/drivers/virtio/virtio_pci_common.h
+++ b/drivers/virtio/virtio_pci_common.h
@@ -75,6 +75,8 @@ struct virtio_pci_device {
/* Multiply queue_notify_off by this value. (non-legacy mode). */
u32 notify_offset_multiplier;
+ int modern_bars;
+
/* Legacy only field */
/* the IO mapping for the PCI config space */
void __iomem *ioaddr;
diff --git a/drivers/virtio/virtio_pci_legacy.c b/drivers/virtio/virtio_pci_legacy.c
index 256a527..48bc979 1...
2015 Jun 23
1
[PATCH] virtio-pci: alloc only resources actually used.
...i_dev);
pci_disable_device(pci_dev);
}
diff --git a/drivers/virtio/virtio_pci_common.h b/drivers/virtio/virtio_pci_common.h
index 28ee4e5..b976d96 100644
--- a/drivers/virtio/virtio_pci_common.h
+++ b/drivers/virtio/virtio_pci_common.h
@@ -75,6 +75,8 @@ struct virtio_pci_device {
/* Multiply queue_notify_off by this value. (non-legacy mode). */
u32 notify_offset_multiplier;
+ int modern_bars;
+
/* Legacy only field */
/* the IO mapping for the PCI config space */
void __iomem *ioaddr;
diff --git a/drivers/virtio/virtio_pci_legacy.c b/drivers/virtio/virtio_pci_legacy.c
index 256a527..48bc979 1...
2015 Jun 23
1
[PATCH] virtio-pci: alloc only resources actually used.
...i_dev);
pci_disable_device(pci_dev);
}
diff --git a/drivers/virtio/virtio_pci_common.h b/drivers/virtio/virtio_pci_common.h
index 28ee4e5..b976d96 100644
--- a/drivers/virtio/virtio_pci_common.h
+++ b/drivers/virtio/virtio_pci_common.h
@@ -75,6 +75,8 @@ struct virtio_pci_device {
/* Multiply queue_notify_off by this value. (non-legacy mode). */
u32 notify_offset_multiplier;
+ int modern_bars;
+
/* Legacy only field */
/* the IO mapping for the PCI config space */
void __iomem *ioaddr;
diff --git a/drivers/virtio/virtio_pci_legacy.c b/drivers/virtio/virtio_pci_legacy.c
index 256a527..48bc979 1...
2020 Jun 10
2
[PATCH V3] vdpa: introduce virtio pci driver
...gt;> + /* The IO mapping for the PCI config space */
>> + void __iomem * const *base;
>> + struct virtio_pci_common_cfg __iomem *common;
>> + void __iomem *device;
>> + /* Base of vq notifications */
>> + void __iomem *notify;
>> +
>> + /* Multiplier for queue_notify_off. */
>> + u32 notify_off_multiplier;
>> +
>> + int modern_bars;
>> + int vectors;
>> +};
>> +
>> +static struct vp_vdpa *vdpa_to_vp(struct vdpa_device *vdpa)
>> +{
>> + return container_of(vdpa, struct vp_vdpa, vdpa);
>> +}
>> +
>&...