From: Chris Mi <cmi@nvidia.com>
Subject: [PATCH] BACKPORT: drivers/net/ethernet/mellanox/mlx5/core/en/rep/tc.h

Change-Id: I549aef5f514fc892c0c6f781700421efca33da41
---
 .../net/ethernet/mellanox/mlx5/core/en/rep/tc.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

--- a/drivers/net/ethernet/mellanox/mlx5/core/en/rep/tc.h
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en/rep/tc.h
@@ -33,12 +33,29 @@ int mlx5e_rep_encap_entry_attach(struct
 void mlx5e_rep_encap_entry_detach(struct mlx5e_priv *priv,
 				  struct mlx5e_encap_entry *e);
 
+#if defined(HAVE_TC_FLOWER_OFFLOAD) || defined(HAVE_FLOW_CLS_OFFLOAD)
+#if defined(HAVE_NDO_SETUP_TC_TAKES_TC_SETUP_TYPE) || defined(HAVE_NDO_SETUP_TC_RH_EXTENDED)
 int mlx5e_rep_setup_tc(struct net_device *dev, enum tc_setup_type type,
 		       void *type_data);
+#else
+int mlx5e_rep_setup_tc(struct net_device *dev, u32 handle,
+#ifdef HAVE_NDO_SETUP_TC_TAKES_CHAIN_INDEX
+		       u32 chain_index, __be16 proto,
+#else
+		       __be16 proto,
+#endif
+		       struct tc_to_netdev *tc);
+#endif
+#endif
 
 void mlx5e_rep_tc_receive(struct mlx5_cqe64 *cqe, struct mlx5e_rq *rq,
 			  struct sk_buff *skb);
 
+void mlx5e_rep_indr_clean_block_privs(struct mlx5e_rep_priv *rpriv);
+
+int mlx5e_rep_setup_tc_cb_egdev(enum tc_setup_type type, void *type_data,
+				void *cb_priv);
+
 #else /* CONFIG_MLX5_CLS_ACT */
 
 struct mlx5e_rep_priv;
