>
> static void
> -vduse_events_handler(int fd, void *arg, int *remove __rte_unused)
> +vduse_events_handler(int fd, void *arg, int *close __rte_unused)
> {
>struct virtio_net *dev = arg;
>struct vduse_dev_request req;
> @@ -563,14 +563,13 @@ vduse_reconnect_log_check(struct virtio_net *dev,
> uint64_t features, uint32_t to
> }
>
> static void
> -vduse_reconnect_handler(int fd, void *arg, int *remove)
> +vduse_reconnect_handler(int fd __rte_unused, void *arg, int *close)
> {
>struct virtio_net *dev = arg;
>
>vduse_device_start(dev, true);
>
> - close(fd);
> - *remove = 1;
> + *close = 1;
> }
>
> static int
> --
> 2.48.1
>
Reviewed-by: Chenbo Xia
t PMD acts as client or server.
> + (Default: 0 (server))
> +
> #. ``iommu-support``:
>
> It is used to enable iommu support in vhost library.
> —
> 2.47.0
>
Reviewed-by: Chenbo Xia
@@ -1028,8 +1025,7 @@ rte_vhost_driver_register(const char *path, uint64_t
> flags)
>}
> out:
>pthread_mutex_unlock(&vhost_user.mutex);
> -
> - return ret;
> + return -1;
> }
>
> static bool
> --
> 2.48.1
>
Reviewed-by: Chenbo Xia
Hi David,
> On Feb 4, 2025, at 21:18, David Marchand wrote:
>
> External email: Use caution opening links or attachments
>
>
> Hello vhost maintainers,
>
> On Tue, Dec 24, 2024 at 4:50 PM Maxime Coquelin
> wrote:
>>
>> The vhost FD manager provides a way for the read/write
>> callbacks to r
; vchan_id);
>else
> - nb_rx = virtio_dev_tx_async_split_compliant(dev, vq,
> mbuf_pool,
> - pkts, count, dma_id, vchan_id);
> + nb_rx += virtio_dev_tx_async_split_compliant(dev, vq,
> mbuf_pool,
> + pkts + nb_rx, count - nb_rx, dma_id,
> vchan_id);
>}
>
>*nr_inflight = vq->async->pkts_inflight_n;
> @@ -4315,9 +4306,6 @@ rte_vhost_async_try_dequeue_burst(int vid, uint16_t
> queue_id,
> out_access_unlock:
>rte_rwlock_read_unlock(&vq->access_lock);
>
> - if (unlikely(rarp_mbuf != NULL))
> - nb_rx += 1;
> -
> out_no_unlock:
>return nb_rx;
> }
> --
> 2.47.1
>
Reviewed-by: Chenbo Xia
IRTIO_DEV_LEGACY_OL_FLAGS)
> - count = virtio_dev_tx_async_split_legacy(dev, vq,
> mbuf_pool,
> + nb_rx = virtio_dev_tx_async_split_legacy(dev, vq,
> mbuf_pool,
> pkts, count, dma_id, vchan_id);
>else
> - count = virtio_dev_tx_async_split_compliant(dev, vq,
> mbuf_pool,
> + nb_rx = virtio_dev_tx_async_split_compliant(dev, vq,
> mbuf_pool,
>pkts, count, dma_id, vchan_id);
>}
>
>*nr_inflight = vq->async->pkts_inflight_n;
> - vhost_queue_stats_update(dev, vq, pkts, count);
> + vhost_queue_stats_update(dev, vq, pkts, nb_rx);
>
> out:
>vhost_user_iotlb_rd_unlock(vq);
> @@ -4322,8 +4316,8 @@ rte_vhost_async_try_dequeue_burst(int vid, uint16_t
> queue_id,
>rte_rwlock_read_unlock(&vq->access_lock);
>
>if (unlikely(rarp_mbuf != NULL))
> - count += 1;
> + nb_rx += 1;
>
> out_no_unlock:
> - return count;
> + return nb_rx;
> }
> --
> 2.47.1
>
Reviewed-by: Chenbo Xia
id, uint16_t queue_id,
>rte_rwlock_read_unlock(&vq->access_lock);
>
>virtio_dev_vring_translate(dev, vq);
> +
> + count = 0;
>goto out_no_unlock;
>}
>
> --
> 2.47.1
>
Reviewed-by: Chenbo Xia
um number of queue pairs supported by VDUSE
> devices. However, a log mentioning the maximim number of
maximum
With above fixed:
Reviewed-by: Chenbo Xia
> queue pairs is being set is emitted unconditionally, which
> may confuse the end user.
>
> This patch moves this log after the b
Hi Gowrishankar,
> On Nov 27, 2024, at 14:50, Gowrishankar Muthukrishnan
> wrote:
>
> External email: Use caution opening links or attachments
>
>
> Hi,
> I wanted to follow up on my previous message regarding the development of a
> vhost vDPA host driver for crypto/virtio. We have proposed
Hi,
> On Oct 21, 2024, at 09:52, Wathsala Vithanage
> wrote:
>
> External email: Use caution opening links or attachments
>
>
> DPDK applications benefit from Direct Cache Access (DCA) features like
> Intel DDIO and Arm's write-allocate-to-SLC. However, those features do
> not allow fine-grai
> @@ -97,7 +98,6 @@ EXPERIMENTAL {
>rte_vhost_async_dma_unconfigure;
>
># added in 23.07
> - rte_vhost_driver_set_max_queue_num;
>rte_vhost_notify_guest;
> };
>
> —
> 2.46.2
>
Reviewed-by: Chenbo Xia
bdev->data = rte_zmalloc(NULL, blk_cnt * blk_size, 0);
>if (!bdev->data) {
>fprintf(stderr, "No enough reserved huge memory for disk\n");
> - free(bdev);
> + rte_free(bdev);
>return NULL;
>}
>
> --
> 2.45.2
>
Reviewed-by: Chenbo Xia
errno));
> + ret = -1;
> + goto out_dev_destroy;
> + }
> +
> + ret = fdset_add(vduse.fdset, reco_fd,
> vduse_reconnect_handler, NULL, dev);
> + if (ret) {
> + VHOST_CONFIG_LOG(name, ERR, "Failed to add reconnect
> fd %d to vduse fdset",
> + reco_fd);
> + goto out_dev_destroy;
> + }
> +
> + ret = eventfd_write(reco_fd, (eventfd_t)1);
> + if (ret < 0) {
> + VHOST_CONFIG_LOG(name, ERR, "Failed to write to
> reconnect eventfd");
> + goto out_dev_destroy;
> + }
> + }
>
>return 0;
>
> @@ -587,6 +796,9 @@ vduse_device_destroy(const char *path)
>if (vid == RTE_MAX_VHOST_DEVICE)
>return -1;
>
> + if (dev->reconnect_log)
> + munmap(dev->reconnect_log, sizeof(*dev->reconnect_log));
> +
>vduse_device_stop(dev);
>
>fdset_del(vduse.fdset, dev->vduse_dev_fd);
> @@ -597,10 +809,26 @@ vduse_device_destroy(const char *path)
>}
>
>if (dev->vduse_ctrl_fd >= 0) {
> + char reconnect_file[PATH_MAX];
> +
>ret = ioctl(dev->vduse_ctrl_fd, VDUSE_DESTROY_DEV, name);
> - if (ret)
> + if (ret) {
>VHOST_CONFIG_LOG(name, ERR, "Failed to destroy VDUSE
> device: %s",
>strerror(errno));
> + } else {
> + /*
> +* VDUSE device was no more attached to the vDPA bus,
> +* so we can remove the reconnect file.
> +*/
> + ret = snprintf(reconnect_file,
> sizeof(reconnect_file), "%s/%s",
> + vduse_reconnect_dir, name);
> + if (ret < 0 || ret == sizeof(reconnect_file))
> + VHOST_CONFIG_LOG(name, ERR,
> + "Failed to create vduse
> reconnect path name");
> + else
> + unlink(reconnect_file);
> + }
> +
>close(dev->vduse_ctrl_fd);
>dev->vduse_ctrl_fd = -1;
>}
> --
> 2.46.0
>
Reviewed-by: Chenbo Xia
uct virtio_net *dev, struct
> vhost_virtqueue *cvq,
>cvq->last_avail_idx++;
>if (cvq->last_avail_idx >= cvq->size)
>cvq->last_avail_idx -= cvq->size;
> + vhost_virtqueue_reconnect_log_split(cvq);
>
>if (dev->features & (1ULL << VIRTIO_RING_F_EVENT_IDX))
>vhost_avail_event(cvq) = cvq->last_avail_idx;
> @@ -181,6 +182,7 @@ virtio_net_ctrl_pop(struct virtio_net *dev, struct
> vhost_virtqueue *cvq,
>cvq->last_avail_idx++;
>if (cvq->last_avail_idx >= cvq->size)
>cvq->last_avail_idx -= cvq->size;
> + vhost_virtqueue_reconnect_log_split(cvq);
>
>if (dev->features & (1ULL << VIRTIO_RING_F_EVENT_IDX))
>vhost_avail_event(cvq) = cvq->last_avail_idx;
> --
> 2.46.0
>
Reviewed-by: Chenbo Xia
Hi Maxime,
> On Sep 5, 2024, at 22:26, Maxime Coquelin wrote:
>
> External email: Use caution opening links or attachments
>
>
> This patch enables VDUSE reconnection support making use of
> the newly introduced reconnection mechanism in Vhost
> library.
>
> At DPDK VDUSE device creation time
name, sizeof(devname), "/dev/uio%u", uio_num);
> + /* save fd */
> + fd = open(devname, O_RDWR);
> + if (fd < 0) {
> + PCI_LOG(ERR, "Cannot open %s: %s", devname, strerror(errno));
> + goto error;
> + }
> +
> + if (rte_intr_fd_set(dev->intr_handle, fd))
> + goto error;
> +
> /* allocate the mapping details for secondary processes*/
> *uio_res = rte_zmalloc("UIO_RES", sizeof(**uio_res), 0);
> if (*uio_res == NULL) {
> --
> 2.45.0
>
Reviewed-by: Chenbo Xia
-digit.
Please also fix the coding style:
WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line
#176: FILE: drivers/bus/pci/linux/pci_uio.c:265:
+ * closed, so open it only in the primary process */
With above fixed:
Reviewed-by: Chenbo Xia
&g
}
> + ea = rte_pktmbuf_mtod(pkt, const struct rte_ether_addr *);
> + RTE_BUILD_BUG_ON(offsetof(struct virtqueue_stats, broadcast)
> !=
> + offsetof(struct virtqueue_stats, multicast) +
> sizeof(uint64_t));
> + if (unlikely(rte_is_multicast_ether_addr(ea)))
> +
> (&stats->multicast)[rte_is_broadcast_ether_addr(ea)]++;
>}
> }
>
> --
> 2.43.0
>
Reviewed-by: Chenbo Xia
-- a/drivers/net/virtio/virtio_rxtx.h
> +++ b/drivers/net/virtio/virtio_rxtx.h
> @@ -35,7 +35,7 @@ struct virtnet_tx {
> };
>
> int virtio_rxq_vec_setup(struct virtnet_rx *rxvq);
> -void virtio_update_packet_stats(struct virtnet_stats *stats,
> - struct rte_mbuf *mbuf);
> +void virtio_update_packet_stats(struct virtnet_stats *const stats,
> + const struct rte_mbuf *const mbuf);
>
> #endif /* _VIRTIO_RXTX_H_ */
> —
> 2.43.0
>
Reviewed-by: Chenbo Xia
>> Reviewed-by: Chaoyong He
>> Reviewed-by: Long Wu
>> Reviewed-by: Peng Zhang
>> Acked-by: Anatoly Burakov
>
> Chenbo,
> Are you ok with this fix?
Sorry that I was interrupted when I was reviewing this and later I forgot..
For this patch:
Reviewed-by: Chenbo Xia
>
> Thanks.
>
> --
> David Marchand
ase address")
The commit id length should be 12.
Since QEMU always send offset 0, I think it’s no need to backport the
patch, so no cc-stable is fine.
With above fixed:
Reviewed-by: Chenbo Xia
> Signed-off-by: BillXiang
> ---
> lib/vhost/vhost_user.c | 2 +-
> 1 file changed,
_pci_device *dev)
>}
>return -1;
> }
> - dev->mem_resource[i].addr = mapaddr;
> + dev->mem_resource[res_idx].addr = mapaddr;
> +
> + i++;
>}
>return 0;
>}
> —
> 2.39.1
>
Reviewed-by: Chenbo Xia
mmon_uio.c | 15 +--
> drivers/bus/pci/pci_params.c | 9 +-
> drivers/bus/pci/private.h| 6 +
> drivers/bus/pci/windows/pci.c| 13 +-
> drivers/bus/pci/windows/pci_netuio.c | 7 +-
> 10 files changed, 202 insertions(+), 277 deletions(-)
Reviewed-by: Chenbo Xia
Hi,
I am not sure why we are calling ioctl(vfio_dev_fd, VFIO_DEVICE_RESET) in
pci_rte_vfio_setup_device()
, which is after opening the VFIO device fd. As I see in linux kernel, opening
the vfio device fd will
trigger the device reset and put device into clean state. Another
VFIO_DEVICE_RESET se
Hi Maxime,
> On Apr 9, 2024, at 19:48, Maxime Coquelin wrote:
>
> External email: Use caution opening links or attachments
>
>
> From: David Marchand
>
> Switch to epoll so that the concern over the poll() fd array
> is removed.
> Add a simple list of used entries and track the next free ent
Hi Maxime,
> On Apr 9, 2024, at 19:48, Maxime Coquelin wrote:
>
> External email: Use caution opening links or attachments
>
>
> This patch heavily reworks fdset initialization:
> - fdsets are now dynamically allocated by the FD manager
> - the event dispatcher is now created by the FD manager
On Nov 22, 2023, at 18:22, Mingjin Ye wrote:
>
> External email: Use caution opening links or attachments
>
>
> This patch adds an API to support getting device information.
>
> The driver can use the "rte_vfio_get_device_info" helper to get
> device information from EAL.
>
> Signed-off-by: M
13/* Page Request Interface */
> -#define RTE_PCI_EXT_CAP_ID_PASID 0x1B/* Process Address Space ID */
> +#define RTE_PCI_EXT_CAP_ID_PASID 0x1b/* Process Address Space ID */
>
> /* Advanced Error Reporting (RTE_PCI_EXT_CAP_ID_ERR) */
> #define RTE_PCI_ERR_UNCOR_STATUS 0x04/* Uncorrectable Error Status
> */
> --
> 2.25.1
>
Reviewed-by: Chenbo Xia
On Nov 17, 2023, at 01:43, Chen, Mike Ximing wrote:
>
> External email: Use caution opening links or attachments
>
>
>> -Original Message-----
>> From: Chenbo Xia
>> Sent: Tuesday, November 14, 2023 8:54 PM
>> To: Sevincer, Abdullah
>> Cc: de
> On Nov 14, 2023, at 18:23, Mingjin Ye wrote:
>
> External email: Use caution opening links or attachments
>
>
> This patch adds an API to support getting device information.
>
> The driver can use the "rte_vfio_get_device_info" helper to get
> device information from EAL.
>
> Cc: sta...@d
On Nov 15, 2023, at 01:39, Sevincer, Abdullah
wrote:
>
> External email: Use caution opening links or attachments
>
>
>> +I don’t know about the details, so it means for different devices that
>> support PASID, they have different offsets?
>
>> +Btw, Is this cap still not exposed to user spa
+Nipun
Please cc me and Nipun if there is a new version.
> On Nov 14, 2023, at 01:27, Abdullah Sevincer
> wrote:
>
> External email: Use caution opening links or attachments
>
>
> This commit revises PASID control function to accept PASID offset to
> pasid *structure* instead of taking exact
Sorry I missed all previous versions…
+ARM guy
> On Nov 4, 2023, at 02:29, Abdullah Sevincer
> wrote:
>
> External email: Use caution opening links or attachments
>
>
> This commit implements an internal api to enable and disable PASID for
> a device e.g. device driver event/dlb2.
>
> For k
I left Intel and joined Nvidia, so update my email address.
Signed-off-by: Chenbo Xia
Acked-by: Maxime Coquelin
---
.mailmap| 2 +-
MAINTAINERS | 12 ++--
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/.mailmap b/.mailmap
index 3f5bab26a8..d40b3ad6c0 100644
--- a
I left Intel and joined Nvidia, so update my email address.
Signed-off-by: Chenbo Xia
---
.mailmap| 2 +-
MAINTAINERS | 12 ++--
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/.mailmap b/.mailmap
index 3f5bab26a8..2ff31b008f 100644
--- a/.mailmap
+++ b/.mailmap
I am leaving Intel, so replace my Intel email with personal one
temporarily.
Signed-off-by: Chenbo Xia
---
.mailmap| 2 +-
MAINTAINERS | 12 ++--
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/.mailmap b/.mailmap
index 864d33ee46..8cb3c1e80f 100644
--- a/.mailmap
Add myself as maintainer of PCI bus driver and co-maintainer of PCI
library.
Signed-off-by: Chenbo Xia
---
MAINTAINERS | 2 ++
1 file changed, 2 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 906b31f97c..fea84b8cb9 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -586,6 +586,7 @@ F
MMIO read and write APIs were defined in PCI bus. But the corresponding
implementations are not done in windows. This patch fixes this.
Bugzilla ID: 1245
Fixes: 095cf6e68b28 ("bus/pci: introduce MMIO read/write")
Cc: sta...@dpdk.org
Signed-off-by: Chenbo Xia
---
drivers/bus/pci/win
This patch adds sparse mmap support in PCI bus. Sparse mmap is a
capability defined in VFIO which allows multiple mmap areas in one
VFIO region.
Signed-off-by: Chenbo Xia
---
drivers/baseband/acc/rte_acc100_pmd.c | 6 +-
drivers/baseband/acc/rte_vrb_pmd.c| 6
The MMIO regions may not be mmap-able for VFIO-PCI devices.
In this case, the driver should explicitly do read and write
to access these regions.
Signed-off-by: Chenbo Xia
---
drivers/bus/pci/bsd/pci.c| 22 +++
drivers/bus/pci/linux/pci.c | 46
More fields will be added.
Signed-off-by: Chenbo Xia
---
drivers/bus/pci/bsd/pci.c| 13 -
drivers/bus/pci/linux/pci.c | 28
drivers/bus/pci/pci_common.c | 12 ++--
drivers/bus/pci/private.h| 14 +-
4 files changed, 43 inser
The value 40 used in VFIO_GET_REGION_ADDR() is a private value
(VFIO_PCI_OFFSET_SHIFT) defined in Linux kernel source [1]. It
is not part of VFIO API, and we should not depend on it.
[1] https://github.com/torvalds/linux/blob/v6.2/include/linux/vfio_pci_core.h
Signed-off-by: Chenbo Xia
driver choose which way it
perfers since either option has its own Pros & Cons.
Please share your comments, Thanks!
Chenbo Xia (4):
bus/pci: introduce an internal representation of PCI device
bus/pci: avoid depending on private value in kernel source
bus/pci: introduce helper for M
fail.
This patch checks the device's max mtu before setting the ethdev
configuration. If the device has a max mtu, use that value to
configure.
Fixes: 1bb4a528c41f ("ethdev: fix max Rx packet length")
Signed-off-by: Chenbo Xia
Reported-by: Xingguang He
---
examples/vhost/main.c |
Ten vhost APIs were announced to be stable and promoted in below
commit, so remove the related deprecation notice.
Fixes: 945ef8a04098 ("vhost: promote some APIs to stable")
Signed-off-by: Chenbo Xia
Reported-by: Maxime Coquelin
---
doc/guides/rel_notes/deprecation.rst | 8 --
-by: Chenbo Xia
Acked-by: Ray Kinsella
Acked-by: Rosen Xu
---
app/test/virtual_pmd.c| 2 +-
doc/guides/rel_notes/release_21_11.rst| 2 +
drivers/baseband/acc100/rte_acc100_pmd.c | 2 +-
.../fpga_5gnr_fec/rte_fpga_5gnr_fec.c | 2 +-
drivers
PCI ID and address in structure rte_kni_conf are never used. And in
order not to break ABI, replace these variables with reserved bytes.
Signed-off-by: Chenbo Xia
---
lib/kni/rte_kni.h | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/lib/kni/rte_kni.h b/lib/kni/rte_kni.h
PCI device id and address in structure rte_kni_conf are never used
in the test, example and kni library. So remove the related code.
Fixes: ea6b39b5b847 ("kni: remove ethtool support")
Cc: sta...@dpdk.org
Signed-off-by: Chenbo Xia
Acked-by: Ferruh Yigit
---
app/test/test_kni.c
The header rte_bus_pci.h is included in kni example but nothing
in it is used. So remove it.
Signed-off-by: Chenbo Xia
Acked-by: Ferruh Yigit
---
examples/kni/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/examples/kni/main.c b/examples/kni/main.c
index beabb3c848..6dc335c0b5 100644
Currently ethtool example uses struct rte_pci_device to know PCI
address of a device. As this API will be removed later in PCI bus,
this patch uses PCI library API to get the PCI address.
Signed-off-by: Chenbo Xia
---
examples/ethtool/lib/rte_ethtool.c | 14 +-
examples/ethtool
Currently testpmd uses struct rte_pci_device to access PCI memory
resource. Since this structure will be internal later, this patch
replaces use of rte_pci_device with new PCI memory resource access
APIs to read/write BAR 0.
Signed-off-by: Chenbo Xia
---
app/test-pmd/config.c | 50
Some applications wants to access PCI memory resource. Currently
applications use struct rte_pci_device to access it. Since the
structure will be made internal later, this patch adds two APIs
for memory resource access.
Signed-off-by: Chenbo Xia
Acked-by: Ray Kinsella
---
doc/guides/rel_notes
backport (David)
Chenbo Xia (7):
bus/pci: add new memory resource access APIs
app/testpmd: use PCI memory resource access APIs
examples/ethtool: use PCI library API to get PCI address
examples/kni: remove unused PCI bus header
kni: remove unused PCI info from test and example
kni: replace
-by: Chenbo Xia
---
app/test/virtual_pmd.c| 2 +-
doc/guides/rel_notes/release_21_11.rst| 2 +
drivers/baseband/acc100/rte_acc100_pmd.c | 2 +-
.../fpga_5gnr_fec/rte_fpga_5gnr_fec.c | 2 +-
drivers/baseband/fpga_lte_fec/fpga_lte_fec.c | 2
PCI ID and address in structure rte_kni_conf are never used. And in
order not to break ABI, replace these variables with reserved bytes.
Signed-off-by: Chenbo Xia
---
lib/kni/rte_kni.h | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/lib/kni/rte_kni.h b/lib/kni/rte_kni.h
PCI ID and address in structure rte_kni_conf are never used and
will be removed in kni library. So remove the setting of them
first in the example.
Signed-off-by: Chenbo Xia
---
examples/ip_pipeline/kni.c | 16
1 file changed, 16 deletions(-)
diff --git a/examples/ip_pipeline
PCI device id and address in structure rte_kni_conf are never used
in the test and kni library. So remove the related code.
Signed-off-by: Chenbo Xia
---
app/test/test_kni.c | 57 -
1 file changed, 57 deletions(-)
diff --git a/app/test/test_kni.c b
The header rte_bus_pci.h is included in kni example but nothing
in it is used. So remove it.
Signed-off-by: Chenbo Xia
---
examples/kni/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/examples/kni/main.c b/examples/kni/main.c
index beabb3c848..6dc335c0b5 100644
--- a/examples/kni
Currently ethtool example uses struct rte_pci_device to know PCI
address of a device. As this API will be removed later in PCI bus,
this patch uses PCI library API to get the PCI address.
Signed-off-by: Chenbo Xia
---
examples/ethtool/lib/rte_ethtool.c | 14 +-
examples/ethtool
Currently testpmd uses struct rte_pci_device to access PCI memory
resource. Since this structure will be internal later, this patch
replaces use of rte_pci_device with new PCI memory resource access
APIs to read/write BAR 0.
Signed-off-by: Chenbo Xia
---
app/test-pmd/config.c | 38
Some applications wants to access PCI memory resource. Currently
applications use struct rte_pci_device to access it. Since the
structure will be made internal later, this patch adds two APIs
for memory resource access.
Signed-off-by: Chenbo Xia
---
doc/guides/rel_notes/release_21_11.rst | 5
bus header in examples.
Patch 5-7 clean up the unused PCI related structure in kni library and related
tests and examples.
Patch 8 finally removes most of ABIs in PCI bus.
Chenbo Xia (8):
bus/pci: add new memory resource access APIs
app/testpmd: use PCI memory resource access APIs
examples
As reported by symbol bot, APIs listed in this patch have been
experimental for more than two years. This patch promotes these
18 APIs to stable.
Signed-off-by: Chenbo Xia
---
lib/vhost/rte_vhost.h| 13 -
lib/vhost/rte_vhost_crypto.h | 5 -
lib/vhost/version.map
This patch announces the experimental tag removal of 10 vhost APIs,
which have been experimental for more than 2 years. All APIs could
be made stable in DPDK 21.11.
Signed-off-by: Chenbo Xia
Acked-by: Maxime Coquelin
---
doc/guides/rel_notes/deprecation.rst | 8
1 file changed, 8
This patch announces the experimental tag removal of 10 vhost APIs,
which have been experimental for more than 2 years. All APIs could
be made stable in DPDK 21.11.
Signed-off-by: Chenbo Xia
Acked-by: Maxime Coquelin
---
doc/guides/rel_notes/deprecation.rst | 8
1 file changed, 8
when fron-end does not have the feature
named VIRTIO_NET_F_SPEED_DUPLEX.
Fixes: 1357b4b36246 ("net/virtio: support Virtio link speed feature")
Cc: sta...@dpdk.org
Signed-off-by: Chenbo Xia
---
drivers/net/virtio/virtio_ethdev.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/
All ABIs in PCI bus driver, which are defined in rte_buc_pci.h,
will be removed and the header will be made internal.
Signed-off-by: Chenbo Xia
---
doc/guides/rel_notes/deprecation.rst | 5 +
1 file changed, 5 insertions(+)
diff --git a/doc/guides/rel_notes/deprecation.rst
b/doc/guides
This patch adds sparse mmap support in PCI bus. Sparse mmap is a
capability defined in VFIO which allows multiple mmap areas in one
VFIO region. Mediated pci devices could use this capability to let
mdev parent driver have control over access of non-mmapable part
of regions.
Signed-off-by: Chenbo
ce address;
Signed-off-by: Cunming Liang
Signed-off-by: Tiwei Bie
Signed-off-by: Chenbo Xia
---
drivers/bus/pci/linux/pci.c | 30 ++-
drivers/bus/pci/linux/pci_init.h | 15 +-
drivers/bus/pci/linux/pci_vfio.c | 147 --
drivers/bus/pci/linux/pci_vfio_md
From: Tiwei Bie
This patch adds a helper for reading string from sysfs.
Signed-off-by: Cunming Liang
Signed-off-by: Tiwei Bie
---
lib/eal/common/eal_filesystem.h | 10 ++
lib/eal/freebsd/eal.c | 22 ++
lib/eal/linux/eal.c | 22
From: Tiwei Bie
The MMIO regions may not be mmap-able for mediated PCI device.
In this case, the application should explicitly do read and write
to access these regions.
Signed-off-by: Tiwei Bie
---
drivers/bus/pci/bsd/pci.c| 22 +++
drivers/bus/pci/linux/pci.c | 46 ++
From: Tiwei Bie
The value 40 used in VFIO_GET_REGION_ADDR() is a private value
(VFIO_PCI_OFFSET_SHIFT) defined in Linux kernel source [1]. It
is not part of VFIO API, and we should not depend on it.
[1]
https://github.com/torvalds/linux/blob/v5.12/drivers/vfio/pci/vfio_pci_private.h
Signed-off
cture. More fields will be added in the coming
patches.
Suggested-by: David Marchand
Signed-off-by: Tiwei Bie
Signed-off-by: Chenbo Xia
---
drivers/bus/pci/bsd/pci.c| 14 +-
drivers/bus/pci/linux/pci.c | 27 ---
drivers/bus/pci/pci_common.c | 2 +-
driver
driver-api/vfio-mediated-device.rst
Chenbo Xia (1):
bus/pci: add sparse mmap support for mediated PCI devices
Tiwei Bie (5):
bus/pci: introduce an internal representation of PCI device
bus/pci: avoid depending on private value in kernel source
bus/pci: introduce helper for MMIO read and wri
disabled queues are not
initialized.
Fixes: 968bbc7e2e50 ("vhost: avoid IOTLB mempool allocation while IOMMU
disabled")
Signed-off-by: Chenbo Xia
---
lib/vhost/vhost_user.c | 13 +
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/lib/vhost/vhost_user.c b
This patch fixes unchecked return value for rte_vhost_get_mem_table(),
which is reported by coverity.
Coverity issue: 364233
Fixes: ca059fa5e290 ("examples/vhost: demonstrate the new generic APIs")
Cc: sta...@dpdk.org
Signed-off-by: Chenbo Xia
---
examples/vhost/virtio_net.c | 8 +
Update release notes for emulated iavf driver.
Signed-off-by: Chenbo Xia
---
doc/guides/rel_notes/release_21_02.rst | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/doc/guides/rel_notes/release_21_02.rst
b/doc/guides/rel_notes/release_21_02.rst
index 9686930de3
This patch introduces functional test for emudev. The
implementation of iavf emudev selftest is also added.
Signed-off-by: Miao Li
Signed-off-by: Chenbo Xia
---
app/test/meson.build | 5 +-
app/test/test_emudev.c | 29 +
drivers/emu/iavf/iavf_emu.c
This patch implements emudev operations to make emulated iavf
fit into rte_emudev framework. Lifecycle related and device
resource related operations are both implemented.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
drivers/emu/iavf/iavf_emu.c | 229
This patch adds the allocation and release of device resources.
Device resources include PCI BARs' memory and interrupt related
resources. Device internal logic is also added.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
drivers/emu/iavf/iavf_emu.c | 1 +
drivers/emu
This patch adds vfio-user APIs call in driver probe and remove.
rte_vfio_user_register() and rte_vfio_user_unregister() are called
to create/destroy a vfio-user device. Notify callbacks that
libvfio_user defines are also implemented.
Signed-off-by: Chenbo Xia
Signed-off-by: Miao Li
---
drivers
This patch introduces emulated iavf driver. It is a vdev driver
emulating all iavf device behavior except data path handling.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
MAINTAINERS | 7 +
drivers/emu/iavf/iavf_emu.c | 30
drivers/emu/iavf
Add emudev library guide and update release notes.
Signed-off-by: Chenbo Xia
---
doc/guides/prog_guide/emudev.rst | 122 +
doc/guides/prog_guide/index.rst| 1 +
doc/guides/rel_notes/release_21_02.rst | 12 +++
3 files changed, 135 insertions(+)
create
driver) to plug in its
high performance data path.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
Signed-off-by: Miao Li
---
MAINTAINERS | 5 +
lib/librte_emudev/meson.build | 5 +
lib/librte_emudev/rte_emudev.c | 502
lib
ng
rawdev APIs
could only cover lifecycle management APIs and some of backend facing APIs.
Other APIs,
even if added to rawdev API are not required by other rawdev applications.
--
v3:
- fix interrupt issue in iavf emudev driver (Jingjing)
v2:
- fix driver meson
Add vfio-user library guide and update release notes.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
doc/guides/prog_guide/index.rst | 1 +
doc/guides/prog_guide/vfio_user_lib.rst | 215
doc/guides/rel_notes/release_21_02.rst | 11 ++
3 files
This patch introduces functional test for vfio_user client and
server. Note that the test can only be run with server and client
both started and server should be started first.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
app/test/meson.build | 4 +
app/test/test_vfio_user.c
rte_vfio_user_set_irqs
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
lib/librte_vfio_user/rte_vfio_user.h| 177 ++
lib/librte_vfio_user/version.map| 9 +
lib/librte_vfio_user/vfio_user_client.c | 419
3 files changed, 605 insertions(+)
diff --git a/lib
This patch implements two APIs, rte_vfio_user_attach_dev() and
rte_vfio_user_detach_dev() for vfio-user client to connect to
or disconnect from a vfio-user device on server side.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
lib/librte_vfio_user/meson.build| 3 +-
lib
This patch implements two interrupt related APIs, which are
rte_vfio_user_get_irq() and rte_vfio_user_set_irq_info().
The former is for devices to get interrupt configuration
(e.g., irqfds). The latter is for setting interrupt information
before vfio-user starts.
Signed-off-by: Chenbo Xia
Signed
device ID and socket address in notify
callbacks.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
lib/librte_vfio_user/rte_vfio_user.h| 77 -
lib/librte_vfio_user/version.map| 2 +
lib/librte_vfio_user/vfio_user_base.h | 2 +
lib/librte_vfio_user/vfio_user_server.c
This patch introduces device and region related APIs, which are
rte_vfio_user_set_dev_info() and rte_vfio_user_set_reg_info().
The corresponding vfio-user command handling is also added with
the definition of all vfio-user command identity.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
This patch implements three lifecycle related APIs for vfio-user server,
which are rte_vfio_user_register(), rte_vfio_user_unregister() and
rte_vfio_user_start(). Socket an device management is implemented
along with the API introduction.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
This patch introduces vfio-user library, which follows vfio-user
protocol v1.0. As vfio-user has server and client implementation,
this patch introduces basic structures and internal functions that
will be used by both server and client.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
de in vfio-user server APIs (Beilei)
- Fix some typos
Chenbo Xia (9):
lib: introduce vfio-user library
vfio_user: implement lifecycle related APIs
vfio_user: implement device and region related APIs
vfio_user: implement DMA table and socket address API
vfio_user: implement interrupt re
Update release notes for emulated iavf driver.
Signed-off-by: Chenbo Xia
---
doc/guides/rel_notes/release_21_02.rst | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/doc/guides/rel_notes/release_21_02.rst
b/doc/guides/rel_notes/release_21_02.rst
index 3d26b6b580
This patch introduces functional test for emudev. The
implementation of iavf emudev selftest is also added.
Signed-off-by: Miao Li
Signed-off-by: Chenbo Xia
---
app/test/meson.build | 5 +-
app/test/test_emudev.c | 29 +
drivers/emu/iavf/iavf_emu.c
This patch implements emudev opertions to make emulated iavf
fit into rte_emudev framework. Lifecycle related and device
resource related operations are both implemented.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
drivers/emu/iavf/iavf_emu.c | 218
This patch adds the allocation and release of device resources.
Device resources include PCI BARs' memory and interrupt related
resources. Device internal logic is also added.
Signed-off-by: Chenbo Xia
Signed-off-by: Xiuchun Lu
---
drivers/emu/iavf/iavf_emu.c | 1 +
drivers/emu
This patch adds vfio-user APIs call in driver probe and remove.
rte_vfio_user_register() and rte_vfio_user_unregister() are called
to create/destroy a vfio-user device. Notify callbacks that
libvfio_user defines are also implemented.
Signed-off-by: Chenbo Xia
Signed-off-by: Miao Li
---
drivers
1 - 100 of 143 matches
Mail list logo