diff mbox series

[v2,28/50] wilc1000: improve send_packets() a bit

Message ID 20211223011358.4031459-29-davidm@egauge.net
State New
Headers show
Series wilc1000: rework tx path to use sk_buffs throughout | expand

Commit Message

David Mosberger-Tang Dec. 23, 2021, 1:14 a.m. UTC
Improve the documentation and simplify the code a bit.

Signed-off-by: David Mosberger-Tang <davidm@egauge.net>
---
 drivers/net/wireless/microchip/wilc1000/wlan.c | 13 +++++--------
 1 file changed, 5 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/drivers/net/wireless/microchip/wilc1000/wlan.c b/drivers/net/wireless/microchip/wilc1000/wlan.c
index 287c0843ba152..033979cc85b43 100644
--- a/drivers/net/wireless/microchip/wilc1000/wlan.c
+++ b/drivers/net/wireless/microchip/wilc1000/wlan.c
@@ -858,29 +858,26 @@  static int copy_packets(struct wilc *wilc, int entries, u32 *vmm_table,
 }
 
 /**
- * send_packets() - Send packets to the chip
+ * send_packets() - send the transmit buffer to the chip
  * @wilc: Pointer to the wilc structure.
- * @len: The length of the buffer containing the packets to be sent to
- *	the chip.
+ * @len: The length of the buffer containing the packets to be to the chip.
  *
- * Send the packets in the VMM table to the chip.
+ * Send the packets in the transmit buffer to the chip.
  *
  * Context: The bus must have been acquired.
  *
- * Return:
- *	Negative number on error, 0 on success.
+ * Return: Negative number on error, 0 on success.
  */
 static int send_packets(struct wilc *wilc, int len)
 {
 	const struct wilc_hif_func *func = wilc->hif_func;
 	int ret;
-	u8 *txb = wilc->tx_buffer;
 
 	ret = func->hif_clear_int_ext(wilc, ENABLE_TX_VMM);
 	if (ret)
 		return ret;
 
-	return func->hif_block_tx_ext(wilc, 0, txb, len);
+	return func->hif_block_tx_ext(wilc, 0, wilc->tx_buffer, len);
 }
 
 int wilc_wlan_handle_txq(struct wilc *wilc, u32 *txq_count)