diff options
author | Ping-Ke Shih <pkshih@realtek.com> | 2018-05-18 17:30:05 +0800 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2018-05-29 10:17:03 +0300 |
commit | 9ae6ed271a60f0e4476fe94f0efc5aba184a9c57 (patch) | |
tree | 65bb6c504fa6009c98ab7380cc0f3aedccab75b0 /drivers/net/wireless/realtek/rtlwifi/pci.c | |
parent | b4f6ee489cff1e9c8637996b7c1079e8bdd979df (diff) | |
download | lwn-9ae6ed271a60f0e4476fe94f0efc5aba184a9c57.tar.gz lwn-9ae6ed271a60f0e4476fe94f0efc5aba184a9c57.zip |
rtlwifi: use sk_buff to queue C2H commands
We use 'struct rtl_c2hcmd' to store C2H commands originally, and the code
is slightly complex to enqueue and dequeue and also wastes time to
allocate and memcpy data. Since C2H commands are asynchronous events,
they can be processed in work queue, so RX ISR enqueues C2H result in
removal of rtl_c2h_packet_handler().
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/realtek/rtlwifi/pci.c')
-rw-r--r-- | drivers/net/wireless/realtek/rtlwifi/pci.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/net/wireless/realtek/rtlwifi/pci.c b/drivers/net/wireless/realtek/rtlwifi/pci.c index dd51c67c09fa..ae13bcfb3bf0 100644 --- a/drivers/net/wireless/realtek/rtlwifi/pci.c +++ b/drivers/net/wireless/realtek/rtlwifi/pci.c @@ -831,8 +831,7 @@ static void _rtl_pci_rx_interrupt(struct ieee80211_hw *hw) } /* handle command packet here */ if (stats.packet_report_type == C2H_PACKET) { - rtl_c2h_packet_handler(hw, skb->data, (u8)skb->len); - dev_kfree_skb_any(skb); + rtl_c2hcmd_enqueue(hw, skb); goto new_trx_end; } |