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

Commit 17e672d6 authored by Arik Nemtsov's avatar Arik Nemtsov Committed by Luciano Coelho
Browse files

wl12xx: configure channel/band while FW is off



Initialize the channel and band from mac80211 conf even when the FW is
not yet loaded. This mitigates a bug in AP-mode where the channel was
never changed from its initial setting after FW boot and was therefore
never configured to FW.

Reported-by: default avatarAlexander Boukaty <alexanderb@ti.com>
Signed-off-by: default avatarArik Nemtsov <arik@wizery.com>
Signed-off-by: default avatarLuciano Coelho <coelho@ti.com>
parent 4a31c11c
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -1706,7 +1706,12 @@ static int wl1271_op_config(struct ieee80211_hw *hw, u32 changed)
	mutex_lock(&wl->mutex);

	if (unlikely(wl->state == WL1271_STATE_OFF)) {
		ret = -EAGAIN;
		/* we support configuring the channel and band while off */
		if ((changed & IEEE80211_CONF_CHANGE_CHANNEL)) {
			wl->band = conf->channel->band;
			wl->channel = channel;
		}

		goto out;
	}