[dpdk-dev] [PATCH v5] vhost_user: protect active rings from async ring changes

2018-01-17 Thread Victor Kaplansky
its own lock in order to not create contention between PMD threads of different vrings and to prevent performance degradation by scaling queue pair number. See https://bugzilla.redhat.com/show_bug.cgi?id=1450680 Signed-off-by: Victor Kaplansky --- v5: o get rid of spinlock wrapping functions in

Re: [dpdk-dev] [PATCH v4] vhost_user: protect active rings from async ring changes

2017-12-21 Thread Victor Kaplansky
- Original Message - > From: "Stephen Hemminger" > To: "Victor Kaplansky" > Cc: dev@dpdk.org, sta...@dpdk.org, "Jens Freimann" , > "Maxime Coquelin" > , "Yuanhan Liu" , "Tiwei > Bie" , "Jianfeng > T

Re: [dpdk-dev] [PATCH v4] vhost_user: protect active rings from async ring changes

2017-12-20 Thread Victor Kaplansky
- Original Message - > From: "Stephen Hemminger" > To: "Victor Kaplansky" > Cc: dev@dpdk.org, sta...@dpdk.org, "Jens Freimann" , > "Maxime Coquelin" > , "Yuanhan Liu" , "Tiwei > Bie" , "Jianfeng >

[dpdk-dev] [PATCH v4] vhost_user: protect active rings from async ring changes

2017-12-20 Thread Victor Kaplansky
its own lock in order to not create contention between PMD threads of different vrings and to prevent performance degradation by scaling queue pair number. See https://bugzilla.redhat.com/show_bug.cgi?id=1450680 Signed-off-by: Victor Kaplansky --- v4: o moved access_unlock before accessing

Re: [dpdk-dev] [PATCH v3] vhost_user: protect active rings from async ring changes

2017-12-14 Thread Victor Kaplansky
- Original Message - > From: "Maxime Coquelin" > To: "Victor Kaplansky" , dev@dpdk.org > Cc: sta...@dpdk.org, "Jens Freimann" , "Yuanhan Liu" > , "Tiwei Bie" > , "Jianfeng Tan" > Sent: Thursday, December

[dpdk-dev] [PATCH v3] vhost_user: protect active rings from async ring changes

2017-12-14 Thread Victor Kaplansky
its own lock in order to not create contention between PMD threads of different vrings and to prevent performance degradation by scaling queue pair number. See https://bugzilla.redhat.com/show_bug.cgi?id=1450680 Signed-off-by: Victor Kaplansky Tested-by: Maxime Coquelin --- v3: o Added locking

[dpdk-dev] [RFC PATCH v2] vhost_user: protect active rings from async ring changes

2017-12-06 Thread Victor Kaplansky
different vrings and to prevent performance degradation by scaling queue pair number. Signed-off-by: Victor Kaplansky --- lib/librte_vhost/vhost.h | 1 + lib/librte_vhost/vhost_user.c | 46 +++ lib/librte_vhost/virtio_net.c | 8 3 files changed, 55

[dpdk-dev] [PATCH] vhost_user: protect active rings from async ring changes

2017-12-06 Thread Victor Kaplansky
When performing live migration or memory hot-plugging, the changes to the device and vrings made by message handler done independently from vring usage by PMD threads. This causes for example segfauls during live-migration with MQ enable, but in general virtually any request sent by qemu changing

Re: [dpdk-dev] [PATCH v2 2/3] vhost: protect dirty logging against logging base change

2017-11-27 Thread Victor Kaplansky
- Original Message - > From: "Maxime Coquelin" > To: "Victor Kaplansky" > Cc: dev@dpdk.org, y...@fridaylinux.org, "tiwei bie" , > "jianfeng tan" , > sta...@dpdk.org, jfrei...@redhat.com > Sent: Monday, November 27, 2017 10:2

Re: [dpdk-dev] [PATCH v2 2/3] vhost: protect dirty logging against logging base change

2017-11-27 Thread Victor Kaplansky
Hi, While I agree that taking full fledged lock by rte_rwlock_read_lock() solves the race condition, I'm afraid that it would be too expensive in case when logging is off, since it introduces acquiring and releasing lock into the main flow of ring updates. It is OK for now, as it fixes the bug,

Re: [dpdk-dev] [RFC PATCH 0/4] testpmd: simulating noisy host environment

2017-11-13 Thread Victor Kaplansky
- > From: "Thomas Monjalon" > To: "Bruce Richardson" , "Victor Kaplansky" > > Cc: dev@dpdk.org, "jingjing wu" , "Amnon Ilan" > , "Tim Irnich" > , "Georg Kunz" , "Gabor > Halász" , > "

[dpdk-dev] [RFC PATCH 0/4] testpmd: simulating noisy host environment

2017-10-29 Thread Victor Kaplansky
This RFC patch propose enhancements to testpmd to simulate more realistic behavior of a guest machine engaged in receiving and sending packets performing Virtual Network Function (VNF). The goal is to enable simple of measuring performance impact on cache and memory footprint utilization from var

[dpdk-dev] [PATCH 6/6] vhost: add pmd client and reconnect option

2016-05-09 Thread Victor Kaplansky
Looks OK to me. I didn't quite get why open_int() is called so. What does it open? -- Victor - Original Message - > From: "Yuanhan Liu" > To: dev at dpdk.org > Cc: "huawei xie" , "Yuanhan Liu" linux.intel.com>, "Tetsuya Mukawa" > > Sent: Saturday, May 7, 2016 9:40:24 AM > Subject: [dpd

[dpdk-dev] [PATCH 5/6] examples/vhost: add client and reconnect option

2016-05-09 Thread Victor Kaplansky
Again, it may be useful to add mixed --client-server option, when backend tries to connect as client and if failed, comes up as a server... Just a suggestion from user point of view... - Original Message - > From: "Yuanhan Liu" > To: dev at dpdk.org > Cc: "huawei xie" , "Yuanhan Liu" lin

[dpdk-dev] [PATCH 4/6] vhost: workaround stale vring base

2016-05-09 Thread Victor Kaplansky
- Original Message - > From: "Yuanhan Liu" > To: dev at dpdk.org > Cc: "huawei xie" , "Yuanhan Liu" linux.intel.com>, "Michael S. Tsirkin" > > Sent: Saturday, May 7, 2016 9:40:22 AM > Subject: [dpdk-dev] [PATCH 4/6] vhost: workaround stale vring base > > When DPDK app crashes (or quit

[dpdk-dev] [PATCH 2/6] vhost: add vhost-user client mode

2016-05-09 Thread Victor Kaplansky
Adding a flag for a future extension seems fine to me. Could we manage without adding a flag? For example, could we always try a client mode for a while at first, and if unsuccessful, then come up with server mode? -- Victor - Original Message - > From: "Yuanhan Liu" > To: dev at dpdk.or

[dpdk-dev] [Announce] A new tree for vhost/virtio

2016-04-19 Thread Victor Kaplansky
Great! Thanks a lot, the tree will allow me to focus on development, and not waste the time on testing and maintenance. -- Victor - Original Message - > From: "Yuanhan Liu" > To: dev at dpdk.org > Cc: "Thomas Monjalon" , "Bruce Richardson"

[dpdk-dev] dpdk: vhost/virtio staging/testing tree

2016-02-12 Thread Victor Kaplansky
Hi! Since I was maintaining an internal tree with patches related to vhost/virtio, I decided to make this staging tree public. It is useful to me and I hope it will be useful to others. Collecting patches like this allows tracking dependencies between patches, their improvement etc. I also rebase

[dpdk-dev] [PATCH 3/4] vhost: log vring changes

2015-12-02 Thread Victor Kaplansky
On Wed, Dec 02, 2015 at 10:38:02PM +0800, Yuanhan Liu wrote: > On Wed, Dec 02, 2015 at 04:07:02PM +0200, Victor Kaplansky wrote: > > On Wed, Dec 02, 2015 at 11:43:12AM +0800, Yuanhan Liu wrote: > > > Invoking vhost_log_write() to mark corresponding page as dirty while > &g

[dpdk-dev] [PATCH 0/4 for 2.3] vhost-user live migration support

2015-12-02 Thread Victor Kaplansky
On Wed, Dec 02, 2015 at 11:43:09AM +0800, Yuanhan Liu wrote: > This patch set adds the initial vhost-user live migration support. > > The major task behind that is to log pages we touched during > live migration. So, this patch is basically about adding vhost > log support, and using it. > > Patc

[dpdk-dev] [PATCH 3/4] vhost: log vring changes

2015-12-02 Thread Victor Kaplansky
On Wed, Dec 02, 2015 at 11:43:12AM +0800, Yuanhan Liu wrote: > Invoking vhost_log_write() to mark corresponding page as dirty while > updating used vring. Looks good, thanks! I didn't find where you log the dirty pages in result of data written to the buffers pointed by the descriptors in RX vrin

[dpdk-dev] [PATCH 2/4] vhost: introduce vhost_log_write

2015-12-02 Thread Victor Kaplansky
On Wed, Dec 02, 2015 at 11:43:11AM +0800, Yuanhan Liu wrote: > Introduce vhost_log_write() helper function to log the dirty pages we > touched. Page size is harded code to 4096 (VHOST_LOG_PAGE), and each > log is presented by 1 bit. > > Therefore, vhost_log_write() simply finds the right bit for r

[dpdk-dev] [PATCH v2] vhost-user: fix enabling of queue pair

2015-11-24 Thread Victor Kaplansky
Yuanhan, looks fine. Thanks for handling this. -- Victor On Tue, Nov 24, 2015 at 03:25:35PM +0800, Yuanhan Liu wrote: > From: Victor Kaplansky > > The VHOST_USER_SET_VRING_ENABLE request was sent for each queue-pair. > However, it's changed to be sent per queue in the q

[dpdk-dev] [PATCH] vhost-user: fix enabling of queue pair

2015-11-20 Thread Victor Kaplansky
On Fri, Nov 20, 2015 at 03:45:00PM +0200, Victor Kaplansky wrote: > The VHOST_USER_SET_VRING_ENABLE request is sent for each queue in > queue-pair separately. So, a queue-pair should be considered > enabled only when both RX and TX queues are enabled. > > The old code caused segfau

[dpdk-dev] [PATCH] vhost-user: fix enabling of queue pair

2015-11-20 Thread Victor Kaplansky
The VHOST_USER_SET_VRING_ENABLE request is sent for each queue in queue-pair separately. So, a queue-pair should be considered enabled only when both RX and TX queues are enabled. The old code caused segfault when last TX queue was enabled. Signed-off-by: Victor Kaplansky --- lib/librte_vhost