#include <linux/hash.h>
#include <linux/mlx5/fs.h>
#include <linux/ip.h>
#include <linux/ipv6.h>
#include <net/rps.h>
#include "en.h"
#define ARFS_HASH_SHIFT …
#define ARFS_HASH_SIZE …
struct arfs_table { … };
enum { … };
enum arfs_type { … };
struct mlx5e_arfs_tables { … };
struct arfs_tuple { … };
struct arfs_rule { … };
#define mlx5e_for_each_arfs_rule(hn, tmp, arfs_tables, i, j) …
#define mlx5e_for_each_hash_arfs_rule(hn, tmp, hash, j) …
static enum mlx5_traffic_types arfs_get_tt(enum arfs_type type)
{ … }
static int arfs_disable(struct mlx5e_flow_steering *fs)
{ … }
static void arfs_del_rules(struct mlx5e_flow_steering *fs);
int mlx5e_arfs_disable(struct mlx5e_flow_steering *fs)
{ … }
int mlx5e_arfs_enable(struct mlx5e_flow_steering *fs)
{ … }
static void arfs_destroy_table(struct arfs_table *arfs_t)
{ … }
static void _mlx5e_cleanup_tables(struct mlx5e_flow_steering *fs)
{ … }
void mlx5e_arfs_destroy_tables(struct mlx5e_flow_steering *fs, bool ntuple)
{ … }
static int arfs_add_default_rule(struct mlx5e_flow_steering *fs,
struct mlx5e_rx_res *rx_res,
enum arfs_type type)
{ … }
#define MLX5E_ARFS_NUM_GROUPS …
#define MLX5E_ARFS_GROUP1_SIZE …
#define MLX5E_ARFS_GROUP2_SIZE …
#define MLX5E_ARFS_TABLE_SIZE …
static int arfs_create_groups(struct mlx5e_flow_table *ft,
enum arfs_type type)
{ … }
static int arfs_create_table(struct mlx5e_flow_steering *fs,
struct mlx5e_rx_res *rx_res,
enum arfs_type type)
{ … }
int mlx5e_arfs_create_tables(struct mlx5e_flow_steering *fs,
struct mlx5e_rx_res *rx_res, bool ntuple)
{ … }
#define MLX5E_ARFS_EXPIRY_QUOTA …
static void arfs_may_expire_flow(struct mlx5e_priv *priv)
{ … }
static void arfs_del_rules(struct mlx5e_flow_steering *fs)
{ … }
static struct hlist_head *
arfs_hash_bucket(struct arfs_table *arfs_t, __be16 src_port,
__be16 dst_port)
{ … }
static struct arfs_table *arfs_get_table(struct mlx5e_arfs_tables *arfs,
u8 ip_proto, __be16 etype)
{ … }
static struct mlx5_flow_handle *arfs_add_rule(struct mlx5e_priv *priv,
struct arfs_rule *arfs_rule)
{ … }
static void arfs_modify_rule_rq(struct mlx5e_priv *priv,
struct mlx5_flow_handle *rule, u16 rxq)
{ … }
static void arfs_handle_work(struct work_struct *work)
{ … }
static struct arfs_rule *arfs_alloc_rule(struct mlx5e_priv *priv,
struct arfs_table *arfs_t,
const struct flow_keys *fk,
u16 rxq, u32 flow_id)
{ … }
static bool arfs_cmp(const struct arfs_tuple *tuple, const struct flow_keys *fk)
{ … }
static struct arfs_rule *arfs_find_rule(struct arfs_table *arfs_t,
const struct flow_keys *fk)
{ … }
int mlx5e_rx_flow_steer(struct net_device *dev, const struct sk_buff *skb,
u16 rxq_index, u32 flow_id)
{ … }