numam-dpdk/drivers/net/i40e/i40e_hash.h
Alvin Zhang ef4c16fd91 net/i40e: refactor RSS flow
1. Delete original code.
2. Add 2 tables(One maps flow pattern and RSS type to PCTYPE,
   another maps RSS type to input set).
3. Parse RSS pattern and RSS type to get PCTYPE.
4. Parse RSS action to get queues, RSS function and hash field.
5. Create and destroy RSS filters.
6. Create new files for hash flows.

Signed-off-by: Alvin Zhang <alvinx.zhang@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
2021-01-08 19:20:09 +01:00

35 lines
820 B
C

/* SPDX-License-Identifier: BSD-3-Clause
* Copyright(c) 2020 Intel Corporation
*/
#ifndef _I40E_HASH_H_
#define _I40E_HASH_H_
#include <rte_ethdev.h>
#include <rte_flow.h>
#include "i40e_ethdev.h"
#ifdef __cplusplus
extern "C" {
#endif
int i40e_hash_parse(const struct rte_eth_dev *dev,
const struct rte_flow_item pattern[],
const struct rte_flow_action actions[],
struct i40e_rte_flow_rss_conf *rss_conf,
struct rte_flow_error *error);
int i40e_hash_filter_create(struct i40e_pf *pf,
struct i40e_rte_flow_rss_conf *rss_conf);
int i40e_hash_filter_restore(struct i40e_pf *pf);
int i40e_hash_filter_destroy(struct i40e_pf *pf,
const struct i40e_rss_filter *rss_filter);
int i40e_hash_filter_flush(struct i40e_pf *pf);
#ifdef __cplusplus
}
#endif
#endif /* I40E_HASH_H_ */