aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/net/wireless/intel/iwlwifi/pcie/tx.c4
-rw-r--r--net/mac80211/spectmgmt.c9
2 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/tx.c b/drivers/net/wireless/intel/iwlwifi/pcie/tx.c
index 748772fa6b3e..22d482ae53d9 100644
--- a/drivers/net/wireless/intel/iwlwifi/pcie/tx.c
+++ b/drivers/net/wireless/intel/iwlwifi/pcie/tx.c
@@ -1770,7 +1770,7 @@ static void *iwl_pcie_get_page_hdr(struct iwl_trans *trans,
* (see also get_workaround_page() in tx-gen2.c)
*/
if (((unsigned long)p->pos & ~PAGE_MASK) + len < IWL_TSO_PAGE_DATA_SIZE) {
- info = IWL_TSO_PAGE_INFO(page_address(ret));
+ info = IWL_TSO_PAGE_INFO(page_address(p->page));
goto out;
}
@@ -1783,7 +1783,7 @@ alloc:
return NULL;
p->pos = page_address(p->page);
- info = IWL_TSO_PAGE_INFO(page_address(ret));
+ info = IWL_TSO_PAGE_INFO(page_address(p->page));
/* set the chaining pointer to NULL */
info->next = NULL;
diff --git a/net/mac80211/spectmgmt.c b/net/mac80211/spectmgmt.c
index e91ca4ccdd37..073ff9e0f397 100644
--- a/net/mac80211/spectmgmt.c
+++ b/net/mac80211/spectmgmt.c
@@ -343,6 +343,9 @@ int ieee80211_parse_ch_switch_ie(struct ieee80211_sub_if_data *sdata,
break;
}
+ /* capture the AP configuration */
+ csa_ie->chanreq.ap = csa_ie->chanreq.oper;
+
/* parse one of the Elements to build a new chandef */
memset(&new_chandef, 0, sizeof(new_chandef));
new_chandef.chan = new_chan;
@@ -369,11 +372,11 @@ int ieee80211_parse_ch_switch_ie(struct ieee80211_sub_if_data *sdata,
validate_chandef_by_ht_vht_oper(sdata, conn, vht_cap_info,
&new_chandef);
- /* capture the AP chandef before (potential) downgrading */
- csa_ie->chanreq.ap = new_chandef;
-
/* if data is there validate the bandwidth & use it */
if (new_chandef.chan) {
+ /* capture the AP chandef before (potential) downgrading */
+ csa_ie->chanreq.ap = new_chandef;
+
if (conn->bw_limit < IEEE80211_CONN_BW_LIMIT_320 &&
new_chandef.width == NL80211_CHAN_WIDTH_320)
ieee80211_chandef_downgrade(&new_chandef, NULL);