Commit 14823bf2 authored by Glen Lee's avatar Glen Lee Committed by Greg Kroah-Hartman

staging: wilc1000: use unified firmware

Use a unified firmware for all mode of operations which are station, ap and
p2p. Two firmware are introduced for 1002 and 1003 chipset.
Signed-off-by: default avatarGlen Lee <glen.lee@atmel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent b8f6ca0b
obj-$(CONFIG_WILC1000) += wilc1000.o obj-$(CONFIG_WILC1000) += wilc1000.o
ccflags-y += -DSTA_FIRMWARE=\"atmel/wilc1000_fw.bin\" \ ccflags-y += -DFIRMWARE_1002=\"atmel/wilc1002_firmware.bin\" \
-DAP_FIRMWARE=\"atmel/wilc1000_ap_fw.bin\" \ -DFIRMWARE_1003=\"atmel/wilc1003_firmware.bin\"
-DP2P_CONCURRENCY_FIRMWARE=\"atmel/wilc1000_p2p_fw.bin\"
ccflags-y += -I$(src)/ -DWILC_ASIC_A0 -DWILC_DEBUGFS ccflags-y += -I$(src)/ -DWILC_ASIC_A0 -DWILC_DEBUGFS
#ccflags-y += -DTCP_ACK_FILTER #ccflags-y += -DTCP_ACK_FILTER
......
...@@ -416,21 +416,21 @@ int wilc_wlan_get_firmware(struct net_device *dev) ...@@ -416,21 +416,21 @@ int wilc_wlan_get_firmware(struct net_device *dev)
{ {
struct wilc_vif *vif; struct wilc_vif *vif;
struct wilc *wilc; struct wilc *wilc;
int ret = 0; int chip_id, ret = 0;
const struct firmware *wilc_firmware; const struct firmware *wilc_firmware;
char *firmware; char *firmware;
vif = netdev_priv(dev); vif = netdev_priv(dev);
wilc = vif->wilc; wilc = vif->wilc;
if (vif->iftype == AP_MODE) { chip_id = wilc_get_chipid(wilc, 0);
firmware = AP_FIRMWARE;
} else if (vif->iftype == STATION_MODE) { if (chip_id < 0x1003a0)
firmware = STA_FIRMWARE; firmware = FIRMWARE_1002;
} else { else
PRINT_D(INIT_DBG, "Get P2P_CONCURRENCY_FIRMWARE\n"); firmware = FIRMWARE_1003;
firmware = P2P_CONCURRENCY_FIRMWARE;
} netdev_info(dev, "loading firmware %s\n", firmware);
if (!vif) { if (!vif) {
PRINT_ER("vif is NULL\n"); PRINT_ER("vif is NULL\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment