wifi: fix wifi panic issue [1/1]
authorRongjun Chen <rongjun.chen@amlogic.com>
Tue, 19 Feb 2019 06:47:17 +0000 (14:47 +0800)
committerRongjun Chen <rongjun.chen@amlogic.com>
Tue, 19 Feb 2019 06:47:17 +0000 (14:47 +0800)
PD#SWPL-4229

Problem:
autoreboot test wifi will panic

Solution:
fix wifi panic issue

Verify:
ampere

Change-Id: I9dcb81fb0f07c0fade264bf23f335c46a8fc4e4f

bcmdhd.100.10.315.x/wl_cfg80211.c

index e3fdbccc41130ec5da37f689e466b083be7914a5..998f677a123652f24b41640cffb73fd1f3e235ee 100644 (file)
@@ -19606,7 +19606,7 @@ s32 wl_cfg80211_down(struct net_device *dev)
 
        WL_DBG(("In\n"));
 
-       if (cfg) {
+       if (cfg && (cfg == wl_cfg80211_get_bcmcfg())) {
                mutex_lock(&cfg->usr_sync);
 #if defined(RSSIAVG)
                wl_free_rssi_cache(&cfg->g_rssi_cache_ctrl);