netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/50] wilc1000: rework tx path to use sk_buffs throughout
@ 2021-12-23  1:14 David Mosberger-Tang
  2021-12-23  1:14 ` [PATCH v2 04/50] wilc1000: factor common code in wilc_wlan_cfg_set() and wilc_wlan_cfg_get() David Mosberger-Tang
                   ` (50 more replies)
  0 siblings, 51 replies; 56+ messages in thread
From: David Mosberger-Tang @ 2021-12-23  1:14 UTC (permalink / raw)
  To: Ajay Singh
  Cc: Claudiu Beznea, Kalle Valo, David S. Miller, Jakub Kicinski,
	linux-wireless, netdev, linux-kernel, David Mosberger-Tang

OK, so I'm nervous about such a large patch series, but it took a lot
of work to break things down into atomic changes.  This should be it
for the transmit path as far as I'm concerned.

- v2:
	- Fix 64-bit architecture compile breakage found by
          kernel build daemon.
	- Fix kernel-doc issues.
	- All patches compie with "make W=1" now and pass scripts/checkpatch.pl
        - Expand series to clean up some locking issues.
        - Expand series to support zero-copy tx transfers for SPI.
        - Rebase to latest wireless-drivers-next

Rework tx path to use sk_buffs throughout and optionally provide
zero-copy transmit.

Based on the earlier discussion (RFC: wilc1000: refactor TX path to
use sk_buff queue), here is the full patch series to clean up and
simplify the TX path.

The biggest patch is 0016, which is the one actually switching the
queue data type, but I worked hard to minimize it to only direct
changes due to the type changes.

There is no dramatic performance difference due to this patch.  I'd
expect the new code to be slightly faster, but my WLAN
test-environment is not sufficiently controlled to be sure of that.

original iperf3 performance (duration 120 seconds):

                TX [Mbps]	RX [Mbps]
  PSM off:	14.8		18.9
  PSM  on:	10.5		17.1

iperf3 performance with this patch-series applied:

		TX [Mbps]	RX [Mbps]
  PSM off:	16.0		19.9
  PSM  on:	11.7		18.0

(PSM == power-save-mode; controlled by iw dev wlan0 set power_save on/off)

David Mosberger-Tang (50):
  wilc1000: don't hold txq_spinlock while initializing AC queue limits
  wilc1000: switch txq_event from completion to waitqueue
  wilc1000: move receive-queue stats from txq to wilc structure
  wilc1000: factor common code in wilc_wlan_cfg_set() and wilc_wlan_cfg_get()
  wilc1000: add wilc_wlan_tx_packet_done() function
  wilc1000: move tx packet drop code into its own function
  wilc1000: increment tx_dropped stat counter on tx packet drop
  wilc1000: fix management packet type inconsistency
  wilc1000: prepare wilc_wlan_tx_packet_done() for sk_buff changes
  wilc1000: factor initialization of tx queue-specific packet fields
  wilc1000: convert tqx_entries from "int" to "atomic_t"
  wilc1000: refactor wilc_wlan_cfg_commit() a bit
  wilc1000: sanitize config packet sequence number management a bit
  wilc1000: if there is no tx packet, don't increment packets-sent counter
  wilc1000: add struct wilc_skb_tx_cb as an alias of struct txq_entry_t
  wilc1000: switch tx queue to normal sk_buff entries
  wilc1000: remove no longer used "vif" argument from init_txq_entry()
  wilc1000: split huge tx handler into subfunctions
  wilc1000: don't tell the chip to go to sleep while copying tx packets
  wilc1000: eliminate "max_size_over" variable in fill_vmm_table
  wilc1000: declare read-only ac_preserve_ratio as static and const
  wilc1000: minor syntax cleanup
  wilc1000: introduce symbolic names for two tx-related control bits
  wilc1000: protect tx_q_limit with a mutex instead of a spinlock
  wilc1000: replace txq_spinlock with ack_filter_lock mutex
  wilc1000: reduce amount of time ack_filter_lock is held
  wilc1000: simplify ac_balance() a bit
  wilc1000: improve send_packets() a bit
  wilc1000: factor header length calculation into a new function
  wilc1000: use more descriptive variable names
  wilc1000: eliminate another magic constant
  wilc1000: introduce vmm_table_entry() helper function
  wilc1000: move ac_desired_ratio calculation to where its needed
  wilc1000: restructure wilc-wlan_handle_txq() for clarity
  wilc1000: introduce copy_and_send_packets() helper function
  wilc1000: introduce transmit path chip queue
  wilc1000: introduce set_header() function
  wilc1000: take advantage of chip queue
  wilc1000: eliminate txq_add_to_head_cs mutex
  wilc1000: introduce schedule_packets() function
  wilc1000: use more descriptive variable name
  wilc1000: simplify code by adding header/padding to skb
  wilc1000: add support for zero-copy transmit of tx packets
  wilc1000: don't allocate tx_buffer when zero-copy is available
  wilc1000: move struct wilc_spi declaration
  wilc1000: remove duplicate CRC calculation code
  wilc1000: factor SPI DMA command initialization code into a function
  wilc1000: introduce function to find and check DMA response
  wilc1000: implement zero-copy transmit support for SPI
  wilc1000: add module parameter "disable_zero_copy_tx" to SPI driver

 .../wireless/microchip/wilc1000/cfg80211.c    |  45 +-
 drivers/net/wireless/microchip/wilc1000/mon.c |  36 +-
 .../net/wireless/microchip/wilc1000/netdev.c  |  46 +-
 .../net/wireless/microchip/wilc1000/netdev.h  |  41 +-
 drivers/net/wireless/microchip/wilc1000/spi.c | 293 ++++-
 .../net/wireless/microchip/wilc1000/wlan.c    | 998 ++++++++++--------
 .../net/wireless/microchip/wilc1000/wlan.h    |  55 +-
 7 files changed, 888 insertions(+), 626 deletions(-)

-- 
2.25.1


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

end of thread, other threads:[~2021-12-28 15:01 UTC | newest]

Thread overview: 56+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-23  1:14 [PATCH v2 00/50] wilc1000: rework tx path to use sk_buffs throughout David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 04/50] wilc1000: factor common code in wilc_wlan_cfg_set() and wilc_wlan_cfg_get() David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 01/50] wilc1000: don't hold txq_spinlock while initializing AC queue limits David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 31/50] wilc1000: eliminate another magic constant David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 29/50] wilc1000: factor header length calculation into a new function David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 18/50] wilc1000: split huge tx handler into subfunctions David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 03/50] wilc1000: move receive-queue stats from txq to wilc structure David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 11/50] wilc1000: convert tqx_entries from "int" to "atomic_t" David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 15/50] wilc1000: add struct wilc_skb_tx_cb as an alias of struct txq_entry_t David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 07/50] wilc1000: increment tx_dropped stat counter on tx packet drop David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 27/50] wilc1000: simplify ac_balance() a bit David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 20/50] wilc1000: eliminate "max_size_over" variable in fill_vmm_table David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 25/50] wilc1000: replace txq_spinlock with ack_filter_lock mutex David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 19/50] wilc1000: don't tell the chip to go to sleep while copying tx packets David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 13/50] wilc1000: sanitize config packet sequence number management a bit David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 22/50] wilc1000: minor syntax cleanup David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 14/50] wilc1000: if there is no tx packet, don't increment packets-sent counter David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 12/50] wilc1000: refactor wilc_wlan_cfg_commit() a bit David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 10/50] wilc1000: factor initialization of tx queue-specific packet fields David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 02/50] wilc1000: switch txq_event from completion to waitqueue David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 09/50] wilc1000: prepare wilc_wlan_tx_packet_done() for sk_buff changes David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 16/50] wilc1000: switch tx queue to normal sk_buff entries David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 23/50] wilc1000: introduce symbolic names for two tx-related control bits David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 24/50] wilc1000: protect tx_q_limit with a mutex instead of a spinlock David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 28/50] wilc1000: improve send_packets() a bit David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 08/50] wilc1000: fix management packet type inconsistency David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 06/50] wilc1000: move tx packet drop code into its own function David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 21/50] wilc1000: declare read-only ac_preserve_ratio as static and const David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 17/50] wilc1000: remove no longer used "vif" argument from init_txq_entry() David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 48/50] wilc1000: introduce function to find and check DMA response David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 26/50] wilc1000: reduce amount of time ack_filter_lock is held David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 45/50] wilc1000: move struct wilc_spi declaration David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 33/50] wilc1000: move ac_desired_ratio calculation to where its needed David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 37/50] wilc1000: introduce set_header() function David Mosberger-Tang
2021-12-28 15:00   ` kernel test robot
2021-12-23  1:14 ` [PATCH v2 46/50] wilc1000: remove duplicate CRC calculation code David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 47/50] wilc1000: factor SPI DMA command initialization code into a function David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 42/50] wilc1000: simplify code by adding header/padding to skb David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 40/50] wilc1000: introduce schedule_packets() function David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 34/50] wilc1000: restructure wilc-wlan_handle_txq() for clarity David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 50/50] wilc1000: add module parameter "disable_zero_copy_tx" to SPI driver David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 49/50] wilc1000: implement zero-copy transmit support for SPI David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 32/50] wilc1000: introduce vmm_table_entry() helper function David Mosberger-Tang
2021-12-28 12:47   ` kernel test robot
2021-12-23  1:14 ` [PATCH v2 44/50] wilc1000: don't allocate tx_buffer when zero-copy is available David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 39/50] wilc1000: eliminate txq_add_to_head_cs mutex David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 36/50] wilc1000: introduce transmit path chip queue David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 38/50] wilc1000: take advantage of " David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 05/50] wilc1000: add wilc_wlan_tx_packet_done() function David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 41/50] wilc1000: use more descriptive variable name David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 43/50] wilc1000: add support for zero-copy transmit of tx packets David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 30/50] wilc1000: use more descriptive variable names David Mosberger-Tang
2021-12-23  1:14 ` [PATCH v2 35/50] wilc1000: introduce copy_and_send_packets() helper function David Mosberger-Tang
2021-12-23  6:16 ` [PATCH v2 00/50] wilc1000: rework tx path to use sk_buffs throughout Ajay.Kathat
2021-12-23  6:41   ` Kalle Valo
2021-12-23 15:23   ` David Mosberger-Tang

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).