From 6f106f345853326b4273ab9ccb07a64856e5cd21 Mon Sep 17 00:00:00 2001 From: David-John Willis Date: Tue, 16 Mar 2010 12:28:19 +0000 Subject: [PATCH] wl1251-modules: Add in more patches to fix and issue with NetworkManager and show ChipID in dmesg. --- recipes/pandora-system/wl1251-modules.bb | 2 + .../no-scan-while-connected.patch | 39 +++++++++++++++++++ .../wl1251-modules/print-chip-id.patch | 18 +++++++++ 3 files changed, 59 insertions(+) create mode 100644 recipes/pandora-system/wl1251-modules/no-scan-while-connected.patch create mode 100644 recipes/pandora-system/wl1251-modules/print-chip-id.patch diff --git a/recipes/pandora-system/wl1251-modules.bb b/recipes/pandora-system/wl1251-modules.bb index 62679d1..770a6db 100755 --- a/recipes/pandora-system/wl1251-modules.bb +++ b/recipes/pandora-system/wl1251-modules.bb @@ -8,6 +8,8 @@ SRC_URI += " \ file://0003-wl1251-reduce-eeprom-read-wait-time.patch;patch=1 \ file://0004-wl1251-fix-potential-crash.patch;patch=1 \ file://0005-pandora-hacks.patch;patch=1 \ + file://no-scan-while-connected.patch;patch=1 \ + file://print-chip-id.patch;patch=1 \ file://rc.wl1251 \ file://50-compat_firmware.rules \ file://compat_firmware.sh \ diff --git a/recipes/pandora-system/wl1251-modules/no-scan-while-connected.patch b/recipes/pandora-system/wl1251-modules/no-scan-while-connected.patch new file mode 100644 index 0000000..d7b438f --- /dev/null +++ b/recipes/pandora-system/wl1251-modules/no-scan-while-connected.patch @@ -0,0 +1,39 @@ +diff --git a/drivers/net/wireless/wl12xx/wl1251.h b/drivers/net/wireless/wl12xx/wl1251.h +index 4f5f02a..d8087ac 100644 +--- a/drivers/net/wireless/wl12xx/wl1251.h ++++ b/drivers/net/wireless/wl12xx/wl1251.h +@@ -381,6 +381,8 @@ struct wl1251 { + + u32 chip_id; + char fw_ver[21]; ++ ++ bool associated; + }; + + int wl1251_plt_start(struct wl1251 *wl); +diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c +index 7a8e489..0e1ae21 100644 +--- a/drivers/net/wireless/wl12xx/wl1251_main.c ++++ b/drivers/net/wireless/wl12xx/wl1251_main.c +@@ -869,6 +869,13 @@ static int wl1251_op_hw_scan(struct ieee80211_hw *hw, + + wl1251_debug(DEBUG_MAC80211, "mac80211 hw scan"); + ++ /* ++ * FIXME: scanning while associated causes lockups, ++ * so we don't allow that ++ */ ++ if (wl->associated) ++ return -EBUSY; ++ + if (req->n_ssids) { + ssid = req->ssids[0].ssid; + ssid_len = req->ssids[0].ssid_len; +@@ -987,6 +994,7 @@ static void wl1251_op_bss_info_changed(struct ieee80211_hw *hw, + } + + if (changed & BSS_CHANGED_ASSOC) { ++ wl->associated = bss_conf->assoc; + if (bss_conf->assoc) { + wl->beacon_int = bss_conf->beacon_int; + diff --git a/recipes/pandora-system/wl1251-modules/print-chip-id.patch b/recipes/pandora-system/wl1251-modules/print-chip-id.patch new file mode 100644 index 0000000..180a0a0 --- /dev/null +++ b/recipes/pandora-system/wl1251-modules/print-chip-id.patch @@ -0,0 +1,18 @@ +diff --git a/drivers/net/wireless/wl12xx/wl1251_main.c b/drivers/net/wireless/wl12xx/wl1251_main.c +index 7a8e489..0e1ae21 100644 +--- a/drivers/net/wireless/wl12xx/wl1251_main.c ++++ b/drivers/net/wireless/wl12xx/wl1251_main.c +@@ -184,11 +184,11 @@ static int wl1251_chip_wakeup(struct wl1251 *wl) + + switch (wl->chip_id) { + case CHIP_ID_1251_PG12: +- wl1251_debug(DEBUG_BOOT, "chip id 0x%x (1251 PG12)", ++ wl1251_info("chip id 0x%x (1251 PG12)", + wl->chip_id); + break; + case CHIP_ID_1251_PG11: +- wl1251_debug(DEBUG_BOOT, "chip id 0x%x (1251 PG11)", ++ wl1251_info("chip id 0x%x (1251 PG11)", + wl->chip_id); + break; + case CHIP_ID_1251_PG10: -- 2.39.5