we have to make sure that each IO is completed.
When we terminate the above mediated virtio ring, we stop
notifying queue about new IOs, wait for all the in-flight IOs to
be completed.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 22 ++
1 file changed, 22
For block device, we make sure no IO is inflight before we
stop device. We terminate the notify relay process and wait
for all inflight IOs to be completed. So in this period, we
wait for hardware to update used index, there is no need to
relay new kick.
Signed-off-by: Andy Pei
---
drivers/vdpa
form DMA map.
Fixes: 4bb531e152d3 ("net/ifc: support SW assisted VDPA live migration")
Cc: sta...@dpdk.org
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.c
index
ot;net/ifc: add LM mode parameter")
Cc: sta...@dpdk.org
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 5 +
1 file changed, 5 insertions(+)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.c
index 49d68ad..9468f66 100644
--- a/drivers/vdpa/ifc/ifcvf_
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when the first queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
lib/vhost
Add type to rte_vdpa_device to store device type.
Call vdpa ops get_dev_type to fill type when register
vdpa device.
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
lib/vhost/socket.c | 15 +--
lib/vhost/vdpa.c| 15 +++
lib
Insert internal list element to internal list before
register vdpa device, in order to call vdpa ops during
vdpa device registration.
Signed-off-by: Andy Pei
Reviewed-by: Maxime Coquelin
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff
Add new internal API "find_internal_resource_by_rte_dev"
to get device.
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 28 ++--
1 file changed, 26 insertions(+), 2 deletions(-)
diff --git a/dr
Change internal function name "find_internal_resource_by_dev"
to "find_internal_resource_by_pci_dev".
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
---
drivers/vdp
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config.
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1
ome code logic.
v4:
fix some commit message.
add some commets to code.
fix some code to reduce confusion.
v3:
rename device ID macro name.
fix some patch title and commit message.
delete some used marco.
rework some code logic.
v2:
fix some coding style issue.
support dynamic enable/disabl
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when the first queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 33 +
1
Add type to rte_vdpa_device to store device type.
Call vdpa ops get_dev_type to fill type when register
vdpa device.
Signed-off-by: Andy Pei
---
lib/vhost/socket.c | 15 +--
lib/vhost/vdpa.c| 15 +++
lib/vhost/vdpa_driver.h | 2 ++
3 files changed, 18
Insert internal list element to internal list before
register vdpa device, in order to call vdpa ops during
vdpa device registration.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/vdpa/ifc
Add new internal API "find_internal_resource_by_rte_dev"
to get device.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 28 ++--
1 file changed, 26 insertions(+), 2 deletions(-)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vd
Change internal function name "find_internal_resource_by_dev"
to "find_internal_resource_by_pci_dev".
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/v
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
---
drivers/vdp
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config.
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
mit message.
add some commets to code.
fix some code to reduce confusion.
v3:
rename device ID macro name.
fix some patch title and commit message.
delete some used marco.
rework some code logic.
v2:
fix some coding style issue.
support dynamic enable/disable queue at run time.
Andy P
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when the first queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 33 ++---
1
Add vdpa_device_type to rte_vdpa_device to store device type.
Call vdpa ops get_dev_type to fill vdpa_device_type
when register vdpa device.
Signed-off-by: Andy Pei
---
lib/vhost/socket.c | 15 +--
lib/vhost/vdpa.c| 17 +
lib/vhost/vdpa_driver.h | 2
Insert internal list element to internal list before
register vdpa device, in order to call vdpa ops during
vdpa device registration.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 11 +++
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/vdpa/ifc
Add new internal API "find_internal_resource_by_rte_dev"
to get device.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 28 ++--
1 file changed, 26 insertions(+), 2 deletions(-)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vd
Change internal function name "find_internal_resource_by_dev"
to "find_internal_resource_by_pci_dev".
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/v
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
---
drivers/vdp
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config.
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
ID macro name.
fix some patch title and commit message.
delete some used marco.
rework some code logic.
v2:
fix some coding style issue.
support dynamic enable/disable queue at run time.
Andy Pei (10):
vdpa/ifc: add multi-queue support
vdpa/ifc: set max queues based on virtio spec
vdpa
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
---
drivers/vdp
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when any queue is ready.
Add vdpa_device_type to rte_vdpa_device to store vDPA device type.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config.
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
.
delete some used marco.
rework some code logic.
v2:
fix some coding style issue.
support dynamic enable/disable queue at run time.
Andy Pei (6):
vdpa/ifc: add multi-queue support
vdpa/ifc: set max queues based on virtio spec
vdpa/ifc: write queue count to MQ register
vdpa/ifc: only
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when any queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 31 +++
1 file
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
---
drivers/vdp
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config.
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
style issue.
support dynamic enable/disable queue at run time.
Andy Pei (6):
vdpa/ifc: add multi-queue support
vdpa/ifc: set max queues based on virtio spec
vdpa/ifc: write queue count to MQ register
vdpa/ifc: only configure enabled queue
vhost: vDPA blk device gets ready when the first
To support multi-queue, configure device
after call fd of all queues are set.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end configure device
when any queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 49
When configuring the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
Reviewed-by: Chenbo Xia
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configure queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifc
Write queue count to IFCVF_MQ_OFFSET register
to enable multi-queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 32
1 file changed, 32 insertions(+)
diff --git a/drivers/vdpa/ifc/base/ifcvf.c b/drivers/vdpa/ifc
Set max_queues according to virtio spec.
For virtio BLK device, set max_queues to the value of num_queues
in struct virtio_blk_config
For virtio NET device, read num_queues from struct ifcvf_pci_common_cfg,
get the queue pair number using num_queues and set max_queues to it.
Signed-off-by: Andy
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi-queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 9 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1 +
3 files changed, 12
run time.
Andy Pei (6):
vdpa/ifc: add multi-queue support
vdpa/ifc: set max queues based on virtio spec
vdpa/ifc: write queue count to MQ register
vdpa/ifc: only configure enabled queue
vhost: vDPA blk device gets ready when any queue is ready
vhost: improve vDPA blk device readiness
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
Reviewed-by: Chenbo Xia
Reviewed-by: Maxime Coquelin
---
d
improve readability.
Signed-off-by: Andy Pei
---
lib/vhost/vhost_user.c | 24
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 0182090..6d93495 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost
fd are well set and make sure no IO drops.
This patch only impact virtio blk vDPA device and does not impact
net device.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhos
When boot from virtio blk device, seabios in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end conf_dev when any
queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 51 --
1
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configurate queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/if
when configure the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 3 +++
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 17 insertions(+), 2 deletions
Write queue count to IFCVF_MQ_OFFSET register
to enable multi queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 30 ++
1 file changed, 30 insertions(+)
diff --git a/drivers/vdpa/ifc/base/ifcvf.c b/drivers/vdpa/ifc
_queues - 1) / 2" and get queue_pairs.
Set max_queues to the value of "queue_pairs".
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.h | 2 +-
drivers/vdpa/ifc/ifcvf_vdpa.c | 19 ++-
2 files changed, 19 insertions(+), 2 deletions(-)
diff
Enable VHOST_USER_PROTOCOL_F_MQ feature.
Expose IFCVF_MQ_OFFSET register to enable multi queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 5 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1 +
3 files changed, 8 insertions
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Rename macro from "IFCVF_BLK_DEVICE_ID" to "IFCVF_SUBSYS_BLK_DEVICE_ID".
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifcvf.h | 6 --
drivers/vdpa/i
v3:
rename device ID macro name.
fix some patch title and commit message.
delete some used marco.
rework some code logic.
v2:
fix some coding style issue.
support dynamic enable/disable queue at run time.
Andy Pei (6):
vdpa/ifc: add multi-queue support
vdpa/ifc: set max queues based on
re no IO drops.
This patch only impact virtio blk vDPA device and does not impact
net device.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_
When boot from virtio blk device, seabois in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end conf_dev when any
queue is ready.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
lib/vhost/vhost_user.c | 56 +++---
1
From: Huang Wei
Support dynamic enable or disable queue.
For front end, like QEMU, user can use ethtool to configurate queue.
For example, "ethtool -L eth0 combined 3" to enable 3 queues pairs.
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifcvf.c
when configure the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 6 +-
drivers/vdpa/ifc/ifcvf_vdpa.c | 16 ++--
2 files changed, 19 insertions(+), 3 deletions
Write queue count to IFCVF_MQ_OFFSET register
to enable multi queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 33 +
1 file changed, 33 insertions(+)
diff --git a/drivers/vdpa/ifc/base/ifcvf.c b/drivers/vdpa
Set max_queues according to virtio HW spec.
For virtio BLK device, set max_queues to the value of "num_queues".
"num_queues" is element of struct virtio_blk_config.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.h | 2 +-
drivers/vdpa/i
Enable VHOST_USER_PROTOCOL_F_MQ feature.
ExposeIFCVF_MQ_OFFSET register to enable multi queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 5 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1 +
3 files changed, 8 insertions
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifcvf.h | 4 +++-
drivers/vdpa/ifc/ifcvf_vdpa.c | 9 -
2 files changed, 11 insertions(+), 2 deletions(-)
diff --git a
v2:
fix some coding style issue.
support dynamic enable/disable queue at run time.
Andy Pei (6):
vdpa/ifc: add multi queue support
vdpa/ifc: set max queues according to HW spec
vdpa/ifc: write queue count to MQ register
vdpa/ifc: only configure enabled queue
vhost: configure device
re no IO drops.
This patch only impact virtio blk vDPA device and does not impact
net device.
Signed-off-by: Andy Pei
---
lib/vhost/vhost_user.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index b65fba3..568030a 10
When boot from virtio blk device, seabois in QEMU only enables one queue.
To work in this scenario, vDPA BLK device back-end conf_dev when any
queue is ready.
Signed-off-by: Andy Pei
---
lib/vhost/vhost_user.c | 56 +++---
1 file changed, 44
.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/ifcvf_vdpa.c | 27 +--
1 file changed, 9 insertions(+), 18 deletions(-)
diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.c
index a62bcec..94c8ef1 100644
--- a/drivers/vdpa/ifc/ifcvf_vdpa.c
+++ b/drivers
when configure the hardware queue, we only configure queues which
have been enabled by vhost.
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifcvf.c | 5 -
drivers/vdpa/ifc/ifcvf_vdpa.c | 4
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/drivers/vdpa/ifc/base/ifcvf.c
Write queue count to IFCVF_MQ_OFFSET register
to enable multi queue feature.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 14 ++
1 file changed, 14 insertions(+)
diff --git a/drivers/vdpa/ifc/base/ifcvf.c b/drivers/vdpa/ifc/base/ifcvf.c
Set max_queues according to virtio HW spec.
For virtio BLK device, set max_queues to the value of "num_queues".
"num_queues" is element of struct virtio_blk_config.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.h | 2 +-
drivers/vdpa/i
Enable VHOST_USER_PROTOCOL_F_MQ feature.
ExposeIFCVF_MQ_OFFSET register to enable multi queue.
Signed-off-by: Andy Pei
Signed-off-by: Huang Wei
---
drivers/vdpa/ifc/base/ifcvf.c | 5 +
drivers/vdpa/ifc/base/ifcvf.h | 2 ++
drivers/vdpa/ifc/ifcvf_vdpa.c | 1 +
3 files changed, 8 insertions
From: Huang Wei
Add new device id to support IFCVF_NET_TRANSITIONAL_DEVICE_ID (0x1000).
Signed-off-by: Huang Wei
Signed-off-by: Andy Pei
---
drivers/vdpa/ifc/base/ifcvf.h | 4 +++-
drivers/vdpa/ifc/ifcvf_vdpa.c | 9 -
2 files changed, 11 insertions(+), 2 deletions(-)
diff --git a
Add multi queue support to vDPA ifc driver.
Multi queue support for virtio-net device and virtio-blk device.
Andy Pei (7):
vdpa/ifc: add multi queue suppoort
vdpa/ifc: set max queues according to HW spec
vdpa/ifc: write queue count to MQ register
vdpa/ifc: only configure enabled queue
readability.
Signed-off-by: Andy Pei
---
lib/vhost/vhost_user.c | 24
1 file changed, 12 insertions(+), 12 deletions(-)
diff --git a/lib/vhost/vhost_user.c b/lib/vhost/vhost_user.c
index 4ad28ba..dac06c9 100644
--- a/lib/vhost/vhost_user.c
+++ b/lib/vhost/vhost_user.c
Fix null pointer dereference reported in coverity scan.
Output some log information when lm_cfg is null.
Make sure lm_cfg is not null before operate on lm_cfg.
Coverity issue: 378882
Fixes: d7fe5a2861e7 ("net/ifc: support live migration")
Signed-off-by: Andy Pei
---
drivers/vdp
1 - 100 of 544 matches
Mail list logo