From: Arend van Spriel Date: Thu, 10 Feb 2011 11:03:48 +0000 (+0100) Subject: staging: brcm80211: handle change in association state from mac80211 X-Git-Tag: MMI-PSA29.97-13-9~20521^2~537 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d8a1fb44abc3e022419ecf8c51acf53b9b78e848;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git staging: brcm80211: handle change in association state from mac80211 The driver has flags for association state which are now being set according to notification from mac80211. Reviewed-by: Roland Vossen Reviewed-by: Brett Rudley Reviewed-by: Henry Ptasinski Signed-off-by: Arend van Spriel Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c b/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c index e485280c9c5d..a51e511ce69f 100644 --- a/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c +++ b/drivers/staging/brcm80211/brcmsmac/wl_mac80211.c @@ -333,6 +333,7 @@ wl_ops_bss_info_changed(struct ieee80211_hw *hw, */ WL_ERROR("%s: %s: %sassociated\n", KBUILD_MODNAME, __func__, info->assoc ? "" : "dis"); + wlc_associate_upd(wl->wlc, info->assoc); } if (changed & BSS_CHANGED_ERP_CTS_PROT) { /* CTS protection changed */ diff --git a/drivers/staging/brcm80211/brcmsmac/wlc_mac80211.c b/drivers/staging/brcm80211/brcmsmac/wlc_mac80211.c index d2b86a6453d1..76d78c18bf8a 100644 --- a/drivers/staging/brcm80211/brcmsmac/wlc_mac80211.c +++ b/drivers/staging/brcm80211/brcmsmac/wlc_mac80211.c @@ -8590,3 +8590,9 @@ void wlc_scan_stop(struct wlc_info *wlc) { wlc_phy_hold_upd(wlc->band->pi, PHY_HOLD_FOR_SCAN, false); } + +void wlc_associate_upd(struct wlc_info *wlc, bool state) +{ + wlc->pub->associated = state; + wlc->cfg->associated = state; +} diff --git a/drivers/staging/brcm80211/brcmsmac/wlc_pub.h b/drivers/staging/brcm80211/brcmsmac/wlc_pub.h index 4d0e0b13e3a9..4b43c3ce42e6 100644 --- a/drivers/staging/brcm80211/brcmsmac/wlc_pub.h +++ b/drivers/staging/brcm80211/brcmsmac/wlc_pub.h @@ -563,6 +563,7 @@ extern void wlc_enable_mac(struct wlc_info *wlc); extern u16 wlc_rate_shm_offset(struct wlc_info *wlc, u8 rate); extern u32 wlc_get_rspec_history(struct wlc_bsscfg *cfg); extern u32 wlc_get_current_highest_rate(struct wlc_bsscfg *cfg); +extern void wlc_associate_upd(struct wlc_info *wlc, bool state); extern void wlc_scan_start(struct wlc_info *wlc); extern void wlc_scan_stop(struct wlc_info *wlc);