netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next v2 0/3] net: refactor ndo_select_queue()
@ 2019-03-20 10:02 Paolo Abeni
  2019-03-20 10:02 ` [PATCH net-next v2 1/3] net: dev: rename queue selection helpers Paolo Abeni
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Paolo Abeni @ 2019-03-20 10:02 UTC (permalink / raw)
  To: netdev
  Cc: Mike Marciniszyn, Doug Ledford, Jay Vosburgh, David S. Miller,
	Saeed Bishara, Florian Fainelli, Ariel Elior, Vishal Kulkarni,
	Jeff Kirsher, Salil Mehta, Tariq Toukan, K. Y. Srinivasan,
	Kalle Valo, Wei Liu, Johannes Berg, Willem de Bruijn,
	Eric Dumazet

Currently, on most devices implementing ndo_select_queue(), we get 2
indirect calls per xmit packet, at least in some scenarios.

We can avoid one of such indirect calls refactoring the ndo_select_queue()
usage so that we don't need anymore the 'fallback' argument.

The first patch renames a helper used later as a public API, the second one
changes the af packet implementation so that it uses the common infrastructure
to select the xmit queue, and the second patch drops the now unneeded argument
from ndo_select_queue().

Alternatively we could use the INDIRECT_CALL_WRAPPER infrastructure to avoid
the fallback indirect call in the common case, but this solution allows also
for some code cleanup.

 v1 -> v2:
  - renamed select queue helpers, as per Eric's and David's suggestions

Paolo Abeni (3):
  net: dev: rename queue selection helpers.
  packet: rework packet_pick_tx_queue() to use common code selection
  net: remove 'fallback' argument from dev->ndo_select_queue()

 drivers/infiniband/hw/hfi1/vnic_main.c        |  3 +--
 .../infiniband/ulp/opa_vnic/opa_vnic_netdev.c |  6 ++---
 drivers/net/bonding/bond_main.c               |  3 +--
 drivers/net/ethernet/amazon/ena/ena_netdev.c  |  5 ++--
 drivers/net/ethernet/broadcom/bcmsysport.c    |  7 +++--
 .../net/ethernet/broadcom/bnx2x/bnx2x_cmn.c   |  5 ++--
 .../net/ethernet/broadcom/bnx2x/bnx2x_cmn.h   |  3 +--
 .../net/ethernet/chelsio/cxgb4/cxgb4_main.c   |  5 ++--
 drivers/net/ethernet/hisilicon/hns/hns_enet.c |  5 ++--
 drivers/net/ethernet/intel/ixgbe/ixgbe_main.c |  5 ++--
 drivers/net/ethernet/mellanox/mlx4/en_tx.c    |  7 +++--
 drivers/net/ethernet/mellanox/mlx4/mlx4_en.h  |  3 +--
 drivers/net/ethernet/mellanox/mlx5/core/en.h  |  3 +--
 .../net/ethernet/mellanox/mlx5/core/en_tx.c   |  5 ++--
 drivers/net/ethernet/qlogic/qede/qede.h       |  3 +--
 drivers/net/ethernet/qlogic/qede/qede_fp.c    |  5 ++--
 drivers/net/ethernet/renesas/ravb_main.c      |  3 +--
 drivers/net/ethernet/sun/ldmvsw.c             |  3 +--
 drivers/net/ethernet/sun/sunvnet.c            |  3 +--
 drivers/net/hyperv/netvsc_drv.c               | 10 +++----
 drivers/net/net_failover.c                    |  8 +++---
 drivers/net/team/team.c                       |  3 +--
 drivers/net/tun.c                             |  3 +--
 drivers/net/wireless/marvell/mwifiex/main.c   |  3 +--
 drivers/net/xen-netback/interface.c           |  6 ++---
 drivers/net/xen-netfront.c                    |  3 +--
 drivers/staging/rtl8188eu/os_dep/os_intfs.c   |  3 +--
 drivers/staging/rtl8723bs/os_dep/os_intfs.c   |  3 +--
 include/linux/netdevice.h                     | 20 +++++++-------
 net/core/dev.c                                | 26 +++++++++----------
 net/core/netpoll.c                            |  2 +-
 net/mac80211/iface.c                          |  6 ++---
 net/packet/af_packet.c                        | 16 +++++-------
 net/xfrm/xfrm_device.c                        |  2 +-
 34 files changed, 79 insertions(+), 117 deletions(-)

-- 
2.20.1


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

end of thread, other threads:[~2019-03-20 18:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-20 10:02 [PATCH net-next v2 0/3] net: refactor ndo_select_queue() Paolo Abeni
2019-03-20 10:02 ` [PATCH net-next v2 1/3] net: dev: rename queue selection helpers Paolo Abeni
2019-03-20 10:02 ` [PATCH net-next v2 2/3] packet: rework packet_pick_tx_queue() to use common code selection Paolo Abeni
2019-03-20 10:02 ` [PATCH net-next v2 3/3] net: remove 'fallback' argument from dev->ndo_select_queue() Paolo Abeni
2019-03-20 18:19 ` [PATCH net-next v2 0/3] net: refactor ndo_select_queue() David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).