All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
@ 2018-07-19  0:11 Pablo Neira Ayuso
  2018-07-19  9:17 ` Martin Habets
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Pablo Neira Ayuso @ 2018-07-19  0:11 UTC (permalink / raw)
  To: netdev
  Cc: jiri, thomas.lendacky, f.fainelli, ariel.elior, michael.chan,
	santosh, madalin.bucur, yisen.zhuang, salil.mehta,
	jeffrey.t.kirsher, tariqt, saeedm, jiri, idosch, ganeshgr,
	jakub.kicinski, linux-net-drivers, peppe.cavallaro,
	alexandre.torgue, joabreu, grygorii.strashko, andrew,
	vivien.didelot

One of the recurring complaints is that we do not have, as a driver
writer, a central location from which we would be fed offloading rules
into a NIC. This was brought up again during Netconf'18 in Boston.

This patch just renames ndo_setup_tc to ndo_setup_offload as a very
early initial work to prepare for follow up patch that discuss unified
flow representation for the existing offload programming APIs.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
---
v2: Missing function definition update in drivers/net/ethernet/sfc/falcon/tx.c
    apparently I forgot to turn on that driver when doing compile-testing,
    problem spotted by Martin Habets. Keeping Jakub and Jiri Acked-by tags,
    as this is the only change in the v1 patch.

 drivers/net/ethernet/amd/xgbe/xgbe-drv.c            |  6 +++---
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c     |  6 +++---
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h     |  4 ++--
 drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c    |  2 +-
 drivers/net/ethernet/broadcom/bnxt/bnxt.c           |  6 +++---
 drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c       |  6 +++---
 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c     |  6 +++---
 drivers/net/ethernet/freescale/dpaa/dpaa_eth.c      |  6 +++---
 drivers/net/ethernet/hisilicon/hns3/hns3_enet.c     |  6 +++---
 drivers/net/ethernet/intel/fm10k/fm10k_netdev.c     |  6 +++---
 drivers/net/ethernet/intel/i40e/i40e_main.c         |  6 +++---
 drivers/net/ethernet/intel/i40evf/i40evf_main.c     |  8 ++++----
 drivers/net/ethernet/intel/igb/igb_main.c           |  6 +++---
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c       |  6 +++---
 drivers/net/ethernet/mellanox/mlx4/en_netdev.c      |  9 +++++----
 drivers/net/ethernet/mellanox/mlx5/core/en_main.c   |  6 +++---
 drivers/net/ethernet/mellanox/mlx5/core/en_rep.c    |  6 +++---
 drivers/net/ethernet/mellanox/mlxsw/spectrum.c      |  6 +++---
 drivers/net/ethernet/netronome/nfp/nfp_net_common.c |  2 +-
 drivers/net/ethernet/netronome/nfp/nfp_net_repr.c   |  2 +-
 drivers/net/ethernet/netronome/nfp/nfp_port.c       |  4 ++--
 drivers/net/ethernet/netronome/nfp/nfp_port.h       |  4 ++--
 drivers/net/ethernet/sfc/efx.c                      |  2 +-
 drivers/net/ethernet/sfc/efx.h                      |  4 ++--
 drivers/net/ethernet/sfc/falcon/efx.c               |  2 +-
 drivers/net/ethernet/sfc/falcon/efx.h               |  4 ++--
 drivers/net/ethernet/sfc/falcon/tx.c                |  4 ++--
 drivers/net/ethernet/sfc/tx.c                       |  4 ++--
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c   |  6 +++---
 drivers/net/ethernet/ti/netcp_core.c                |  6 +++---
 drivers/net/netdevsim/netdev.c                      |  5 +++--
 include/linux/netdevice.h                           | 18 +++++++++---------
 net/dsa/slave.c                                     |  7 ++++---
 net/sched/cls_api.c                                 |  6 +++---
 net/sched/sch_cbs.c                                 |  8 ++++----
 net/sched/sch_etf.c                                 |  8 ++++----
 net/sched/sch_mq.c                                  |  8 ++++----
 net/sched/sch_mqprio.c                              | 16 ++++++++--------
 net/sched/sch_prio.c                                | 15 ++++++++-------
 net/sched/sch_red.c                                 | 15 ++++++++-------
 40 files changed, 131 insertions(+), 126 deletions(-)

diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
index 24f1053b8785..766864a35648 100644
--- a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
+++ b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
@@ -2246,8 +2246,8 @@ static void xgbe_poll_controller(struct net_device *netdev)
 }
 #endif /* End CONFIG_NET_POLL_CONTROLLER */
 
-static int xgbe_setup_tc(struct net_device *netdev, enum tc_setup_type type,
-			 void *type_data)
+static int xgbe_setup_offload(struct net_device *netdev,
+			      enum tc_setup_type type, void *type_data)
 {
 	struct xgbe_prv_data *pdata = netdev_priv(netdev);
 	struct tc_mqprio_qopt *mqprio = type_data;
@@ -2501,7 +2501,7 @@ static const struct net_device_ops xgbe_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= xgbe_poll_controller,
 #endif
-	.ndo_setup_tc		= xgbe_setup_tc,
+	.ndo_setup_offload	= xgbe_setup_offload,
 	.ndo_fix_features	= xgbe_fix_features,
 	.ndo_set_features	= xgbe_set_features,
 	.ndo_udp_tunnel_add	= xgbe_udp_tunnel_add,
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
index 5a727d4729da..200a5938dfe5 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
@@ -4228,7 +4228,7 @@ void bnx2x_get_c2s_mapping(struct bnx2x *bp, u8 *c2s_map, u8 *c2s_default)
  * @netdev: net device to configure
  * @tc: number of traffic classes to enable
  *
- * callback connected to the ndo_setup_tc function pointer
+ * callback connected to the ndo_setup_offload function pointer
  */
 int bnx2x_setup_tc(struct net_device *dev, u8 num_tc)
 {
@@ -4293,8 +4293,8 @@ int bnx2x_setup_tc(struct net_device *dev, u8 num_tc)
 	return 0;
 }
 
-int __bnx2x_setup_tc(struct net_device *dev, enum tc_setup_type type,
-		     void *type_data)
+int __bnx2x_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			  void *type_data)
 {
 	struct tc_mqprio_qopt *mqprio = type_data;
 
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
index 0e508e5defce..e3df86f8d140 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
@@ -486,8 +486,8 @@ netdev_tx_t bnx2x_start_xmit(struct sk_buff *skb, struct net_device *dev);
 
 /* setup_tc callback */
 int bnx2x_setup_tc(struct net_device *dev, u8 num_tc);
-int __bnx2x_setup_tc(struct net_device *dev, enum tc_setup_type type,
-		     void *type_data);
+int __bnx2x_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			  void *type_data);
 
 int bnx2x_get_vf_config(struct net_device *dev, int vf,
 			struct ifla_vf_info *ivi);
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
index 71362b7f6040..b238f3478a2f 100644
--- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
+++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
@@ -13116,7 +13116,7 @@ static const struct net_device_ops bnx2x_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= poll_bnx2x,
 #endif
-	.ndo_setup_tc		= __bnx2x_setup_tc,
+	.ndo_setup_offload	= __bnx2x_setup_offload,
 #ifdef CONFIG_BNX2X_SRIOV
 	.ndo_set_vf_mac		= bnx2x_set_vf_mac,
 	.ndo_set_vf_vlan	= bnx2x_set_vf_vlan,
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
index d2dadade1d0e..e38e1cdd4e02 100644
--- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c
+++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
@@ -7993,8 +7993,8 @@ static int bnxt_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int bnxt_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			 void *type_data)
+static int bnxt_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			      void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -8377,7 +8377,7 @@ static const struct net_device_ops bnxt_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= bnxt_poll_controller,
 #endif
-	.ndo_setup_tc           = bnxt_setup_tc,
+	.ndo_setup_offload	= bnxt_setup_offload,
 #ifdef CONFIG_RFS_ACCEL
 	.ndo_rx_flow_steer	= bnxt_rx_flow_steer,
 #endif
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
index e31f5d803c13..76abfd943d7c 100644
--- a/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
+++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
@@ -183,8 +183,8 @@ static int bnxt_vf_rep_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int bnxt_vf_rep_setup_tc(struct net_device *dev, enum tc_setup_type type,
-				void *type_data)
+static int bnxt_vf_rep_setup_offload(struct net_device *dev,
+				     enum tc_setup_type type, void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -263,7 +263,7 @@ static const struct net_device_ops bnxt_vf_rep_netdev_ops = {
 	.ndo_stop		= bnxt_vf_rep_close,
 	.ndo_start_xmit		= bnxt_vf_rep_xmit,
 	.ndo_get_stats64	= bnxt_vf_rep_get_stats64,
-	.ndo_setup_tc		= bnxt_vf_rep_setup_tc,
+	.ndo_setup_offload	= bnxt_vf_rep_setup_offload,
 	.ndo_get_phys_port_name = bnxt_vf_rep_get_phys_port_name
 };
 
diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
index 40cf8dc9f163..899fe9921bdf 100644
--- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
+++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
@@ -3027,8 +3027,8 @@ static int cxgb_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int cxgb_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			 void *type_data)
+static int cxgb_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			      void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -3236,7 +3236,7 @@ static const struct net_device_ops cxgb4_netdev_ops = {
 	.ndo_fcoe_disable     = cxgb_fcoe_disable,
 #endif /* CONFIG_CHELSIO_T4_FCOE */
 	.ndo_set_tx_maxrate   = cxgb_set_tx_maxrate,
-	.ndo_setup_tc         = cxgb_setup_tc,
+	.ndo_setup_offload    = cxgb_setup_offload,
 	.ndo_udp_tunnel_add   = cxgb_add_udp_tunnel,
 	.ndo_udp_tunnel_del   = cxgb_del_udp_tunnel,
 	.ndo_features_check   = cxgb_features_check,
diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
index 65a22cd9aef2..1537e92d147c 100644
--- a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
+++ b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
@@ -346,8 +346,8 @@ static void dpaa_get_stats64(struct net_device *net_dev,
 	}
 }
 
-static int dpaa_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
-			 void *type_data)
+static int dpaa_setup_offload(struct net_device *net_dev,
+			      enum tc_setup_type type, void *type_data)
 {
 	struct dpaa_priv *priv = netdev_priv(net_dev);
 	struct tc_mqprio_qopt *mqprio = type_data;
@@ -2619,7 +2619,7 @@ static const struct net_device_ops dpaa_ops = {
 	.ndo_validate_addr = eth_validate_addr,
 	.ndo_set_rx_mode = dpaa_set_rx_mode,
 	.ndo_do_ioctl = dpaa_ioctl,
-	.ndo_setup_tc = dpaa_setup_tc,
+	.ndo_setup_offload = dpaa_setup_offload,
 };
 
 static int dpaa_napi_add(struct net_device *net_dev)
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
index c211450bfd78..b5fdafff1ff7 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
@@ -1368,8 +1368,8 @@ static int hns3_setup_tc(struct net_device *netdev, void *type_data)
 	return ret;
 }
 
-static int hns3_nic_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			     void *type_data)
+static int hns3_nic_setup_offload(struct net_device *dev,
+				  enum tc_setup_type type, void *type_data)
 {
 	if (type != TC_SETUP_QDISC_MQPRIO)
 		return -EOPNOTSUPP;
@@ -1543,7 +1543,7 @@ static const struct net_device_ops hns3_nic_netdev_ops = {
 	.ndo_change_mtu		= hns3_nic_change_mtu,
 	.ndo_set_features	= hns3_nic_set_features,
 	.ndo_get_stats64	= hns3_nic_get_stats64,
-	.ndo_setup_tc		= hns3_nic_setup_tc,
+	.ndo_setup_offload	= hns3_nic_setup_offload,
 	.ndo_set_rx_mode	= hns3_nic_set_rx_mode,
 	.ndo_vlan_rx_add_vid	= hns3_vlan_rx_add_vid,
 	.ndo_vlan_rx_kill_vid	= hns3_vlan_rx_kill_vid,
diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c b/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
index 929f538d28bc..40bfc52f1928 100644
--- a/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
+++ b/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
@@ -1428,8 +1428,8 @@ int fm10k_setup_tc(struct net_device *dev, u8 tc)
 	return err;
 }
 
-static int __fm10k_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			    void *type_data)
+static int __fm10k_setup_offload(struct net_device *dev,
+				 enum tc_setup_type type, void *type_data)
 {
 	struct tc_mqprio_qopt *mqprio = type_data;
 
@@ -1639,7 +1639,7 @@ static const struct net_device_ops fm10k_netdev_ops = {
 	.ndo_vlan_rx_kill_vid	= fm10k_vlan_rx_kill_vid,
 	.ndo_set_rx_mode	= fm10k_set_rx_mode,
 	.ndo_get_stats64	= fm10k_get_stats64,
-	.ndo_setup_tc		= __fm10k_setup_tc,
+	.ndo_setup_offload	= __fm10k_setup_offload,
 	.ndo_set_vf_mac		= fm10k_ndo_set_vf_mac,
 	.ndo_set_vf_vlan	= fm10k_ndo_set_vf_vlan,
 	.ndo_set_vf_rate	= fm10k_ndo_set_vf_bw,
diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
index 51762428b40e..f409ca5a9c9a 100644
--- a/drivers/net/ethernet/intel/i40e/i40e_main.c
+++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
@@ -7563,8 +7563,8 @@ static int i40e_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int __i40e_setup_tc(struct net_device *netdev, enum tc_setup_type type,
-			   void *type_data)
+static int __i40e_setup_offload(struct net_device *netdev,
+				enum tc_setup_type type, void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_QDISC_MQPRIO:
@@ -11864,7 +11864,7 @@ static const struct net_device_ops i40e_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= i40e_netpoll,
 #endif
-	.ndo_setup_tc		= __i40e_setup_tc,
+	.ndo_setup_offload	= __i40e_setup_offload,
 	.ndo_set_features	= i40e_set_features,
 	.ndo_set_vf_mac		= i40e_ndo_set_vf_mac,
 	.ndo_set_vf_vlan	= i40e_ndo_set_vf_port_vlan,
diff --git a/drivers/net/ethernet/intel/i40evf/i40evf_main.c b/drivers/net/ethernet/intel/i40evf/i40evf_main.c
index 5906c1c1d19d..9c1111410f2b 100644
--- a/drivers/net/ethernet/intel/i40evf/i40evf_main.c
+++ b/drivers/net/ethernet/intel/i40evf/i40evf_main.c
@@ -2942,13 +2942,13 @@ static int i40evf_setup_tc_block(struct net_device *dev,
  * @type: type of offload
  * @type_date: tc offload data
  *
- * This function is the callback to ndo_setup_tc in the
+ * This function is the callback to ndo_setup_offload in the
  * netdev_ops.
  *
  * Returns 0 on success
  **/
-static int i40evf_setup_tc(struct net_device *netdev, enum tc_setup_type type,
-			   void *type_data)
+static int i40evf_setup_offload(struct net_device *netdev,
+				enum tc_setup_type type, void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_QDISC_MQPRIO:
@@ -3232,7 +3232,7 @@ static const struct net_device_ops i40evf_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= i40evf_netpoll,
 #endif
-	.ndo_setup_tc		= i40evf_setup_tc,
+	.ndo_setup_offload	= i40evf_setup_offload,
 };
 
 /**
diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
index e3a0c02721c9..69b1633b6351 100644
--- a/drivers/net/ethernet/intel/igb/igb_main.c
+++ b/drivers/net/ethernet/intel/igb/igb_main.c
@@ -2845,8 +2845,8 @@ static int igb_offload_txtime(struct igb_adapter *adapter,
 	return 0;
 }
 
-static int igb_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			void *type_data)
+static int igb_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			     void *type_data)
 {
 	struct igb_adapter *adapter = netdev_priv(dev);
 
@@ -2889,7 +2889,7 @@ static const struct net_device_ops igb_netdev_ops = {
 	.ndo_set_features	= igb_set_features,
 	.ndo_fdb_add		= igb_ndo_fdb_add,
 	.ndo_features_check	= igb_features_check,
-	.ndo_setup_tc		= igb_setup_tc,
+	.ndo_setup_offload	= igb_setup_offload,
 };
 
 /**
diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
index 5a6600f7b382..872b2a4f3d9a 100644
--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
@@ -9360,8 +9360,8 @@ static int ixgbe_setup_tc_mqprio(struct net_device *dev,
 	return ixgbe_setup_tc(dev, mqprio->num_tc);
 }
 
-static int __ixgbe_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			    void *type_data)
+static int __ixgbe_setup_offload(struct net_device *dev,
+				 enum tc_setup_type type, void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -10068,7 +10068,7 @@ static const struct net_device_ops ixgbe_netdev_ops = {
 	.ndo_set_vf_trust	= ixgbe_ndo_set_vf_trust,
 	.ndo_get_vf_config	= ixgbe_ndo_get_vf_config,
 	.ndo_get_stats64	= ixgbe_get_stats64,
-	.ndo_setup_tc		= __ixgbe_setup_tc,
+	.ndo_setup_offload	= __ixgbe_setup_offload,
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller	= ixgbe_netpoll,
 #endif
diff --git a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
index 6785661d1a72..4a01b58a07f4 100644
--- a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
+++ b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
@@ -130,8 +130,9 @@ int mlx4_en_alloc_tx_queue_per_tc(struct net_device *dev, u8 tc)
 	return err;
 }
 
-static int __mlx4_en_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			      void *type_data)
+static int __mlx4_en_setup_offload(struct net_device *dev,
+				   enum tc_setup_type type,
+				   void *type_data)
 {
 	struct tc_mqprio_qopt *mqprio = type_data;
 
@@ -2951,7 +2952,7 @@ static const struct net_device_ops mlx4_netdev_ops = {
 #endif
 	.ndo_set_features	= mlx4_en_set_features,
 	.ndo_fix_features	= mlx4_en_fix_features,
-	.ndo_setup_tc		= __mlx4_en_setup_tc,
+	.ndo_setup_offload	= __mlx4_en_setup_offload,
 #ifdef CONFIG_RFS_ACCEL
 	.ndo_rx_flow_steer	= mlx4_en_filter_rfs,
 #endif
@@ -2988,7 +2989,7 @@ static const struct net_device_ops mlx4_netdev_ops_master = {
 #endif
 	.ndo_set_features	= mlx4_en_set_features,
 	.ndo_fix_features	= mlx4_en_fix_features,
-	.ndo_setup_tc		= __mlx4_en_setup_tc,
+	.ndo_setup_offload	= __mlx4_en_setup_offload,
 #ifdef CONFIG_RFS_ACCEL
 	.ndo_rx_flow_steer	= mlx4_en_filter_rfs,
 #endif
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
index 712b9766485f..469359cbef27 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
@@ -3383,8 +3383,8 @@ static int mlx5e_setup_tc_block(struct net_device *dev,
 }
 #endif
 
-static int mlx5e_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			  void *type_data)
+static int mlx5e_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			       void *type_data)
 {
 	switch (type) {
 #ifdef CONFIG_MLX5_ESWITCH
@@ -4222,7 +4222,7 @@ static const struct net_device_ops mlx5e_netdev_ops = {
 	.ndo_open                = mlx5e_open,
 	.ndo_stop                = mlx5e_close,
 	.ndo_start_xmit          = mlx5e_xmit,
-	.ndo_setup_tc            = mlx5e_setup_tc,
+	.ndo_setup_offload       = mlx5e_setup_offload,
 	.ndo_select_queue        = mlx5e_select_queue,
 	.ndo_get_stats64         = mlx5e_get_stats,
 	.ndo_set_rx_mode         = mlx5e_set_rx_mode,
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c b/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
index 8e3c5b4b90ab..eddb20fd4dcc 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
@@ -806,8 +806,8 @@ static int mlx5e_rep_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int mlx5e_rep_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			      void *type_data)
+static int mlx5e_rep_setup_offload(struct net_device *dev,
+				   enum tc_setup_type type, void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -917,7 +917,7 @@ static const struct net_device_ops mlx5e_netdev_ops_rep = {
 	.ndo_stop                = mlx5e_rep_close,
 	.ndo_start_xmit          = mlx5e_xmit,
 	.ndo_get_phys_port_name  = mlx5e_rep_get_phys_port_name,
-	.ndo_setup_tc            = mlx5e_rep_setup_tc,
+	.ndo_setup_offload       = mlx5e_rep_setup_offload,
 	.ndo_get_stats64         = mlx5e_rep_get_stats,
 	.ndo_has_offload_stats	 = mlx5e_has_offload_stats,
 	.ndo_get_offload_stats	 = mlx5e_get_offload_stats,
diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
index 6ec0f91a93cc..910fefbec88d 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
@@ -1631,8 +1631,8 @@ static int mlxsw_sp_setup_tc_block(struct mlxsw_sp_port *mlxsw_sp_port,
 	}
 }
 
-static int mlxsw_sp_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			     void *type_data)
+static int mlxsw_sp_setup_offload(struct net_device *dev,
+				  enum tc_setup_type type, void *type_data)
 {
 	struct mlxsw_sp_port *mlxsw_sp_port = netdev_priv(dev);
 
@@ -1708,7 +1708,7 @@ static const struct net_device_ops mlxsw_sp_port_netdev_ops = {
 	.ndo_open		= mlxsw_sp_port_open,
 	.ndo_stop		= mlxsw_sp_port_stop,
 	.ndo_start_xmit		= mlxsw_sp_port_xmit,
-	.ndo_setup_tc           = mlxsw_sp_setup_tc,
+	.ndo_setup_offload      = mlxsw_sp_setup_offload,
 	.ndo_set_rx_mode	= mlxsw_sp_set_rx_mode,
 	.ndo_set_mac_address	= mlxsw_sp_port_set_mac_address,
 	.ndo_change_mtu		= mlxsw_sp_port_change_mtu,
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
index a712e83c3f0f..56f7b468bc8c 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
+++ b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
@@ -3494,7 +3494,7 @@ const struct net_device_ops nfp_net_netdev_ops = {
 	.ndo_set_vf_spoofchk    = nfp_app_set_vf_spoofchk,
 	.ndo_get_vf_config	= nfp_app_get_vf_config,
 	.ndo_set_vf_link_state  = nfp_app_set_vf_link_state,
-	.ndo_setup_tc		= nfp_port_setup_tc,
+	.ndo_setup_offload	= nfp_port_setup_offload,
 	.ndo_tx_timeout		= nfp_net_tx_timeout,
 	.ndo_set_rx_mode	= nfp_net_set_rx_mode,
 	.ndo_change_mtu		= nfp_net_change_mtu,
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c b/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
index d7b712f6362f..a98d3762caa2 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
+++ b/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
@@ -270,7 +270,7 @@ const struct net_device_ops nfp_repr_netdev_ops = {
 	.ndo_has_offload_stats	= nfp_repr_has_offload_stats,
 	.ndo_get_offload_stats	= nfp_repr_get_offload_stats,
 	.ndo_get_phys_port_name	= nfp_port_get_phys_port_name,
-	.ndo_setup_tc		= nfp_port_setup_tc,
+	.ndo_setup_offload	= nfp_port_setup_offload,
 	.ndo_set_vf_mac		= nfp_app_set_vf_mac,
 	.ndo_set_vf_vlan	= nfp_app_set_vf_vlan,
 	.ndo_set_vf_spoofchk	= nfp_app_set_vf_spoofchk,
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_port.c b/drivers/net/ethernet/netronome/nfp/nfp_port.c
index 9c1298114c70..fb945adada08 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_port.c
+++ b/drivers/net/ethernet/netronome/nfp/nfp_port.c
@@ -89,8 +89,8 @@ const struct switchdev_ops nfp_port_switchdev_ops = {
 	.switchdev_port_attr_get	= nfp_port_attr_get,
 };
 
-int nfp_port_setup_tc(struct net_device *netdev, enum tc_setup_type type,
-		      void *type_data)
+int nfp_port_setup_offload(struct net_device *netdev, enum tc_setup_type type,
+			   void *type_data)
 {
 	struct nfp_port *port;
 
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_port.h b/drivers/net/ethernet/netronome/nfp/nfp_port.h
index 51f10ae2d53e..044fbb6f9219 100644
--- a/drivers/net/ethernet/netronome/nfp/nfp_port.h
+++ b/drivers/net/ethernet/netronome/nfp/nfp_port.h
@@ -124,8 +124,8 @@ extern const struct switchdev_ops nfp_port_switchdev_ops;
 
 __printf(2, 3) u8 *nfp_pr_et(u8 *data, const char *fmt, ...);
 
-int nfp_port_setup_tc(struct net_device *netdev, enum tc_setup_type type,
-		      void *type_data);
+int nfp_port_setup_offload(struct net_device *netdev, enum tc_setup_type type,
+			   void *type_data);
 
 static inline bool nfp_port_is_vnic(const struct nfp_port *port)
 {
diff --git a/drivers/net/ethernet/sfc/efx.c b/drivers/net/ethernet/sfc/efx.c
index b24c2e21db8e..d0cbded8360b 100644
--- a/drivers/net/ethernet/sfc/efx.c
+++ b/drivers/net/ethernet/sfc/efx.c
@@ -2518,7 +2518,7 @@ static const struct net_device_ops efx_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller = efx_netpoll,
 #endif
-	.ndo_setup_tc		= efx_setup_tc,
+	.ndo_setup_offload	= efx_setup_offload,
 #ifdef CONFIG_RFS_ACCEL
 	.ndo_rx_flow_steer	= efx_filter_rfs,
 #endif
diff --git a/drivers/net/ethernet/sfc/efx.h b/drivers/net/ethernet/sfc/efx.h
index 3f759ebdcf10..383fb4c15dea 100644
--- a/drivers/net/ethernet/sfc/efx.h
+++ b/drivers/net/ethernet/sfc/efx.h
@@ -27,8 +27,8 @@ netdev_tx_t efx_hard_start_xmit(struct sk_buff *skb,
 				struct net_device *net_dev);
 netdev_tx_t efx_enqueue_skb(struct efx_tx_queue *tx_queue, struct sk_buff *skb);
 void efx_xmit_done(struct efx_tx_queue *tx_queue, unsigned int index);
-int efx_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
-		 void *type_data);
+int efx_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
+		      void *type_data);
 unsigned int efx_tx_max_skb_descs(struct efx_nic *efx);
 extern unsigned int efx_piobuf_size;
 extern bool efx_separate_tx_channels;
diff --git a/drivers/net/ethernet/sfc/falcon/efx.c b/drivers/net/ethernet/sfc/falcon/efx.c
index dd5530a4f8c8..8c8b012945a8 100644
--- a/drivers/net/ethernet/sfc/falcon/efx.c
+++ b/drivers/net/ethernet/sfc/falcon/efx.c
@@ -2253,7 +2253,7 @@ static const struct net_device_ops ef4_netdev_ops = {
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller = ef4_netpoll,
 #endif
-	.ndo_setup_tc		= ef4_setup_tc,
+	.ndo_setup_offload	= ef4_setup_offload,
 #ifdef CONFIG_RFS_ACCEL
 	.ndo_rx_flow_steer	= ef4_filter_rfs,
 #endif
diff --git a/drivers/net/ethernet/sfc/falcon/efx.h b/drivers/net/ethernet/sfc/falcon/efx.h
index a4e4d8ea4078..67ff3891bc42 100644
--- a/drivers/net/ethernet/sfc/falcon/efx.h
+++ b/drivers/net/ethernet/sfc/falcon/efx.h
@@ -32,8 +32,8 @@ netdev_tx_t ef4_hard_start_xmit(struct sk_buff *skb,
 				struct net_device *net_dev);
 netdev_tx_t ef4_enqueue_skb(struct ef4_tx_queue *tx_queue, struct sk_buff *skb);
 void ef4_xmit_done(struct ef4_tx_queue *tx_queue, unsigned int index);
-int ef4_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
-		 void *type_data);
+int ef4_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
+		      void *type_data);
 unsigned int ef4_tx_max_skb_descs(struct ef4_nic *efx);
 extern bool ef4_separate_tx_channels;
 
diff --git a/drivers/net/ethernet/sfc/falcon/tx.c b/drivers/net/ethernet/sfc/falcon/tx.c
index 3409bbf5b19f..15a1b82160bb 100644
--- a/drivers/net/ethernet/sfc/falcon/tx.c
+++ b/drivers/net/ethernet/sfc/falcon/tx.c
@@ -425,8 +425,8 @@ void ef4_init_tx_queue_core_txq(struct ef4_tx_queue *tx_queue)
 				     efx->n_tx_channels : 0));
 }
 
-int ef4_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
-		 void *type_data)
+int ef4_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
+		      void *type_data)
 {
 	struct ef4_nic *efx = netdev_priv(net_dev);
 	struct tc_mqprio_qopt *mqprio = type_data;
diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c
index c3ad564ac4c0..53c7801decbc 100644
--- a/drivers/net/ethernet/sfc/tx.c
+++ b/drivers/net/ethernet/sfc/tx.c
@@ -687,8 +687,8 @@ void efx_init_tx_queue_core_txq(struct efx_tx_queue *tx_queue)
 				     efx->n_tx_channels : 0));
 }
 
-int efx_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
-		 void *type_data)
+int efx_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
+		      void *type_data)
 {
 	struct efx_nic *efx = netdev_priv(net_dev);
 	struct tc_mqprio_qopt *mqprio = type_data;
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index d9e60cfd8a85..a274d0c6b375 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -3787,8 +3787,8 @@ static int stmmac_setup_tc_block(struct stmmac_priv *priv,
 	}
 }
 
-static int stmmac_setup_tc(struct net_device *ndev, enum tc_setup_type type,
-			   void *type_data)
+static int stmmac_setup_offload(struct net_device *ndev,
+				enum tc_setup_type type, void *type_data)
 {
 	struct stmmac_priv *priv = netdev_priv(ndev);
 
@@ -4040,7 +4040,7 @@ static const struct net_device_ops stmmac_netdev_ops = {
 	.ndo_set_rx_mode = stmmac_set_rx_mode,
 	.ndo_tx_timeout = stmmac_tx_timeout,
 	.ndo_do_ioctl = stmmac_ioctl,
-	.ndo_setup_tc = stmmac_setup_tc,
+	.ndo_setup_offload = stmmac_setup_offload,
 #ifdef CONFIG_NET_POLL_CONTROLLER
 	.ndo_poll_controller = stmmac_poll_controller,
 #endif
diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c
index a1d335a3c5e4..70d469eabc10 100644
--- a/drivers/net/ethernet/ti/netcp_core.c
+++ b/drivers/net/ethernet/ti/netcp_core.c
@@ -1889,8 +1889,8 @@ static int netcp_rx_kill_vid(struct net_device *ndev, __be16 proto, u16 vid)
 	return err;
 }
 
-static int netcp_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			  void *type_data)
+static int netcp_setup_offload(struct net_device *dev, enum tc_setup_type type,
+			       void *type_data)
 {
 	struct tc_mqprio_qopt *mqprio = type_data;
 	u8 num_tc;
@@ -1966,7 +1966,7 @@ static const struct net_device_ops netcp_netdev_ops = {
 	.ndo_vlan_rx_kill_vid	= netcp_rx_kill_vid,
 	.ndo_tx_timeout		= netcp_ndo_tx_timeout,
 	.ndo_select_queue	= dev_pick_tx_zero,
-	.ndo_setup_tc		= netcp_setup_tc,
+	.ndo_setup_offload	= netcp_setup_offload,
 };
 
 static int netcp_create_interface(struct netcp_device *netcp_device,
diff --git a/drivers/net/netdevsim/netdev.c b/drivers/net/netdevsim/netdev.c
index a7b179f0d954..9b6a5d2f335f 100644
--- a/drivers/net/netdevsim/netdev.c
+++ b/drivers/net/netdevsim/netdev.c
@@ -393,7 +393,8 @@ static int nsim_set_vf_link_state(struct net_device *dev, int vf, int state)
 }
 
 static int
-nsim_setup_tc(struct net_device *dev, enum tc_setup_type type, void *type_data)
+nsim_setup_offload(struct net_device *dev, enum tc_setup_type type,
+		   void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -431,7 +432,7 @@ static const struct net_device_ops nsim_netdev_ops = {
 	.ndo_get_vf_config	= nsim_get_vf_config,
 	.ndo_set_vf_link_state	= nsim_set_vf_link_state,
 	.ndo_set_vf_rss_query_en = nsim_set_vf_rss_query_en,
-	.ndo_setup_tc		= nsim_setup_tc,
+	.ndo_setup_offload	= nsim_setup_offload,
 	.ndo_set_features	= nsim_set_features,
 	.ndo_bpf		= nsim_bpf,
 };
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 3514d67112b3..0f50bf95b7cd 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -1047,12 +1047,12 @@ struct dev_ifalias {
  *      with PF and querying it may introduce a theoretical security risk.
  * int (*ndo_set_vf_rss_query_en)(struct net_device *dev, int vf, bool setting);
  * int (*ndo_get_vf_port)(struct net_device *dev, int vf, struct sk_buff *skb);
- * int (*ndo_setup_tc)(struct net_device *dev, enum tc_setup_type type,
- *		       void *type_data);
- *	Called to setup any 'tc' scheduler, classifier or action on @dev.
- *	This is always called from the stack with the rtnl lock held and netif
- *	tx queues stopped. This allows the netdevice to perform queue
- *	management safely.
+ * int (*ndo_setup_offload)(struct net_device *dev, enum tc_setup_type type,
+			    void *type_data);
+ *	Called to setup any offload, such as 'tc' scheduler, classifier or
+ *	action on @dev. This is always called from the stack with the rtnl lock
+ *	held and netif tx queues stopped. This allows the netdevice to perform
+ *	queue management safely.
  *
  *	Fiber Channel over Ethernet (FCoE) offload functions.
  * int (*ndo_fcoe_enable)(struct net_device *dev);
@@ -1297,9 +1297,9 @@ struct net_device_ops {
 	int			(*ndo_set_vf_rss_query_en)(
 						   struct net_device *dev,
 						   int vf, bool setting);
-	int			(*ndo_setup_tc)(struct net_device *dev,
-						enum tc_setup_type type,
-						void *type_data);
+	int			(*ndo_setup_offload)(struct net_device *dev,
+						     enum tc_setup_type type,
+						     void *type_data);
 #if IS_ENABLED(CONFIG_FCOE)
 	int			(*ndo_fcoe_enable)(struct net_device *dev);
 	int			(*ndo_fcoe_disable)(struct net_device *dev);
diff --git a/net/dsa/slave.c b/net/dsa/slave.c
index 71536c435132..a8f4013edc2a 100644
--- a/net/dsa/slave.c
+++ b/net/dsa/slave.c
@@ -909,8 +909,9 @@ static int dsa_slave_setup_tc_block(struct net_device *dev,
 	}
 }
 
-static int dsa_slave_setup_tc(struct net_device *dev, enum tc_setup_type type,
-			      void *type_data)
+static int dsa_slave_setup_offload(struct net_device *dev,
+				   enum tc_setup_type type,
+				   void *type_data)
 {
 	switch (type) {
 	case TC_SETUP_BLOCK:
@@ -1045,7 +1046,7 @@ static const struct net_device_ops dsa_slave_netdev_ops = {
 	.ndo_poll_controller	= dsa_slave_poll_controller,
 #endif
 	.ndo_get_phys_port_name	= dsa_slave_get_phys_port_name,
-	.ndo_setup_tc		= dsa_slave_setup_tc,
+	.ndo_setup_offload	= dsa_slave_setup_offload,
 	.ndo_get_stats64	= dsa_slave_get_stats64,
 };
 
diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
index c51b1b12450d..d5add1358b66 100644
--- a/net/sched/cls_api.c
+++ b/net/sched/cls_api.c
@@ -286,7 +286,7 @@ static int tcf_block_offload_cmd(struct tcf_block *block,
 	bo.binder_type = ei->binder_type;
 	bo.block = block;
 	bo.extack = extack;
-	return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_BLOCK, &bo);
+	return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_BLOCK, &bo);
 }
 
 static int tcf_block_offload_bind(struct tcf_block *block, struct Qdisc *q,
@@ -296,7 +296,7 @@ static int tcf_block_offload_bind(struct tcf_block *block, struct Qdisc *q,
 	struct net_device *dev = q->dev_queue->dev;
 	int err;
 
-	if (!dev->netdev_ops->ndo_setup_tc)
+	if (!dev->netdev_ops->ndo_setup_offload)
 		goto no_offload_dev_inc;
 
 	/* If tc offload feature is disabled and the block we try to bind
@@ -325,7 +325,7 @@ static void tcf_block_offload_unbind(struct tcf_block *block, struct Qdisc *q,
 	struct net_device *dev = q->dev_queue->dev;
 	int err;
 
-	if (!dev->netdev_ops->ndo_setup_tc)
+	if (!dev->netdev_ops->ndo_setup_offload)
 		goto no_offload_dev_dec;
 	err = tcf_block_offload_cmd(block, dev, ei, TC_BLOCK_UNBIND, NULL);
 	if (err == -EOPNOTSUPP)
diff --git a/net/sched/sch_cbs.c b/net/sched/sch_cbs.c
index cdd96b9a27bc..d7e4169f9a1c 100644
--- a/net/sched/sch_cbs.c
+++ b/net/sched/sch_cbs.c
@@ -206,13 +206,13 @@ static void cbs_disable_offload(struct net_device *dev,
 	q->dequeue = cbs_dequeue_soft;
 
 	ops = dev->netdev_ops;
-	if (!ops->ndo_setup_tc)
+	if (!ops->ndo_setup_offload)
 		return;
 
 	cbs.queue = q->queue;
 	cbs.enable = 0;
 
-	err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_CBS, &cbs);
+	err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_CBS, &cbs);
 	if (err < 0)
 		pr_warn("Couldn't disable CBS offload for queue %d\n",
 			cbs.queue);
@@ -226,7 +226,7 @@ static int cbs_enable_offload(struct net_device *dev, struct cbs_sched_data *q,
 	struct tc_cbs_qopt_offload cbs = { };
 	int err;
 
-	if (!ops->ndo_setup_tc) {
+	if (!ops->ndo_setup_offload) {
 		NL_SET_ERR_MSG(extack, "Specified device does not support cbs offload");
 		return -EOPNOTSUPP;
 	}
@@ -239,7 +239,7 @@ static int cbs_enable_offload(struct net_device *dev, struct cbs_sched_data *q,
 	cbs.idleslope = opt->idleslope;
 	cbs.sendslope = opt->sendslope;
 
-	err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_CBS, &cbs);
+	err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_CBS, &cbs);
 	if (err < 0) {
 		NL_SET_ERR_MSG(extack, "Specified device failed to setup cbs hardware offload");
 		return err;
diff --git a/net/sched/sch_etf.c b/net/sched/sch_etf.c
index 1538d6fa8165..97061e26d2b5 100644
--- a/net/sched/sch_etf.c
+++ b/net/sched/sch_etf.c
@@ -272,13 +272,13 @@ static void etf_disable_offload(struct net_device *dev,
 		return;
 
 	ops = dev->netdev_ops;
-	if (!ops->ndo_setup_tc)
+	if (!ops->ndo_setup_offload)
 		return;
 
 	etf.queue = q->queue;
 	etf.enable = 0;
 
-	err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_ETF, &etf);
+	err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_ETF, &etf);
 	if (err < 0)
 		pr_warn("Couldn't disable ETF offload for queue %d\n",
 			etf.queue);
@@ -294,7 +294,7 @@ static int etf_enable_offload(struct net_device *dev, struct etf_sched_data *q,
 	if (q->offload)
 		return 0;
 
-	if (!ops->ndo_setup_tc) {
+	if (!ops->ndo_setup_offload) {
 		NL_SET_ERR_MSG(extack, "Specified device does not support ETF offload");
 		return -EOPNOTSUPP;
 	}
@@ -302,7 +302,7 @@ static int etf_enable_offload(struct net_device *dev, struct etf_sched_data *q,
 	etf.queue = q->queue;
 	etf.enable = 1;
 
-	err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_ETF, &etf);
+	err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_ETF, &etf);
 	if (err < 0) {
 		NL_SET_ERR_MSG(extack, "Specified device failed to setup ETF hardware offload");
 		return err;
diff --git a/net/sched/sch_mq.c b/net/sched/sch_mq.c
index d6b8ae4ed7a3..575a6b168dbc 100644
--- a/net/sched/sch_mq.c
+++ b/net/sched/sch_mq.c
@@ -32,10 +32,10 @@ static int mq_offload(struct Qdisc *sch, enum tc_mq_command cmd)
 		.handle = sch->handle,
 	};
 
-	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
+	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
 		return -EOPNOTSUPP;
 
-	return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_MQ, &opt);
+	return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_MQ, &opt);
 }
 
 static void mq_offload_stats(struct Qdisc *sch)
@@ -50,8 +50,8 @@ static void mq_offload_stats(struct Qdisc *sch)
 		},
 	};
 
-	if (tc_can_offload(dev) && dev->netdev_ops->ndo_setup_tc)
-		dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_MQ, &opt);
+	if (tc_can_offload(dev) && dev->netdev_ops->ndo_setup_offload)
+		dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_MQ, &opt);
 }
 
 static void mq_destroy(struct Qdisc *sch)
diff --git a/net/sched/sch_mqprio.c b/net/sched/sch_mqprio.c
index 0e9d761cdd80..153d137aa2cc 100644
--- a/net/sched/sch_mqprio.c
+++ b/net/sched/sch_mqprio.c
@@ -44,15 +44,15 @@ static void mqprio_destroy(struct Qdisc *sch)
 		kfree(priv->qdiscs);
 	}
 
-	if (priv->hw_offload && dev->netdev_ops->ndo_setup_tc) {
+	if (priv->hw_offload && dev->netdev_ops->ndo_setup_offload) {
 		struct tc_mqprio_qopt_offload mqprio = { { 0 } };
 
 		switch (priv->mode) {
 		case TC_MQPRIO_MODE_DCB:
 		case TC_MQPRIO_MODE_CHANNEL:
-			dev->netdev_ops->ndo_setup_tc(dev,
-						      TC_SETUP_QDISC_MQPRIO,
-						      &mqprio);
+			dev->netdev_ops->ndo_setup_offload(dev,
+							   TC_SETUP_QDISC_MQPRIO,
+							   &mqprio);
 			break;
 		default:
 			return;
@@ -85,11 +85,11 @@ static int mqprio_parse_opt(struct net_device *dev, struct tc_mqprio_qopt *qopt)
 
 	/* If hardware offload is requested we will leave it to the device
 	 * to either populate the queue counts itself or to validate the
-	 * provided queue counts.  If ndo_setup_tc is not present then
+	 * provided queue counts.  If ndo_setup_offload is not present then
 	 * hardware doesn't support offload and we should return an error.
 	 */
 	if (qopt->hw)
-		return dev->netdev_ops->ndo_setup_tc ? 0 : -EINVAL;
+		return dev->netdev_ops->ndo_setup_offload ? 0 : -EINVAL;
 
 	for (i = 0; i < qopt->num_tc; i++) {
 		unsigned int last = qopt->offset[i] + qopt->count[i];
@@ -239,7 +239,7 @@ static int mqprio_init(struct Qdisc *sch, struct nlattr *opt,
 	}
 
 	/* If the mqprio options indicate that hardware should own
-	 * the queue mapping then run ndo_setup_tc otherwise use the
+	 * the queue mapping then run ndo_setup_offload otherwise use the
 	 * supplied and verified mapping
 	 */
 	if (qopt->hw) {
@@ -266,7 +266,7 @@ static int mqprio_init(struct Qdisc *sch, struct nlattr *opt,
 		default:
 			return -EINVAL;
 		}
-		err = dev->netdev_ops->ndo_setup_tc(dev,
+		err = dev->netdev_ops->ndo_setup_offload(dev,
 						    TC_SETUP_QDISC_MQPRIO,
 						    &mqprio);
 		if (err)
diff --git a/net/sched/sch_prio.c b/net/sched/sch_prio.c
index 222e53d3d27a..ae9bf5fe320a 100644
--- a/net/sched/sch_prio.c
+++ b/net/sched/sch_prio.c
@@ -150,7 +150,7 @@ static int prio_offload(struct Qdisc *sch, struct tc_prio_qopt *qopt)
 		.parent = sch->parent,
 	};
 
-	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
+	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
 		return -EOPNOTSUPP;
 
 	if (qopt) {
@@ -163,7 +163,8 @@ static int prio_offload(struct Qdisc *sch, struct tc_prio_qopt *qopt)
 		opt.command = TC_PRIO_DESTROY;
 	}
 
-	return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO, &opt);
+	return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
+						  &opt);
 }
 
 static void
@@ -266,11 +267,11 @@ static int prio_dump_offload(struct Qdisc *sch)
 	int err;
 
 	sch->flags &= ~TCQ_F_OFFLOADED;
-	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
+	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
 		return 0;
 
-	err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO,
-					    &hw_stats);
+	err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
+						 &hw_stats);
 	if (err == -EOPNOTSUPP)
 		return 0;
 
@@ -328,8 +329,8 @@ static int prio_graft(struct Qdisc *sch, unsigned long arg, struct Qdisc *new,
 	graft_offload.graft_params.child_handle = new->handle;
 	graft_offload.command = TC_PRIO_GRAFT;
 
-	err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO,
-					    &graft_offload);
+	err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
+						 &graft_offload);
 
 	/* Don't report error if the graft is part of destroy operation. */
 	if (err && new != &noop_qdisc) {
diff --git a/net/sched/sch_red.c b/net/sched/sch_red.c
index 56c181c3feeb..63a4ee50cf05 100644
--- a/net/sched/sch_red.c
+++ b/net/sched/sch_red.c
@@ -158,7 +158,7 @@ static int red_offload(struct Qdisc *sch, bool enable)
 		.parent = sch->parent,
 	};
 
-	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
+	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
 		return -EOPNOTSUPP;
 
 	if (enable) {
@@ -172,7 +172,8 @@ static int red_offload(struct Qdisc *sch, bool enable)
 		opt.command = TC_RED_DESTROY;
 	}
 
-	return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED, &opt);
+	return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
+						  &opt);
 }
 
 static void red_destroy(struct Qdisc *sch)
@@ -295,11 +296,11 @@ static int red_dump_offload_stats(struct Qdisc *sch, struct tc_red_qopt *opt)
 
 	sch->flags &= ~TCQ_F_OFFLOADED;
 
-	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
+	if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
 		return 0;
 
-	err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED,
-					    &hw_stats);
+	err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
+						 &hw_stats);
 	if (err == -EOPNOTSUPP)
 		return 0;
 
@@ -356,8 +357,8 @@ static int red_dump_stats(struct Qdisc *sch, struct gnet_dump *d)
 				.xstats = &q->stats,
 			},
 		};
-		dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED,
-					      &hw_stats_request);
+		dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
+						   &hw_stats_request);
 	}
 	st.early = q->stats.prob_drop + q->stats.forced_drop;
 	st.pdrop = q->stats.pdrop;
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19  0:11 [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload Pablo Neira Ayuso
@ 2018-07-19  9:17 ` Martin Habets
  2018-07-19 15:18 ` Alexander Duyck
  2018-07-20 14:01 ` Florian Fainelli
  2 siblings, 0 replies; 11+ messages in thread
From: Martin Habets @ 2018-07-19  9:17 UTC (permalink / raw)
  To: Pablo Neira Ayuso, netdev
  Cc: jiri, thomas.lendacky, f.fainelli, ariel.elior, michael.chan,
	santosh, madalin.bucur, yisen.zhuang, salil.mehta,
	jeffrey.t.kirsher, tariqt, saeedm, jiri, idosch, ganeshgr,
	jakub.kicinski, linux-net-drivers, peppe.cavallaro,
	alexandre.torgue, joabreu, grygorii.strashko, andrew,
	vivien.didelot

On 19/07/18 01:11, Pablo Neira Ayuso wrote:
> One of the recurring complaints is that we do not have, as a driver
> writer, a central location from which we would be fed offloading rules
> into a NIC. This was brought up again during Netconf'18 in Boston.
> 
> This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> early initial work to prepare for follow up patch that discuss unified
> flow representation for the existing offload programming APIs.
> 
> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> Acked-by: Jiri Pirko <jiri@mellanox.com>
> Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>

Acked-by: Martin Habets <mhabets@solarflare.com>

> ---
> v2: Missing function definition update in drivers/net/ethernet/sfc/falcon/tx.c
>     apparently I forgot to turn on that driver when doing compile-testing,
>     problem spotted by Martin Habets. Keeping Jakub and Jiri Acked-by tags,
>     as this is the only change in the v1 patch.
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19  0:11 [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload Pablo Neira Ayuso
  2018-07-19  9:17 ` Martin Habets
@ 2018-07-19 15:18 ` Alexander Duyck
  2018-07-19 20:52   ` Pablo Neira Ayuso
  2018-07-20 14:01 ` Florian Fainelli
  2 siblings, 1 reply; 11+ messages in thread
From: Alexander Duyck @ 2018-07-19 15:18 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: Netdev, Jiri Pirko, Tom Lendacky, Florian Fainelli, Ariel Elior,
	Michael Chan, Santosh Raspatur, madalin.bucur, yisen.zhuang,
	salil.mehta, Jeff Kirsher, Tariq Toukan, Saeed Mahameed,
	Jiri Pirko, Ido Schimmel, Ganesh Goudar, Jakub Kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, Andrew Lunn

On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> One of the recurring complaints is that we do not have, as a driver
> writer, a central location from which we would be fed offloading rules
> into a NIC. This was brought up again during Netconf'18 in Boston.
>
> This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> early initial work to prepare for follow up patch that discuss unified
> flow representation for the existing offload programming APIs.
>
> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> Acked-by: Jiri Pirko <jiri@mellanox.com>
> Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>

One request I would have here is to not bother updating the individual
driver function names. For now I would say we could leave the
"_setup_tc" in the naming of the driver functions itself and just
update the name of the net device operation. Renaming the driver
functions just adds unnecessary overhead and complexity to the patch
and will make it more difficult to maintain. When we get around to
adding additional functionality that relates to the rename we could
address renaming the function on a per driver basis in the future.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19 15:18 ` Alexander Duyck
@ 2018-07-19 20:52   ` Pablo Neira Ayuso
  2018-07-19 21:04     ` Alexander Duyck
  0 siblings, 1 reply; 11+ messages in thread
From: Pablo Neira Ayuso @ 2018-07-19 20:52 UTC (permalink / raw)
  To: Alexander Duyck
  Cc: Netdev, Jiri Pirko, Tom Lendacky, Florian Fainelli, Ariel Elior,
	Michael Chan, Santosh Raspatur, madalin.bucur, yisen.zhuang,
	salil.mehta, Jeff Kirsher, Tariq Toukan, Saeed Mahameed,
	Jiri Pirko, Ido Schimmel, Ganesh Goudar, Jakub Kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, Andrew Lunn

On Thu, Jul 19, 2018 at 08:18:20AM -0700, Alexander Duyck wrote:
> On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> > One of the recurring complaints is that we do not have, as a driver
> > writer, a central location from which we would be fed offloading rules
> > into a NIC. This was brought up again during Netconf'18 in Boston.
> >
> > This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> > early initial work to prepare for follow up patch that discuss unified
> > flow representation for the existing offload programming APIs.
> >
> > Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> > Acked-by: Jiri Pirko <jiri@mellanox.com>
> > Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
> 
> One request I would have here is to not bother updating the individual
> driver function names. For now I would say we could leave the
> "_setup_tc" in the naming of the driver functions itself and just
> update the name of the net device operation. Renaming the driver
> functions just adds unnecessary overhead and complexity to the patch
> and will make it more difficult to maintain. When we get around to
> adding additional functionality that relates to the rename we could
> address renaming the function on a per driver basis in the future.

Plan was to follow up patch will rename enum tc_setup_type too:

https://marc.info/?l=linux-netdev&m=153193158512556&w=2

that will result in more renames in the driver side.

I would expect this will happen sooner or later, and out of tree
patches will end up needing a rebase sooner or later, if that is the
concern.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19 20:52   ` Pablo Neira Ayuso
@ 2018-07-19 21:04     ` Alexander Duyck
  2018-07-20 10:09       ` Pablo Neira Ayuso
  0 siblings, 1 reply; 11+ messages in thread
From: Alexander Duyck @ 2018-07-19 21:04 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: Netdev, Jiri Pirko, Tom Lendacky, Florian Fainelli, Ariel Elior,
	Michael Chan, Santosh Raspatur, madalin.bucur, yisen.zhuang,
	salil.mehta, Jeff Kirsher, Tariq Toukan, Saeed Mahameed,
	Jiri Pirko, Ido Schimmel, Ganesh Goudar, Jakub Kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, Andrew Lunn

On Thu, Jul 19, 2018 at 1:52 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> On Thu, Jul 19, 2018 at 08:18:20AM -0700, Alexander Duyck wrote:
>> On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
>> > One of the recurring complaints is that we do not have, as a driver
>> > writer, a central location from which we would be fed offloading rules
>> > into a NIC. This was brought up again during Netconf'18 in Boston.
>> >
>> > This patch just renames ndo_setup_tc to ndo_setup_offload as a very
>> > early initial work to prepare for follow up patch that discuss unified
>> > flow representation for the existing offload programming APIs.
>> >
>> > Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
>> > Acked-by: Jiri Pirko <jiri@mellanox.com>
>> > Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
>>
>> One request I would have here is to not bother updating the individual
>> driver function names. For now I would say we could leave the
>> "_setup_tc" in the naming of the driver functions itself and just
>> update the name of the net device operation. Renaming the driver
>> functions just adds unnecessary overhead and complexity to the patch
>> and will make it more difficult to maintain. When we get around to
>> adding additional functionality that relates to the rename we could
>> address renaming the function on a per driver basis in the future.
>
> Plan was to follow up patch will rename enum tc_setup_type too:
>
> https://marc.info/?l=linux-netdev&m=153193158512556&w=2
>
> that will result in more renames in the driver side.
>
> I would expect this will happen sooner or later, and out of tree
> patches will end up needing a rebase sooner or later, if that is the
> concern.

I was just thinking that renaming the functions themselves adds noise
and makes it harder to debug functions later when they get renamed. As
far as the out-of-tree driver I agree we will still have to deal with
it due to the enum and NDO function rename. I just figured that using
things like LXR is a bit easier when the function name stays the same
and you have to move between versions.

- Alex

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19 21:04     ` Alexander Duyck
@ 2018-07-20 10:09       ` Pablo Neira Ayuso
  2018-07-20 14:45         ` Alexander Duyck
  0 siblings, 1 reply; 11+ messages in thread
From: Pablo Neira Ayuso @ 2018-07-20 10:09 UTC (permalink / raw)
  To: Alexander Duyck
  Cc: Netdev, Jiri Pirko, Tom Lendacky, Florian Fainelli, Ariel Elior,
	Michael Chan, Santosh Raspatur, madalin.bucur, yisen.zhuang,
	salil.mehta, Jeff Kirsher, Tariq Toukan, Saeed Mahameed,
	Jiri Pirko, Ido Schimmel, Ganesh Goudar, Jakub Kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, Andrew Lunn

On Thu, Jul 19, 2018 at 02:04:16PM -0700, Alexander Duyck wrote:
> On Thu, Jul 19, 2018 at 1:52 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> > On Thu, Jul 19, 2018 at 08:18:20AM -0700, Alexander Duyck wrote:
> >> On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> >> > One of the recurring complaints is that we do not have, as a driver
> >> > writer, a central location from which we would be fed offloading rules
> >> > into a NIC. This was brought up again during Netconf'18 in Boston.
> >> >
> >> > This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> >> > early initial work to prepare for follow up patch that discuss unified
> >> > flow representation for the existing offload programming APIs.
> >> >
> >> > Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> >> > Acked-by: Jiri Pirko <jiri@mellanox.com>
> >> > Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
> >>
> >> One request I would have here is to not bother updating the individual
> >> driver function names. For now I would say we could leave the
> >> "_setup_tc" in the naming of the driver functions itself and just
> >> update the name of the net device operation. Renaming the driver
> >> functions just adds unnecessary overhead and complexity to the patch
> >> and will make it more difficult to maintain. When we get around to
> >> adding additional functionality that relates to the rename we could
> >> address renaming the function on a per driver basis in the future.
> >
> > Plan was to follow up patch will rename enum tc_setup_type too:
> >
> > https://marc.info/?l=linux-netdev&m=153193158512556&w=2
> >
> > that will result in more renames in the driver side.
> >
> > I would expect this will happen sooner or later, and out of tree
> > patches will end up needing a rebase sooner or later, if that is the
> > concern.
> 
> I was just thinking that renaming the functions themselves adds noise
> and makes it harder to debug functions later when they get renamed. As
> far as the out-of-tree driver I agree we will still have to deal with
> it due to the enum and NDO function rename. I just figured that using
> things like LXR is a bit easier when the function name stays the same
> and you have to move between versions.

Semantic changes in this interface are expected in follow up patches.
Specifically, this interface will not be exclusively dedicated to 'tc'
anymore. The function rename will provide a hint on this semantic change
going on. I understand your concern, and I also tend to dislike renaming
for the sake of renaming, but in this case this rename coveys useful
information to developers.

Thanks.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-19  0:11 [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload Pablo Neira Ayuso
  2018-07-19  9:17 ` Martin Habets
  2018-07-19 15:18 ` Alexander Duyck
@ 2018-07-20 14:01 ` Florian Fainelli
  2 siblings, 0 replies; 11+ messages in thread
From: Florian Fainelli @ 2018-07-20 14:01 UTC (permalink / raw)
  To: Pablo Neira Ayuso, netdev
  Cc: jiri, thomas.lendacky, ariel.elior, michael.chan, santosh,
	madalin.bucur, yisen.zhuang, salil.mehta, jeffrey.t.kirsher,
	tariqt, saeedm, jiri, idosch, ganeshgr, jakub.kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, andrew, vivien.didelot



On 07/18/2018 05:11 PM, Pablo Neira Ayuso wrote:
> One of the recurring complaints is that we do not have, as a driver
> writer, a central location from which we would be fed offloading rules
> into a NIC. This was brought up again during Netconf'18 in Boston.
> 
> This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> early initial work to prepare for follow up patch that discuss unified
> flow representation for the existing offload programming APIs.
> 
> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> Acked-by: Jiri Pirko <jiri@mellanox.com>
> Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>

Acked-by: Florian Fainelli <f.fainelli@gmail.com>

Thanks Pablo!
-- 
Florian

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-20 10:09       ` Pablo Neira Ayuso
@ 2018-07-20 14:45         ` Alexander Duyck
  0 siblings, 0 replies; 11+ messages in thread
From: Alexander Duyck @ 2018-07-20 14:45 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: Netdev, Jiri Pirko, Tom Lendacky, Florian Fainelli, Ariel Elior,
	Michael Chan, Santosh Raspatur, madalin.bucur, yisen.zhuang,
	salil.mehta, Jeff Kirsher, Tariq Toukan, Saeed Mahameed,
	Jiri Pirko, Ido Schimmel, Ganesh Goudar, Jakub Kicinski,
	linux-net-drivers, peppe.cavallaro, alexandre.torgue, joabreu,
	grygorii.strashko, Andrew Lunn

On Fri, Jul 20, 2018 at 3:09 AM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> On Thu, Jul 19, 2018 at 02:04:16PM -0700, Alexander Duyck wrote:
>> On Thu, Jul 19, 2018 at 1:52 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
>> > On Thu, Jul 19, 2018 at 08:18:20AM -0700, Alexander Duyck wrote:
>> >> On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
>> >> > One of the recurring complaints is that we do not have, as a driver
>> >> > writer, a central location from which we would be fed offloading rules
>> >> > into a NIC. This was brought up again during Netconf'18 in Boston.
>> >> >
>> >> > This patch just renames ndo_setup_tc to ndo_setup_offload as a very
>> >> > early initial work to prepare for follow up patch that discuss unified
>> >> > flow representation for the existing offload programming APIs.
>> >> >
>> >> > Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
>> >> > Acked-by: Jiri Pirko <jiri@mellanox.com>
>> >> > Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
>> >>
>> >> One request I would have here is to not bother updating the individual
>> >> driver function names. For now I would say we could leave the
>> >> "_setup_tc" in the naming of the driver functions itself and just
>> >> update the name of the net device operation. Renaming the driver
>> >> functions just adds unnecessary overhead and complexity to the patch
>> >> and will make it more difficult to maintain. When we get around to
>> >> adding additional functionality that relates to the rename we could
>> >> address renaming the function on a per driver basis in the future.
>> >
>> > Plan was to follow up patch will rename enum tc_setup_type too:
>> >
>> > https://marc.info/?l=linux-netdev&m=153193158512556&w=2
>> >
>> > that will result in more renames in the driver side.
>> >
>> > I would expect this will happen sooner or later, and out of tree
>> > patches will end up needing a rebase sooner or later, if that is the
>> > concern.
>>
>> I was just thinking that renaming the functions themselves adds noise
>> and makes it harder to debug functions later when they get renamed. As
>> far as the out-of-tree driver I agree we will still have to deal with
>> it due to the enum and NDO function rename. I just figured that using
>> things like LXR is a bit easier when the function name stays the same
>> and you have to move between versions.
>
> Semantic changes in this interface are expected in follow up patches.
> Specifically, this interface will not be exclusively dedicated to 'tc'
> anymore. The function rename will provide a hint on this semantic change
> going on. I understand your concern, and I also tend to dislike renaming
> for the sake of renaming, but in this case this rename coveys useful
> information to developers.
>
> Thanks.

I kind of figured semantic changes were coming. I just thought we
could wait until then for the function renames. There isn't any point
in renaming the function until it changes what it is actually doing. I
suspect you may only have a few drivers that do the update as there
probably isn't much value in updating the function name on drivers
such as fm10k or igb as they are unlikely to ever support anything
other than the tc offloads. That way it is clear that currently none
of the drivers are supporting anything other than the tc offloads
until the new functionality to support netfilter offloads is added on
a per driver basis.

- Alex

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-20 17:28 ` Daniel Borkmann
@ 2018-07-20 19:07   ` David Miller
  0 siblings, 0 replies; 11+ messages in thread
From: David Miller @ 2018-07-20 19:07 UTC (permalink / raw)
  To: daniel
  Cc: roopa, pablo, netdev, jiri, thomas.lendacky, f.fainelli,
	ariel.elior, michael.chan, santosh, madalin.bucur, yisen.zhuang,
	salil.mehta, jeffrey.t.kirsher, tariqt, saeedm, jiri, idosch,
	ganeshgr, jakub.kicinski, linux-net-drivers, peppe.cavallaro,
	alexandre.torgue, joabreu, grygorii.strashko, andrew,
	vivien.didelot

From: Daniel Borkmann <daniel@iogearbox.net>
Date: Fri, 20 Jul 2018 19:28:23 +0200

> This might be fine as new ndo depending on the use case this will have (?),
> but fwiw the term 'flow' or 'rule' would be misleading for what tc offload
> would be doing today (e.g. to name one, there's no notion of 'flow' in BPF
> offload). Given today this interface is deeply baked into tc, just a rename
> might not suffice but should probably move the whole handling around it such
> as assembling the offload info into generic net/core/netdev.c as well if this
> is the way to go.

I would much rather see a new NDO for handling a new offload.  That is
consistent with our overall game plan of the past few years ever since
this TC offload NDO went in.

We can't pretend to be able to predict the future and know that these
various things can be consolidated into a single interface beforehand.

It is important to see what implementing a new offload looks like, in
a couple of drivers, first.  And then we can have something to look
at, and discuss, with respect to NDO consolidation.

What is happening with this patch is you are brute force making this
NDO generic, and then saying "I will show you how it can be generic."

Sorry, that's the wrong way around.  Make a new NDO op for your flow
offloading, show how it works and is implemented in a few drivers,
and then (and only then) can you talk about whether consolidating
is possible or appropriate.

Thank you.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
  2018-07-20 14:37 Roopa Prabhu
@ 2018-07-20 17:28 ` Daniel Borkmann
  2018-07-20 19:07   ` David Miller
  0 siblings, 1 reply; 11+ messages in thread
From: Daniel Borkmann @ 2018-07-20 17:28 UTC (permalink / raw)
  To: Roopa Prabhu, Pablo Neira Ayuso
  Cc: netdev, Jiří Pírko, thomas.lendacky,
	Florian Fainelli, Elior, Ariel, Michael Chan, Santosh Rastapur,
	madalin.bucur, yisen.zhuang, salil.mehta, Jeff Kirsher, tariqt,
	Saeed Mahameed, Jiri Pirko, Ido Schimmel, Ganesh GR,
	Jakub Kicinski, linux-net-drivers, peppe.cavallaro,
	alexandre.torgue, joabreu, grygorii.strashko, Andrew Lunn

On 07/20/2018 04:37 PM, Roopa Prabhu wrote:
> On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
>> One of the recurring complaints is that we do not have, as a driver
>> writer, a central location from which we would be fed offloading rules
>> into a NIC. This was brought up again during Netconf'18 in Boston.
>>
>> This patch just renames ndo_setup_tc to ndo_setup_offload as a very
>> early initial work to prepare for follow up patch that discuss unified
>> flow representation for the existing offload programming APIs.
>>
>> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
>> Acked-by: Jiri Pirko <jiri@mellanox.com>
>> Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
> 
> ok with a rename,...but this seems to be going from a very specific to
> a completely generic name.
> maybe ndo_setup_flow_offload or ndo_setup_rule_offload might be better ?.

This might be fine as new ndo depending on the use case this will have (?),
but fwiw the term 'flow' or 'rule' would be misleading for what tc offload
would be doing today (e.g. to name one, there's no notion of 'flow' in BPF
offload). Given today this interface is deeply baked into tc, just a rename
might not suffice but should probably move the whole handling around it such
as assembling the offload info into generic net/core/netdev.c as well if this
is the way to go.

> (or maybe i am missing some context and this is really for setting up
> every possible hardware offload ?)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload
@ 2018-07-20 14:37 Roopa Prabhu
  2018-07-20 17:28 ` Daniel Borkmann
  0 siblings, 1 reply; 11+ messages in thread
From: Roopa Prabhu @ 2018-07-20 14:37 UTC (permalink / raw)
  To: Pablo Neira Ayuso
  Cc: netdev, Jiří Pírko, thomas.lendacky,
	Florian Fainelli, Elior, Ariel, Michael Chan, Santosh Rastapur,
	madalin.bucur, yisen.zhuang, salil.mehta, Jeff Kirsher, tariqt,
	Saeed Mahameed, Jiri Pirko, Ido Schimmel, Ganesh GR,
	Jakub Kicinski, linux-net-drivers, peppe.cavallaro,
	alexandre.torgue, joabreu, grygorii.strashko, Andrew Lunn

On Wed, Jul 18, 2018 at 5:11 PM, Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> One of the recurring complaints is that we do not have, as a driver
> writer, a central location from which we would be fed offloading rules
> into a NIC. This was brought up again during Netconf'18 in Boston.
>
> This patch just renames ndo_setup_tc to ndo_setup_offload as a very
> early initial work to prepare for follow up patch that discuss unified
> flow representation for the existing offload programming APIs.
>
> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
> Acked-by: Jiri Pirko <jiri@mellanox.com>
> Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>



ok with a rename,...but this seems to be going from a very specific to
a completely generic name.
maybe ndo_setup_flow_offload or ndo_setup_rule_offload might be better ?.

(or maybe i am missing some context and this is really for setting up
every possible hardware offload ?)




> ---
> v2: Missing function definition update in drivers/net/ethernet/sfc/falcon/tx.c
>     apparently I forgot to turn on that driver when doing compile-testing,
>     problem spotted by Martin Habets. Keeping Jakub and Jiri Acked-by tags,
>     as this is the only change in the v1 patch.
>
>  drivers/net/ethernet/amd/xgbe/xgbe-drv.c            |  6 +++---
>  drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c     |  6 +++---
>  drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h     |  4 ++--
>  drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c    |  2 +-
>  drivers/net/ethernet/broadcom/bnxt/bnxt.c           |  6 +++---
>  drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c       |  6 +++---
>  drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c     |  6 +++---
>  drivers/net/ethernet/freescale/dpaa/dpaa_eth.c      |  6 +++---
>  drivers/net/ethernet/hisilicon/hns3/hns3_enet.c     |  6 +++---
>  drivers/net/ethernet/intel/fm10k/fm10k_netdev.c     |  6 +++---
>  drivers/net/ethernet/intel/i40e/i40e_main.c         |  6 +++---
>  drivers/net/ethernet/intel/i40evf/i40evf_main.c     |  8 ++++----
>  drivers/net/ethernet/intel/igb/igb_main.c           |  6 +++---
>  drivers/net/ethernet/intel/ixgbe/ixgbe_main.c       |  6 +++---
>  drivers/net/ethernet/mellanox/mlx4/en_netdev.c      |  9 +++++----
>  drivers/net/ethernet/mellanox/mlx5/core/en_main.c   |  6 +++---
>  drivers/net/ethernet/mellanox/mlx5/core/en_rep.c    |  6 +++---
>  drivers/net/ethernet/mellanox/mlxsw/spectrum.c      |  6 +++---
>  drivers/net/ethernet/netronome/nfp/nfp_net_common.c |  2 +-
>  drivers/net/ethernet/netronome/nfp/nfp_net_repr.c   |  2 +-
>  drivers/net/ethernet/netronome/nfp/nfp_port.c       |  4 ++--
>  drivers/net/ethernet/netronome/nfp/nfp_port.h       |  4 ++--
>  drivers/net/ethernet/sfc/efx.c                      |  2 +-
>  drivers/net/ethernet/sfc/efx.h                      |  4 ++--
>  drivers/net/ethernet/sfc/falcon/efx.c               |  2 +-
>  drivers/net/ethernet/sfc/falcon/efx.h               |  4 ++--
>  drivers/net/ethernet/sfc/falcon/tx.c                |  4 ++--
>  drivers/net/ethernet/sfc/tx.c                       |  4 ++--
>  drivers/net/ethernet/stmicro/stmmac/stmmac_main.c   |  6 +++---
>  drivers/net/ethernet/ti/netcp_core.c                |  6 +++---
>  drivers/net/netdevsim/netdev.c                      |  5 +++--
>  include/linux/netdevice.h                           | 18 +++++++++---------
>  net/dsa/slave.c                                     |  7 ++++---
>  net/sched/cls_api.c                                 |  6 +++---
>  net/sched/sch_cbs.c                                 |  8 ++++----
>  net/sched/sch_etf.c                                 |  8 ++++----
>  net/sched/sch_mq.c                                  |  8 ++++----
>  net/sched/sch_mqprio.c                              | 16 ++++++++--------
>  net/sched/sch_prio.c                                | 15 ++++++++-------
>  net/sched/sch_red.c                                 | 15 ++++++++-------
>  40 files changed, 131 insertions(+), 126 deletions(-)
>
> diff --git a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
> index 24f1053b8785..766864a35648 100644
> --- a/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
> +++ b/drivers/net/ethernet/amd/xgbe/xgbe-drv.c
> @@ -2246,8 +2246,8 @@ static void xgbe_poll_controller(struct net_device *netdev)
>  }
>  #endif /* End CONFIG_NET_POLL_CONTROLLER */
>
> -static int xgbe_setup_tc(struct net_device *netdev, enum tc_setup_type type,
> -                        void *type_data)
> +static int xgbe_setup_offload(struct net_device *netdev,
> +                             enum tc_setup_type type, void *type_data)
>  {
>         struct xgbe_prv_data *pdata = netdev_priv(netdev);
>         struct tc_mqprio_qopt *mqprio = type_data;
> @@ -2501,7 +2501,7 @@ static const struct net_device_ops xgbe_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = xgbe_poll_controller,
>  #endif
> -       .ndo_setup_tc           = xgbe_setup_tc,
> +       .ndo_setup_offload      = xgbe_setup_offload,
>         .ndo_fix_features       = xgbe_fix_features,
>         .ndo_set_features       = xgbe_set_features,
>         .ndo_udp_tunnel_add     = xgbe_udp_tunnel_add,
> diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
> index 5a727d4729da..200a5938dfe5 100644
> --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
> +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.c
> @@ -4228,7 +4228,7 @@ void bnx2x_get_c2s_mapping(struct bnx2x *bp, u8 *c2s_map, u8 *c2s_default)
>   * @netdev: net device to configure
>   * @tc: number of traffic classes to enable
>   *
> - * callback connected to the ndo_setup_tc function pointer
> + * callback connected to the ndo_setup_offload function pointer
>   */
>  int bnx2x_setup_tc(struct net_device *dev, u8 num_tc)
>  {
> @@ -4293,8 +4293,8 @@ int bnx2x_setup_tc(struct net_device *dev, u8 num_tc)
>         return 0;
>  }
>
> -int __bnx2x_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                    void *type_data)
> +int __bnx2x_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                         void *type_data)
>  {
>         struct tc_mqprio_qopt *mqprio = type_data;
>
> diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
> index 0e508e5defce..e3df86f8d140 100644
> --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
> +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_cmn.h
> @@ -486,8 +486,8 @@ netdev_tx_t bnx2x_start_xmit(struct sk_buff *skb, struct net_device *dev);
>
>  /* setup_tc callback */
>  int bnx2x_setup_tc(struct net_device *dev, u8 num_tc);
> -int __bnx2x_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                    void *type_data);
> +int __bnx2x_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                         void *type_data);
>
>  int bnx2x_get_vf_config(struct net_device *dev, int vf,
>                         struct ifla_vf_info *ivi);
> diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
> index 71362b7f6040..b238f3478a2f 100644
> --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
> +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c
> @@ -13116,7 +13116,7 @@ static const struct net_device_ops bnx2x_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = poll_bnx2x,
>  #endif
> -       .ndo_setup_tc           = __bnx2x_setup_tc,
> +       .ndo_setup_offload      = __bnx2x_setup_offload,
>  #ifdef CONFIG_BNX2X_SRIOV
>         .ndo_set_vf_mac         = bnx2x_set_vf_mac,
>         .ndo_set_vf_vlan        = bnx2x_set_vf_vlan,
> diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
> index d2dadade1d0e..e38e1cdd4e02 100644
> --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c
> +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c
> @@ -7993,8 +7993,8 @@ static int bnxt_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int bnxt_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                        void *type_data)
> +static int bnxt_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                             void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -8377,7 +8377,7 @@ static const struct net_device_ops bnxt_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = bnxt_poll_controller,
>  #endif
> -       .ndo_setup_tc           = bnxt_setup_tc,
> +       .ndo_setup_offload      = bnxt_setup_offload,
>  #ifdef CONFIG_RFS_ACCEL
>         .ndo_rx_flow_steer      = bnxt_rx_flow_steer,
>  #endif
> diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
> index e31f5d803c13..76abfd943d7c 100644
> --- a/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
> +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c
> @@ -183,8 +183,8 @@ static int bnxt_vf_rep_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int bnxt_vf_rep_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                               void *type_data)
> +static int bnxt_vf_rep_setup_offload(struct net_device *dev,
> +                                    enum tc_setup_type type, void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -263,7 +263,7 @@ static const struct net_device_ops bnxt_vf_rep_netdev_ops = {
>         .ndo_stop               = bnxt_vf_rep_close,
>         .ndo_start_xmit         = bnxt_vf_rep_xmit,
>         .ndo_get_stats64        = bnxt_vf_rep_get_stats64,
> -       .ndo_setup_tc           = bnxt_vf_rep_setup_tc,
> +       .ndo_setup_offload      = bnxt_vf_rep_setup_offload,
>         .ndo_get_phys_port_name = bnxt_vf_rep_get_phys_port_name
>  };
>
> diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
> index 40cf8dc9f163..899fe9921bdf 100644
> --- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
> +++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c
> @@ -3027,8 +3027,8 @@ static int cxgb_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int cxgb_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                        void *type_data)
> +static int cxgb_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                             void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -3236,7 +3236,7 @@ static const struct net_device_ops cxgb4_netdev_ops = {
>         .ndo_fcoe_disable     = cxgb_fcoe_disable,
>  #endif /* CONFIG_CHELSIO_T4_FCOE */
>         .ndo_set_tx_maxrate   = cxgb_set_tx_maxrate,
> -       .ndo_setup_tc         = cxgb_setup_tc,
> +       .ndo_setup_offload    = cxgb_setup_offload,
>         .ndo_udp_tunnel_add   = cxgb_add_udp_tunnel,
>         .ndo_udp_tunnel_del   = cxgb_del_udp_tunnel,
>         .ndo_features_check   = cxgb_features_check,
> diff --git a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
> index 65a22cd9aef2..1537e92d147c 100644
> --- a/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
> +++ b/drivers/net/ethernet/freescale/dpaa/dpaa_eth.c
> @@ -346,8 +346,8 @@ static void dpaa_get_stats64(struct net_device *net_dev,
>         }
>  }
>
> -static int dpaa_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
> -                        void *type_data)
> +static int dpaa_setup_offload(struct net_device *net_dev,
> +                             enum tc_setup_type type, void *type_data)
>  {
>         struct dpaa_priv *priv = netdev_priv(net_dev);
>         struct tc_mqprio_qopt *mqprio = type_data;
> @@ -2619,7 +2619,7 @@ static const struct net_device_ops dpaa_ops = {
>         .ndo_validate_addr = eth_validate_addr,
>         .ndo_set_rx_mode = dpaa_set_rx_mode,
>         .ndo_do_ioctl = dpaa_ioctl,
> -       .ndo_setup_tc = dpaa_setup_tc,
> +       .ndo_setup_offload = dpaa_setup_offload,
>  };
>
>  static int dpaa_napi_add(struct net_device *net_dev)
> diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
> index c211450bfd78..b5fdafff1ff7 100644
> --- a/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
> +++ b/drivers/net/ethernet/hisilicon/hns3/hns3_enet.c
> @@ -1368,8 +1368,8 @@ static int hns3_setup_tc(struct net_device *netdev, void *type_data)
>         return ret;
>  }
>
> -static int hns3_nic_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                            void *type_data)
> +static int hns3_nic_setup_offload(struct net_device *dev,
> +                                 enum tc_setup_type type, void *type_data)
>  {
>         if (type != TC_SETUP_QDISC_MQPRIO)
>                 return -EOPNOTSUPP;
> @@ -1543,7 +1543,7 @@ static const struct net_device_ops hns3_nic_netdev_ops = {
>         .ndo_change_mtu         = hns3_nic_change_mtu,
>         .ndo_set_features       = hns3_nic_set_features,
>         .ndo_get_stats64        = hns3_nic_get_stats64,
> -       .ndo_setup_tc           = hns3_nic_setup_tc,
> +       .ndo_setup_offload      = hns3_nic_setup_offload,
>         .ndo_set_rx_mode        = hns3_nic_set_rx_mode,
>         .ndo_vlan_rx_add_vid    = hns3_vlan_rx_add_vid,
>         .ndo_vlan_rx_kill_vid   = hns3_vlan_rx_kill_vid,
> diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c b/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
> index 929f538d28bc..40bfc52f1928 100644
> --- a/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
> +++ b/drivers/net/ethernet/intel/fm10k/fm10k_netdev.c
> @@ -1428,8 +1428,8 @@ int fm10k_setup_tc(struct net_device *dev, u8 tc)
>         return err;
>  }
>
> -static int __fm10k_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                           void *type_data)
> +static int __fm10k_setup_offload(struct net_device *dev,
> +                                enum tc_setup_type type, void *type_data)
>  {
>         struct tc_mqprio_qopt *mqprio = type_data;
>
> @@ -1639,7 +1639,7 @@ static const struct net_device_ops fm10k_netdev_ops = {
>         .ndo_vlan_rx_kill_vid   = fm10k_vlan_rx_kill_vid,
>         .ndo_set_rx_mode        = fm10k_set_rx_mode,
>         .ndo_get_stats64        = fm10k_get_stats64,
> -       .ndo_setup_tc           = __fm10k_setup_tc,
> +       .ndo_setup_offload      = __fm10k_setup_offload,
>         .ndo_set_vf_mac         = fm10k_ndo_set_vf_mac,
>         .ndo_set_vf_vlan        = fm10k_ndo_set_vf_vlan,
>         .ndo_set_vf_rate        = fm10k_ndo_set_vf_bw,
> diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
> index 51762428b40e..f409ca5a9c9a 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_main.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
> @@ -7563,8 +7563,8 @@ static int i40e_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int __i40e_setup_tc(struct net_device *netdev, enum tc_setup_type type,
> -                          void *type_data)
> +static int __i40e_setup_offload(struct net_device *netdev,
> +                               enum tc_setup_type type, void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_QDISC_MQPRIO:
> @@ -11864,7 +11864,7 @@ static const struct net_device_ops i40e_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = i40e_netpoll,
>  #endif
> -       .ndo_setup_tc           = __i40e_setup_tc,
> +       .ndo_setup_offload      = __i40e_setup_offload,
>         .ndo_set_features       = i40e_set_features,
>         .ndo_set_vf_mac         = i40e_ndo_set_vf_mac,
>         .ndo_set_vf_vlan        = i40e_ndo_set_vf_port_vlan,
> diff --git a/drivers/net/ethernet/intel/i40evf/i40evf_main.c b/drivers/net/ethernet/intel/i40evf/i40evf_main.c
> index 5906c1c1d19d..9c1111410f2b 100644
> --- a/drivers/net/ethernet/intel/i40evf/i40evf_main.c
> +++ b/drivers/net/ethernet/intel/i40evf/i40evf_main.c
> @@ -2942,13 +2942,13 @@ static int i40evf_setup_tc_block(struct net_device *dev,
>   * @type: type of offload
>   * @type_date: tc offload data
>   *
> - * This function is the callback to ndo_setup_tc in the
> + * This function is the callback to ndo_setup_offload in the
>   * netdev_ops.
>   *
>   * Returns 0 on success
>   **/
> -static int i40evf_setup_tc(struct net_device *netdev, enum tc_setup_type type,
> -                          void *type_data)
> +static int i40evf_setup_offload(struct net_device *netdev,
> +                               enum tc_setup_type type, void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_QDISC_MQPRIO:
> @@ -3232,7 +3232,7 @@ static const struct net_device_ops i40evf_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = i40evf_netpoll,
>  #endif
> -       .ndo_setup_tc           = i40evf_setup_tc,
> +       .ndo_setup_offload      = i40evf_setup_offload,
>  };
>
>  /**
> diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c
> index e3a0c02721c9..69b1633b6351 100644
> --- a/drivers/net/ethernet/intel/igb/igb_main.c
> +++ b/drivers/net/ethernet/intel/igb/igb_main.c
> @@ -2845,8 +2845,8 @@ static int igb_offload_txtime(struct igb_adapter *adapter,
>         return 0;
>  }
>
> -static int igb_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                       void *type_data)
> +static int igb_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                            void *type_data)
>  {
>         struct igb_adapter *adapter = netdev_priv(dev);
>
> @@ -2889,7 +2889,7 @@ static const struct net_device_ops igb_netdev_ops = {
>         .ndo_set_features       = igb_set_features,
>         .ndo_fdb_add            = igb_ndo_fdb_add,
>         .ndo_features_check     = igb_features_check,
> -       .ndo_setup_tc           = igb_setup_tc,
> +       .ndo_setup_offload      = igb_setup_offload,
>  };
>
>  /**
> diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> index 5a6600f7b382..872b2a4f3d9a 100644
> --- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> +++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c
> @@ -9360,8 +9360,8 @@ static int ixgbe_setup_tc_mqprio(struct net_device *dev,
>         return ixgbe_setup_tc(dev, mqprio->num_tc);
>  }
>
> -static int __ixgbe_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                           void *type_data)
> +static int __ixgbe_setup_offload(struct net_device *dev,
> +                                enum tc_setup_type type, void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -10068,7 +10068,7 @@ static const struct net_device_ops ixgbe_netdev_ops = {
>         .ndo_set_vf_trust       = ixgbe_ndo_set_vf_trust,
>         .ndo_get_vf_config      = ixgbe_ndo_get_vf_config,
>         .ndo_get_stats64        = ixgbe_get_stats64,
> -       .ndo_setup_tc           = __ixgbe_setup_tc,
> +       .ndo_setup_offload      = __ixgbe_setup_offload,
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller    = ixgbe_netpoll,
>  #endif
> diff --git a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
> index 6785661d1a72..4a01b58a07f4 100644
> --- a/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
> +++ b/drivers/net/ethernet/mellanox/mlx4/en_netdev.c
> @@ -130,8 +130,9 @@ int mlx4_en_alloc_tx_queue_per_tc(struct net_device *dev, u8 tc)
>         return err;
>  }
>
> -static int __mlx4_en_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                             void *type_data)
> +static int __mlx4_en_setup_offload(struct net_device *dev,
> +                                  enum tc_setup_type type,
> +                                  void *type_data)
>  {
>         struct tc_mqprio_qopt *mqprio = type_data;
>
> @@ -2951,7 +2952,7 @@ static const struct net_device_ops mlx4_netdev_ops = {
>  #endif
>         .ndo_set_features       = mlx4_en_set_features,
>         .ndo_fix_features       = mlx4_en_fix_features,
> -       .ndo_setup_tc           = __mlx4_en_setup_tc,
> +       .ndo_setup_offload      = __mlx4_en_setup_offload,
>  #ifdef CONFIG_RFS_ACCEL
>         .ndo_rx_flow_steer      = mlx4_en_filter_rfs,
>  #endif
> @@ -2988,7 +2989,7 @@ static const struct net_device_ops mlx4_netdev_ops_master = {
>  #endif
>         .ndo_set_features       = mlx4_en_set_features,
>         .ndo_fix_features       = mlx4_en_fix_features,
> -       .ndo_setup_tc           = __mlx4_en_setup_tc,
> +       .ndo_setup_offload      = __mlx4_en_setup_offload,
>  #ifdef CONFIG_RFS_ACCEL
>         .ndo_rx_flow_steer      = mlx4_en_filter_rfs,
>  #endif
> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
> index 712b9766485f..469359cbef27 100644
> --- a/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
> +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_main.c
> @@ -3383,8 +3383,8 @@ static int mlx5e_setup_tc_block(struct net_device *dev,
>  }
>  #endif
>
> -static int mlx5e_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                         void *type_data)
> +static int mlx5e_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                              void *type_data)
>  {
>         switch (type) {
>  #ifdef CONFIG_MLX5_ESWITCH
> @@ -4222,7 +4222,7 @@ static const struct net_device_ops mlx5e_netdev_ops = {
>         .ndo_open                = mlx5e_open,
>         .ndo_stop                = mlx5e_close,
>         .ndo_start_xmit          = mlx5e_xmit,
> -       .ndo_setup_tc            = mlx5e_setup_tc,
> +       .ndo_setup_offload       = mlx5e_setup_offload,
>         .ndo_select_queue        = mlx5e_select_queue,
>         .ndo_get_stats64         = mlx5e_get_stats,
>         .ndo_set_rx_mode         = mlx5e_set_rx_mode,
> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c b/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
> index 8e3c5b4b90ab..eddb20fd4dcc 100644
> --- a/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
> +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_rep.c
> @@ -806,8 +806,8 @@ static int mlx5e_rep_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int mlx5e_rep_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                             void *type_data)
> +static int mlx5e_rep_setup_offload(struct net_device *dev,
> +                                  enum tc_setup_type type, void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -917,7 +917,7 @@ static const struct net_device_ops mlx5e_netdev_ops_rep = {
>         .ndo_stop                = mlx5e_rep_close,
>         .ndo_start_xmit          = mlx5e_xmit,
>         .ndo_get_phys_port_name  = mlx5e_rep_get_phys_port_name,
> -       .ndo_setup_tc            = mlx5e_rep_setup_tc,
> +       .ndo_setup_offload       = mlx5e_rep_setup_offload,
>         .ndo_get_stats64         = mlx5e_rep_get_stats,
>         .ndo_has_offload_stats   = mlx5e_has_offload_stats,
>         .ndo_get_offload_stats   = mlx5e_get_offload_stats,
> diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
> index 6ec0f91a93cc..910fefbec88d 100644
> --- a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
> +++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
> @@ -1631,8 +1631,8 @@ static int mlxsw_sp_setup_tc_block(struct mlxsw_sp_port *mlxsw_sp_port,
>         }
>  }
>
> -static int mlxsw_sp_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                            void *type_data)
> +static int mlxsw_sp_setup_offload(struct net_device *dev,
> +                                 enum tc_setup_type type, void *type_data)
>  {
>         struct mlxsw_sp_port *mlxsw_sp_port = netdev_priv(dev);
>
> @@ -1708,7 +1708,7 @@ static const struct net_device_ops mlxsw_sp_port_netdev_ops = {
>         .ndo_open               = mlxsw_sp_port_open,
>         .ndo_stop               = mlxsw_sp_port_stop,
>         .ndo_start_xmit         = mlxsw_sp_port_xmit,
> -       .ndo_setup_tc           = mlxsw_sp_setup_tc,
> +       .ndo_setup_offload      = mlxsw_sp_setup_offload,
>         .ndo_set_rx_mode        = mlxsw_sp_set_rx_mode,
>         .ndo_set_mac_address    = mlxsw_sp_port_set_mac_address,
>         .ndo_change_mtu         = mlxsw_sp_port_change_mtu,
> diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
> index a712e83c3f0f..56f7b468bc8c 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
> +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c
> @@ -3494,7 +3494,7 @@ const struct net_device_ops nfp_net_netdev_ops = {
>         .ndo_set_vf_spoofchk    = nfp_app_set_vf_spoofchk,
>         .ndo_get_vf_config      = nfp_app_get_vf_config,
>         .ndo_set_vf_link_state  = nfp_app_set_vf_link_state,
> -       .ndo_setup_tc           = nfp_port_setup_tc,
> +       .ndo_setup_offload      = nfp_port_setup_offload,
>         .ndo_tx_timeout         = nfp_net_tx_timeout,
>         .ndo_set_rx_mode        = nfp_net_set_rx_mode,
>         .ndo_change_mtu         = nfp_net_change_mtu,
> diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c b/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
> index d7b712f6362f..a98d3762caa2 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
> +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_repr.c
> @@ -270,7 +270,7 @@ const struct net_device_ops nfp_repr_netdev_ops = {
>         .ndo_has_offload_stats  = nfp_repr_has_offload_stats,
>         .ndo_get_offload_stats  = nfp_repr_get_offload_stats,
>         .ndo_get_phys_port_name = nfp_port_get_phys_port_name,
> -       .ndo_setup_tc           = nfp_port_setup_tc,
> +       .ndo_setup_offload      = nfp_port_setup_offload,
>         .ndo_set_vf_mac         = nfp_app_set_vf_mac,
>         .ndo_set_vf_vlan        = nfp_app_set_vf_vlan,
>         .ndo_set_vf_spoofchk    = nfp_app_set_vf_spoofchk,
> diff --git a/drivers/net/ethernet/netronome/nfp/nfp_port.c b/drivers/net/ethernet/netronome/nfp/nfp_port.c
> index 9c1298114c70..fb945adada08 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfp_port.c
> +++ b/drivers/net/ethernet/netronome/nfp/nfp_port.c
> @@ -89,8 +89,8 @@ const struct switchdev_ops nfp_port_switchdev_ops = {
>         .switchdev_port_attr_get        = nfp_port_attr_get,
>  };
>
> -int nfp_port_setup_tc(struct net_device *netdev, enum tc_setup_type type,
> -                     void *type_data)
> +int nfp_port_setup_offload(struct net_device *netdev, enum tc_setup_type type,
> +                          void *type_data)
>  {
>         struct nfp_port *port;
>
> diff --git a/drivers/net/ethernet/netronome/nfp/nfp_port.h b/drivers/net/ethernet/netronome/nfp/nfp_port.h
> index 51f10ae2d53e..044fbb6f9219 100644
> --- a/drivers/net/ethernet/netronome/nfp/nfp_port.h
> +++ b/drivers/net/ethernet/netronome/nfp/nfp_port.h
> @@ -124,8 +124,8 @@ extern const struct switchdev_ops nfp_port_switchdev_ops;
>
>  __printf(2, 3) u8 *nfp_pr_et(u8 *data, const char *fmt, ...);
>
> -int nfp_port_setup_tc(struct net_device *netdev, enum tc_setup_type type,
> -                     void *type_data);
> +int nfp_port_setup_offload(struct net_device *netdev, enum tc_setup_type type,
> +                          void *type_data);
>
>  static inline bool nfp_port_is_vnic(const struct nfp_port *port)
>  {
> diff --git a/drivers/net/ethernet/sfc/efx.c b/drivers/net/ethernet/sfc/efx.c
> index b24c2e21db8e..d0cbded8360b 100644
> --- a/drivers/net/ethernet/sfc/efx.c
> +++ b/drivers/net/ethernet/sfc/efx.c
> @@ -2518,7 +2518,7 @@ static const struct net_device_ops efx_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller = efx_netpoll,
>  #endif
> -       .ndo_setup_tc           = efx_setup_tc,
> +       .ndo_setup_offload      = efx_setup_offload,
>  #ifdef CONFIG_RFS_ACCEL
>         .ndo_rx_flow_steer      = efx_filter_rfs,
>  #endif
> diff --git a/drivers/net/ethernet/sfc/efx.h b/drivers/net/ethernet/sfc/efx.h
> index 3f759ebdcf10..383fb4c15dea 100644
> --- a/drivers/net/ethernet/sfc/efx.h
> +++ b/drivers/net/ethernet/sfc/efx.h
> @@ -27,8 +27,8 @@ netdev_tx_t efx_hard_start_xmit(struct sk_buff *skb,
>                                 struct net_device *net_dev);
>  netdev_tx_t efx_enqueue_skb(struct efx_tx_queue *tx_queue, struct sk_buff *skb);
>  void efx_xmit_done(struct efx_tx_queue *tx_queue, unsigned int index);
> -int efx_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
> -                void *type_data);
> +int efx_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
> +                     void *type_data);
>  unsigned int efx_tx_max_skb_descs(struct efx_nic *efx);
>  extern unsigned int efx_piobuf_size;
>  extern bool efx_separate_tx_channels;
> diff --git a/drivers/net/ethernet/sfc/falcon/efx.c b/drivers/net/ethernet/sfc/falcon/efx.c
> index dd5530a4f8c8..8c8b012945a8 100644
> --- a/drivers/net/ethernet/sfc/falcon/efx.c
> +++ b/drivers/net/ethernet/sfc/falcon/efx.c
> @@ -2253,7 +2253,7 @@ static const struct net_device_ops ef4_netdev_ops = {
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller = ef4_netpoll,
>  #endif
> -       .ndo_setup_tc           = ef4_setup_tc,
> +       .ndo_setup_offload      = ef4_setup_offload,
>  #ifdef CONFIG_RFS_ACCEL
>         .ndo_rx_flow_steer      = ef4_filter_rfs,
>  #endif
> diff --git a/drivers/net/ethernet/sfc/falcon/efx.h b/drivers/net/ethernet/sfc/falcon/efx.h
> index a4e4d8ea4078..67ff3891bc42 100644
> --- a/drivers/net/ethernet/sfc/falcon/efx.h
> +++ b/drivers/net/ethernet/sfc/falcon/efx.h
> @@ -32,8 +32,8 @@ netdev_tx_t ef4_hard_start_xmit(struct sk_buff *skb,
>                                 struct net_device *net_dev);
>  netdev_tx_t ef4_enqueue_skb(struct ef4_tx_queue *tx_queue, struct sk_buff *skb);
>  void ef4_xmit_done(struct ef4_tx_queue *tx_queue, unsigned int index);
> -int ef4_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
> -                void *type_data);
> +int ef4_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
> +                     void *type_data);
>  unsigned int ef4_tx_max_skb_descs(struct ef4_nic *efx);
>  extern bool ef4_separate_tx_channels;
>
> diff --git a/drivers/net/ethernet/sfc/falcon/tx.c b/drivers/net/ethernet/sfc/falcon/tx.c
> index 3409bbf5b19f..15a1b82160bb 100644
> --- a/drivers/net/ethernet/sfc/falcon/tx.c
> +++ b/drivers/net/ethernet/sfc/falcon/tx.c
> @@ -425,8 +425,8 @@ void ef4_init_tx_queue_core_txq(struct ef4_tx_queue *tx_queue)
>                                      efx->n_tx_channels : 0));
>  }
>
> -int ef4_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
> -                void *type_data)
> +int ef4_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
> +                     void *type_data)
>  {
>         struct ef4_nic *efx = netdev_priv(net_dev);
>         struct tc_mqprio_qopt *mqprio = type_data;
> diff --git a/drivers/net/ethernet/sfc/tx.c b/drivers/net/ethernet/sfc/tx.c
> index c3ad564ac4c0..53c7801decbc 100644
> --- a/drivers/net/ethernet/sfc/tx.c
> +++ b/drivers/net/ethernet/sfc/tx.c
> @@ -687,8 +687,8 @@ void efx_init_tx_queue_core_txq(struct efx_tx_queue *tx_queue)
>                                      efx->n_tx_channels : 0));
>  }
>
> -int efx_setup_tc(struct net_device *net_dev, enum tc_setup_type type,
> -                void *type_data)
> +int efx_setup_offload(struct net_device *net_dev, enum tc_setup_type type,
> +                     void *type_data)
>  {
>         struct efx_nic *efx = netdev_priv(net_dev);
>         struct tc_mqprio_qopt *mqprio = type_data;
> diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
> index d9e60cfd8a85..a274d0c6b375 100644
> --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
> +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
> @@ -3787,8 +3787,8 @@ static int stmmac_setup_tc_block(struct stmmac_priv *priv,
>         }
>  }
>
> -static int stmmac_setup_tc(struct net_device *ndev, enum tc_setup_type type,
> -                          void *type_data)
> +static int stmmac_setup_offload(struct net_device *ndev,
> +                               enum tc_setup_type type, void *type_data)
>  {
>         struct stmmac_priv *priv = netdev_priv(ndev);
>
> @@ -4040,7 +4040,7 @@ static const struct net_device_ops stmmac_netdev_ops = {
>         .ndo_set_rx_mode = stmmac_set_rx_mode,
>         .ndo_tx_timeout = stmmac_tx_timeout,
>         .ndo_do_ioctl = stmmac_ioctl,
> -       .ndo_setup_tc = stmmac_setup_tc,
> +       .ndo_setup_offload = stmmac_setup_offload,
>  #ifdef CONFIG_NET_POLL_CONTROLLER
>         .ndo_poll_controller = stmmac_poll_controller,
>  #endif
> diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c
> index a1d335a3c5e4..70d469eabc10 100644
> --- a/drivers/net/ethernet/ti/netcp_core.c
> +++ b/drivers/net/ethernet/ti/netcp_core.c
> @@ -1889,8 +1889,8 @@ static int netcp_rx_kill_vid(struct net_device *ndev, __be16 proto, u16 vid)
>         return err;
>  }
>
> -static int netcp_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                         void *type_data)
> +static int netcp_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                              void *type_data)
>  {
>         struct tc_mqprio_qopt *mqprio = type_data;
>         u8 num_tc;
> @@ -1966,7 +1966,7 @@ static const struct net_device_ops netcp_netdev_ops = {
>         .ndo_vlan_rx_kill_vid   = netcp_rx_kill_vid,
>         .ndo_tx_timeout         = netcp_ndo_tx_timeout,
>         .ndo_select_queue       = dev_pick_tx_zero,
> -       .ndo_setup_tc           = netcp_setup_tc,
> +       .ndo_setup_offload      = netcp_setup_offload,
>  };
>
>  static int netcp_create_interface(struct netcp_device *netcp_device,
> diff --git a/drivers/net/netdevsim/netdev.c b/drivers/net/netdevsim/netdev.c
> index a7b179f0d954..9b6a5d2f335f 100644
> --- a/drivers/net/netdevsim/netdev.c
> +++ b/drivers/net/netdevsim/netdev.c
> @@ -393,7 +393,8 @@ static int nsim_set_vf_link_state(struct net_device *dev, int vf, int state)
>  }
>
>  static int
> -nsim_setup_tc(struct net_device *dev, enum tc_setup_type type, void *type_data)
> +nsim_setup_offload(struct net_device *dev, enum tc_setup_type type,
> +                  void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -431,7 +432,7 @@ static const struct net_device_ops nsim_netdev_ops = {
>         .ndo_get_vf_config      = nsim_get_vf_config,
>         .ndo_set_vf_link_state  = nsim_set_vf_link_state,
>         .ndo_set_vf_rss_query_en = nsim_set_vf_rss_query_en,
> -       .ndo_setup_tc           = nsim_setup_tc,
> +       .ndo_setup_offload      = nsim_setup_offload,
>         .ndo_set_features       = nsim_set_features,
>         .ndo_bpf                = nsim_bpf,
>  };
> diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
> index 3514d67112b3..0f50bf95b7cd 100644
> --- a/include/linux/netdevice.h
> +++ b/include/linux/netdevice.h
> @@ -1047,12 +1047,12 @@ struct dev_ifalias {
>   *      with PF and querying it may introduce a theoretical security risk.
>   * int (*ndo_set_vf_rss_query_en)(struct net_device *dev, int vf, bool setting);
>   * int (*ndo_get_vf_port)(struct net_device *dev, int vf, struct sk_buff *skb);
> - * int (*ndo_setup_tc)(struct net_device *dev, enum tc_setup_type type,
> - *                    void *type_data);
> - *     Called to setup any 'tc' scheduler, classifier or action on @dev.
> - *     This is always called from the stack with the rtnl lock held and netif
> - *     tx queues stopped. This allows the netdevice to perform queue
> - *     management safely.
> + * int (*ndo_setup_offload)(struct net_device *dev, enum tc_setup_type type,
> +                           void *type_data);
> + *     Called to setup any offload, such as 'tc' scheduler, classifier or
> + *     action on @dev. This is always called from the stack with the rtnl lock
> + *     held and netif tx queues stopped. This allows the netdevice to perform
> + *     queue management safely.
>   *
>   *     Fiber Channel over Ethernet (FCoE) offload functions.
>   * int (*ndo_fcoe_enable)(struct net_device *dev);
> @@ -1297,9 +1297,9 @@ struct net_device_ops {
>         int                     (*ndo_set_vf_rss_query_en)(
>                                                    struct net_device *dev,
>                                                    int vf, bool setting);
> -       int                     (*ndo_setup_tc)(struct net_device *dev,
> -                                               enum tc_setup_type type,
> -                                               void *type_data);
> +       int                     (*ndo_setup_offload)(struct net_device *dev,
> +                                                    enum tc_setup_type type,
> +                                                    void *type_data);
>  #if IS_ENABLED(CONFIG_FCOE)
>         int                     (*ndo_fcoe_enable)(struct net_device *dev);
>         int                     (*ndo_fcoe_disable)(struct net_device *dev);
> diff --git a/net/dsa/slave.c b/net/dsa/slave.c
> index 71536c435132..a8f4013edc2a 100644
> --- a/net/dsa/slave.c
> +++ b/net/dsa/slave.c
> @@ -909,8 +909,9 @@ static int dsa_slave_setup_tc_block(struct net_device *dev,
>         }
>  }
>
> -static int dsa_slave_setup_tc(struct net_device *dev, enum tc_setup_type type,
> -                             void *type_data)
> +static int dsa_slave_setup_offload(struct net_device *dev,
> +                                  enum tc_setup_type type,
> +                                  void *type_data)
>  {
>         switch (type) {
>         case TC_SETUP_BLOCK:
> @@ -1045,7 +1046,7 @@ static const struct net_device_ops dsa_slave_netdev_ops = {
>         .ndo_poll_controller    = dsa_slave_poll_controller,
>  #endif
>         .ndo_get_phys_port_name = dsa_slave_get_phys_port_name,
> -       .ndo_setup_tc           = dsa_slave_setup_tc,
> +       .ndo_setup_offload      = dsa_slave_setup_offload,
>         .ndo_get_stats64        = dsa_slave_get_stats64,
>  };
>
> diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
> index c51b1b12450d..d5add1358b66 100644
> --- a/net/sched/cls_api.c
> +++ b/net/sched/cls_api.c
> @@ -286,7 +286,7 @@ static int tcf_block_offload_cmd(struct tcf_block *block,
>         bo.binder_type = ei->binder_type;
>         bo.block = block;
>         bo.extack = extack;
> -       return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_BLOCK, &bo);
> +       return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_BLOCK, &bo);
>  }
>
>  static int tcf_block_offload_bind(struct tcf_block *block, struct Qdisc *q,
> @@ -296,7 +296,7 @@ static int tcf_block_offload_bind(struct tcf_block *block, struct Qdisc *q,
>         struct net_device *dev = q->dev_queue->dev;
>         int err;
>
> -       if (!dev->netdev_ops->ndo_setup_tc)
> +       if (!dev->netdev_ops->ndo_setup_offload)
>                 goto no_offload_dev_inc;
>
>         /* If tc offload feature is disabled and the block we try to bind
> @@ -325,7 +325,7 @@ static void tcf_block_offload_unbind(struct tcf_block *block, struct Qdisc *q,
>         struct net_device *dev = q->dev_queue->dev;
>         int err;
>
> -       if (!dev->netdev_ops->ndo_setup_tc)
> +       if (!dev->netdev_ops->ndo_setup_offload)
>                 goto no_offload_dev_dec;
>         err = tcf_block_offload_cmd(block, dev, ei, TC_BLOCK_UNBIND, NULL);
>         if (err == -EOPNOTSUPP)
> diff --git a/net/sched/sch_cbs.c b/net/sched/sch_cbs.c
> index cdd96b9a27bc..d7e4169f9a1c 100644
> --- a/net/sched/sch_cbs.c
> +++ b/net/sched/sch_cbs.c
> @@ -206,13 +206,13 @@ static void cbs_disable_offload(struct net_device *dev,
>         q->dequeue = cbs_dequeue_soft;
>
>         ops = dev->netdev_ops;
> -       if (!ops->ndo_setup_tc)
> +       if (!ops->ndo_setup_offload)
>                 return;
>
>         cbs.queue = q->queue;
>         cbs.enable = 0;
>
> -       err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_CBS, &cbs);
> +       err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_CBS, &cbs);
>         if (err < 0)
>                 pr_warn("Couldn't disable CBS offload for queue %d\n",
>                         cbs.queue);
> @@ -226,7 +226,7 @@ static int cbs_enable_offload(struct net_device *dev, struct cbs_sched_data *q,
>         struct tc_cbs_qopt_offload cbs = { };
>         int err;
>
> -       if (!ops->ndo_setup_tc) {
> +       if (!ops->ndo_setup_offload) {
>                 NL_SET_ERR_MSG(extack, "Specified device does not support cbs offload");
>                 return -EOPNOTSUPP;
>         }
> @@ -239,7 +239,7 @@ static int cbs_enable_offload(struct net_device *dev, struct cbs_sched_data *q,
>         cbs.idleslope = opt->idleslope;
>         cbs.sendslope = opt->sendslope;
>
> -       err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_CBS, &cbs);
> +       err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_CBS, &cbs);
>         if (err < 0) {
>                 NL_SET_ERR_MSG(extack, "Specified device failed to setup cbs hardware offload");
>                 return err;
> diff --git a/net/sched/sch_etf.c b/net/sched/sch_etf.c
> index 1538d6fa8165..97061e26d2b5 100644
> --- a/net/sched/sch_etf.c
> +++ b/net/sched/sch_etf.c
> @@ -272,13 +272,13 @@ static void etf_disable_offload(struct net_device *dev,
>                 return;
>
>         ops = dev->netdev_ops;
> -       if (!ops->ndo_setup_tc)
> +       if (!ops->ndo_setup_offload)
>                 return;
>
>         etf.queue = q->queue;
>         etf.enable = 0;
>
> -       err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_ETF, &etf);
> +       err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_ETF, &etf);
>         if (err < 0)
>                 pr_warn("Couldn't disable ETF offload for queue %d\n",
>                         etf.queue);
> @@ -294,7 +294,7 @@ static int etf_enable_offload(struct net_device *dev, struct etf_sched_data *q,
>         if (q->offload)
>                 return 0;
>
> -       if (!ops->ndo_setup_tc) {
> +       if (!ops->ndo_setup_offload) {
>                 NL_SET_ERR_MSG(extack, "Specified device does not support ETF offload");
>                 return -EOPNOTSUPP;
>         }
> @@ -302,7 +302,7 @@ static int etf_enable_offload(struct net_device *dev, struct etf_sched_data *q,
>         etf.queue = q->queue;
>         etf.enable = 1;
>
> -       err = ops->ndo_setup_tc(dev, TC_SETUP_QDISC_ETF, &etf);
> +       err = ops->ndo_setup_offload(dev, TC_SETUP_QDISC_ETF, &etf);
>         if (err < 0) {
>                 NL_SET_ERR_MSG(extack, "Specified device failed to setup ETF hardware offload");
>                 return err;
> diff --git a/net/sched/sch_mq.c b/net/sched/sch_mq.c
> index d6b8ae4ed7a3..575a6b168dbc 100644
> --- a/net/sched/sch_mq.c
> +++ b/net/sched/sch_mq.c
> @@ -32,10 +32,10 @@ static int mq_offload(struct Qdisc *sch, enum tc_mq_command cmd)
>                 .handle = sch->handle,
>         };
>
> -       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
> +       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
>                 return -EOPNOTSUPP;
>
> -       return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_MQ, &opt);
> +       return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_MQ, &opt);
>  }
>
>  static void mq_offload_stats(struct Qdisc *sch)
> @@ -50,8 +50,8 @@ static void mq_offload_stats(struct Qdisc *sch)
>                 },
>         };
>
> -       if (tc_can_offload(dev) && dev->netdev_ops->ndo_setup_tc)
> -               dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_MQ, &opt);
> +       if (tc_can_offload(dev) && dev->netdev_ops->ndo_setup_offload)
> +               dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_MQ, &opt);
>  }
>
>  static void mq_destroy(struct Qdisc *sch)
> diff --git a/net/sched/sch_mqprio.c b/net/sched/sch_mqprio.c
> index 0e9d761cdd80..153d137aa2cc 100644
> --- a/net/sched/sch_mqprio.c
> +++ b/net/sched/sch_mqprio.c
> @@ -44,15 +44,15 @@ static void mqprio_destroy(struct Qdisc *sch)
>                 kfree(priv->qdiscs);
>         }
>
> -       if (priv->hw_offload && dev->netdev_ops->ndo_setup_tc) {
> +       if (priv->hw_offload && dev->netdev_ops->ndo_setup_offload) {
>                 struct tc_mqprio_qopt_offload mqprio = { { 0 } };
>
>                 switch (priv->mode) {
>                 case TC_MQPRIO_MODE_DCB:
>                 case TC_MQPRIO_MODE_CHANNEL:
> -                       dev->netdev_ops->ndo_setup_tc(dev,
> -                                                     TC_SETUP_QDISC_MQPRIO,
> -                                                     &mqprio);
> +                       dev->netdev_ops->ndo_setup_offload(dev,
> +                                                          TC_SETUP_QDISC_MQPRIO,
> +                                                          &mqprio);
>                         break;
>                 default:
>                         return;
> @@ -85,11 +85,11 @@ static int mqprio_parse_opt(struct net_device *dev, struct tc_mqprio_qopt *qopt)
>
>         /* If hardware offload is requested we will leave it to the device
>          * to either populate the queue counts itself or to validate the
> -        * provided queue counts.  If ndo_setup_tc is not present then
> +        * provided queue counts.  If ndo_setup_offload is not present then
>          * hardware doesn't support offload and we should return an error.
>          */
>         if (qopt->hw)
> -               return dev->netdev_ops->ndo_setup_tc ? 0 : -EINVAL;
> +               return dev->netdev_ops->ndo_setup_offload ? 0 : -EINVAL;
>
>         for (i = 0; i < qopt->num_tc; i++) {
>                 unsigned int last = qopt->offset[i] + qopt->count[i];
> @@ -239,7 +239,7 @@ static int mqprio_init(struct Qdisc *sch, struct nlattr *opt,
>         }
>
>         /* If the mqprio options indicate that hardware should own
> -        * the queue mapping then run ndo_setup_tc otherwise use the
> +        * the queue mapping then run ndo_setup_offload otherwise use the
>          * supplied and verified mapping
>          */
>         if (qopt->hw) {
> @@ -266,7 +266,7 @@ static int mqprio_init(struct Qdisc *sch, struct nlattr *opt,
>                 default:
>                         return -EINVAL;
>                 }
> -               err = dev->netdev_ops->ndo_setup_tc(dev,
> +               err = dev->netdev_ops->ndo_setup_offload(dev,
>                                                     TC_SETUP_QDISC_MQPRIO,
>                                                     &mqprio);
>                 if (err)
> diff --git a/net/sched/sch_prio.c b/net/sched/sch_prio.c
> index 222e53d3d27a..ae9bf5fe320a 100644
> --- a/net/sched/sch_prio.c
> +++ b/net/sched/sch_prio.c
> @@ -150,7 +150,7 @@ static int prio_offload(struct Qdisc *sch, struct tc_prio_qopt *qopt)
>                 .parent = sch->parent,
>         };
>
> -       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
> +       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
>                 return -EOPNOTSUPP;
>
>         if (qopt) {
> @@ -163,7 +163,8 @@ static int prio_offload(struct Qdisc *sch, struct tc_prio_qopt *qopt)
>                 opt.command = TC_PRIO_DESTROY;
>         }
>
> -       return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO, &opt);
> +       return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
> +                                                 &opt);
>  }
>
>  static void
> @@ -266,11 +267,11 @@ static int prio_dump_offload(struct Qdisc *sch)
>         int err;
>
>         sch->flags &= ~TCQ_F_OFFLOADED;
> -       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
> +       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
>                 return 0;
>
> -       err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO,
> -                                           &hw_stats);
> +       err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
> +                                                &hw_stats);
>         if (err == -EOPNOTSUPP)
>                 return 0;
>
> @@ -328,8 +329,8 @@ static int prio_graft(struct Qdisc *sch, unsigned long arg, struct Qdisc *new,
>         graft_offload.graft_params.child_handle = new->handle;
>         graft_offload.command = TC_PRIO_GRAFT;
>
> -       err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_PRIO,
> -                                           &graft_offload);
> +       err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_PRIO,
> +                                                &graft_offload);
>
>         /* Don't report error if the graft is part of destroy operation. */
>         if (err && new != &noop_qdisc) {
> diff --git a/net/sched/sch_red.c b/net/sched/sch_red.c
> index 56c181c3feeb..63a4ee50cf05 100644
> --- a/net/sched/sch_red.c
> +++ b/net/sched/sch_red.c
> @@ -158,7 +158,7 @@ static int red_offload(struct Qdisc *sch, bool enable)
>                 .parent = sch->parent,
>         };
>
> -       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
> +       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
>                 return -EOPNOTSUPP;
>
>         if (enable) {
> @@ -172,7 +172,8 @@ static int red_offload(struct Qdisc *sch, bool enable)
>                 opt.command = TC_RED_DESTROY;
>         }
>
> -       return dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED, &opt);
> +       return dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
> +                                                 &opt);
>  }
>
>  static void red_destroy(struct Qdisc *sch)
> @@ -295,11 +296,11 @@ static int red_dump_offload_stats(struct Qdisc *sch, struct tc_red_qopt *opt)
>
>         sch->flags &= ~TCQ_F_OFFLOADED;
>
> -       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_tc)
> +       if (!tc_can_offload(dev) || !dev->netdev_ops->ndo_setup_offload)
>                 return 0;
>
> -       err = dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED,
> -                                           &hw_stats);
> +       err = dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
> +                                                &hw_stats);
>         if (err == -EOPNOTSUPP)
>                 return 0;
>
> @@ -356,8 +357,8 @@ static int red_dump_stats(struct Qdisc *sch, struct gnet_dump *d)
>                                 .xstats = &q->stats,
>                         },
>                 };
> -               dev->netdev_ops->ndo_setup_tc(dev, TC_SETUP_QDISC_RED,
> -                                             &hw_stats_request);
> +               dev->netdev_ops->ndo_setup_offload(dev, TC_SETUP_QDISC_RED,
> +                                                  &hw_stats_request);
>         }
>         st.early = q->stats.prob_drop + q->stats.forced_drop;
>         st.pdrop = q->stats.pdrop;
> --
> 2.11.0
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2018-07-20 19:57 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-19  0:11 [PATCH net-next,v2] net: rename ndo_setup_tc to ndo_setup_offload Pablo Neira Ayuso
2018-07-19  9:17 ` Martin Habets
2018-07-19 15:18 ` Alexander Duyck
2018-07-19 20:52   ` Pablo Neira Ayuso
2018-07-19 21:04     ` Alexander Duyck
2018-07-20 10:09       ` Pablo Neira Ayuso
2018-07-20 14:45         ` Alexander Duyck
2018-07-20 14:01 ` Florian Fainelli
2018-07-20 14:37 Roopa Prabhu
2018-07-20 17:28 ` Daniel Borkmann
2018-07-20 19:07   ` David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.