summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
diff options
context:
space:
mode:
authorPing-Ke Shih <pkshih@realtek.com>2017-02-06 21:30:08 -0600
committerKalle Valo <kvalo@codeaurora.org>2017-02-07 09:25:08 +0200
commitcceb0a5973202b4a5d649ede937d35786d7ca168 (patch)
tree56c411d898641f02204668c93f875c4ebb4094ac /drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
parent0ff78adeef117a9aa547e737f635cae8ca2f0c90 (diff)
downloadop-kernel-dev-cceb0a5973202b4a5d649ede937d35786d7ca168.zip
op-kernel-dev-cceb0a5973202b4a5d649ede937d35786d7ca168.tar.gz
rtlwifi: Add work queue for c2h cmd.
btcoex needs to sleep, thus it must run in thread context. Signed-off-by: Ping-Ke Shih <pkshih@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c')
-rw-r--r--drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
index 328c64d..a504dfa 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/fw.c
@@ -1740,9 +1740,9 @@ static void rtl8821ae_c2h_ra_report_handler(struct ieee80211_hw *hw,
rtl8821ae_dm_update_init_rate(hw, rate);
}
-static void _rtl8821ae_c2h_content_parsing(struct ieee80211_hw *hw,
- u8 c2h_cmd_id, u8 c2h_cmd_len,
- u8 *tmp_buf)
+void rtl8821ae_c2h_content_parsing(struct ieee80211_hw *hw,
+ u8 c2h_cmd_id, u8 c2h_cmd_len,
+ u8 *tmp_buf)
{
struct rtl_priv *rtlpriv = rtl_priv(hw);
@@ -1784,5 +1784,15 @@ void rtl8821ae_c2h_packet_handler(struct ieee80211_hw *hw, u8 *buffer,
RT_PRINT_DATA(rtlpriv, COMP_FW, DBG_LOUD,
"[C2H packet], Content Hex:\n", tmp_buf, c2h_cmd_len);
- _rtl8821ae_c2h_content_parsing(hw, c2h_cmd_id, c2h_cmd_len, tmp_buf);
+
+ switch (c2h_cmd_id) {
+ case C2H_8812_BT_INFO:
+ rtl_c2hcmd_enqueue(hw, c2h_cmd_id, c2h_cmd_len, tmp_buf);
+ break;
+
+ default:
+ rtl8821ae_c2h_content_parsing(hw, c2h_cmd_id, c2h_cmd_len,
+ tmp_buf);
+ break;
+ }
}
OpenPOWER on IntegriCloud