mac80211: update to wireless-testing 2016-01-10

Signed-off-by: Felix Fietkau <nbd@openwrt.org>

SVN-Revision: 48247
This commit is contained in:
Felix Fietkau 2016-01-15 15:03:48 +00:00
parent 56f6d35716
commit 82c5e2c497
71 changed files with 584 additions and 367 deletions

View file

@ -10,11 +10,11 @@ include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=mac80211 PKG_NAME:=mac80211
PKG_VERSION:=2015-12-03 PKG_VERSION:=2016-01-10
PKG_RELEASE:=2 PKG_RELEASE:=1
PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources
PKG_BACKPORT_VERSION:= PKG_BACKPORT_VERSION:=
PKG_MD5SUM:=7a1dc4dc2f509e5532b935b0a0d15103 PKG_MD5SUM:=be5fae2e8d6f7490f9b073374fb895ba
PKG_SOURCE:=compat-wireless-$(PKG_VERSION)$(PKG_BACKPORT_VERSION).tar.bz2 PKG_SOURCE:=compat-wireless-$(PKG_VERSION)$(PKG_BACKPORT_VERSION).tar.bz2
PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION) PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION)

View file

@ -1,28 +0,0 @@
From 7a6e8b70a956a722f90d551e920c1096a9455b54 Mon Sep 17 00:00:00 2001
From: Hauke Mehrtens <hauke@hauke-m.de>
Date: Sat, 5 Dec 2015 14:10:28 +0100
Subject: [PATCH 07/12] header: fix genl_notify() on kernel 4.4
The change of the parameters of genl_notify() is in kernel 4.4. This
backport should not be applied for kernel 4.4 and newer kernel versions.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
backport/backport-include/net/genetlink.h | 2 ++
1 file changed, 2 insertions(+)
--- a/backport-include/net/genetlink.h
+++ b/backport-include/net/genetlink.h
@@ -146,10 +146,12 @@ backport_genlmsg_multicast_allns(struct
#define __genl_const
#else /* < 3.13 */
#define __genl_const const
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4,4,0)
#define genl_notify(_fam, _skb, _info, _group, _flags) \
genl_notify(_fam, _skb, genl_info_net(_info), \
genl_info_snd_portid(_info), \
_group, _info->nlhdr, _flags)
+#endif /* < 4.4 */
#endif /* < 3.13 */
#endif /* __BACKPORT_NET_GENETLINK_H */

View file

@ -1,6 +1,6 @@
--- a/net/wireless/Kconfig --- a/net/wireless/Kconfig
+++ b/net/wireless/Kconfig +++ b/net/wireless/Kconfig
@@ -184,7 +184,7 @@ config CFG80211_WEXT_EXPORT @@ -171,7 +171,7 @@ config CFG80211_WEXT_EXPORT
wext compatibility symbols to be exported. wext compatibility symbols to be exported.
config LIB80211 config LIB80211
@ -9,7 +9,7 @@
depends on m depends on m
default n default n
help help
@@ -194,15 +194,15 @@ config LIB80211 @@ -181,15 +181,15 @@ config LIB80211
Drivers should select this themselves if needed. Drivers should select this themselves if needed.
config LIB80211_CRYPT_WEP config LIB80211_CRYPT_WEP

View file

@ -1,6 +1,6 @@
--- a/.local-symbols --- a/.local-symbols
+++ b/.local-symbols +++ b/.local-symbols
@@ -475,44 +475,6 @@ USB_IPHETH= @@ -476,44 +476,6 @@ USB_IPHETH=
USB_SIERRA_NET= USB_SIERRA_NET=
USB_VL600= USB_VL600=
USB_NET_CH9200= USB_NET_CH9200=

View file

@ -1,6 +1,6 @@
--- a/net/mac80211/main.c --- a/net/mac80211/main.c
+++ b/net/mac80211/main.c +++ b/net/mac80211/main.c
@@ -285,7 +285,7 @@ void ieee80211_restart_hw(struct ieee802 @@ -291,7 +291,7 @@ void ieee80211_restart_hw(struct ieee802
} }
EXPORT_SYMBOL(ieee80211_restart_hw); EXPORT_SYMBOL(ieee80211_restart_hw);
@ -9,7 +9,7 @@
static int ieee80211_ifa_changed(struct notifier_block *nb, static int ieee80211_ifa_changed(struct notifier_block *nb,
unsigned long data, void *arg) unsigned long data, void *arg)
{ {
@@ -344,7 +344,7 @@ static int ieee80211_ifa_changed(struct @@ -350,7 +350,7 @@ static int ieee80211_ifa_changed(struct
} }
#endif #endif
@ -18,7 +18,7 @@
static int ieee80211_ifa6_changed(struct notifier_block *nb, static int ieee80211_ifa6_changed(struct notifier_block *nb,
unsigned long data, void *arg) unsigned long data, void *arg)
{ {
@@ -1081,14 +1081,14 @@ int ieee80211_register_hw(struct ieee802 @@ -1087,14 +1087,14 @@ int ieee80211_register_hw(struct ieee802
rtnl_unlock(); rtnl_unlock();
@ -35,7 +35,7 @@
local->ifa6_notifier.notifier_call = ieee80211_ifa6_changed; local->ifa6_notifier.notifier_call = ieee80211_ifa6_changed;
result = register_inet6addr_notifier(&local->ifa6_notifier); result = register_inet6addr_notifier(&local->ifa6_notifier);
if (result) if (result)
@@ -1097,13 +1097,13 @@ int ieee80211_register_hw(struct ieee802 @@ -1103,13 +1103,13 @@ int ieee80211_register_hw(struct ieee802
return 0; return 0;
@ -52,7 +52,7 @@
fail_ifa: fail_ifa:
#endif #endif
rtnl_lock(); rtnl_lock();
@@ -1131,10 +1131,10 @@ void ieee80211_unregister_hw(struct ieee @@ -1137,10 +1137,10 @@ void ieee80211_unregister_hw(struct ieee
tasklet_kill(&local->tx_pending_tasklet); tasklet_kill(&local->tx_pending_tasklet);
tasklet_kill(&local->tasklet); tasklet_kill(&local->tasklet);

View file

@ -1,6 +1,6 @@
--- a/net/mac80211/cfg.c --- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c
@@ -1971,7 +1971,7 @@ static int ieee80211_scan(struct wiphy * @@ -1999,7 +1999,7 @@ static int ieee80211_scan(struct wiphy *
* the frames sent while scanning on other channel will be * the frames sent while scanning on other channel will be
* lost) * lost)
*/ */

View file

@ -58,7 +58,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (aggr) if (aggr)
last = ath_tx_form_aggr(sc, txq, tid, &bf_q, bf, last = ath_tx_form_aggr(sc, txq, tid, &bf_q, bf,
tid_q, &aggr_len); tid_q, &aggr_len);
@@ -1632,7 +1647,7 @@ void ath9k_release_buffered_frames(struc @@ -1647,7 +1662,7 @@ void ath9k_release_buffered_frames(struc
__skb_unlink(bf->bf_mpdu, tid_q); __skb_unlink(bf->bf_mpdu, tid_q);
list_add_tail(&bf->list, &bf_q); list_add_tail(&bf->list, &bf_q);
@ -67,7 +67,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
if (bf_isampdu(bf)) { if (bf_isampdu(bf)) {
ath_tx_addto_baw(sc, tid, bf); ath_tx_addto_baw(sc, tid, bf);
bf->bf_state.bf_type &= ~BUF_AGGR; bf->bf_state.bf_type &= ~BUF_AGGR;
@@ -2278,7 +2293,7 @@ int ath_tx_start(struct ieee80211_hw *hw @@ -2293,7 +2308,7 @@ int ath_tx_start(struct ieee80211_hw *hw
struct ath_txq *txq = txctl->txq; struct ath_txq *txq = txctl->txq;
struct ath_atx_tid *tid = NULL; struct ath_atx_tid *tid = NULL;
struct ath_buf *bf; struct ath_buf *bf;
@ -76,7 +76,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
int q, ret; int q, ret;
if (vif) if (vif)
@@ -2325,13 +2340,13 @@ int ath_tx_start(struct ieee80211_hw *hw @@ -2346,13 +2361,13 @@ int ath_tx_start(struct ieee80211_hw *hw
if (!txctl->an) if (!txctl->an)
txctl->an = &avp->mcast_node; txctl->an = &avp->mcast_node;
queue = true; queue = true;
@ -92,7 +92,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
ath_txq_unlock(sc, txq); ath_txq_unlock(sc, txq);
txq = sc->tx.uapsdq; txq = sc->tx.uapsdq;
ath_txq_lock(sc, txq); ath_txq_lock(sc, txq);
@@ -2369,7 +2384,7 @@ int ath_tx_start(struct ieee80211_hw *hw @@ -2390,7 +2405,7 @@ int ath_tx_start(struct ieee80211_hw *hw
if (txctl->paprd) if (txctl->paprd)
bf->bf_state.bfs_paprd_timestamp = jiffies; bf->bf_state.bfs_paprd_timestamp = jiffies;
@ -101,7 +101,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
ath_tx_send_normal(sc, txq, tid, skb); ath_tx_send_normal(sc, txq, tid, skb);
out: out:
@@ -2408,7 +2423,7 @@ void ath_tx_cabq(struct ieee80211_hw *hw @@ -2429,7 +2444,7 @@ void ath_tx_cabq(struct ieee80211_hw *hw
break; break;
bf->bf_lastbf = bf; bf->bf_lastbf = bf;
@ -110,7 +110,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
ath_buf_set_rate(sc, bf, &info, fi->framelen, false); ath_buf_set_rate(sc, bf, &info, fi->framelen, false);
duration += info.rates[0].PktDuration; duration += info.rates[0].PktDuration;
if (bf_tail) if (bf_tail)
@@ -2911,7 +2926,7 @@ int ath9k_tx99_send(struct ath_softc *sc @@ -2932,7 +2947,7 @@ int ath9k_tx99_send(struct ath_softc *sc
return -EINVAL; return -EINVAL;
} }

View file

@ -1,24 +0,0 @@
From: Bob Copeland <me@bobcopeland.com>
Date: Thu, 19 Nov 2015 10:04:48 -0500
Subject: [PATCH] ath5k: fix RTS/CTS by using proper rate flags
The rates in the tx control rateset do not have the protection
flags applied, so RTS/CTS would never get enabled if requested.
Fix by using the rate flags in the rates returned by
ieee80211_get_tx_rates().
Signed-off-by: Bob Copeland <me@bobcopeland.com>
---
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -767,7 +767,7 @@ ath5k_txbuf_setup(struct ath5k_hw *ah, s
if (info->flags & IEEE80211_TX_CTL_NO_ACK)
flags |= AR5K_TXDESC_NOACK;
- rc_flags = info->control.rates[0].flags;
+ rc_flags = bf->rates[0].flags;
hw_rate = ath5k_get_rate_hw_value(ah->hw, info, bf, 0);

View file

@ -1,104 +0,0 @@
From: Felix Fietkau <nbd@openwrt.org>
Date: Sun, 22 Nov 2015 14:03:40 +0100
Subject: [PATCH] ath10k: do not use coherent memory for allocated device
memory chunks
Coherent memory is more expensive to allocate (and constrained on some
architectures where it has to be pre-allocated). It is also completely
unnecessary, since the host has no reason to even access these allocated
memory spaces
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
---
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -4312,34 +4312,58 @@ void ath10k_wmi_event_vdev_resume_req(st
ath10k_dbg(ar, ATH10K_DBG_WMI, "WMI_VDEV_RESUME_REQ_EVENTID\n");
}
-static int ath10k_wmi_alloc_host_mem(struct ath10k *ar, u32 req_id,
- u32 num_units, u32 unit_len)
+static int ath10k_wmi_alloc_chunk(struct ath10k *ar, u32 req_id,
+ u32 num_units, u32 unit_len)
{
dma_addr_t paddr;
- u32 pool_size;
+ u32 pool_size = 0;
int idx = ar->wmi.num_mem_chunks;
+ void *vaddr = NULL;
- pool_size = num_units * round_up(unit_len, 4);
+ if (ar->wmi.num_mem_chunks == ARRAY_SIZE(ar->wmi.mem_chunks))
+ return -ENOMEM;
- if (!pool_size)
- return -EINVAL;
+ while (!vaddr && num_units) {
+ pool_size = num_units * round_up(unit_len, 4);
+ if (!pool_size)
+ return -EINVAL;
- ar->wmi.mem_chunks[idx].vaddr = dma_alloc_coherent(ar->dev,
- pool_size,
- &paddr,
- GFP_KERNEL);
- if (!ar->wmi.mem_chunks[idx].vaddr) {
- ath10k_warn(ar, "failed to allocate memory chunk\n");
- return -ENOMEM;
+ vaddr = kzalloc(pool_size, GFP_KERNEL | __GFP_NOWARN);
+ if (!vaddr)
+ num_units /= 2;
}
- memset(ar->wmi.mem_chunks[idx].vaddr, 0, pool_size);
+ if (!num_units)
+ return -ENOMEM;
+
+ paddr = dma_map_single(ar->dev, vaddr, pool_size, DMA_TO_DEVICE);
+ if (dma_mapping_error(ar->dev, paddr)) {
+ kfree(vaddr);
+ return -ENOMEM;
+ }
+ ar->wmi.mem_chunks[idx].vaddr = vaddr;
ar->wmi.mem_chunks[idx].paddr = paddr;
ar->wmi.mem_chunks[idx].len = pool_size;
ar->wmi.mem_chunks[idx].req_id = req_id;
ar->wmi.num_mem_chunks++;
+ return num_units;
+}
+
+static int ath10k_wmi_alloc_host_mem(struct ath10k *ar, u32 req_id,
+ u32 num_units, u32 unit_len)
+{
+ int ret;
+
+ while (num_units) {
+ ret = ath10k_wmi_alloc_chunk(ar, req_id, num_units, unit_len);
+ if (ret < 0)
+ return ret;
+
+ num_units -= ret;
+ }
+
return 0;
}
@@ -7717,10 +7741,11 @@ void ath10k_wmi_free_host_mem(struct ath
/* free the host memory chunks requested by firmware */
for (i = 0; i < ar->wmi.num_mem_chunks; i++) {
- dma_free_coherent(ar->dev,
- ar->wmi.mem_chunks[i].len,
- ar->wmi.mem_chunks[i].vaddr,
- ar->wmi.mem_chunks[i].paddr);
+ dma_unmap_single(ar->dev,
+ ar->wmi.mem_chunks[i].paddr,
+ ar->wmi.mem_chunks[i].len,
+ DMA_TO_DEVICE);
+ kfree(ar->wmi.mem_chunks[i].vaddr);
}
ar->wmi.num_mem_chunks = 0;

View file

@ -0,0 +1,156 @@
From: Eli Cooper <elicooper@gmx.com>
Date: Thu, 14 Jan 2016 00:07:12 +0800
Subject: [PATCH] rt2x00: fix monitor mode regression
Since commit df1404650ccbfeb76a84f301f22316be0d00a864 monitor mode for rt2x00
has been made effectively useless because the hardware filter is configured to
drop packets whose intended recipient is not the device, regardless of the
presence of monitor mode interfaces.
This patch fixes this regression by adding explicit monitor mode support, and
configuring the hardware filter accordingly.
Signed-off-by: Eli Cooper <elicooper@gmx.com>
---
--- a/drivers/net/wireless/ralink/rt2x00/rt2400pci.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2400pci.c
@@ -273,8 +273,10 @@ static void rt2400pci_config_filter(stru
!(filter_flags & FIF_PLCPFAIL));
rt2x00_set_field32(&reg, RXCSR0_DROP_CONTROL,
!(filter_flags & FIF_CONTROL));
- rt2x00_set_field32(&reg, RXCSR0_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field32(&reg, RXCSR0_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field32(&reg, RXCSR0_DROP_TODS,
+ !rt2x00dev->is_monitoring &&
!rt2x00dev->intf_ap_count);
rt2x00_set_field32(&reg, RXCSR0_DROP_VERSION_ERROR, 1);
rt2x00mmio_register_write(rt2x00dev, RXCSR0, reg);
--- a/drivers/net/wireless/ralink/rt2x00/rt2500pci.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2500pci.c
@@ -274,8 +274,10 @@ static void rt2500pci_config_filter(stru
!(filter_flags & FIF_PLCPFAIL));
rt2x00_set_field32(&reg, RXCSR0_DROP_CONTROL,
!(filter_flags & FIF_CONTROL));
- rt2x00_set_field32(&reg, RXCSR0_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field32(&reg, RXCSR0_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field32(&reg, RXCSR0_DROP_TODS,
+ !rt2x00dev->is_monitoring &&
!rt2x00dev->intf_ap_count);
rt2x00_set_field32(&reg, RXCSR0_DROP_VERSION_ERROR, 1);
rt2x00_set_field32(&reg, RXCSR0_DROP_MCAST,
--- a/drivers/net/wireless/ralink/rt2x00/rt2500usb.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2500usb.c
@@ -437,8 +437,10 @@ static void rt2500usb_config_filter(stru
!(filter_flags & FIF_PLCPFAIL));
rt2x00_set_field16(&reg, TXRX_CSR2_DROP_CONTROL,
!(filter_flags & FIF_CONTROL));
- rt2x00_set_field16(&reg, TXRX_CSR2_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field16(&reg, TXRX_CSR2_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field16(&reg, TXRX_CSR2_DROP_TODS,
+ !rt2x00dev->is_monitoring &&
!rt2x00dev->intf_ap_count);
rt2x00_set_field16(&reg, TXRX_CSR2_DROP_VERSION_ERROR, 1);
rt2x00_set_field16(&reg, TXRX_CSR2_DROP_MULTICAST,
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -1490,7 +1490,8 @@ void rt2800_config_filter(struct rt2x00_
!(filter_flags & FIF_FCSFAIL));
rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_PHY_ERROR,
!(filter_flags & FIF_PLCPFAIL));
- rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_NOT_MY_BSSD, 0);
rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_VER_ERROR, 1);
rt2x00_set_field32(&reg, RX_FILTER_CFG_DROP_MULTICAST,
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h
@@ -844,11 +844,13 @@ struct rt2x00_dev {
* - Open sta interface count.
* - Association count.
* - Beaconing enabled count.
+ * - Whether the device is monitoring.
*/
unsigned int intf_ap_count;
unsigned int intf_sta_count;
unsigned int intf_associated;
unsigned int intf_beaconing;
+ bool is_monitoring;
/*
* Interface combinations
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00config.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00config.c
@@ -244,6 +244,16 @@ void rt2x00lib_config(struct rt2x00_dev
(ieee80211_flags & IEEE80211_CONF_CHANGE_PS))
cancel_delayed_work_sync(&rt2x00dev->autowakeup_work);
+ if (ieee80211_flags & IEEE80211_CONF_CHANGE_MONITOR) {
+ if (conf->flags & IEEE80211_CONF_MONITOR) {
+ rt2x00_dbg(rt2x00dev, "Monitor mode is enabled\n");
+ rt2x00dev->is_monitoring = true;
+ } else {
+ rt2x00_dbg(rt2x00dev, "Monitor mode is disabled\n");
+ rt2x00dev->is_monitoring = false;
+ }
+ }
+
/*
* Start configuration.
*/
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
@@ -1204,6 +1204,7 @@ int rt2x00lib_start(struct rt2x00_dev *r
rt2x00dev->intf_ap_count = 0;
rt2x00dev->intf_sta_count = 0;
rt2x00dev->intf_associated = 0;
+ rt2x00dev->is_monitoring = false;
/* Enable the radio */
retval = rt2x00lib_enable_radio(rt2x00dev);
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
@@ -385,11 +385,6 @@ void rt2x00mac_configure_filter(struct i
*total_flags |= FIF_PSPOLL;
}
- /*
- * Check if there is any work left for us.
- */
- if (rt2x00dev->packet_filter == *total_flags)
- return;
rt2x00dev->packet_filter = *total_flags;
rt2x00dev->ops->lib->config_filter(rt2x00dev, *total_flags);
--- a/drivers/net/wireless/ralink/rt2x00/rt61pci.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt61pci.c
@@ -530,8 +530,10 @@ static void rt61pci_config_filter(struct
!(filter_flags & FIF_PLCPFAIL));
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_CONTROL,
!(filter_flags & (FIF_CONTROL | FIF_PSPOLL)));
- rt2x00_set_field32(&reg, TXRX_CSR0_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field32(&reg, TXRX_CSR0_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_TO_DS,
+ !rt2x00dev->is_monitoring &&
!rt2x00dev->intf_ap_count);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_VERSION_ERROR, 1);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_MULTICAST,
--- a/drivers/net/wireless/ralink/rt2x00/rt73usb.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt73usb.c
@@ -480,8 +480,10 @@ static void rt73usb_config_filter(struct
!(filter_flags & FIF_PLCPFAIL));
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_CONTROL,
!(filter_flags & (FIF_CONTROL | FIF_PSPOLL)));
- rt2x00_set_field32(&reg, TXRX_CSR0_DROP_NOT_TO_ME, 1);
+ rt2x00_set_field32(&reg, TXRX_CSR0_DROP_NOT_TO_ME,
+ !rt2x00dev->is_monitoring);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_TO_DS,
+ !rt2x00dev->is_monitoring &&
!rt2x00dev->intf_ap_count);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_VERSION_ERROR, 1);
rt2x00_set_field32(&reg, TXRX_CSR0_DROP_MULTICAST,

View file

@ -0,0 +1,32 @@
From: Miaoqing Pan <miaoqing@codeaurora.org>
Date: Fri, 15 Jan 2016 18:17:17 +0800
Subject: [PATCH] ath9k: avoid ANI restart if no trigger
Fixes commit 54da20d83f0e ("ath9k_hw: improve ANI processing and rx desensitizing parameters")
Call ath9k_ani_restart() only when the phy error rate reach the
ANI immunity threshold. Sync the logic with internal code base.
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
---
--- a/drivers/net/wireless/ath/ath9k/ani.c
+++ b/drivers/net/wireless/ath/ath9k/ani.c
@@ -444,14 +444,16 @@ void ath9k_hw_ani_monitor(struct ath_hw
ofdmPhyErrRate < ah->config.ofdm_trig_low) {
ath9k_hw_ani_lower_immunity(ah);
aniState->ofdmsTurn = !aniState->ofdmsTurn;
+ ath9k_ani_restart(ah);
} else if (ofdmPhyErrRate > ah->config.ofdm_trig_high) {
ath9k_hw_ani_ofdm_err_trigger(ah);
aniState->ofdmsTurn = false;
+ ath9k_ani_restart(ah);
} else if (cckPhyErrRate > ah->config.cck_trig_high) {
ath9k_hw_ani_cck_err_trigger(ah);
aniState->ofdmsTurn = true;
+ ath9k_ani_restart(ah);
}
- ath9k_ani_restart(ah);
}
}
EXPORT_SYMBOL(ath9k_hw_ani_monitor);

View file

@ -1,48 +0,0 @@
From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Date: Sun, 20 Dec 2015 13:50:00 +0200
Subject: [PATCH] mac80211: fix PS-Poll handling
My commit below broken PS-Poll handling. In case the driver
has no frames buffered, driver_release_tids will be 0, but
calling find_highest_prio_tid() with 0 as a parameter is
not a good idea:
fls(0) - 1 = -1.
This bug caused mac80211 to think that frames were buffered
in the driver which in turn was confused because mac80211
was asking to release frames that were not reported to
exist.
On iwlwifi, this led to the WARNING below:
WARNING: CPU: 0 PID: 11230 at drivers/net/wireless/intel/iwlwifi/mvm/sta.c:1733 iwl_mvm_sta_modify_sleep_tx_count+0x2af/0x320 [iwlmvm]()
ffffffffc0627c60 ffff8800069b7648 ffffffff81888913 0000000000000000
0000000000000000 ffff8800069b7688 ffffffff81089d6a ffff8800069b7678
0000000000000001 ffff88003b35abf0 ffff88000698b128 ffff8800069b76d4
Call Trace:
[<ffffffff81888913>] dump_stack+0x4c/0x65
[<ffffffff81089d6a>] warn_slowpath_common+0x8a/0xc0
[<ffffffff81089e5a>] warn_slowpath_null+0x1a/0x20
[<ffffffffc05f36bf>] iwl_mvm_sta_modify_sleep_tx_count+0x2af/0x320 [iwlmvm]
[<ffffffffc05dae41>] iwl_mvm_mac_release_buffered_frames+0x31/0x40 [iwlmvm]
[<ffffffffc045d8b6>] ieee80211_sta_ps_deliver_response+0x6e6/0xd80 [mac80211]
[<ffffffffc0461296>] ieee80211_sta_ps_deliver_poll_response+0x26/0x30 [mac80211]
[<ffffffffc048f743>] ieee80211_rx_handlers+0xa83/0x2900 [mac80211]
[<ffffffffc04917ad>] ieee80211_prepare_and_rx_handle+0x1ed/0xa70 [mac80211]
[<ffffffffc045e3d5>] ? sta_info_get_bss+0x5/0x4a0 [mac80211]
[<ffffffffc04925b6>] ieee80211_rx_napi+0x586/0xcd0 [mac80211]
[<ffffffffc05eaa3e>] iwl_mvm_rx_rx_mpdu+0x59e/0xc60 [iwlmvm]
Fixes: 0ead2510f8ce ("mac80211: allow the driver to send EOSP when needed")
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
---
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -1453,7 +1453,7 @@ ieee80211_sta_ps_deliver_response(struct
more_data = ieee80211_sta_ps_more_data(sta, ignored_acs, reason, driver_release_tids);
- if (reason == IEEE80211_FRAME_RELEASE_PSPOLL)
+ if (driver_release_tids && reason == IEEE80211_FRAME_RELEASE_PSPOLL)
driver_release_tids =
BIT(find_highest_prio_tid(driver_release_tids));

View file

@ -0,0 +1,91 @@
From: Miaoqing Pan <miaoqing@codeaurora.org>
Date: Fri, 15 Jan 2016 18:17:18 +0800
Subject: [PATCH] ath9k: clean up ANI per-channel pointer checking
commit c24bd3620c50 ("ath9k: Do not maintain ANI state per-channel")
removed per-channel handling, the code to check 'curchan' also
should be removed as never used.
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
---
--- a/drivers/net/wireless/ath/ath9k/ani.c
+++ b/drivers/net/wireless/ath/ath9k/ani.c
@@ -126,12 +126,8 @@ static void ath9k_hw_update_mibstats(str
static void ath9k_ani_restart(struct ath_hw *ah)
{
- struct ar5416AniState *aniState;
-
- if (!ah->curchan)
- return;
+ struct ar5416AniState *aniState = &ah->ani;
- aniState = &ah->ani;
aniState->listenTime = 0;
ENABLE_REGWRITE_BUFFER(ah);
@@ -221,12 +217,7 @@ static void ath9k_hw_set_ofdm_nil(struct
static void ath9k_hw_ani_ofdm_err_trigger(struct ath_hw *ah)
{
- struct ar5416AniState *aniState;
-
- if (!ah->curchan)
- return;
-
- aniState = &ah->ani;
+ struct ar5416AniState *aniState = &ah->ani;
if (aniState->ofdmNoiseImmunityLevel < ATH9K_ANI_OFDM_MAX_LEVEL)
ath9k_hw_set_ofdm_nil(ah, aniState->ofdmNoiseImmunityLevel + 1, false);
@@ -281,12 +272,7 @@ static void ath9k_hw_set_cck_nil(struct
static void ath9k_hw_ani_cck_err_trigger(struct ath_hw *ah)
{
- struct ar5416AniState *aniState;
-
- if (!ah->curchan)
- return;
-
- aniState = &ah->ani;
+ struct ar5416AniState *aniState = &ah->ani;
if (aniState->cckNoiseImmunityLevel < ATH9K_ANI_CCK_MAX_LEVEL)
ath9k_hw_set_cck_nil(ah, aniState->cckNoiseImmunityLevel + 1,
@@ -299,9 +285,7 @@ static void ath9k_hw_ani_cck_err_trigger
*/
static void ath9k_hw_ani_lower_immunity(struct ath_hw *ah)
{
- struct ar5416AniState *aniState;
-
- aniState = &ah->ani;
+ struct ar5416AniState *aniState = &ah->ani;
/* lower OFDM noise immunity */
if (aniState->ofdmNoiseImmunityLevel > 0 &&
@@ -329,7 +313,7 @@ void ath9k_ani_reset(struct ath_hw *ah,
struct ath_common *common = ath9k_hw_common(ah);
int ofdm_nil, cck_nil;
- if (!ah->curchan)
+ if (!chan)
return;
BUG_ON(aniState == NULL);
@@ -416,14 +400,10 @@ static bool ath9k_hw_ani_read_counters(s
void ath9k_hw_ani_monitor(struct ath_hw *ah, struct ath9k_channel *chan)
{
- struct ar5416AniState *aniState;
+ struct ar5416AniState *aniState = &ah->ani;
struct ath_common *common = ath9k_hw_common(ah);
u32 ofdmPhyErrRate, cckPhyErrRate;
- if (!ah->curchan)
- return;
-
- aniState = &ah->ani;
if (!ath9k_hw_ani_read_counters(ah))
return;

View file

@ -0,0 +1,31 @@
From: Miaoqing Pan <miaoqing@codeaurora.org>
Date: Fri, 15 Jan 2016 18:17:19 +0800
Subject: [PATCH] ath9k: do not reset while BB panic(0x4000409) on ar9561
BB panic(0x4000409) observed while AP enabling/disabling
bursting.
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
---
--- a/drivers/net/wireless/ath/ath9k/ar9003_phy.c
+++ b/drivers/net/wireless/ath/ath9k/ar9003_phy.c
@@ -2071,7 +2071,8 @@ void ar9003_hw_attach_phy_ops(struct ath
* to be disabled.
*
* 0x04000409: Packet stuck on receive.
- * Full chip reset is required for all chips except AR9340.
+ * Full chip reset is required for all chips except
+ * AR9340, AR9531 and AR9561.
*/
/*
@@ -2100,7 +2101,7 @@ bool ar9003_hw_bb_watchdog_check(struct
case 0x04000b09:
return true;
case 0x04000409:
- if (AR_SREV_9340(ah) || AR_SREV_9531(ah))
+ if (AR_SREV_9340(ah) || AR_SREV_9531(ah) || AR_SREV_9561(ah))
return false;
else
return true;

View file

@ -0,0 +1,27 @@
From: Miaoqing Pan <miaoqing@codeaurora.org>
Date: Fri, 15 Jan 2016 18:17:20 +0800
Subject: [PATCH] ath9k: fix inconsistent use of tab and space in
indentation
Minor changes for indenting.
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
---
--- a/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
+++ b/drivers/net/wireless/ath/ath9k/ar9003_eeprom.c
@@ -5485,11 +5485,11 @@ unsigned int ar9003_get_paprd_scale_fact
AR9300_PAPRD_SCALE_1);
else {
if (chan->channel >= 5700)
- return MS(le32_to_cpu(eep->modalHeader5G.papdRateMaskHt20),
- AR9300_PAPRD_SCALE_1);
+ return MS(le32_to_cpu(eep->modalHeader5G.papdRateMaskHt20),
+ AR9300_PAPRD_SCALE_1);
else if (chan->channel >= 5400)
return MS(le32_to_cpu(eep->modalHeader5G.papdRateMaskHt40),
- AR9300_PAPRD_SCALE_2);
+ AR9300_PAPRD_SCALE_2);
else
return MS(le32_to_cpu(eep->modalHeader5G.papdRateMaskHt40),
AR9300_PAPRD_SCALE_1);

View file

@ -0,0 +1,65 @@
From: Miaoqing Pan <miaoqing@codeaurora.org>
Date: Fri, 15 Jan 2016 18:17:21 +0800
Subject: [PATCH] ath9k: fix data bus error on ar9300 and ar9580
One crash issue be found on ar9300: RTC_RC reg read leads crash, leading
the data bus error, due to RTC_RC reg write not happen properly.
Warm Reset trigger in continuous beacon stuck for one of the customer for
other chip, noticed the MAC was stuck in RTC reset. After analysis noticed
DMA did not complete when RTC was put in reset.
So, before resetting the MAC need to make sure there are no pending DMA
transactions because this reset does not reset all parts of the chip.
The 12th and 11th bit of MAC _DMA_CFG register used to do that.
12 cfg_halt_ack 0x0
0 DMA has not yet halted
1 DMA has halted
11 cfg_halt_req 0x0
0 DMA logic operates normally
1 Request DMA logic to stop so software can reset the MAC
The Bit [12] of this register indicates when the halt has taken effect or
not. the DMA halt IS NOT recoverable; once software sets bit [11] to
request a DMA halt, software must wait for bit [12] to be set and reset
the MAC.
So, the same thing we implemented for ar9580 chip.
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
---
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -1368,6 +1368,16 @@ static bool ath9k_hw_set_reset(struct at
if (ath9k_hw_mci_is_enabled(ah))
ar9003_mci_check_gpm_offset(ah);
+ /* DMA HALT added to resolve ar9300 and ar9580 bus error during
+ * RTC_RC reg read
+ */
+ if (AR_SREV_9300(ah) || AR_SREV_9580(ah)) {
+ REG_SET_BIT(ah, AR_CFG, AR_CFG_HALT_REQ);
+ ath9k_hw_wait(ah, AR_CFG, AR_CFG_HALT_ACK, AR_CFG_HALT_ACK,
+ 20 * AH_WAIT_TIMEOUT);
+ REG_CLR_BIT(ah, AR_CFG, AR_CFG_HALT_REQ);
+ }
+
REG_WRITE(ah, AR_RTC_RC, rst_flags);
REGWRITE_BUFFER_FLUSH(ah);
--- a/drivers/net/wireless/ath/ath9k/reg.h
+++ b/drivers/net/wireless/ath/ath9k/reg.h
@@ -34,8 +34,10 @@
#define AR_CFG_SWRG 0x00000010
#define AR_CFG_AP_ADHOC_INDICATION 0x00000020
#define AR_CFG_PHOK 0x00000100
-#define AR_CFG_CLK_GATE_DIS 0x00000400
#define AR_CFG_EEBS 0x00000200
+#define AR_CFG_CLK_GATE_DIS 0x00000400
+#define AR_CFG_HALT_REQ 0x00000800
+#define AR_CFG_HALT_ACK 0x00001000
#define AR_CFG_PCI_MASTER_REQ_Q_THRESH 0x00060000
#define AR_CFG_PCI_MASTER_REQ_Q_THRESH_S 17

View file

@ -0,0 +1,19 @@
From: Felix Fietkau <nbd@openwrt.org>
Date: Fri, 15 Jan 2016 15:59:45 +0100
Subject: [PATCH] brcmfmac: add missing include
linux/module.h is required for defining module parameters
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
---
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/common.c
@@ -17,6 +17,7 @@
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/netdevice.h>
+#include <linux/module.h>
#include <brcmu_wifi.h>
#include <brcmu_utils.h>
#include "core.h"

View file

@ -59,7 +59,7 @@
---help--- ---help---
--- a/.local-symbols --- a/.local-symbols
+++ b/.local-symbols +++ b/.local-symbols
@@ -126,6 +126,7 @@ ADM8211= @@ -125,6 +125,7 @@ ADM8211=
ATH_COMMON= ATH_COMMON=
WLAN_VENDOR_ATH= WLAN_VENDOR_ATH=
ATH_DEBUG= ATH_DEBUG=

View file

@ -1,6 +1,6 @@
--- a/net/wireless/reg.c --- a/net/wireless/reg.c
+++ b/net/wireless/reg.c +++ b/net/wireless/reg.c
@@ -2463,6 +2463,8 @@ void regulatory_hint_country_ie(struct w @@ -2411,6 +2411,8 @@ void regulatory_hint_country_ie(struct w
enum environment_cap env = ENVIRON_ANY; enum environment_cap env = ENVIRON_ANY;
struct regulatory_request *request = NULL, *lr; struct regulatory_request *request = NULL, *lr;
@ -9,11 +9,11 @@
/* IE len must be evenly divisible by 2 */ /* IE len must be evenly divisible by 2 */
if (country_ie_len & 0x01) if (country_ie_len & 0x01)
return; return;
@@ -2669,6 +2671,7 @@ static void restore_regulatory_settings( @@ -2617,6 +2619,7 @@ static void restore_regulatory_settings(
void regulatory_hint_disconnect(void) void regulatory_hint_disconnect(void)
{ {
+ return; + return;
REG_DBG_PRINT("All devices are disconnected, going to restore regulatory settings\n"); pr_debug("All devices are disconnected, going to restore regulatory settings\n");
restore_regulatory_settings(false); restore_regulatory_settings(false);
} }

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath9k/init.c --- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -1038,23 +1038,23 @@ static int __init ath9k_init(void) @@ -1039,23 +1039,23 @@ static int __init ath9k_init(void)
{ {
int error; int error;

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath9k/ath9k.h --- a/drivers/net/wireless/ath/ath9k/ath9k.h
+++ b/drivers/net/wireless/ath/ath9k/ath9k.h +++ b/drivers/net/wireless/ath/ath9k/ath9k.h
@@ -87,7 +87,7 @@ int ath_descdma_setup(struct ath_softc * @@ -88,7 +88,7 @@ int ath_descdma_setup(struct ath_softc *
(_l) &= ((_sz) - 1); \ (_l) &= ((_sz) - 1); \
} while (0) } while (0)

View file

@ -18,7 +18,7 @@
const u8 *addr); const u8 *addr);
--- a/include/net/mac80211.h --- a/include/net/mac80211.h
+++ b/include/net/mac80211.h +++ b/include/net/mac80211.h
@@ -1252,6 +1252,7 @@ enum ieee80211_smps_mode { @@ -1282,6 +1282,7 @@ enum ieee80211_smps_mode {
* *
* @power_level: requested transmit power (in dBm), backward compatibility * @power_level: requested transmit power (in dBm), backward compatibility
* value only that is set to the minimum of all interfaces * value only that is set to the minimum of all interfaces
@ -26,7 +26,7 @@
* *
* @chandef: the channel definition to tune to * @chandef: the channel definition to tune to
* @radar_enabled: whether radar detection is enabled * @radar_enabled: whether radar detection is enabled
@@ -1272,6 +1273,7 @@ enum ieee80211_smps_mode { @@ -1302,6 +1303,7 @@ enum ieee80211_smps_mode {
struct ieee80211_conf { struct ieee80211_conf {
u32 flags; u32 flags;
int power_level, dynamic_ps_timeout; int power_level, dynamic_ps_timeout;
@ -57,7 +57,7 @@
__NL80211_ATTR_AFTER_LAST, __NL80211_ATTR_AFTER_LAST,
--- a/net/mac80211/cfg.c --- a/net/mac80211/cfg.c
+++ b/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c
@@ -2201,6 +2201,19 @@ static int ieee80211_get_tx_power(struct @@ -2229,6 +2229,19 @@ static int ieee80211_get_tx_power(struct
return 0; return 0;
} }
@ -77,7 +77,7 @@
static int ieee80211_set_wds_peer(struct wiphy *wiphy, struct net_device *dev, static int ieee80211_set_wds_peer(struct wiphy *wiphy, struct net_device *dev,
const u8 *addr) const u8 *addr)
{ {
@@ -3375,6 +3388,7 @@ const struct cfg80211_ops mac80211_confi @@ -3403,6 +3416,7 @@ const struct cfg80211_ops mac80211_confi
.set_wiphy_params = ieee80211_set_wiphy_params, .set_wiphy_params = ieee80211_set_wiphy_params,
.set_tx_power = ieee80211_set_tx_power, .set_tx_power = ieee80211_set_tx_power,
.get_tx_power = ieee80211_get_tx_power, .get_tx_power = ieee80211_get_tx_power,
@ -119,7 +119,7 @@
if (local->hw.conf.power_level != power) { if (local->hw.conf.power_level != power) {
changed |= IEEE80211_CONF_CHANGE_POWER; changed |= IEEE80211_CONF_CHANGE_POWER;
local->hw.conf.power_level = power; local->hw.conf.power_level = power;
@@ -580,6 +586,7 @@ struct ieee80211_hw *ieee80211_alloc_hw_ @@ -586,6 +592,7 @@ struct ieee80211_hw *ieee80211_alloc_hw_
IEEE80211_RADIOTAP_MCS_HAVE_BW; IEEE80211_RADIOTAP_MCS_HAVE_BW;
local->hw.radiotap_vht_details = IEEE80211_RADIOTAP_VHT_KNOWN_GI | local->hw.radiotap_vht_details = IEEE80211_RADIOTAP_VHT_KNOWN_GI |
IEEE80211_RADIOTAP_VHT_KNOWN_BANDWIDTH; IEEE80211_RADIOTAP_VHT_KNOWN_BANDWIDTH;

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath9k/ath9k.h --- a/drivers/net/wireless/ath/ath9k/ath9k.h
+++ b/drivers/net/wireless/ath/ath9k/ath9k.h +++ b/drivers/net/wireless/ath/ath9k/ath9k.h
@@ -813,6 +813,9 @@ static inline int ath9k_dump_btcoex(stru @@ -814,6 +814,9 @@ static inline int ath9k_dump_btcoex(stru
void ath_init_leds(struct ath_softc *sc); void ath_init_leds(struct ath_softc *sc);
void ath_deinit_leds(struct ath_softc *sc); void ath_deinit_leds(struct ath_softc *sc);
void ath_fill_led_pin(struct ath_softc *sc); void ath_fill_led_pin(struct ath_softc *sc);
@ -10,7 +10,7 @@
#else #else
static inline void ath_init_leds(struct ath_softc *sc) static inline void ath_init_leds(struct ath_softc *sc)
{ {
@@ -952,6 +955,13 @@ void ath_ant_comb_scan(struct ath_softc @@ -953,6 +956,13 @@ void ath_ant_comb_scan(struct ath_softc
#define ATH9K_NUM_CHANCTX 2 /* supports 2 operating channels */ #define ATH9K_NUM_CHANCTX 2 /* supports 2 operating channels */
@ -24,7 +24,7 @@
struct ath_softc { struct ath_softc {
struct ieee80211_hw *hw; struct ieee80211_hw *hw;
struct device *dev; struct device *dev;
@@ -1003,9 +1013,8 @@ struct ath_softc { @@ -1005,9 +1015,8 @@ struct ath_softc {
spinlock_t chan_lock; spinlock_t chan_lock;
#ifdef CPTCFG_MAC80211_LEDS #ifdef CPTCFG_MAC80211_LEDS
@ -165,7 +165,7 @@
void ath_fill_led_pin(struct ath_softc *sc) void ath_fill_led_pin(struct ath_softc *sc)
--- a/drivers/net/wireless/ath/ath9k/init.c --- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -950,7 +950,7 @@ int ath9k_init_device(u16 devid, struct @@ -951,7 +951,7 @@ int ath9k_init_device(u16 devid, struct
#ifdef CPTCFG_MAC80211_LEDS #ifdef CPTCFG_MAC80211_LEDS
/* must be initialized before ieee80211_register_hw */ /* must be initialized before ieee80211_register_hw */

View file

@ -10,7 +10,7 @@
int (*external_reset)(void); int (*external_reset)(void);
--- a/drivers/net/wireless/ath/ath9k/init.c --- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -577,6 +577,7 @@ static int ath9k_init_softc(u16 devid, struct ath_softc *sc, @@ -577,6 +577,7 @@ static int ath9k_init_softc(u16 devid, s
ah->external_reset = pdata->external_reset; ah->external_reset = pdata->external_reset;
ah->disable_2ghz = pdata->disable_2ghz; ah->disable_2ghz = pdata->disable_2ghz;
ah->disable_5ghz = pdata->disable_5ghz; ah->disable_5ghz = pdata->disable_5ghz;

View file

@ -94,7 +94,7 @@
struct ath_gen_timer *ath_gen_timer_alloc(struct ath_hw *ah, struct ath_gen_timer *ath_gen_timer_alloc(struct ath_hw *ah,
--- a/drivers/net/wireless/ath/ath9k/hw.c --- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -1809,6 +1809,20 @@ u32 ath9k_hw_get_tsf_offset(struct times @@ -1819,6 +1819,20 @@ u32 ath9k_hw_get_tsf_offset(struct times
} }
EXPORT_SYMBOL(ath9k_hw_get_tsf_offset); EXPORT_SYMBOL(ath9k_hw_get_tsf_offset);
@ -115,7 +115,7 @@
int ath9k_hw_reset(struct ath_hw *ah, struct ath9k_channel *chan, int ath9k_hw_reset(struct ath_hw *ah, struct ath9k_channel *chan,
struct ath9k_hw_cal_data *caldata, bool fastcc) struct ath9k_hw_cal_data *caldata, bool fastcc)
{ {
@@ -2017,6 +2031,7 @@ int ath9k_hw_reset(struct ath_hw *ah, st @@ -2027,6 +2041,7 @@ int ath9k_hw_reset(struct ath_hw *ah, st
ar9003_hw_disable_phy_restart(ah); ar9003_hw_disable_phy_restart(ah);
ath9k_hw_apply_gpio_override(ah); ath9k_hw_apply_gpio_override(ah);

View file

@ -65,7 +65,7 @@
} }
static const struct ieee80211_iface_limit if_limits[] = { static const struct ieee80211_iface_limit if_limits[] = {
@@ -911,6 +912,18 @@ static void ath9k_set_hw_capab(struct at @@ -912,6 +913,18 @@ static void ath9k_set_hw_capab(struct at
SET_IEEE80211_PERM_ADDR(hw, common->macaddr); SET_IEEE80211_PERM_ADDR(hw, common->macaddr);
} }
@ -84,7 +84,7 @@
int ath9k_init_device(u16 devid, struct ath_softc *sc, int ath9k_init_device(u16 devid, struct ath_softc *sc,
const struct ath_bus_ops *bus_ops) const struct ath_bus_ops *bus_ops)
{ {
@@ -956,6 +969,8 @@ int ath9k_init_device(u16 devid, struct @@ -957,6 +970,8 @@ int ath9k_init_device(u16 devid, struct
ARRAY_SIZE(ath9k_tpt_blink)); ARRAY_SIZE(ath9k_tpt_blink));
#endif #endif

View file

@ -20,7 +20,7 @@
/******************/ /******************/
/* Chip Revisions */ /* Chip Revisions */
/******************/ /******************/
@@ -1387,6 +1400,9 @@ static bool ath9k_hw_set_reset(struct at @@ -1397,6 +1410,9 @@ static bool ath9k_hw_set_reset(struct at
if (AR_SREV_9100(ah)) if (AR_SREV_9100(ah))
udelay(50); udelay(50);
@ -30,7 +30,7 @@
return true; return true;
} }
@@ -1486,6 +1502,9 @@ static bool ath9k_hw_chip_reset(struct a @@ -1496,6 +1512,9 @@ static bool ath9k_hw_chip_reset(struct a
ar9003_hw_internal_regulator_apply(ah); ar9003_hw_internal_regulator_apply(ah);
ath9k_hw_init_pll(ah, chan); ath9k_hw_init_pll(ah, chan);
@ -40,7 +40,7 @@
return true; return true;
} }
@@ -1787,8 +1806,14 @@ static int ath9k_hw_do_fastcc(struct ath @@ -1797,8 +1816,14 @@ static int ath9k_hw_do_fastcc(struct ath
if (AR_SREV_9271(ah)) if (AR_SREV_9271(ah))
ar9002_hw_load_ani_reg(ah, chan); ar9002_hw_load_ani_reg(ah, chan);
@ -55,7 +55,7 @@
return -EINVAL; return -EINVAL;
} }
@@ -2042,6 +2067,9 @@ int ath9k_hw_reset(struct ath_hw *ah, st @@ -2052,6 +2077,9 @@ int ath9k_hw_reset(struct ath_hw *ah, st
ath9k_hw_set_radar_params(ah); ath9k_hw_set_radar_params(ah);
} }

View file

@ -24,7 +24,7 @@ Changes since v1:
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7721,6 +7721,7 @@ static int rt2800_probe_rt(struct rt2x00 @@ -7722,6 +7722,7 @@ static int rt2800_probe_rt(struct rt2x00
int rt2800_probe_hw(struct rt2x00_dev *rt2x00dev) int rt2800_probe_hw(struct rt2x00_dev *rt2x00dev)
{ {
@ -32,7 +32,7 @@ Changes since v1:
int retval; int retval;
u32 reg; u32 reg;
@@ -7728,6 +7729,9 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -7729,6 +7730,9 @@ int rt2800_probe_hw(struct rt2x00_dev *r
if (retval) if (retval)
return retval; return retval;

View file

@ -187,7 +187,7 @@ Changes since v1: ---
} }
/* /*
@@ -4884,14 +4917,19 @@ static int rt2800_init_registers(struct @@ -4885,14 +4918,19 @@ static int rt2800_init_registers(struct
/* /*
* ASIC will keep garbage value after boot, clear encryption keys. * ASIC will keep garbage value after boot, clear encryption keys.
*/ */
@ -207,7 +207,7 @@ Changes since v1: ---
} }
/* /*
@@ -5017,8 +5055,10 @@ static int rt2800_wait_bbp_ready(struct @@ -5018,8 +5056,10 @@ static int rt2800_wait_bbp_ready(struct
* BBP was enabled after firmware was loaded, * BBP was enabled after firmware was loaded,
* but we need to reactivate it now. * but we need to reactivate it now.
*/ */
@ -218,7 +218,7 @@ Changes since v1: ---
msleep(1); msleep(1);
for (i = 0; i < REGISTER_BUSY_COUNT; i++) { for (i = 0; i < REGISTER_BUSY_COUNT; i++) {
@@ -6714,11 +6754,19 @@ int rt2800_enable_radio(struct rt2x00_de @@ -6715,11 +6755,19 @@ int rt2800_enable_radio(struct rt2x00_de
/* /*
* Send signal during boot time to initialize firmware. * Send signal during boot time to initialize firmware.
*/ */
@ -239,7 +239,7 @@ Changes since v1: ---
msleep(1); msleep(1);
/* /*
@@ -7725,6 +7773,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -7726,6 +7774,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r
int retval; int retval;
u32 reg; u32 reg;
@ -248,7 +248,7 @@ Changes since v1: ---
retval = rt2800_probe_rt(rt2x00dev); retval = rt2800_probe_rt(rt2x00dev);
if (retval) if (retval)
return retval; return retval;
@@ -7808,8 +7858,11 @@ void rt2800_get_key_seq(struct ieee80211 @@ -7809,8 +7859,11 @@ void rt2800_get_key_seq(struct ieee80211
return; return;
offset = MAC_IVEIV_ENTRY(key->hw_key_idx); offset = MAC_IVEIV_ENTRY(key->hw_key_idx);

View file

@ -24,7 +24,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4614,6 +4614,7 @@ EXPORT_SYMBOL_GPL(rt2800_link_tuner); @@ -4615,6 +4615,7 @@ EXPORT_SYMBOL_GPL(rt2800_link_tuner);
*/ */
static int rt2800_init_registers(struct rt2x00_dev *rt2x00dev) static int rt2800_init_registers(struct rt2x00_dev *rt2x00dev)
{ {
@ -32,7 +32,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
u32 reg; u32 reg;
u16 eeprom; u16 eeprom;
unsigned int i; unsigned int i;
@@ -4979,7 +4980,7 @@ static int rt2800_init_registers(struct @@ -4980,7 +4981,7 @@ static int rt2800_init_registers(struct
/* /*
* Clear all beacons * Clear all beacons
*/ */
@ -41,7 +41,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2800_clear_beacon_register(rt2x00dev, i); rt2800_clear_beacon_register(rt2x00dev, i);
if (rt2x00_is_usb(rt2x00dev)) { if (rt2x00_is_usb(rt2x00dev)) {
@@ -7826,6 +7827,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -7827,6 +7828,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r
if (rt2x00_rt(rt2x00dev, RT3593)) if (rt2x00_rt(rt2x00dev, RT3593))
__set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags); __set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags);

View file

@ -34,7 +34,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
*/ */
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4626,6 +4626,30 @@ static int rt2800_init_registers(struct @@ -4627,6 +4627,30 @@ static int rt2800_init_registers(struct
if (ret) if (ret)
return ret; return ret;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7851,7 +7851,10 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -7852,7 +7852,10 @@ int rt2800_probe_hw(struct rt2x00_dev *r
if (rt2x00_rt(rt2x00dev, RT3593)) if (rt2x00_rt(rt2x00dev, RT3593))
__set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags); __set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7821,6 +7821,7 @@ static int rt2800_probe_rt(struct rt2x00 @@ -7822,6 +7822,7 @@ static int rt2800_probe_rt(struct rt2x00
case RT3390: case RT3390:
case RT3572: case RT3572:
case RT3593: case RT3593:

View file

@ -31,7 +31,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
#define RF5370 0x5370 #define RF5370 0x5370
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7441,6 +7441,66 @@ static const struct rf_channel rf_vals_3 @@ -7442,6 +7442,66 @@ static const struct rf_channel rf_vals_3
{173, 0x61, 0, 9}, {173, 0x61, 0, 9},
}; };
@ -98,7 +98,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
static const struct rf_channel rf_vals_5592_xtal20[] = { static const struct rf_channel rf_vals_5592_xtal20[] = {
/* Channel, N, K, mod, R */ /* Channel, N, K, mod, R */
{1, 482, 4, 10, 3}, {1, 482, 4, 10, 3},
@@ -7668,6 +7728,11 @@ static int rt2800_probe_hw_mode(struct r @@ -7669,6 +7729,11 @@ static int rt2800_probe_hw_mode(struct r
spec->channels = rf_vals_3x; spec->channels = rf_vals_3x;
break; break;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4378,6 +4378,7 @@ void rt2800_vco_calibration(struct rt2x0 @@ -4379,6 +4379,7 @@ void rt2800_vco_calibration(struct rt2x0
case RF3053: case RF3053:
case RF3070: case RF3070:
case RF3290: case RF3290:
@ -18,7 +18,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -7847,6 +7848,7 @@ static int rt2800_probe_hw_mode(struct r @@ -7848,6 +7849,7 @@ static int rt2800_probe_hw_mode(struct r
case RF3053: case RF3053:
case RF3070: case RF3070:
case RF3290: case RF3290:

View file

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -2625,6 +2625,211 @@ static void rt2800_config_channel_rf3053 @@ -2626,6 +2626,211 @@ static void rt2800_config_channel_rf3053
} }
} }
@ -223,7 +223,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
#define POWER_BOUND 0x27 #define POWER_BOUND 0x27
#define POWER_BOUND_5G 0x2b #define POWER_BOUND_5G 0x2b
@@ -3237,6 +3442,9 @@ static void rt2800_config_channel(struct @@ -3238,6 +3443,9 @@ static void rt2800_config_channel(struct
case RF3322: case RF3322:
rt2800_config_channel_rf3322(rt2x00dev, conf, rf, info); rt2800_config_channel_rf3322(rt2x00dev, conf, rf, info);
break; break;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7406,6 +7406,7 @@ static int rt2800_init_eeprom(struct rt2 @@ -7407,6 +7407,7 @@ static int rt2800_init_eeprom(struct rt2
case RF3290: case RF3290:
case RF3320: case RF3320:
case RF3322: case RF3322:

View file

@ -35,7 +35,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
#define RX_FILTER_CFG 0x1400 #define RX_FILTER_CFG 0x1400
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4981,6 +4981,12 @@ static int rt2800_init_registers(struct @@ -4982,6 +4982,12 @@ static int rt2800_init_registers(struct
rt2800_register_write(rt2x00dev, TX_SW_CFG2, rt2800_register_write(rt2x00dev, TX_SW_CFG2,
0x00000000); 0x00000000);
} }
@ -48,7 +48,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
} else if (rt2x00_rt(rt2x00dev, RT5390) || } else if (rt2x00_rt(rt2x00dev, RT5390) ||
rt2x00_rt(rt2x00dev, RT5392) || rt2x00_rt(rt2x00dev, RT5392) ||
rt2x00_rt(rt2x00dev, RT5592)) { rt2x00_rt(rt2x00dev, RT5592)) {
@@ -5011,9 +5017,11 @@ static int rt2800_init_registers(struct @@ -5012,9 +5018,11 @@ static int rt2800_init_registers(struct
rt2800_register_read(rt2x00dev, MAX_LEN_CFG, &reg); rt2800_register_read(rt2x00dev, MAX_LEN_CFG, &reg);
rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_MPDU, AGGREGATION_SIZE); rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_MPDU, AGGREGATION_SIZE);
@ -63,7 +63,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_PSDU, 2); rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_PSDU, 2);
else else
rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_PSDU, 1); rt2x00_set_field32(&reg, MAX_LEN_CFG_MAX_PSDU, 1);
@@ -5166,6 +5174,11 @@ static int rt2800_init_registers(struct @@ -5167,6 +5175,11 @@ static int rt2800_init_registers(struct
reg = rt2x00_rt(rt2x00dev, RT5592) ? 0x00000082 : 0x00000002; reg = rt2x00_rt(rt2x00dev, RT5592) ? 0x00000082 : 0x00000002;
rt2800_register_write(rt2x00dev, TXOP_HLDR_ET, reg); rt2800_register_write(rt2x00dev, TXOP_HLDR_ET, reg);

View file

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -5784,6 +5784,47 @@ static void rt2800_init_bbp_3593(struct @@ -5785,6 +5785,47 @@ static void rt2800_init_bbp_3593(struct
rt2800_bbp_write(rt2x00dev, 103, 0xc0); rt2800_bbp_write(rt2x00dev, 103, 0xc0);
} }
@ -59,7 +59,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
static void rt2800_init_bbp_53xx(struct rt2x00_dev *rt2x00dev) static void rt2800_init_bbp_53xx(struct rt2x00_dev *rt2x00dev)
{ {
int ant, div_mode; int ant, div_mode;
@@ -6002,6 +6043,9 @@ static void rt2800_init_bbp(struct rt2x0 @@ -6003,6 +6044,9 @@ static void rt2800_init_bbp(struct rt2x0
case RT3593: case RT3593:
rt2800_init_bbp_3593(rt2x00dev); rt2800_init_bbp_3593(rt2x00dev);
return; return;

View file

@ -21,7 +21,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
/* /*
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -6819,6 +6819,144 @@ static void rt2800_init_rfcsr_3593(struc @@ -6820,6 +6820,144 @@ static void rt2800_init_rfcsr_3593(struc
/* TODO: enable stream mode support */ /* TODO: enable stream mode support */
} }
@ -166,7 +166,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
static void rt2800_init_rfcsr_5390(struct rt2x00_dev *rt2x00dev) static void rt2800_init_rfcsr_5390(struct rt2x00_dev *rt2x00dev)
{ {
rt2800_rf_init_calibration(rt2x00dev, 2); rt2800_rf_init_calibration(rt2x00dev, 2);
@@ -7050,6 +7188,9 @@ static void rt2800_init_rfcsr(struct rt2 @@ -7051,6 +7189,9 @@ static void rt2800_init_rfcsr(struct rt2
case RT3390: case RT3390:
rt2800_init_rfcsr_3390(rt2x00dev); rt2800_init_rfcsr_3390(rt2x00dev);
break; break;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7587,6 +7587,8 @@ static int rt2800_init_eeprom(struct rt2 @@ -7588,6 +7588,8 @@ static int rt2800_init_eeprom(struct rt2
rt2x00_rt(rt2x00dev, RT5390) || rt2x00_rt(rt2x00dev, RT5390) ||
rt2x00_rt(rt2x00dev, RT5392)) rt2x00_rt(rt2x00dev, RT5392))
rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf); rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3405,6 +3405,36 @@ static char rt2800_txpower_to_dev(struct @@ -3406,6 +3406,36 @@ static char rt2800_txpower_to_dev(struct
return clamp_t(char, txpower, MIN_A_TXPOWER, MAX_A_TXPOWER); return clamp_t(char, txpower, MIN_A_TXPOWER, MAX_A_TXPOWER);
} }
@ -47,7 +47,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev, static void rt2800_config_channel(struct rt2x00_dev *rt2x00dev,
struct ieee80211_conf *conf, struct ieee80211_conf *conf,
struct rf_channel *rf, struct rf_channel *rf,
@@ -3423,6 +3453,12 @@ static void rt2800_config_channel(struct @@ -3424,6 +3454,12 @@ static void rt2800_config_channel(struct
rt2800_txpower_to_dev(rt2x00dev, rf->channel, rt2800_txpower_to_dev(rt2x00dev, rf->channel,
info->default_power3); info->default_power3);
@ -60,7 +60,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
switch (rt2x00dev->chip.rf) { switch (rt2x00dev->chip.rf) {
case RF2020: case RF2020:
case RF3020: case RF3020:
@@ -3506,6 +3542,15 @@ static void rt2800_config_channel(struct @@ -3507,6 +3543,15 @@ static void rt2800_config_channel(struct
rt2800_bbp_write(rt2x00dev, 63, 0x37 - rt2x00dev->lna_gain); rt2800_bbp_write(rt2x00dev, 63, 0x37 - rt2x00dev->lna_gain);
rt2800_bbp_write(rt2x00dev, 64, 0x37 - rt2x00dev->lna_gain); rt2800_bbp_write(rt2x00dev, 64, 0x37 - rt2x00dev->lna_gain);
rt2800_bbp_write(rt2x00dev, 77, 0x98); rt2800_bbp_write(rt2x00dev, 77, 0x98);
@ -76,7 +76,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
} else { } else {
rt2800_bbp_write(rt2x00dev, 62, 0x37 - rt2x00dev->lna_gain); rt2800_bbp_write(rt2x00dev, 62, 0x37 - rt2x00dev->lna_gain);
rt2800_bbp_write(rt2x00dev, 63, 0x37 - rt2x00dev->lna_gain); rt2800_bbp_write(rt2x00dev, 63, 0x37 - rt2x00dev->lna_gain);
@@ -3518,6 +3563,7 @@ static void rt2800_config_channel(struct @@ -3519,6 +3564,7 @@ static void rt2800_config_channel(struct
!rt2x00_rt(rt2x00dev, RT5392)) { !rt2x00_rt(rt2x00dev, RT5392)) {
if (rt2x00_has_cap_external_lna_bg(rt2x00dev)) { if (rt2x00_has_cap_external_lna_bg(rt2x00dev)) {
rt2800_bbp_write(rt2x00dev, 82, 0x62); rt2800_bbp_write(rt2x00dev, 82, 0x62);
@ -84,7 +84,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2800_bbp_write(rt2x00dev, 75, 0x46); rt2800_bbp_write(rt2x00dev, 75, 0x46);
} else { } else {
if (rt2x00_rt(rt2x00dev, RT3593)) if (rt2x00_rt(rt2x00dev, RT3593))
@@ -3526,19 +3572,22 @@ static void rt2800_config_channel(struct @@ -3527,19 +3573,22 @@ static void rt2800_config_channel(struct
rt2800_bbp_write(rt2x00dev, 82, 0x84); rt2800_bbp_write(rt2x00dev, 82, 0x84);
rt2800_bbp_write(rt2x00dev, 75, 0x50); rt2800_bbp_write(rt2x00dev, 75, 0x50);
} }
@ -110,7 +110,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2800_bbp_write(rt2x00dev, 83, 0x9a); rt2800_bbp_write(rt2x00dev, 83, 0x9a);
if (rt2x00_has_cap_external_lna_a(rt2x00dev)) if (rt2x00_has_cap_external_lna_a(rt2x00dev))
@@ -3660,6 +3709,23 @@ static void rt2800_config_channel(struct @@ -3661,6 +3710,23 @@ static void rt2800_config_channel(struct
rt2800_bbp_write_with_rx_chain(rt2x00dev, 66, reg); rt2800_bbp_write_with_rx_chain(rt2x00dev, 66, reg);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3392,13 +3392,15 @@ static char rt2800_txpower_to_dev(struct @@ -3393,13 +3393,15 @@ static char rt2800_txpower_to_dev(struct
unsigned int channel, unsigned int channel,
char txpower) char txpower)
{ {

View file

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4611,7 +4611,8 @@ static void rt2800_config_txpower(struct @@ -4612,7 +4612,8 @@ static void rt2800_config_txpower(struct
struct ieee80211_channel *chan, struct ieee80211_channel *chan,
int power_level) int power_level)
{ {

View file

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7469,7 +7469,8 @@ static u8 rt2800_get_txmixer_gain_24g(st @@ -7470,7 +7470,8 @@ static u8 rt2800_get_txmixer_gain_24g(st
{ {
u16 word; u16 word;
@ -21,7 +21,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
return 0; return 0;
rt2800_eeprom_read(rt2x00dev, EEPROM_TXMIXER_GAIN_BG, &word); rt2800_eeprom_read(rt2x00dev, EEPROM_TXMIXER_GAIN_BG, &word);
@@ -7483,7 +7484,8 @@ static u8 rt2800_get_txmixer_gain_5g(str @@ -7484,7 +7485,8 @@ static u8 rt2800_get_txmixer_gain_5g(str
{ {
u16 word; u16 word;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -8402,7 +8402,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -8403,7 +8403,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r
if (rt2x00_rt(rt2x00dev, RT3593)) if (rt2x00_rt(rt2x00dev, RT3593))
__set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags); __set_bit(RT2800_HAS_HIGH_SHARED_MEM, &drv_data->rt2800_flags);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -1937,7 +1937,8 @@ void rt2800_config_ant(struct rt2x00_dev @@ -1938,7 +1938,8 @@ void rt2800_config_ant(struct rt2x00_dev
rt2800_bbp_write(rt2x00dev, 3, r3); rt2800_bbp_write(rt2x00dev, 3, r3);
rt2800_bbp_write(rt2x00dev, 1, r1); rt2800_bbp_write(rt2x00dev, 1, r1);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -1960,7 +1960,8 @@ static void rt2800_config_lna_gain(struc @@ -1961,7 +1961,8 @@ static void rt2800_config_lna_gain(struc
rt2800_eeprom_read(rt2x00dev, EEPROM_LNA, &eeprom); rt2800_eeprom_read(rt2x00dev, EEPROM_LNA, &eeprom);
lna_gain = rt2x00_get_field16(eeprom, EEPROM_LNA_A0); lna_gain = rt2x00_get_field16(eeprom, EEPROM_LNA_A0);
} else if (libconf->rf.channel <= 128) { } else if (libconf->rf.channel <= 128) {
@ -20,7 +20,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2800_eeprom_read(rt2x00dev, EEPROM_EXT_LNA2, &eeprom); rt2800_eeprom_read(rt2x00dev, EEPROM_EXT_LNA2, &eeprom);
lna_gain = rt2x00_get_field16(eeprom, lna_gain = rt2x00_get_field16(eeprom,
EEPROM_EXT_LNA2_A1); EEPROM_EXT_LNA2_A1);
@@ -1970,7 +1971,8 @@ static void rt2800_config_lna_gain(struc @@ -1971,7 +1972,8 @@ static void rt2800_config_lna_gain(struc
EEPROM_RSSI_BG2_LNA_A1); EEPROM_RSSI_BG2_LNA_A1);
} }
} else { } else {

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -4811,7 +4811,8 @@ static u8 rt2800_get_default_vgc(struct @@ -4812,7 +4812,8 @@ static u8 rt2800_get_default_vgc(struct
else else
vgc = 0x2e + rt2x00dev->lna_gain; vgc = 0x2e + rt2x00dev->lna_gain;
} else { /* 5GHZ band */ } else { /* 5GHZ band */
@ -20,7 +20,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
vgc = 0x20 + (rt2x00dev->lna_gain * 5) / 3; vgc = 0x20 + (rt2x00dev->lna_gain * 5) / 3;
else if (rt2x00_rt(rt2x00dev, RT5592)) else if (rt2x00_rt(rt2x00dev, RT5592))
vgc = 0x24 + (2 * rt2x00dev->lna_gain); vgc = 0x24 + (2 * rt2x00dev->lna_gain);
@@ -4831,7 +4832,8 @@ static inline void rt2800_set_vgc(struct @@ -4832,7 +4833,8 @@ static inline void rt2800_set_vgc(struct
{ {
if (qual->vgc_level != vgc_level) { if (qual->vgc_level != vgc_level) {
if (rt2x00_rt(rt2x00dev, RT3572) || if (rt2x00_rt(rt2x00dev, RT3572) ||
@ -30,7 +30,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
rt2800_bbp_write_with_rx_chain(rt2x00dev, 66, rt2800_bbp_write_with_rx_chain(rt2x00dev, 66,
vgc_level); vgc_level);
} else if (rt2x00_rt(rt2x00dev, RT5592)) { } else if (rt2x00_rt(rt2x00dev, RT5592)) {
@@ -4878,6 +4880,11 @@ void rt2800_link_tuner(struct rt2x00_dev @@ -4879,6 +4881,11 @@ void rt2800_link_tuner(struct rt2x00_dev
} }
break; break;

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7606,7 +7606,8 @@ static int rt2800_validate_eeprom(struct @@ -7607,7 +7607,8 @@ static int rt2800_validate_eeprom(struct
rt2800_eeprom_read(rt2x00dev, EEPROM_RSSI_BG2, &word); rt2800_eeprom_read(rt2x00dev, EEPROM_RSSI_BG2, &word);
if (abs(rt2x00_get_field16(word, EEPROM_RSSI_BG2_OFFSET2)) > 10) if (abs(rt2x00_get_field16(word, EEPROM_RSSI_BG2_OFFSET2)) > 10)
rt2x00_set_field16(&word, EEPROM_RSSI_BG2_OFFSET2, 0); rt2x00_set_field16(&word, EEPROM_RSSI_BG2_OFFSET2, 0);
@ -20,7 +20,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
if (rt2x00_get_field16(word, EEPROM_RSSI_BG2_LNA_A1) == 0x00 || if (rt2x00_get_field16(word, EEPROM_RSSI_BG2_LNA_A1) == 0x00 ||
rt2x00_get_field16(word, EEPROM_RSSI_BG2_LNA_A1) == 0xff) rt2x00_get_field16(word, EEPROM_RSSI_BG2_LNA_A1) == 0xff)
rt2x00_set_field16(&word, EEPROM_RSSI_BG2_LNA_A1, rt2x00_set_field16(&word, EEPROM_RSSI_BG2_LNA_A1,
@@ -7626,7 +7627,8 @@ static int rt2800_validate_eeprom(struct @@ -7627,7 +7628,8 @@ static int rt2800_validate_eeprom(struct
rt2800_eeprom_read(rt2x00dev, EEPROM_RSSI_A2, &word); rt2800_eeprom_read(rt2x00dev, EEPROM_RSSI_A2, &word);
if (abs(rt2x00_get_field16(word, EEPROM_RSSI_A2_OFFSET2)) > 10) if (abs(rt2x00_get_field16(word, EEPROM_RSSI_A2_OFFSET2)) > 10)
rt2x00_set_field16(&word, EEPROM_RSSI_A2_OFFSET2, 0); rt2x00_set_field16(&word, EEPROM_RSSI_A2_OFFSET2, 0);
@ -30,7 +30,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
if (rt2x00_get_field16(word, EEPROM_RSSI_A2_LNA_A2) == 0x00 || if (rt2x00_get_field16(word, EEPROM_RSSI_A2_LNA_A2) == 0x00 ||
rt2x00_get_field16(word, EEPROM_RSSI_A2_LNA_A2) == 0xff) rt2x00_get_field16(word, EEPROM_RSSI_A2_LNA_A2) == 0xff)
rt2x00_set_field16(&word, EEPROM_RSSI_A2_LNA_A2, rt2x00_set_field16(&word, EEPROM_RSSI_A2_LNA_A2,
@@ -7634,7 +7636,8 @@ static int rt2800_validate_eeprom(struct @@ -7635,7 +7637,8 @@ static int rt2800_validate_eeprom(struct
} }
rt2800_eeprom_write(rt2x00dev, EEPROM_RSSI_A2, word); rt2800_eeprom_write(rt2x00dev, EEPROM_RSSI_A2, word);

View file

@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3981,6 +3981,9 @@ static u8 rt2800_compensate_txpower(stru @@ -3982,6 +3982,9 @@ static u8 rt2800_compensate_txpower(stru
if (rt2x00_rt(rt2x00dev, RT3593)) if (rt2x00_rt(rt2x00dev, RT3593))
return min_t(u8, txpower, 0xc); return min_t(u8, txpower, 0xc);

View file

@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -8415,7 +8415,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -8416,7 +8416,8 @@ int rt2800_probe_hw(struct rt2x00_dev *r
if (retval) if (retval)
return retval; return retval;

View file

@ -122,7 +122,7 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
*/ */
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h
@@ -989,6 +989,11 @@ struct rt2x00_dev { @@ -991,6 +991,11 @@ struct rt2x00_dev {
int rf_channel; int rf_channel;
/* /*

View file

@ -113,7 +113,7 @@
/* /*
* Capabilities * Capabilities
@@ -966,6 +967,11 @@ struct rt2x00_dev { @@ -968,6 +969,11 @@ struct rt2x00_dev {
const struct firmware *fw; const struct firmware *fw;
/* /*
@ -127,7 +127,7 @@
DECLARE_KFIFO_PTR(txstatus_fifo, u32); DECLARE_KFIFO_PTR(txstatus_fifo, u32);
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c --- a/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
@@ -1334,6 +1334,10 @@ int rt2x00lib_probe_dev(struct rt2x00_de @@ -1335,6 +1335,10 @@ int rt2x00lib_probe_dev(struct rt2x00_de
INIT_DELAYED_WORK(&rt2x00dev->autowakeup_work, rt2x00lib_autowakeup); INIT_DELAYED_WORK(&rt2x00dev->autowakeup_work, rt2x00lib_autowakeup);
INIT_WORK(&rt2x00dev->sleep_work, rt2x00lib_sleep); INIT_WORK(&rt2x00dev->sleep_work, rt2x00lib_sleep);
@ -138,7 +138,7 @@
/* /*
* Let the driver probe the device to detect the capabilities. * Let the driver probe the device to detect the capabilities.
*/ */
@@ -1474,6 +1478,11 @@ void rt2x00lib_remove_dev(struct rt2x00_ @@ -1475,6 +1479,11 @@ void rt2x00lib_remove_dev(struct rt2x00_
* Free the driver data. * Free the driver data.
*/ */
kfree(rt2x00dev->drv_data); kfree(rt2x00dev->drv_data);

View file

@ -31,7 +31,7 @@
{ {
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h --- a/drivers/net/wireless/ralink/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00.h
@@ -1412,6 +1412,7 @@ static inline void rt2x00debug_dump_fram @@ -1414,6 +1414,7 @@ static inline void rt2x00debug_dump_fram
*/ */
u32 rt2x00lib_get_bssidx(struct rt2x00_dev *rt2x00dev, u32 rt2x00lib_get_bssidx(struct rt2x00_dev *rt2x00dev,
struct ieee80211_vif *vif); struct ieee80211_vif *vif);
@ -41,7 +41,7 @@
* Interrupt context handlers. * Interrupt context handlers.
--- a/drivers/net/wireless/ralink/rt2x00/rt61pci.c --- a/drivers/net/wireless/ralink/rt2x00/rt61pci.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt61pci.c +++ b/drivers/net/wireless/ralink/rt2x00/rt61pci.c
@@ -2390,6 +2390,7 @@ static int rt61pci_validate_eeprom(struc @@ -2392,6 +2392,7 @@ static int rt61pci_validate_eeprom(struc
u32 reg; u32 reg;
u16 word; u16 word;
u8 *mac; u8 *mac;
@ -49,7 +49,7 @@
s8 value; s8 value;
rt2x00mmio_register_read(rt2x00dev, E2PROM_CSR, &reg); rt2x00mmio_register_read(rt2x00dev, E2PROM_CSR, &reg);
@@ -2410,7 +2411,11 @@ static int rt61pci_validate_eeprom(struc @@ -2412,7 +2413,11 @@ static int rt61pci_validate_eeprom(struc
/* /*
* Start validation of the data that has been read. * Start validation of the data that has been read.
*/ */

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3528,11 +3528,18 @@ static void rt2800_config_channel(struct @@ -3529,11 +3529,18 @@ static void rt2800_config_channel(struct
/* /*
* Change BBP settings * Change BBP settings
*/ */
@ -19,7 +19,7 @@
} else if (rt2x00_rt(rt2x00dev, RT3593)) { } else if (rt2x00_rt(rt2x00dev, RT3593)) {
if (rf->channel > 14) { if (rf->channel > 14) {
/* Disable CCK Packet detection on 5GHz */ /* Disable CCK Packet detection on 5GHz */
@@ -6594,6 +6601,12 @@ static void rt2800_init_rfcsr_3290(struc @@ -6595,6 +6602,12 @@ static void rt2800_init_rfcsr_3290(struc
static void rt2800_init_rfcsr_3352(struct rt2x00_dev *rt2x00dev) static void rt2800_init_rfcsr_3352(struct rt2x00_dev *rt2x00dev)
{ {
@ -32,7 +32,7 @@
rt2800_rf_init_calibration(rt2x00dev, 30); rt2800_rf_init_calibration(rt2x00dev, 30);
rt2800_rfcsr_write(rt2x00dev, 0, 0xf0); rt2800_rfcsr_write(rt2x00dev, 0, 0xf0);
@@ -6629,15 +6642,30 @@ static void rt2800_init_rfcsr_3352(struc @@ -6630,15 +6643,30 @@ static void rt2800_init_rfcsr_3352(struc
rt2800_rfcsr_write(rt2x00dev, 31, 0x80); rt2800_rfcsr_write(rt2x00dev, 31, 0x80);
rt2800_rfcsr_write(rt2x00dev, 32, 0x80); rt2800_rfcsr_write(rt2x00dev, 32, 0x80);
rt2800_rfcsr_write(rt2x00dev, 33, 0x00); rt2800_rfcsr_write(rt2x00dev, 33, 0x00);
@ -66,7 +66,7 @@
rt2800_rfcsr_write(rt2x00dev, 43, 0xdb); rt2800_rfcsr_write(rt2x00dev, 43, 0xdb);
rt2800_rfcsr_write(rt2x00dev, 44, 0xdb); rt2800_rfcsr_write(rt2x00dev, 44, 0xdb);
rt2800_rfcsr_write(rt2x00dev, 45, 0xdb); rt2800_rfcsr_write(rt2x00dev, 45, 0xdb);
@@ -6645,15 +6673,20 @@ static void rt2800_init_rfcsr_3352(struc @@ -6646,15 +6674,20 @@ static void rt2800_init_rfcsr_3352(struc
rt2800_rfcsr_write(rt2x00dev, 47, 0x0d); rt2800_rfcsr_write(rt2x00dev, 47, 0x0d);
rt2800_rfcsr_write(rt2x00dev, 48, 0x14); rt2800_rfcsr_write(rt2x00dev, 48, 0x14);
rt2800_rfcsr_write(rt2x00dev, 49, 0x00); rt2800_rfcsr_write(rt2x00dev, 49, 0x00);
@ -96,7 +96,7 @@
rt2800_rfcsr_write(rt2x00dev, 59, 0x00); rt2800_rfcsr_write(rt2x00dev, 59, 0x00);
rt2800_rfcsr_write(rt2x00dev, 60, 0x00); rt2800_rfcsr_write(rt2x00dev, 60, 0x00);
rt2800_rfcsr_write(rt2x00dev, 61, 0x00); rt2800_rfcsr_write(rt2x00dev, 61, 0x00);
@@ -7674,6 +7707,7 @@ static int rt2800_init_eeprom(struct rt2 @@ -7675,6 +7708,7 @@ static int rt2800_init_eeprom(struct rt2
* RT53xx: defined in "EEPROM_CHIP_ID" field * RT53xx: defined in "EEPROM_CHIP_ID" field
*/ */
if (rt2x00_rt(rt2x00dev, RT3290) || if (rt2x00_rt(rt2x00dev, RT3290) ||
@ -104,7 +104,7 @@
rt2x00_rt(rt2x00dev, RT5390) || rt2x00_rt(rt2x00dev, RT5390) ||
rt2x00_rt(rt2x00dev, RT5392)) rt2x00_rt(rt2x00dev, RT5392))
rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf); rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf);
@@ -7769,7 +7803,8 @@ static int rt2800_init_eeprom(struct rt2 @@ -7770,7 +7804,8 @@ static int rt2800_init_eeprom(struct rt2
/* /*
* Detect if this device has Bluetooth co-existence. * Detect if this device has Bluetooth co-existence.
*/ */
@ -114,7 +114,7 @@
__set_bit(CAPABILITY_BT_COEXIST, &rt2x00dev->cap_flags); __set_bit(CAPABILITY_BT_COEXIST, &rt2x00dev->cap_flags);
/* /*
@@ -7798,6 +7833,22 @@ static int rt2800_init_eeprom(struct rt2 @@ -7799,6 +7834,22 @@ static int rt2800_init_eeprom(struct rt2
EIRP_MAX_TX_POWER_LIMIT) EIRP_MAX_TX_POWER_LIMIT)
__set_bit(CAPABILITY_POWER_LIMIT, &rt2x00dev->cap_flags); __set_bit(CAPABILITY_POWER_LIMIT, &rt2x00dev->cap_flags);

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -8185,6 +8185,27 @@ static const struct rf_channel rf_vals_5 @@ -8186,6 +8186,27 @@ static const struct rf_channel rf_vals_5
{196, 83, 0, 12, 1}, {196, 83, 0, 12, 1},
}; };
@ -28,7 +28,7 @@
static int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev) static int rt2800_probe_hw_mode(struct rt2x00_dev *rt2x00dev)
{ {
struct hw_mode_spec *spec = &rt2x00dev->spec; struct hw_mode_spec *spec = &rt2x00dev->spec;
@@ -8271,7 +8292,10 @@ static int rt2800_probe_hw_mode(struct r @@ -8272,7 +8293,10 @@ static int rt2800_probe_hw_mode(struct r
case RF5390: case RF5390:
case RF5392: case RF5392:
spec->num_channels = 14; spec->num_channels = 14;
@ -40,7 +40,7 @@
break; break;
case RF3052: case RF3052:
@@ -8455,6 +8479,19 @@ static int rt2800_probe_rt(struct rt2x00 @@ -8456,6 +8480,19 @@ static int rt2800_probe_rt(struct rt2x00
return 0; return 0;
} }
@ -60,7 +60,7 @@
int rt2800_probe_hw(struct rt2x00_dev *rt2x00dev) int rt2800_probe_hw(struct rt2x00_dev *rt2x00dev)
{ {
struct rt2800_drv_data *drv_data = rt2x00dev->drv_data; struct rt2800_drv_data *drv_data = rt2x00dev->drv_data;
@@ -8497,6 +8534,15 @@ int rt2800_probe_hw(struct rt2x00_dev *r @@ -8498,6 +8535,15 @@ int rt2800_probe_hw(struct rt2x00_dev *r
rt2800_register_write(rt2x00dev, GPIO_CTRL, reg); rt2800_register_write(rt2x00dev, GPIO_CTRL, reg);
/* /*

View file

@ -8,7 +8,7 @@
#include "rt2x00.h" #include "rt2x00.h"
#include "rt2800lib.h" #include "rt2800lib.h"
@@ -8481,13 +8482,14 @@ static int rt2800_probe_rt(struct rt2x00 @@ -8482,13 +8483,14 @@ static int rt2800_probe_rt(struct rt2x00
int rt2800_probe_clk(struct rt2x00_dev *rt2x00dev) int rt2800_probe_clk(struct rt2x00_dev *rt2x00dev)
{ {

View file

@ -10,7 +10,7 @@
#define RF5370 0x5370 #define RF5370 0x5370
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3014,6 +3014,13 @@ static void rt2800_config_channel_rf53xx @@ -3015,6 +3015,13 @@ static void rt2800_config_channel_rf53xx
rt2800_rfcsr_write(rt2x00dev, 59, rt2800_rfcsr_write(rt2x00dev, 59,
r59_non_bt[idx]); r59_non_bt[idx]);
@ -24,7 +24,7 @@
} }
} }
} }
@@ -3492,6 +3499,7 @@ static void rt2800_config_channel(struct @@ -3493,6 +3500,7 @@ static void rt2800_config_channel(struct
rt2800_config_channel_rf3853(rt2x00dev, conf, rf, info); rt2800_config_channel_rf3853(rt2x00dev, conf, rf, info);
break; break;
case RF3070: case RF3070:
@ -32,7 +32,7 @@
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -3510,6 +3518,7 @@ static void rt2800_config_channel(struct @@ -3511,6 +3519,7 @@ static void rt2800_config_channel(struct
if (rt2x00_rf(rt2x00dev, RF3070) || if (rt2x00_rf(rt2x00dev, RF3070) ||
rt2x00_rf(rt2x00dev, RF3290) || rt2x00_rf(rt2x00dev, RF3290) ||
rt2x00_rf(rt2x00dev, RF3322) || rt2x00_rf(rt2x00dev, RF3322) ||
@ -40,7 +40,7 @@
rt2x00_rf(rt2x00dev, RF5360) || rt2x00_rf(rt2x00dev, RF5360) ||
rt2x00_rf(rt2x00dev, RF5362) || rt2x00_rf(rt2x00dev, RF5362) ||
rt2x00_rf(rt2x00dev, RF5370) || rt2x00_rf(rt2x00dev, RF5370) ||
@@ -3788,7 +3797,8 @@ static void rt2800_config_channel(struct @@ -3789,7 +3798,8 @@ static void rt2800_config_channel(struct
/* /*
* Clear update flag * Clear update flag
*/ */
@ -50,7 +50,7 @@
rt2800_bbp_read(rt2x00dev, 49, &bbp); rt2800_bbp_read(rt2x00dev, 49, &bbp);
rt2x00_set_field8(&bbp, BBP49_UPDATE_FLAG, 0); rt2x00_set_field8(&bbp, BBP49_UPDATE_FLAG, 0);
rt2800_bbp_write(rt2x00dev, 49, bbp); rt2800_bbp_write(rt2x00dev, 49, bbp);
@@ -4674,6 +4684,7 @@ void rt2800_vco_calibration(struct rt2x0 @@ -4675,6 +4685,7 @@ void rt2800_vco_calibration(struct rt2x0
case RF3070: case RF3070:
case RF3290: case RF3290:
case RF3853: case RF3853:
@ -58,7 +58,7 @@
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -5087,6 +5098,8 @@ static int rt2800_init_registers(struct @@ -5088,6 +5099,8 @@ static int rt2800_init_registers(struct
rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000404); rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000404);
rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x00080606); rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x00080606);
rt2800_register_write(rt2x00dev, TX_SW_CFG2, 0x00000000); rt2800_register_write(rt2x00dev, TX_SW_CFG2, 0x00000000);
@ -67,7 +67,7 @@
} else { } else {
rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000000); rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000000);
rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x00080606); rt2800_register_write(rt2x00dev, TX_SW_CFG1, 0x00080606);
@@ -5742,9 +5755,13 @@ static void rt2800_init_bbp_3352(struct @@ -5743,9 +5756,13 @@ static void rt2800_init_bbp_3352(struct
rt2800_bbp_write(rt2x00dev, 82, 0x62); rt2800_bbp_write(rt2x00dev, 82, 0x62);
@ -84,7 +84,7 @@
rt2800_bbp_write(rt2x00dev, 86, 0x38); rt2800_bbp_write(rt2x00dev, 86, 0x38);
@@ -5758,9 +5775,13 @@ static void rt2800_init_bbp_3352(struct @@ -5759,9 +5776,13 @@ static void rt2800_init_bbp_3352(struct
rt2800_bbp_write(rt2x00dev, 104, 0x92); rt2800_bbp_write(rt2x00dev, 104, 0x92);
@ -101,7 +101,7 @@
rt2800_bbp_write(rt2x00dev, 120, 0x50); rt2800_bbp_write(rt2x00dev, 120, 0x50);
@@ -5785,6 +5806,13 @@ static void rt2800_init_bbp_3352(struct @@ -5786,6 +5807,13 @@ static void rt2800_init_bbp_3352(struct
rt2800_bbp_write(rt2x00dev, 143, 0xa2); rt2800_bbp_write(rt2x00dev, 143, 0xa2);
rt2800_bbp_write(rt2x00dev, 148, 0xc8); rt2800_bbp_write(rt2x00dev, 148, 0xc8);
@ -115,7 +115,7 @@
} }
static void rt2800_init_bbp_3390(struct rt2x00_dev *rt2x00dev) static void rt2800_init_bbp_3390(struct rt2x00_dev *rt2x00dev)
@@ -6126,6 +6154,7 @@ static void rt2800_init_bbp(struct rt2x0 @@ -6127,6 +6155,7 @@ static void rt2800_init_bbp(struct rt2x0
rt2800_init_bbp_3290(rt2x00dev); rt2800_init_bbp_3290(rt2x00dev);
break; break;
case RT3352: case RT3352:
@ -123,7 +123,7 @@
rt2800_init_bbp_3352(rt2x00dev); rt2800_init_bbp_3352(rt2x00dev);
break; break;
case RT3390: case RT3390:
@@ -7077,6 +7106,76 @@ static void rt2800_init_rfcsr_3883(struc @@ -7078,6 +7107,76 @@ static void rt2800_init_rfcsr_3883(struc
rt2800_rfcsr_write(rt2x00dev, 20, rfcsr); rt2800_rfcsr_write(rt2x00dev, 20, rfcsr);
} }
@ -200,7 +200,7 @@
static void rt2800_init_rfcsr_5390(struct rt2x00_dev *rt2x00dev) static void rt2800_init_rfcsr_5390(struct rt2x00_dev *rt2x00dev)
{ {
rt2800_rf_init_calibration(rt2x00dev, 2); rt2800_rf_init_calibration(rt2x00dev, 2);
@@ -7317,6 +7416,9 @@ static void rt2800_init_rfcsr(struct rt2 @@ -7318,6 +7417,9 @@ static void rt2800_init_rfcsr(struct rt2
case RT3593: case RT3593:
rt2800_init_rfcsr_3593(rt2x00dev); rt2800_init_rfcsr_3593(rt2x00dev);
break; break;
@ -210,7 +210,7 @@
case RT5390: case RT5390:
rt2800_init_rfcsr_5390(rt2x00dev); rt2800_init_rfcsr_5390(rt2x00dev);
break; break;
@@ -7576,6 +7678,12 @@ static int rt2800_validate_eeprom(struct @@ -7577,6 +7679,12 @@ static int rt2800_validate_eeprom(struct
rt2x00_set_field16(&word, EEPROM_NIC_CONF0_RF_TYPE, RF2820); rt2x00_set_field16(&word, EEPROM_NIC_CONF0_RF_TYPE, RF2820);
rt2800_eeprom_write(rt2x00dev, EEPROM_NIC_CONF0, word); rt2800_eeprom_write(rt2x00dev, EEPROM_NIC_CONF0, word);
rt2x00_eeprom_dbg(rt2x00dev, "Antenna: 0x%04x\n", word); rt2x00_eeprom_dbg(rt2x00dev, "Antenna: 0x%04x\n", word);
@ -223,7 +223,7 @@
} else if (rt2x00_rt(rt2x00dev, RT2860) || } else if (rt2x00_rt(rt2x00dev, RT2860) ||
rt2x00_rt(rt2x00dev, RT2872)) { rt2x00_rt(rt2x00dev, RT2872)) {
/* /*
@@ -7714,6 +7822,8 @@ static int rt2800_init_eeprom(struct rt2 @@ -7715,6 +7823,8 @@ static int rt2800_init_eeprom(struct rt2
rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf); rt2800_eeprom_read(rt2x00dev, EEPROM_CHIP_ID, &rf);
else if (rt2x00_rt(rt2x00dev, RT3883)) else if (rt2x00_rt(rt2x00dev, RT3883))
rf = RF3853; rf = RF3853;
@ -232,7 +232,7 @@
else else
rf = rt2x00_get_field16(eeprom, EEPROM_NIC_CONF0_RF_TYPE); rf = rt2x00_get_field16(eeprom, EEPROM_NIC_CONF0_RF_TYPE);
@@ -7733,6 +7843,7 @@ static int rt2800_init_eeprom(struct rt2 @@ -7734,6 +7844,7 @@ static int rt2800_init_eeprom(struct rt2
case RF3320: case RF3320:
case RF3322: case RF3322:
case RF3853: case RF3853:
@ -240,7 +240,7 @@
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -8286,6 +8397,7 @@ static int rt2800_probe_hw_mode(struct r @@ -8287,6 +8398,7 @@ static int rt2800_probe_hw_mode(struct r
case RF3290: case RF3290:
case RF3320: case RF3320:
case RF3322: case RF3322:
@ -248,7 +248,7 @@
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -8425,6 +8537,7 @@ static int rt2800_probe_hw_mode(struct r @@ -8426,6 +8538,7 @@ static int rt2800_probe_hw_mode(struct r
case RF3070: case RF3070:
case RF3290: case RF3290:
case RF3853: case RF3853:
@ -256,7 +256,7 @@
case RF5360: case RF5360:
case RF5362: case RF5362:
case RF5370: case RF5370:
@@ -8465,6 +8578,7 @@ static int rt2800_probe_rt(struct rt2x00 @@ -8466,6 +8579,7 @@ static int rt2800_probe_rt(struct rt2x00
case RT3572: case RT3572:
case RT3593: case RT3593:
case RT3883: case RT3883:

View file

@ -8,7 +8,7 @@
#include "rt2x00.h" #include "rt2x00.h"
#include "rt2800lib.h" #include "rt2800lib.h"
@@ -7933,6 +7934,17 @@ static int rt2800_init_eeprom(struct rt2 @@ -7934,6 +7935,17 @@ static int rt2800_init_eeprom(struct rt2
rt2800_init_led(rt2x00dev, &rt2x00dev->led_assoc, LED_TYPE_ASSOC); rt2800_init_led(rt2x00dev, &rt2x00dev->led_assoc, LED_TYPE_ASSOC);
rt2800_init_led(rt2x00dev, &rt2x00dev->led_qual, LED_TYPE_QUALITY); rt2800_init_led(rt2x00dev, &rt2x00dev->led_qual, LED_TYPE_QUALITY);

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c --- a/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00dev.c
@@ -1283,7 +1283,7 @@ static inline void rt2x00lib_set_if_comb @@ -1284,7 +1284,7 @@ static inline void rt2x00lib_set_if_comb
*/ */
if_limit = &rt2x00dev->if_limits_ap; if_limit = &rt2x00dev->if_limits_ap;
if_limit->max = rt2x00dev->ops->max_ap_intf; if_limit->max = rt2x00dev->ops->max_ap_intf;

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -7817,10 +7817,11 @@ static int rt2800_init_eeprom(struct rt2 @@ -7818,10 +7818,11 @@ static int rt2800_init_eeprom(struct rt2
* RT53xx: defined in "EEPROM_CHIP_ID" field * RT53xx: defined in "EEPROM_CHIP_ID" field
*/ */
if (rt2x00_rt(rt2x00dev, RT3290) || if (rt2x00_rt(rt2x00dev, RT3290) ||

View file

@ -11,7 +11,7 @@
* RFCSR 31: * RFCSR 31:
--- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c --- a/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2800lib.c
@@ -3527,8 +3527,13 @@ static void rt2800_config_channel(struct @@ -3528,8 +3528,13 @@ static void rt2800_config_channel(struct
rt2x00_rf(rt2x00dev, RF5390) || rt2x00_rf(rt2x00dev, RF5390) ||
rt2x00_rf(rt2x00dev, RF5392)) { rt2x00_rf(rt2x00dev, RF5392)) {
rt2800_rfcsr_read(rt2x00dev, 30, &rfcsr); rt2800_rfcsr_read(rt2x00dev, 30, &rfcsr);

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c --- a/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
+++ b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00mac.c
@@ -632,12 +632,8 @@ void rt2x00mac_bss_info_changed(struct i @@ -627,12 +627,8 @@ void rt2x00mac_bss_info_changed(struct i
} else if (bss_conf->enable_beacon && !intf->enable_beacon) { } else if (bss_conf->enable_beacon && !intf->enable_beacon) {
rt2x00dev->intf_beaconing++; rt2x00dev->intf_beaconing++;
intf->enable_beacon = true; intf->enable_beacon = true;

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/marvell/mwl8k.c --- a/drivers/net/wireless/marvell/mwl8k.c
+++ b/drivers/net/wireless/marvell/mwl8k.c +++ b/drivers/net/wireless/marvell/mwl8k.c
@@ -5679,6 +5679,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw") @@ -5681,6 +5681,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw")
MODULE_FIRMWARE(MWL8K_8366_AP_FW(MWL8K_8366_AP_FW_API)); MODULE_FIRMWARE(MWL8K_8366_AP_FW(MWL8K_8366_AP_FW_API));
static const struct pci_device_id mwl8k_pci_id_table[] = { static const struct pci_device_id mwl8k_pci_id_table[] = {

View file

@ -13,7 +13,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c
@@ -1226,6 +1226,7 @@ static int __init brcmfmac_module_init(v @@ -1332,6 +1332,7 @@ static int __init brcmfmac_module_init(v
#endif #endif
if (!schedule_work(&brcmf_driver_work)) if (!schedule_work(&brcmf_driver_work))
return -EBUSY; return -EBUSY;
@ -23,7 +23,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
} }
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c
@@ -420,6 +420,7 @@ struct brcmf_fw { @@ -418,6 +418,7 @@ struct brcmf_fw {
u16 bus_nr; u16 bus_nr;
void (*done)(struct device *dev, const struct firmware *fw, void (*done)(struct device *dev, const struct firmware *fw,
void *nvram_image, u32 nvram_len); void *nvram_image, u32 nvram_len);
@ -31,7 +31,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
}; };
static void brcmf_fw_request_nvram_done(const struct firmware *fw, void *ctx) static void brcmf_fw_request_nvram_done(const struct firmware *fw, void *ctx)
@@ -454,6 +455,8 @@ static void brcmf_fw_request_nvram_done( @@ -452,6 +453,8 @@ static void brcmf_fw_request_nvram_done(
goto fail; goto fail;
fwctx->done(fwctx->dev, fwctx->code, nvram, nvram_length); fwctx->done(fwctx->dev, fwctx->code, nvram, nvram_length);
@ -40,7 +40,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
kfree(fwctx); kfree(fwctx);
return; return;
@@ -461,6 +464,8 @@ fail: @@ -459,6 +462,8 @@ fail:
brcmf_dbg(TRACE, "failed: dev=%s\n", dev_name(fwctx->dev)); brcmf_dbg(TRACE, "failed: dev=%s\n", dev_name(fwctx->dev));
release_firmware(fwctx->code); release_firmware(fwctx->code);
device_release_driver(fwctx->dev); device_release_driver(fwctx->dev);
@ -49,7 +49,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
kfree(fwctx); kfree(fwctx);
} }
@@ -476,6 +481,8 @@ static void brcmf_fw_request_code_done(c @@ -474,6 +479,8 @@ static void brcmf_fw_request_code_done(c
/* only requested code so done here */ /* only requested code so done here */
if (!(fwctx->flags & BRCMF_FW_REQUEST_NVRAM)) { if (!(fwctx->flags & BRCMF_FW_REQUEST_NVRAM)) {
fwctx->done(fwctx->dev, fw, NULL, 0); fwctx->done(fwctx->dev, fw, NULL, 0);
@ -58,7 +58,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
kfree(fwctx); kfree(fwctx);
return; return;
} }
@@ -493,6 +500,8 @@ static void brcmf_fw_request_code_done(c @@ -491,6 +498,8 @@ static void brcmf_fw_request_code_done(c
fail: fail:
brcmf_dbg(TRACE, "failed: dev=%s\n", dev_name(fwctx->dev)); brcmf_dbg(TRACE, "failed: dev=%s\n", dev_name(fwctx->dev));
device_release_driver(fwctx->dev); device_release_driver(fwctx->dev);
@ -67,7 +67,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
kfree(fwctx); kfree(fwctx);
} }
@@ -504,6 +513,8 @@ int brcmf_fw_get_firmwares_pcie(struct d @@ -502,6 +511,8 @@ int brcmf_fw_get_firmwares_pcie(struct d
u16 domain_nr, u16 bus_nr) u16 domain_nr, u16 bus_nr)
{ {
struct brcmf_fw *fwctx; struct brcmf_fw *fwctx;
@ -76,7 +76,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
brcmf_dbg(TRACE, "enter: dev=%s\n", dev_name(dev)); brcmf_dbg(TRACE, "enter: dev=%s\n", dev_name(dev));
if (!fw_cb || !code) if (!fw_cb || !code)
@@ -524,9 +535,17 @@ int brcmf_fw_get_firmwares_pcie(struct d @@ -522,9 +533,17 @@ int brcmf_fw_get_firmwares_pcie(struct d
fwctx->domain_nr = domain_nr; fwctx->domain_nr = domain_nr;
fwctx->bus_nr = bus_nr; fwctx->bus_nr = bus_nr;

View file

@ -10,7 +10,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
@@ -609,9 +609,37 @@ static struct wireless_dev *brcmf_cfg802 @@ -618,9 +618,37 @@ static struct wireless_dev *brcmf_cfg802
u32 *flags, u32 *flags,
struct vif_params *params) struct vif_params *params)
{ {

View file

@ -210,7 +210,7 @@
case RT5592: case RT5592:
*txwi_size = TXWI_DESC_SIZE_5WORDS; *txwi_size = TXWI_DESC_SIZE_5WORDS;
*rxwi_size = RXWI_DESC_SIZE_6WORDS; *rxwi_size = RXWI_DESC_SIZE_6WORDS;
@@ -3302,6 +3375,312 @@ static void rt2800_config_channel_rf55xx @@ -3303,6 +3376,312 @@ static void rt2800_config_channel_rf55xx
rt2800_bbp_write(rt2x00dev, 196, (rf->channel <= 14) ? 0x19 : 0x7F); rt2800_bbp_write(rt2x00dev, 196, (rf->channel <= 14) ? 0x19 : 0x7F);
} }
@ -523,7 +523,7 @@
static void rt2800_bbp_write_with_rx_chain(struct rt2x00_dev *rt2x00dev, static void rt2800_bbp_write_with_rx_chain(struct rt2x00_dev *rt2x00dev,
const unsigned int word, const unsigned int word,
const u8 value) const u8 value)
@@ -3458,7 +3837,7 @@ static void rt2800_config_channel(struct @@ -3459,7 +3838,7 @@ static void rt2800_config_channel(struct
struct channel_info *info) struct channel_info *info)
{ {
u32 reg; u32 reg;
@ -532,7 +532,7 @@
u8 bbp, rfcsr; u8 bbp, rfcsr;
info->default_power1 = rt2800_txpower_to_dev(rt2x00dev, rf->channel, info->default_power1 = rt2800_txpower_to_dev(rt2x00dev, rf->channel,
@@ -3512,6 +3891,9 @@ static void rt2800_config_channel(struct @@ -3513,6 +3892,9 @@ static void rt2800_config_channel(struct
case RF5592: case RF5592:
rt2800_config_channel_rf55xx(rt2x00dev, conf, rf, info); rt2800_config_channel_rf55xx(rt2x00dev, conf, rf, info);
break; break;
@ -542,7 +542,7 @@
default: default:
rt2800_config_channel_rf2xxx(rt2x00dev, conf, rf, info); rt2800_config_channel_rf2xxx(rt2x00dev, conf, rf, info);
} }
@@ -3614,7 +3996,7 @@ static void rt2800_config_channel(struct @@ -3615,7 +3997,7 @@ static void rt2800_config_channel(struct
else if (rt2x00_rt(rt2x00dev, RT3593) || else if (rt2x00_rt(rt2x00dev, RT3593) ||
rt2x00_rt(rt2x00dev, RT3883)) rt2x00_rt(rt2x00dev, RT3883))
rt2800_bbp_write(rt2x00dev, 82, 0x82); rt2800_bbp_write(rt2x00dev, 82, 0x82);
@ -551,7 +551,7 @@
rt2800_bbp_write(rt2x00dev, 82, 0xf2); rt2800_bbp_write(rt2x00dev, 82, 0xf2);
if (rt2x00_rt(rt2x00dev, RT3593) || if (rt2x00_rt(rt2x00dev, RT3593) ||
@@ -3636,7 +4018,7 @@ static void rt2800_config_channel(struct @@ -3637,7 +4019,7 @@ static void rt2800_config_channel(struct
if (rt2x00_rt(rt2x00dev, RT3572)) if (rt2x00_rt(rt2x00dev, RT3572))
rt2800_rfcsr_write(rt2x00dev, 8, 0); rt2800_rfcsr_write(rt2x00dev, 8, 0);
@ -560,7 +560,7 @@
switch (rt2x00dev->default_ant.tx_chain_num) { switch (rt2x00dev->default_ant.tx_chain_num) {
case 3: case 3:
@@ -3685,6 +4067,7 @@ static void rt2800_config_channel(struct @@ -3686,6 +4068,7 @@ static void rt2800_config_channel(struct
rt2x00_set_field32(&tx_pin, TX_PIN_CFG_RFTR_EN, 1); rt2x00_set_field32(&tx_pin, TX_PIN_CFG_RFTR_EN, 1);
rt2x00_set_field32(&tx_pin, TX_PIN_CFG_TRSW_EN, 1); rt2x00_set_field32(&tx_pin, TX_PIN_CFG_TRSW_EN, 1);
@ -568,7 +568,7 @@
rt2800_register_write(rt2x00dev, TX_PIN_CFG, tx_pin); rt2800_register_write(rt2x00dev, TX_PIN_CFG, tx_pin);
@@ -4701,6 +5084,14 @@ void rt2800_vco_calibration(struct rt2x0 @@ -4702,6 +5085,14 @@ void rt2800_vco_calibration(struct rt2x0
rt2x00_set_field8(&rfcsr, RFCSR3_VCOCAL_EN, 1); rt2x00_set_field8(&rfcsr, RFCSR3_VCOCAL_EN, 1);
rt2800_rfcsr_write(rt2x00dev, 3, rfcsr); rt2800_rfcsr_write(rt2x00dev, 3, rfcsr);
break; break;
@ -583,7 +583,7 @@
default: default:
return; return;
} }
@@ -5101,9 +5492,42 @@ static int rt2800_init_registers(struct @@ -5102,9 +5493,42 @@ static int rt2800_init_registers(struct
} else if (rt2x00_rt(rt2x00dev, RT5390) || } else if (rt2x00_rt(rt2x00dev, RT5390) ||
rt2x00_rt(rt2x00dev, RT5392) || rt2x00_rt(rt2x00dev, RT5392) ||
rt2x00_rt(rt2x00dev, RT5592)) { rt2x00_rt(rt2x00dev, RT5592)) {
@ -629,7 +629,7 @@
} else if (rt2x00_rt(rt2x00dev, RT5350)) { } else if (rt2x00_rt(rt2x00dev, RT5350)) {
rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000404); rt2800_register_write(rt2x00dev, TX_SW_CFG0, 0x00000404);
} else { } else {
@@ -6135,6 +6559,225 @@ static void rt2800_init_bbp_5592(struct @@ -6136,6 +6560,225 @@ static void rt2800_init_bbp_5592(struct
rt2800_bbp_write(rt2x00dev, 103, 0xc0); rt2800_bbp_write(rt2x00dev, 103, 0xc0);
} }
@ -855,7 +855,7 @@
static void rt2800_init_bbp(struct rt2x00_dev *rt2x00dev) static void rt2800_init_bbp(struct rt2x00_dev *rt2x00dev)
{ {
unsigned int i; unsigned int i;
@@ -6177,7 +6820,10 @@ static void rt2800_init_bbp(struct rt2x0 @@ -6178,7 +6821,10 @@ static void rt2800_init_bbp(struct rt2x0
return; return;
case RT5390: case RT5390:
case RT5392: case RT5392:
@ -867,7 +867,7 @@
break; break;
case RT5592: case RT5592:
rt2800_init_bbp_5592(rt2x00dev); rt2800_init_bbp_5592(rt2x00dev);
@@ -7391,6 +8037,296 @@ static void rt2800_init_rfcsr_5592(struc @@ -7392,6 +8038,296 @@ static void rt2800_init_rfcsr_5592(struc
rt2800_led_open_drain_enable(rt2x00dev); rt2800_led_open_drain_enable(rt2x00dev);
} }
@ -1164,7 +1164,7 @@
static void rt2800_init_rfcsr(struct rt2x00_dev *rt2x00dev) static void rt2800_init_rfcsr(struct rt2x00_dev *rt2x00dev)
{ {
if (rt2800_is_305x_soc(rt2x00dev)) { if (rt2800_is_305x_soc(rt2x00dev)) {
@@ -7426,7 +8362,10 @@ static void rt2800_init_rfcsr(struct rt2 @@ -7427,7 +8363,10 @@ static void rt2800_init_rfcsr(struct rt2
rt2800_init_rfcsr_5350(rt2x00dev); rt2800_init_rfcsr_5350(rt2x00dev);
break; break;
case RT5390: case RT5390:
@ -1176,7 +1176,7 @@
break; break;
case RT5392: case RT5392:
rt2800_init_rfcsr_5392(rt2x00dev); rt2800_init_rfcsr_5392(rt2x00dev);
@@ -7858,6 +8797,7 @@ static int rt2800_init_eeprom(struct rt2 @@ -7859,6 +8798,7 @@ static int rt2800_init_eeprom(struct rt2
case RF5390: case RF5390:
case RF5392: case RF5392:
case RF5592: case RF5592:
@ -1184,7 +1184,7 @@
break; break;
default: default:
rt2x00_err(rt2x00dev, "Invalid RF chipset 0x%04x detected\n", rt2x00_err(rt2x00dev, "Invalid RF chipset 0x%04x detected\n",
@@ -8422,6 +9362,7 @@ static int rt2800_probe_hw_mode(struct r @@ -8423,6 +9363,7 @@ static int rt2800_probe_hw_mode(struct r
case RF5372: case RF5372:
case RF5390: case RF5390:
case RF5392: case RF5392:
@ -1192,7 +1192,7 @@
spec->num_channels = 14; spec->num_channels = 14;
if (spec->clk_is_20mhz) if (spec->clk_is_20mhz)
spec->channels = rf_vals_xtal20mhz_3x; spec->channels = rf_vals_xtal20mhz_3x;
@@ -8562,6 +9503,7 @@ static int rt2800_probe_hw_mode(struct r @@ -8563,6 +9504,7 @@ static int rt2800_probe_hw_mode(struct r
case RF5372: case RF5372:
case RF5390: case RF5390:
case RF5392: case RF5392:

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath10k/mac.c --- a/drivers/net/wireless/ath/ath10k/mac.c
+++ b/drivers/net/wireless/ath/ath10k/mac.c +++ b/drivers/net/wireless/ath/ath10k/mac.c
@@ -7138,6 +7138,21 @@ struct ath10k_vif *ath10k_get_arvif(stru @@ -7141,6 +7141,21 @@ struct ath10k_vif *ath10k_get_arvif(stru
return arvif_iter.arvif; return arvif_iter.arvif;
} }
@ -22,7 +22,7 @@
int ath10k_mac_register(struct ath10k *ar) int ath10k_mac_register(struct ath10k *ar)
{ {
static const u32 cipher_suites[] = { static const u32 cipher_suites[] = {
@@ -7354,6 +7369,12 @@ int ath10k_mac_register(struct ath10k *a @@ -7357,6 +7372,12 @@ int ath10k_mac_register(struct ath10k *a
ar->hw->wiphy->cipher_suites = cipher_suites; ar->hw->wiphy->cipher_suites = cipher_suites;
ar->hw->wiphy->n_cipher_suites = ARRAY_SIZE(cipher_suites); ar->hw->wiphy->n_cipher_suites = ARRAY_SIZE(cipher_suites);

View file

@ -1,6 +1,6 @@
--- a/drivers/net/wireless/marvell/mwl8k.c --- a/drivers/net/wireless/marvell/mwl8k.c
+++ b/drivers/net/wireless/marvell/mwl8k.c +++ b/drivers/net/wireless/marvell/mwl8k.c
@@ -6262,6 +6262,8 @@ static int mwl8k_probe(struct pci_dev *p @@ -6264,6 +6264,8 @@ static int mwl8k_probe(struct pci_dev *p
priv->running_bsses = 0; priv->running_bsses = 0;
@ -9,7 +9,7 @@
return rc; return rc;
err_stop_firmware: err_stop_firmware:
@@ -6295,8 +6297,6 @@ static void mwl8k_remove(struct pci_dev @@ -6297,8 +6299,6 @@ static void mwl8k_remove(struct pci_dev
return; return;
priv = hw->priv; priv = hw->priv;