eal: increase max file descriptor for secondary process device

Message ID 20240905162018.74301-1-stephen@networkplumber.org (mailing list archive)
State New
Delegated to: Thomas Monjalon
Headers
Series eal: increase max file descriptor for secondary process device |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/github-robot: build success github build: passed
ci/intel-Functional success Functional PASS
ci/iol-compile-amd64-testing pending Testing pending
ci/iol-unit-amd64-testing pending Testing pending
ci/iol-unit-arm64-testing pending Testing pending
ci/iol-marvell-Functional success Functional Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-compile-arm64-testing success Testing PASS
ci/iol-sample-apps-testing success Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-intel-Performance success Performance Testing PASS

Commit Message

Stephen Hemminger Sept. 5, 2024, 4:20 p.m. UTC
The TAP and XDP driver both are limited to only 8 queues when
because of the small limit imposed by EAL. Increase the limit
now since this release allows changing ABI.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 doc/guides/rel_notes/release_24_11.rst | 5 +++++
 lib/eal/include/rte_eal.h              | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)
  

Comments

fengchengwen Sept. 6, 2024, 1:19 a.m. UTC | #1
Acked-by: Chengwen Feng <fengchengwen@huawei.com>

On 2024/9/6 0:20, Stephen Hemminger wrote:
> The TAP and XDP driver both are limited to only 8 queues when
> because of the small limit imposed by EAL. Increase the limit
> now since this release allows changing ABI.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
>  doc/guides/rel_notes/release_24_11.rst | 5 +++++
>  lib/eal/include/rte_eal.h              | 2 +-
>  2 files changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/doc/guides/rel_notes/release_24_11.rst b/doc/guides/rel_notes/release_24_11.rst
> index 0ff70d9057..5af70e04c5 100644
> --- a/doc/guides/rel_notes/release_24_11.rst
> +++ b/doc/guides/rel_notes/release_24_11.rst
> @@ -100,6 +100,11 @@ ABI Changes
>     Also, make sure to start the actual text at the margin.
>     =======================================================
>  
> +* The maximum number of file descriptors that can be passed to a secondary process
> +  has been increased from 8 to 253 (which is the maximum possible with Unix domain
> +  socket). This allows for more queues when using software devices such as TAP
> +  and XDP.
> +
>  
>  Known Issues
>  ------------
> diff --git a/lib/eal/include/rte_eal.h b/lib/eal/include/rte_eal.h
> index c2256f832e..c826e143f1 100644
> --- a/lib/eal/include/rte_eal.h
> +++ b/lib/eal/include/rte_eal.h
> @@ -155,7 +155,7 @@ int rte_eal_primary_proc_alive(const char *config_file_path);
>   */
>  bool rte_mp_disable(void);
>  
> -#define RTE_MP_MAX_FD_NUM	8    /* The max amount of fds */
> +#define RTE_MP_MAX_FD_NUM	253  /* The max amount of fds (see SCM_MAX_FD) */
>  #define RTE_MP_MAX_NAME_LEN	64   /* The max length of action name */
>  #define RTE_MP_MAX_PARAM_LEN	256  /* The max length of param */
>  struct rte_mp_msg {
>
  
Morten Brørup Sept. 6, 2024, 6:23 a.m. UTC | #2
> From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> Sent: Thursday, 5 September 2024 18.20
> 
> The TAP and XDP driver both are limited to only 8 queues when
> because of the small limit imposed by EAL. Increase the limit
> now since this release allows changing ABI.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---

Acked-by: Morten Brørup <mb@smartsharesystems.com>
  
Ferruh Yigit Sept. 6, 2024, 7:55 a.m. UTC | #3
On 9/5/2024 5:20 PM, Stephen Hemminger wrote:
> The TAP and XDP driver both are limited to only 8 queues when
> because of the small limit imposed by EAL. Increase the limit
> now since this release allows changing ABI.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---
>  doc/guides/rel_notes/release_24_11.rst | 5 +++++
>  lib/eal/include/rte_eal.h              | 2 +-
>  2 files changed, 6 insertions(+), 1 deletion(-)
> 
> diff --git a/doc/guides/rel_notes/release_24_11.rst b/doc/guides/rel_notes/release_24_11.rst
> index 0ff70d9057..5af70e04c5 100644
> --- a/doc/guides/rel_notes/release_24_11.rst
> +++ b/doc/guides/rel_notes/release_24_11.rst
> @@ -100,6 +100,11 @@ ABI Changes
>     Also, make sure to start the actual text at the margin.
>     =======================================================
>  
> +* The maximum number of file descriptors that can be passed to a secondary process
> +  has been increased from 8 to 253 (which is the maximum possible with Unix domain
> +  socket). This allows for more queues when using software devices such as TAP
> +  and XDP.
> +
>  
>  Known Issues
>  ------------
> diff --git a/lib/eal/include/rte_eal.h b/lib/eal/include/rte_eal.h
> index c2256f832e..c826e143f1 100644
> --- a/lib/eal/include/rte_eal.h
> +++ b/lib/eal/include/rte_eal.h
> @@ -155,7 +155,7 @@ int rte_eal_primary_proc_alive(const char *config_file_path);
>   */
>  bool rte_mp_disable(void);
>  
> -#define RTE_MP_MAX_FD_NUM	8    /* The max amount of fds */
> +#define RTE_MP_MAX_FD_NUM	253  /* The max amount of fds (see SCM_MAX_FD) */
>  #define RTE_MP_MAX_NAME_LEN	64   /* The max length of action name */
>  #define RTE_MP_MAX_PARAM_LEN	256  /* The max length of param */
>  struct rte_mp_msg {
>

It would be nice to add this to deprecation notice first, but it seems
we missed, I think it is safe to update in ABI break release and good to
remove this restriction.

Acked-by: Ferruh Yigit <ferruh.yigit@amd.com>
  

Patch

diff --git a/doc/guides/rel_notes/release_24_11.rst b/doc/guides/rel_notes/release_24_11.rst
index 0ff70d9057..5af70e04c5 100644
--- a/doc/guides/rel_notes/release_24_11.rst
+++ b/doc/guides/rel_notes/release_24_11.rst
@@ -100,6 +100,11 @@  ABI Changes
    Also, make sure to start the actual text at the margin.
    =======================================================
 
+* The maximum number of file descriptors that can be passed to a secondary process
+  has been increased from 8 to 253 (which is the maximum possible with Unix domain
+  socket). This allows for more queues when using software devices such as TAP
+  and XDP.
+
 
 Known Issues
 ------------
diff --git a/lib/eal/include/rte_eal.h b/lib/eal/include/rte_eal.h
index c2256f832e..c826e143f1 100644
--- a/lib/eal/include/rte_eal.h
+++ b/lib/eal/include/rte_eal.h
@@ -155,7 +155,7 @@  int rte_eal_primary_proc_alive(const char *config_file_path);
  */
 bool rte_mp_disable(void);
 
-#define RTE_MP_MAX_FD_NUM	8    /* The max amount of fds */
+#define RTE_MP_MAX_FD_NUM	253  /* The max amount of fds (see SCM_MAX_FD) */
 #define RTE_MP_MAX_NAME_LEN	64   /* The max length of action name */
 #define RTE_MP_MAX_PARAM_LEN	256  /* The max length of param */
 struct rte_mp_msg {