Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8fd77aec authored by Larry Finger's avatar Larry Finger Committed by John W. Linville
Browse files

rtlwifi: rtl8192c: Prevent reconnect attempts if not connected



This driver has a watchdog timer that attempts to reconnect when beacon frames
are not seen for 6 seconds. This patch disables that reconnect whenever the
device has never been connected.

Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent ac0ef813
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1437,7 +1437,8 @@ void rtl_watchdog_wq_callback(void *data)
			/* if we can't recv beacon for 6s, we should
			 * reconnect this AP
			 */
			if (rtlpriv->link_info.roam_times >= 3) {
			if ((rtlpriv->link_info.roam_times >= 3) &&
			    !is_zero_ether_addr(rtlpriv->mac80211.bssid)) {
				RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG,
					 "AP off, try to reconnect now\n");
				rtlpriv->link_info.roam_times = 0;