Hi Sean, Your fix looks to be hacky. With your fix, brcm driver will always report success for cfg80211_scan_done. But, there are some occasions where scan may be aborted by FW, which needs to be reported to cfg80211. In my view, first we need to debug why iscan is unable to send cfg80211_scan_done notification. Recently, we fixed some issues related to scan. Those fixes might help here. Currently they are under review. Will let you know once they reached the staging tree. Regards, Sukesh. -----Original Message----- From: Sean Paul [mailto:seanpaul@xxxxxxxxxx] On Behalf Of Sean Paul Sent: Wednesday, May 11, 2011 4:39 PM To: Arend Van Spriel; Sukesh Srikakula Cc: devel@xxxxxxxxxxxxxxxxxxxxxx; grundler@xxxxxxxxxxxx; bryeung@xxxxxxxxxxxx; Sean Paul Subject: [PATCH] brcm80211: Allow scans after scanning for specific ssid brcmfmac driver returned "busy" for all scan requests after a scan request for a specific SSID. scan_request field was not being cleared if the code path did not call wl_do_iscan(). Users can then not reconnect to any SSID after disconnecting (unless they take the interface down and then back up). Tested on Nvidia Seaboard + BCM4329 + 2.6.38 Signed-off-by: Sean Paul <seanpaul@xxxxxxxxxxxx> Reviewed-by: Grant Grundler <grundler@xxxxxxxxxxxx> --- drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c b/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c index 555b056..7f4817d 100644 --- a/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c +++ b/drivers/staging/brcm80211/brcmfmac/wl_cfg80211.c @@ -828,21 +828,21 @@ __wl_cfg80211_scan(struct wiphy *wiphy, struct net_device *ndev, wl_set_mpc(ndev, 0); err = wl_dev_ioctl(ndev, WLC_SCAN, &sr->ssid, sizeof(sr->ssid)); - if (err) { + if (!err) { + cfg80211_scan_done(wl->scan_request, false); + } else { if (err == -EBUSY) { WL_INFO("system busy : scan for \"%s\" canceled\n", sr->ssid.SSID); } else { WL_ERR("WLC_SCAN error (%d)\n", err); } - wl_set_mpc(ndev, 1); goto scan_out; } } - return 0; - scan_out: + wl_set_mpc(ndev, 1); clear_bit(WL_STATUS_SCANNING, &wl->status); wl->scan_request = NULL; return err; -- 1.7.1 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/devel