net/memif: allocate socket hash on any NUMA socket
PATCH 1/1 net/memif: allocate socket hash on any NUMA socket
Previously, memif socket hash is always allocated on NUMA socket 0. If the application is entirely running on another NUMA socket and EAL --socket-limit prevents memory allocation on NUMA socket 0, memif creation fails with "HASH: memory allocation failed" error.
This patch allows allocating memif socket hash on any NUMA socket.
--- drivers/net/memif/memif_socket.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/memif/memif_socket.c +1 -0
@@ -946,6 +946,7 @@ memif_create_socket_hash(void) params.key_len =MEMIF_SOCKET_UN_SIZE ; params.hash_func = rte_jhash; params.hash_func_init_val =0 ; + params.socket_id =SOCKET_ID_ANY ;return rte_hash_create (¶ms); }
Signature · 1 line
2.17.1
Quoted 18 lines · Junxiao Shi
Previously, memif socket hash is always allocated on NUMA socket 0. If the application is entirely running on another NUMA socket and EAL --socket-limit prevents memory allocation on NUMA socket 0, memif creation fails with "HASH: memory allocation failed" error.
This patch allows allocating memif socket hash on any NUMA socket.
Signed-off-by Junxiao Shi <[email protected]>--- drivers/net/memif/memif_socket.c | 1 + 1 file changed, 1 insertion(+)drivers/net/memif/memif_socket.c +0
-0
drivers/net/memif/memif_socket.c memif_create_socket_hash(void) · line 952
Quoted 7 lines
drivers/net/memif/memif_socket.c +1
-0@@ -946,6 +946,7 @@ memif_create_socket_hash(void) params.key_len =MEMIF_SOCKET_UN_SIZE ; params.hash_func = rte_jhash; params.hash_func_init_val =0 ; + params.socket_id =SOCKET_ID_ANY ;return rte_hash_create (¶ms); }
looks good to me. cc'ed the memif maintainer.
Quoted 11 lines · Junxiao Shi
Quoted 8 lines
Previously, memif socket hash is always allocated on NUMA socket 0. If the application is entirely running on another NUMA socket and EAL --socket-limit prevents memory allocation on NUMA socket 0, memif creation fails with "HASH: memory allocation failed" error.
This patch allows allocating memif socket hash on any NUMA socket.
Signed-off-by Junxiao Shi <[email protected]>
Looks ok. Thanks for the patch!
Quoted 12 lines · Jakub Grajciar -X (jgrajcia - PANTHEON TECH SRO at Cisco)
Quoted 11 lines · Junxiao Shi
Quoted 8 lines
Previously, memif socket hash is always allocated on NUMA socket 0. If the application is entirely running on another NUMA socket and EAL --socket-limit prevents memory allocation on NUMA socket 0, memif creation fails with "HASH: memory allocation failed" error.
This patch allows allocating memif socket hash on any NUMA socket.
Signed-off-by Junxiao Shi <[email protected]>
Applied to dpdk-next-net/main, thanks.