net/mlx5: Add new miss flow table action
[linux-2.6-microblaze.git] / drivers / net / ethernet / mellanox / mlx5 / core / fs_core.h
index b51ad21..0c6c5fe 100644 (file)
@@ -67,6 +67,7 @@ enum fs_flow_table_type {
        FS_FT_FDB             = 0X4,
        FS_FT_SNIFFER_RX        = 0X5,
        FS_FT_SNIFFER_TX        = 0X6,
+       FS_FT_RDMA_RX           = 0X7,
        FS_FT_MAX_TYPE = FS_FT_SNIFFER_TX,
 };
 
@@ -90,6 +91,7 @@ struct mlx5_flow_steering {
        struct mlx5_flow_root_namespace **esw_ingress_root_ns;
        struct mlx5_flow_root_namespace *sniffer_tx_root_ns;
        struct mlx5_flow_root_namespace *sniffer_rx_root_ns;
+       struct mlx5_flow_root_namespace *rdma_rx_root_ns;
        struct mlx5_flow_root_namespace *egress_root_ns;
 };
 
@@ -145,29 +147,6 @@ struct mlx5_flow_table {
        struct rhltable                 fgs_hash;
 };
 
-struct mlx5_fc_cache {
-       u64 packets;
-       u64 bytes;
-       u64 lastuse;
-};
-
-struct mlx5_fc {
-       struct list_head list;
-       struct llist_node addlist;
-       struct llist_node dellist;
-
-       /* last{packets,bytes} members are used when calculating the delta since
-        * last reading
-        */
-       u64 lastpackets;
-       u64 lastbytes;
-
-       u32 id;
-       bool aging;
-
-       struct mlx5_fc_cache cache ____cacheline_aligned_in_smp;
-};
-
 struct mlx5_ft_underlay_qp {
        struct list_head list;
        u32 qpn;
@@ -195,6 +174,7 @@ struct fs_fte {
        enum fs_fte_status              status;
        struct mlx5_fc                  *counter;
        struct rhash_head               hash;
+       int                             modify_mask;
 };
 
 /* Type of children is mlx5_flow_table/namespace */
@@ -238,6 +218,7 @@ struct mlx5_flow_root_namespace {
        struct mutex                    chain_lock;
        struct list_head                underlay_qpns;
        const struct mlx5_flow_cmds     *cmds;
+       enum mlx5_flow_table_miss_action def_miss_action;
 };
 
 int mlx5_init_fc_stats(struct mlx5_core_dev *dev);