[v3] examples/vhost: change the default value of NIC's max queues

Message ID 20211015164832.8865-1-wenwux.ma@intel.com (mailing list archive)
State Superseded, archived
Delegated to: Maxime Coquelin
Headers
Series [v3] examples/vhost: change the default value of NIC's max queues |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/github-robot: build success github build: passed
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-aarch64-unit-testing success Testing PASS
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/iol-aarch64-compile-testing success Testing PASS

Commit Message

Ma, WenwuX Oct. 15, 2021, 4:48 p.m. UTC
  vswitch can't launch with a 40G i40e port due to device start fails
if NIC’s max queues > the default number of 128, so, we changed
the default value from 128 to 512.

Fixes: 4796ad63ba1f ("examples/vhost: import userspace vhost application")
Cc: stable@dpdk.org

Signed-off-by: Wenwu Ma <wenwux.ma@intel.com>
---
 examples/vhost/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Maxime Coquelin Oct. 21, 2021, 11:29 a.m. UTC | #1
On 10/15/21 18:48, Wenwu Ma wrote:
> vswitch can't launch with a 40G i40e port due to device start fails
> if NIC’s max queues > the default number of 128, so, we changed
> the default value from 128 to 512.
> 
> Fixes: 4796ad63ba1f ("examples/vhost: import userspace vhost application")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Wenwu Ma <wenwux.ma@intel.com>
> ---
>   examples/vhost/main.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/examples/vhost/main.c b/examples/vhost/main.c
> index bc3d71c898..36969a4de5 100644
> --- a/examples/vhost/main.c
> +++ b/examples/vhost/main.c
> @@ -29,7 +29,7 @@
>   #include "main.h"
>   
>   #ifndef MAX_QUEUES
> -#define MAX_QUEUES 128
> +#define MAX_QUEUES 512
>   #endif
>   
>   /* the maximum number of external ports supported */
> 

As discussed, this is far from ideal, but let's use our time to remove
gaps in Vhost testing with testpmd so that we can remove this example
later.

Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>

Thanks,
Maxime
  
Maxime Coquelin Oct. 21, 2021, 12:34 p.m. UTC | #2
On 10/15/21 18:48, Wenwu Ma wrote:
> vswitch can't launch with a 40G i40e port due to device start fails
> if NIC’s max queues > the default number of 128, so, we changed
> the default value from 128 to 512.
> 
> Fixes: 4796ad63ba1f ("examples/vhost: import userspace vhost application")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Wenwu Ma <wenwux.ma@intel.com>
> ---
>   examples/vhost/main.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 

Applied to dpdk-next-virtio/main.

Thanks,
Maxime
  
Ferruh Yigit Oct. 21, 2021, 5:10 p.m. UTC | #3
On 10/15/2021 5:48 PM, Wenwu Ma wrote:
> vswitch can't launch with a 40G i40e port due to device start fails

what is 'vswitch' that is referred? I expect what can't launch should
be this sample app but why referring it as 'vswitch'?

Also patch title describes what is done, better to describe why it is done,
like:
examples/vhost: fix init for devices that has big max queue number

btw, why a device with big max queue number causes failure in the sample app?
Can you please provide more detail on the error? What and why fails on
device start?

> if NIC’s max queues > the default number of 128, so, we changed
> the default value from 128 to 512.
> 
> Fixes: 4796ad63ba1f ("examples/vhost: import userspace vhost application")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Wenwu Ma <wenwux.ma@intel.com>
> ---
>   examples/vhost/main.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/examples/vhost/main.c b/examples/vhost/main.c
> index bc3d71c898..36969a4de5 100644
> --- a/examples/vhost/main.c
> +++ b/examples/vhost/main.c
> @@ -29,7 +29,7 @@
>   #include "main.h"
>   
>   #ifndef MAX_QUEUES
> -#define MAX_QUEUES 128
> +#define MAX_QUEUES 512
>   #endif
>   
>   /* the maximum number of external ports supported */
>
  

Patch

diff --git a/examples/vhost/main.c b/examples/vhost/main.c
index bc3d71c898..36969a4de5 100644
--- a/examples/vhost/main.c
+++ b/examples/vhost/main.c
@@ -29,7 +29,7 @@ 
 #include "main.h"
 
 #ifndef MAX_QUEUES
-#define MAX_QUEUES 128
+#define MAX_QUEUES 512
 #endif
 
 /* the maximum number of external ports supported */