summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rtlwifi/rtl8723ae/sw.c
diff options
context:
space:
mode:
authorLarry Finger2014-02-28 22:16:48 +0100
committerJohn W. Linville2014-03-04 19:19:37 +0100
commitcbd0c8512f3b06c86849c554eb092862c46885d5 (patch)
treed48a9d4dd30e74418e7c841c74aba7f43eeb619b /drivers/net/wireless/rtlwifi/rtl8723ae/sw.c
parentrtlwifi: rtl8723ae: rtl8723-common: Create new driver for common code (diff)
downloadkernel-qcow2-linux-cbd0c8512f3b06c86849c554eb092862c46885d5.tar.gz
kernel-qcow2-linux-cbd0c8512f3b06c86849c554eb092862c46885d5.tar.xz
kernel-qcow2-linux-cbd0c8512f3b06c86849c554eb092862c46885d5.zip
rtlwifi: rtl8723ae: rtl8723-common: Copy common firmware code
The drivers for RTL8723AE and RTL8723BE have some code in common. This commit copies the common firmware routines into the shared code. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtlwifi/rtl8723ae/sw.c')
-rw-r--r--drivers/net/wireless/rtlwifi/rtl8723ae/sw.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8723ae/sw.c b/drivers/net/wireless/rtlwifi/rtl8723ae/sw.c
index 0b97c9acebaa..1087a3bd07fa 100644
--- a/drivers/net/wireless/rtlwifi/rtl8723ae/sw.c
+++ b/drivers/net/wireless/rtlwifi/rtl8723ae/sw.c
@@ -40,6 +40,8 @@
#include "../rtl8723com/phy_common.h"
#include "dm.h"
#include "hw.h"
+#include "fw.h"
+#include "../rtl8723com/fw_common.h"
#include "sw.h"
#include "trx.h"
#include "led.h"
@@ -194,6 +196,11 @@ void rtl8723ae_deinit_sw_vars(struct ieee80211_hw *hw)
}
}
+static bool is_fw_header(struct rtl92c_firmware_header *hdr)
+{
+ return (hdr->signature & 0xfff0) == 0x2300;
+}
+
static struct rtl_hal_ops rtl8723ae_hal_ops = {
.init_sw_vars = rtl8723ae_init_sw_vars,
.deinit_sw_vars = rtl8723ae_deinit_sw_vars,
@@ -239,6 +246,7 @@ static struct rtl_hal_ops rtl8723ae_hal_ops = {
.c2h_command_handle = rtl_8723e_c2h_command_handle,
.bt_wifi_media_status_notify = rtl_8723e_bt_wifi_media_status_notify,
.bt_coex_off_before_lps = rtl8723ae_bt_coex_off_before_lps,
+ .is_fw_header = is_fw_header,
};
static struct rtl_mod_params rtl8723ae_mod_params = {