From d172886440996b13ac0d681379fff8fc11873506 Mon Sep 17 00:00:00 2001 From: Simei Su Date: Tue, 1 Oct 2019 17:22:12 +0800 Subject: [PATCH] ethdev: add symmetric Toeplitz hash Currently, there are DEFAULT,TOEPLITZ and SIMPLE_XOR hash function. To support symmetric hash by rte_flow RSS action, this patch adds new hash function "Symmetric Toeplitz" which is supported by some hardware. Signed-off-by: Simei Su Reviewed-by: Qi Zhang Acked-by: Ori Kam Acked-by: Andrew Rybchenko --- lib/librte_ethdev/rte_flow.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/librte_ethdev/rte_flow.h b/lib/librte_ethdev/rte_flow.h index 3d2423e629..391a44a576 100644 --- a/lib/librte_ethdev/rte_flow.h +++ b/lib/librte_ethdev/rte_flow.h @@ -1907,6 +1907,12 @@ enum rte_eth_hash_function { RTE_ETH_HASH_FUNCTION_DEFAULT = 0, RTE_ETH_HASH_FUNCTION_TOEPLITZ, /**< Toeplitz */ RTE_ETH_HASH_FUNCTION_SIMPLE_XOR, /**< Simple XOR */ + /** + * Symmetric Toeplitz: src, dst will be replaced by + * xor(src, dst). For the case with src/dst only, + * src or dst address will xor with zero pair. + */ + RTE_ETH_HASH_FUNCTION_SYMMETRIC_TOEPLITZ, RTE_ETH_HASH_FUNCTION_MAX, }; -- 2.20.1