* [PATCH] cfg80211: Pass station supported channel and oper class info to kernel
From: Sunil Dutt @ 2013-08-27 5:44 UTC (permalink / raw)
To: johannes; +Cc: linux-wireless, j
The information of the peer's supported channels and supported operating
classes are required for the driver to perform TDLS off channel
operations. This commit enhances the function nl80211_(new)set_station
to pass this information of the peer to the driver.
Signed-off-by: Sunil Dutt <c_duttus@qti.qualcomm.com>
---
include/net/cfg80211.h | 8 ++++++++
include/uapi/linux/nl80211.h | 9 +++++++++
net/wireless/nl80211.c | 30 ++++++++++++++++++++++++++++++
3 files changed, 47 insertions(+)
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 9ab7a06..81889ca 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -735,6 +735,10 @@ enum station_parameters_apply_mask {
* @capability: station capability
* @ext_capab: extended capabilities of the station
* @ext_capab_len: number of extended capabilities
+ * @supported_channels: supported channels in IEEE 802.11 format
+ * @supported_channels_len: number of supported channels
+ * @supported_oper_classes: supported oper classes in IEEE 802.11 format
+ * @supported_oper_classes_len: number of supported operating classes
*/
struct station_parameters {
const u8 *supported_rates;
@@ -754,6 +758,10 @@ struct station_parameters {
u16 capability;
const u8 *ext_capab;
u8 ext_capab_len;
+ const u8 *supported_channels;
+ u8 supported_channels_len;
+ const u8 *supported_oper_classes;
+ u8 supported_oper_classes_len;
};
/**
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 1f42bc3..61a21a4 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -1493,6 +1493,11 @@ enum nl80211_commands {
* @NL80211_ATTR_CSA_C_OFF_PRESP: Offset of the channel switch counter
* field in the probe response (%NL80211_ATTR_PROBE_RESP).
*
+ * @NL80211_ATTR_STA_SUPPORTED_CHANNELS: array of supported channels.
+ *
+ * @NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES: array of supported
+ * supported operating classes.
+ *
* @NL80211_ATTR_MAX: highest attribute number currently defined
* @__NL80211_ATTR_AFTER_LAST: internal use
*/
@@ -1801,6 +1806,10 @@ enum nl80211_attrs {
NL80211_ATTR_CSA_C_OFF_BEACON,
NL80211_ATTR_CSA_C_OFF_PRESP,
+ NL80211_ATTR_STA_SUPPORTED_CHANNELS,
+
+ NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES,
+
/* add attributes here, update the policy in nl80211.c */
__NL80211_ATTR_AFTER_LAST,
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 741368c..0765b9a 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -354,6 +354,8 @@ static const struct nla_policy nl80211_policy[NL80211_ATTR_MAX+1] = {
[NL80211_ATTR_CSA_IES] = { .type = NLA_NESTED },
[NL80211_ATTR_CSA_C_OFF_BEACON] = { .type = NLA_U16 },
[NL80211_ATTR_CSA_C_OFF_PRESP] = { .type = NLA_U16 },
+ [NL80211_ATTR_STA_SUPPORTED_CHANNELS] = { .type = NLA_BINARY },
+ [NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES] = { .type = NLA_BINARY },
};
/* policy for the key attributes */
@@ -3909,6 +3911,20 @@ static int nl80211_set_station_tdls(struct genl_info *info,
params->vht_capa =
nla_data(info->attrs[NL80211_ATTR_VHT_CAPABILITY]);
+ if (info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]) {
+ params->supported_channels =
+ nla_data(info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]);
+ params->supported_channels_len =
+ nla_len(info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]);
+ }
+
+ if (info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]) {
+ params->supported_oper_classes =
+ nla_data(info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]);
+ params->supported_oper_classes_len =
+ nla_len(info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]);
+ }
+
return nl80211_parse_sta_wme(info, params);
}
@@ -4089,6 +4105,20 @@ static int nl80211_new_station(struct sk_buff *skb, struct genl_info *info)
return -EINVAL;
}
+ if (info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]) {
+ params->supported_channels =
+ nla_data(info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]);
+ params->supported_channels_len =
+ nla_len(info->attrs[NL80211_ATTR_STA_SUPPORTED_CHANNELS]);
+ }
+
+ if (info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]) {
+ params->supported_oper_classes =
+ nla_data(info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]);
+ params->supported_oper_classes_len =
+ nla_len(info->attrs[NL80211_ATTR_STA_SUPPORTED_OPER_CLASSES]);
+ }
+
err = nl80211_parse_sta_wme(info, ¶ms);
if (err)
return err;
--
1.8.2.1
^ permalink raw reply related
* Re: [PATCH] mwifiex: add missing endian conversions
From: Tobias Waldekranz @ 2013-08-27 5:52 UTC (permalink / raw)
To: Bing Zhao; +Cc: linux-wireless@vger.kernel.org
In-Reply-To: <477F20668A386D41ADCC57781B1F70430EAF1FEDB2@SC-VEXCH1.marvell.com>
On Mon, Aug 26, 2013 at 12:49:57PM -0700, Bing Zhao wrote:
> Hi Tobias,
>
> > Thanks for your patch.
> > It doesn't apply to wireless or wireless-next trees.
> >
> > Which git tree are you using?
>
> Never mind. John has merged the patch already.
>
> Regards,
> Bing
Ok, thanks for picking up the slack :)
It was based on linux-stable/linux-3.10.y, I will base any subsequent
patches on wireless-next.
Thanks
- wkz
^ permalink raw reply
* [PATCH] ath9k: Remove unused ANI commands
From: Sujith Manoharan @ 2013-08-27 6:04 UTC (permalink / raw)
To: John Linville; +Cc: linux-wireless
From: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
---
drivers/net/wireless/ath/ath9k/ani.c | 3 ---
drivers/net/wireless/ath/ath9k/ani.h | 13 ++++---------
drivers/net/wireless/ath/ath9k/ar5008_phy.c | 2 --
drivers/net/wireless/ath/ath9k/ar9003_phy.c | 2 --
drivers/net/wireless/ath/ath9k/hw.c | 2 --
5 files changed, 4 insertions(+), 18 deletions(-)
diff --git a/drivers/net/wireless/ath/ath9k/ani.c b/drivers/net/wireless/ath/ath9k/ani.c
index 4994bea..be466b0 100644
--- a/drivers/net/wireless/ath/ath9k/ani.c
+++ b/drivers/net/wireless/ath/ath9k/ani.c
@@ -319,9 +319,6 @@ void ath9k_ani_reset(struct ath_hw *ah, bool is_scanning)
ah->ani_function = 0;
}
- /* always allow mode (on/off) to be controlled */
- ah->ani_function |= ATH9K_ANI_MODE;
-
ofdm_nil = max_t(int, ATH9K_ANI_OFDM_DEF_LEVEL,
aniState->ofdmNoiseImmunityLevel);
cck_nil = max_t(int, ATH9K_ANI_CCK_DEF_LEVEL,
diff --git a/drivers/net/wireless/ath/ath9k/ani.h b/drivers/net/wireless/ath/ath9k/ani.h
index b54a3fb..21e7b83 100644
--- a/drivers/net/wireless/ath/ath9k/ani.h
+++ b/drivers/net/wireless/ath/ath9k/ani.h
@@ -48,15 +48,10 @@
/* values here are relative to the INI */
enum ath9k_ani_cmd {
- ATH9K_ANI_PRESENT = 0x1,
- ATH9K_ANI_NOISE_IMMUNITY_LEVEL = 0x2,
- ATH9K_ANI_OFDM_WEAK_SIGNAL_DETECTION = 0x4,
- ATH9K_ANI_CCK_WEAK_SIGNAL_THR = 0x8,
- ATH9K_ANI_FIRSTEP_LEVEL = 0x10,
- ATH9K_ANI_SPUR_IMMUNITY_LEVEL = 0x20,
- ATH9K_ANI_MODE = 0x40,
- ATH9K_ANI_PHYERR_RESET = 0x80,
- ATH9K_ANI_MRC_CCK = 0x100,
+ ATH9K_ANI_OFDM_WEAK_SIGNAL_DETECTION = 0x1,
+ ATH9K_ANI_FIRSTEP_LEVEL = 0x2,
+ ATH9K_ANI_SPUR_IMMUNITY_LEVEL = 0x4,
+ ATH9K_ANI_MRC_CCK = 0x8,
ATH9K_ANI_ALL = 0xfff
};
diff --git a/drivers/net/wireless/ath/ath9k/ar5008_phy.c b/drivers/net/wireless/ath/ath9k/ar5008_phy.c
index 1576d58..0865647 100644
--- a/drivers/net/wireless/ath/ath9k/ar5008_phy.c
+++ b/drivers/net/wireless/ath/ath9k/ar5008_phy.c
@@ -1160,8 +1160,6 @@ static bool ar5008_hw_ani_control_new(struct ath_hw *ah,
*/
WARN_ON(1);
break;
- case ATH9K_ANI_PRESENT:
- break;
default:
ath_dbg(common, ANI, "invalid cmd %u\n", cmd);
return false;
diff --git a/drivers/net/wireless/ath/ath9k/ar9003_phy.c b/drivers/net/wireless/ath/ath9k/ar9003_phy.c
index 46b910a..e897648 100644
--- a/drivers/net/wireless/ath/ath9k/ar9003_phy.c
+++ b/drivers/net/wireless/ath/ath9k/ar9003_phy.c
@@ -1193,8 +1193,6 @@ skip_ws_det:
}
break;
}
- case ATH9K_ANI_PRESENT:
- break;
default:
ath_dbg(common, ANI, "invalid cmd %u\n", cmd);
return false;
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
index 2670bf6..ec47c50 100644
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -655,8 +655,6 @@ static int __ath9k_hw_init(struct ath_hw *ah)
ath9k_hw_init_cal_settings(ah);
ah->ani_function = ATH9K_ANI_ALL;
- if (AR_SREV_9280_20_OR_LATER(ah) && !AR_SREV_9300_20_OR_LATER(ah))
- ah->ani_function &= ~ATH9K_ANI_NOISE_IMMUNITY_LEVEL;
if (!AR_SREV_9300_20_OR_LATER(ah))
ah->ani_function &= ~ATH9K_ANI_MRC_CCK;
--
1.8.4
^ permalink raw reply related
* [PATCH] ath9k: Enable D3/L1 ASPM fix for AR9462
From: Sujith Manoharan @ 2013-08-27 6:04 UTC (permalink / raw)
To: John Linville; +Cc: linux-wireless
From: Sujith Manoharan <c_manoha@qca.qualcomm.com>
AR9462 requires this HW fix for ASPM to work properly.
Also, since WARegVal is used only for the AR8003 family,
use AR_SREV_9300_20_OR_LATER.
Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
---
drivers/net/wireless/ath/ath9k/hw.c | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
index ec47c50..ecc6ec4 100644
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -574,18 +574,17 @@ static int __ath9k_hw_init(struct ath_hw *ah)
* We need to do this to avoid RMW of this register. We cannot
* read the reg when chip is asleep.
*/
- ah->WARegVal = REG_READ(ah, AR_WA);
- ah->WARegVal |= (AR_WA_D3_L1_DISABLE |
- AR_WA_ASPM_TIMER_BASED_DISABLE);
+ if (AR_SREV_9300_20_OR_LATER(ah)) {
+ ah->WARegVal = REG_READ(ah, AR_WA);
+ ah->WARegVal |= (AR_WA_D3_L1_DISABLE |
+ AR_WA_ASPM_TIMER_BASED_DISABLE);
+ }
if (!ath9k_hw_set_reset_reg(ah, ATH9K_RESET_POWER_ON)) {
ath_err(common, "Couldn't reset chip\n");
return -EIO;
}
- if (AR_SREV_9462(ah))
- ah->WARegVal &= ~AR_WA_D3_L1_DISABLE;
-
if (AR_SREV_9565(ah)) {
ah->WARegVal |= AR_WA_BIT22;
REG_WRITE(ah, AR_WA, ah->WARegVal);
--
1.8.4
^ permalink raw reply related
* Re: [PATCH 0/6] ath10k: CE cleanups
From: Kalle Valo @ 2013-08-27 6:11 UTC (permalink / raw)
To: Michal Kazior; +Cc: ath10k, linux-wireless
In-Reply-To: <1377068249-26025-1-git-send-email-michal.kazior@tieto.com>
Michal Kazior <michal.kazior@tieto.com> writes:
> Hi,
>
> This patchset contains non-functional changes
> except patch #1 which changes memory allocation
> from dynamic to static.
Good cleanups, but there's a problem with long lines:
drivers/net/wireless/ath/ath10k/ce.h:184: WARNING: line over 80 characters
drivers/net/wireless/ath/ath10k/ce.h:231: WARNING: line over 80 characters
drivers/net/wireless/ath/ath10k/ce.c:858: WARNING: line over 80 characters
drivers/net/wireless/ath/ath10k/ce.c:875: WARNING: line over 80 characters
drivers/net/wireless/ath/ath10k/pci.c:1303: WARNING: line over 80 characters
drivers/net/wireless/ath/ath10k/pci.c:1304: WARNING: line over 80 characters
> There is still some more to clean up in PCI/CE
> but it's probably better to keep patchsets compact
> and more frequent.
I agree.
--
Kalle Valo
^ permalink raw reply
* Re: sd8787 (mwifiex) on big endian system
From: Tobias Waldekranz @ 2013-08-27 6:17 UTC (permalink / raw)
To: Bing Zhao; +Cc: linux-wireless@vger.kernel.org
In-Reply-To: <477F20668A386D41ADCC57781B1F70430EAF1FEDA0@SC-VEXCH1.marvell.com>
On Mon, Aug 26, 2013 at 12:16:00PM -0700, Bing Zhao wrote:
> Hi Tobias,
>
> > As the subject suggests, I am trying to use the SD8787 on a PPC
> > system. I have found a few endian related issues (submitted a few
> > hours ago), but it is still not working.
> >
> > So my first question, has anyone successfully used an mwifiex device
> > on a big endian system?
>
> AFAIK, you are probably the first one to try on a big endian system ;)
>
> >
> > Also, I have found that the chip seems to signal interrupts before its
> > internal registers are in a consistent state. Specifically, the
> > sdio_ireg and wr_bitmask seems to be out of sync. Inserting a small
> > delay in mwifiex_interrupt_status (sdio.c), currently 50 us solves the
> > problem. Is there some bit that should be polled here to make sure that
> > the registers are in a consistent state?
>
> Can you enable dynamic debug and post the logs showing the register mismatch?
>
> Thanks,
> Bing
Hi Bing,
Here is the log output without the added udelay. It is always the 0xd9
command that fails, but not always with these sdio_ireg/wr_bitmask
values. I have seen these combinations:
- sdio_ireg incorrect(2), wr_bitmask incorrect(fffe)
- sdio_ireg correct(3), wr_bitmask incorrect(fffe)
- sdio_ireg incorrect(2), wr_bitmask correct(ffff)
Waiting 50 us before reading the mp_regs always returns the correct
response.
mmc0: new high speed SDIO card at address 0001
mwifiex_sdio: info: vendor=0x02DF device=0x9119 class=0 function=1
mwifiex_sdio: info: SDIO FUNC1 IO port: 0x10000
mwifiex_sdio mmc0:0001:1: info: downloading FW image (447384 bytes)
mwifiex_sdio mmc0:0001:1: info: FW download over, size 447384 bytes
mwifiex_sdio mmc0:0001:1: WLAN FW is active
mwifiex_sdio mmc0:0001:1: cmd: QUEUE_CMD: cmd=0xa9, cmd_pending=1
mwifiex_sdio mmc0:0001:1: cmd: DNLD_CMD: (1035334.499952): 0xa9, act 0x0, len 8, seqno 0x1
mwifiex_sdio mmc0:0001:1: info: mwifiex_host_to_card_mp_aggr: tx aggregation disabled
mwifiex_sdio mmc0:0001:1: data: mwifiex_host_to_card_mp_aggr: send current buffer 0
mwifiex_sdio mmc0:0001:1: int: sdio_ireg = 0x1
mwifiex_sdio mmc0:0001:1: info: cmd_sent=0 data_sent=1
mwifiex_sdio mmc0:0001:1: int: UPLD: rd_bitmap=0x0001
mwifiex_sdio mmc0:0001:1: data: mp_rd_bitmap=0x0001
mwifiex_sdio mmc0:0001:1: data: port=0 mp_rd_bitmap=0x0000
mwifiex_sdio mmc0:0001:1: info: RX: port=0 rx_len=12
mwifiex_sdio mmc0:0001:1: info: rx_len = 256 skb->len = 256
mwifiex_sdio mmc0:0001:1: info: mwifiex_sdio_card_to_host_mp_aggr: no aggregation for cmd response
mwifiex_sdio mmc0:0001:1: info: RX: port: 0, rx_len: 256
mwifiex_sdio mmc0:0001:1: info: --- Rx: Cmd Response ---
mwifiex_sdio mmc0:0001:1: data: mp_rd_bitmap=0x0000
mwifiex_sdio mmc0:0001:1: info: no more rd_port available
mwifiex_sdio mmc0:0001:1: cmd: CMD_RESP: (1035334.645688): 0x80a9, result 0, len 8, seqno 0x1
mwifiex_sdio mmc0:0001:1: cmd completed: status=0
mwifiex_sdio mmc0:0001:1: cmd: FREE_CMD: cmd=0xa9, cmd_pending=0
mwifiex_sdio mmc0:0001:1: cmd: QUEUE_CMD: cmd=0x3, cmd_pending=1
mwifiex_sdio mmc0:0001:1: cmd: DNLD_CMD: (1035334.645742): 0x3, act 0x0, len 71, seqno 0x2
mwifiex_sdio mmc0:0001:1: info: mwifiex_host_to_card_mp_aggr: tx aggregation disabled
mwifiex_sdio mmc0:0001:1: data: mwifiex_host_to_card_mp_aggr: send current buffer 0
mwifiex_sdio mmc0:0001:1: int: sdio_ireg = 0x1
mwifiex_sdio mmc0:0001:1: info: cmd_sent=0 data_sent=1
mwifiex_sdio mmc0:0001:1: int: UPLD: rd_bitmap=0x0001
mwifiex_sdio mmc0:0001:1: data: mp_rd_bitmap=0x0001
mwifiex_sdio mmc0:0001:1: data: port=0 mp_rd_bitmap=0x0000
mwifiex_sdio mmc0:0001:1: info: RX: port=0 rx_len=75
mwifiex_sdio mmc0:0001:1: info: rx_len = 256 skb->len = 256
mwifiex_sdio mmc0:0001:1: info: mwifiex_sdio_card_to_host_mp_aggr: no aggregation for cmd response
mwifiex_sdio mmc0:0001:1: info: RX: port: 0, rx_len: 256
mwifiex_sdio mmc0:0001:1: info: --- Rx: Cmd Response ---
mwifiex_sdio mmc0:0001:1: data: mp_rd_bitmap=0x0000
mwifiex_sdio mmc0:0001:1: info: no more rd_port available
mwifiex_sdio mmc0:0001:1: cmd: CMD_RESP: (1035334.664109): 0x8003, result 0, len 71, seqno 0x2
mwifiex_sdio mmc0:0001:1: info: GET_HW_SPEC: fw_release_number- 0x600e4209
mwifiex_sdio mmc0:0001:1: info: GET_HW_SPEC: permanent addr: 00:06:c6:37:45:28
mwifiex_sdio mmc0:0001:1: info: GET_HW_SPEC: hw_if_version=0x2 version=0x41
mwifiex_sdio mmc0:0001:1: cmd: mp_end_port 16, data port mask 0xfffe
mwifiex_sdio mmc0:0001:1: cmd completed: status=0
mwifiex_sdio mmc0:0001:1: cmd: FREE_CMD: cmd=0x3, cmd_pending=0
mwifiex_sdio mmc0:0001:1: cmd: set tx_buf=2048
mwifiex_sdio mmc0:0001:1: cmd: QUEUE_CMD: cmd=0xd9, cmd_pending=1
mwifiex_sdio mmc0:0001:1: cmd: DNLD_CMD: (1035334.664215): 0xd9, act 0x1, len 16, seqno 0x3
mwifiex_sdio mmc0:0001:1: info: mwifiex_host_to_card_mp_aggr: tx aggregation disabled
mwifiex_sdio mmc0:0001:1: data: mwifiex_host_to_card_mp_aggr: send current buffer 0
mwifiex_sdio mmc0:0001:1: int: sdio_ireg = 0x2
mwifiex_sdio mmc0:0001:1: int: DNLD: wr_bitmap=0xfffe
mwifiex_sdio mmc0:0001:1: info: <--- Tx DONE Interrupt --->
mwifiex_sdio mmc0:0001:1: info: cmd_sent=1 data_sent=0
mwifiex_sdio mmc0:0001:1: mwifiex_cmd_timeout_func: Timeout cmd id (1035344.696670) = 0xd9, act = 0x1
mwifiex_sdio mmc0:0001:1: num_data_h2c_failure = 0
mwifiex_sdio mmc0:0001:1: num_cmd_h2c_failure = 0
mwifiex_sdio mmc0:0001:1: num_cmd_timeout = 1
mwifiex_sdio mmc0:0001:1: num_tx_timeout = 0
mwifiex_sdio mmc0:0001:1: last_cmd_index = 3
mwifiex_sdio mmc0:0001:1: last_cmd_id: 00 00 00 a9 00 03 00 d9 00 00
mwifiex_sdio mmc0:0001:1: last_cmd_act: 00 00 00 00 00 00 00 01 00 00
mwifiex_sdio mmc0:0001:1: last_cmd_resp_index = 2
mwifiex_sdio mmc0:0001:1: last_cmd_resp_id: 00 00 80 a9 80 03 00 00 00 00
mwifiex_sdio mmc0:0001:1: last_event_index = 0
mwifiex_sdio mmc0:0001:1: last_event: 00 00 00 00 00 00 00 00 00 00
mwifiex_sdio mmc0:0001:1: data_sent=0 cmd_sent=1
mwifiex_sdio mmc0:0001:1: ps_mode=0 ps_state=0
mwifiex_sdio mmc0:0001:1: cmd: FREE_CMD: cmd=0xd9, cmd_pending=0
mwifiex_sdio mmc0:0001:1: cmd completed: status=-110
mwifiex_sdio mmc0:0001:1: cmd timeout
mwifiex_sdio: Resetting card...
mwifiex_sdio: info: SDIO func num=1
mwifiex_sdio mmc0:0001:1: cmd: calling mwifiex_shutdown_drv...
mwifiex_sdio mmc0:0001:1: info: shutdown mwifiex...
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 0
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 1
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 2
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 3
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 4
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 5
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 6
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 7
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 0, head = dea340d0
mwifiex_sdio mmc0:0001:1: info: Delete node c79be1a0, next = c79be1b0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 1, head = dea340e0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 2, head = dea340f0
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 0
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 1
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 2
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 3
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 4
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 5
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 6
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 7
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 0, head = dea340d0
mwifiex_sdio mmc0:0001:1: info: Delete node c79be1b0, next = c79be1c0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 1, head = dea340e0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 2, head = dea340f0
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 0
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 1
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 2
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 3
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 4
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 5
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 6
mwifiex_sdio mmc0:0001:1: info: ra_list: freeing buf for tid 7
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 0, head = dea340d0
mwifiex_sdio mmc0:0001:1: info: Delete node c79be1c0, next = dea340d0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 1, head = dea340e0
mwifiex_sdio mmc0:0001:1: info: delete BSS priority table, bss_type = 0, bss_num = 0, i = 2, head = dea340f0
mwifiex_sdio mmc0:0001:1: info: free cmd buffer
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 0
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 1
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 2
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 3
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 4
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 5
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 6
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 7
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 8
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 9
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 10
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 11
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 12
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 13
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 14
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 15
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 16
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 17
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 18
mwifiex_sdio mmc0:0001:1: cmd: free cmd buffer 19
mwifiex_sdio mmc0:0001:1: cmd: free cmd pool
mwifiex_sdio mmc0:0001:1: info: free scan table
mwifiex_sdio mmc0:0001:1: cmd: mwifiex_shutdown_drv done
WARNING: driver mwifiex_sdio did not remove its interrupt handler!
mmc0: card 0001 removed
mmc0: new high speed SDIO card at address 0001
mwifiex_sdio: info: vendor=0x02DF device=0x9119 class=0 function=1
mwifiex_sdio: info: SDIO FUNC1 IO port: 0x10000
mwifiex_sdio mmc0:0001:1: info: downloading FW image (447384 bytes)
mwifiex_sdio mmc0:0001:1: poll card status failed, tries = 100
mwifiex_sdio mmc0:0001:1: FW download with helper: poll status timeout @ 0
mwifiex_sdio mmc0:0001:1: prog_fw failed ret=0xffffffff
Thanks
- wkz
^ permalink raw reply
* Re: [PATCH 0/3] ath10k: initial per-VDEV FW statistics implementation
From: Kalle Valo @ 2013-08-27 6:56 UTC (permalink / raw)
To: Bartosz Markowski; +Cc: ath10k, linux-wireless
In-Reply-To: <1377516815-12660-1-git-send-email-bartosz.markowski@tieto.com>
Bartosz Markowski <bartosz.markowski@tieto.com> writes:
> FW 1.0.0.716 brings per-VDEV statistics. This patch-set implements
> debugfs mechanism to fetch those. There's still few more fileds we
> can read from the FW stats event, which are not covered here.
>
> Please note there's an ABI change in wmi_peer_stats structure, hence
> the PEER statistics will be corrupted if used with older firmware
> (e.g. 1.0.0.636)
We need to support the older firmware, so please add a feature flag VDEV
statistics so that we can detect which version of the struct needs to be
used.
Also I think you can fold patches 1 and 2.
--
Kalle Valo
^ permalink raw reply
* Re: [PATCH v2 0/4] ath10k: fixes
From: Kalle Valo @ 2013-08-27 6:57 UTC (permalink / raw)
To: Luis R. Rodriguez; +Cc: Michal Kazior, linux-wireless, ath10k
In-Reply-To: <CAB=NE6X=P2hTnOC8xqFwb=-32-hBgx=ndq3KHoUG83KptKv0vA@mail.gmail.com>
"Luis R. Rodriguez" <mcgrof@do-not-panic.com> writes:
> On Mon, Aug 26, 2013 at 1:53 AM, Michal Kazior <michal.kazior@tieto.com> wrote:
>> ath10k: fix issues on non-preemptible systems
>
> This patch looks like a stable candidate fix. Please annotate as such
> if you confirm. Also, I reviewed other ath10k "fixes" and I see no
> practice of propagating any patches to stable yet. Can you please
> start doing that? If there were patches which are already merged
> upstream that should be propagated to stable then they can be
> submitted as stable candidate patches.
I disagree. The point of linux-stable is _not_ that we send all possible
fixes to stable. Instead we should send fixes only which really matter
to users and for which we have received bug reports. I haven't yet seen
any fix for ath10k which should be a candidate for stable releases.
If we start sending all ath10k fixes to stable it's just extra churn for
both Greg and people working on ath10k.
--
Kalle Valo
^ permalink raw reply
* Re: [PATCH v2 4/4] ath10k: fix issues on non-preemptible systems
From: Kalle Valo @ 2013-08-27 7:06 UTC (permalink / raw)
To: Michal Kazior; +Cc: ath10k, linux-wireless
In-Reply-To: <1377507205-5386-5-git-send-email-michal.kazior@tieto.com>
Michal Kazior <michal.kazior@tieto.com> writes:
> Workers may not call into a sleepable function
> (e.g. mutex_lock). Since ath10k workers can run
> for a very long time it is necessary to explicitly
> allow process rescheduling in case there's no
> preemption.
>
> This fixes some issues with system freezes, hangs,
> watchdogs being triggered, userspace being
> unresponsive on slow host machines under heavy
> load.
I consider this more as a workaround as a real fix. Would NAPI be a
proper fix for issues like this?
NAPI support was removed from mac80211 six months ago, but I guess we
could try to get it back if we have a good reason:
http://marc.info/?l=linux-wireless&m=136204135907491
> --- a/drivers/net/wireless/ath/ath10k/htt_rx.c
> +++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
> @@ -1229,6 +1229,10 @@ static void ath10k_htt_rx_work(struct work_struct *work)
> break;
>
> ath10k_htt_rx_process_skb(htt->ar, skb);
> +
> +#ifndef CONFIG_PREEMPT
> + cond_resched();
> +#endif
Why the #ifndef? Why should we not call cond_resched() when PREEMPT is
enabled? Does something negative happen then?
--
Kalle Valo
^ permalink raw reply
* Re: [PATCH v2 4/4] ath10k: fix issues on non-preemptible systems
From: Michal Kazior @ 2013-08-27 7:30 UTC (permalink / raw)
To: Kalle Valo; +Cc: ath10k, linux-wireless
In-Reply-To: <87ioyrmx3u.fsf@kamboji.qca.qualcomm.com>
On 27 August 2013 09:06, Kalle Valo <kvalo@qca.qualcomm.com> wrote:
> Michal Kazior <michal.kazior@tieto.com> writes:
>
>> Workers may not call into a sleepable function
>> (e.g. mutex_lock). Since ath10k workers can run
>> for a very long time it is necessary to explicitly
>> allow process rescheduling in case there's no
>> preemption.
>>
>> This fixes some issues with system freezes, hangs,
>> watchdogs being triggered, userspace being
>> unresponsive on slow host machines under heavy
>> load.
>
> I consider this more as a workaround as a real fix. Would NAPI be a
> proper fix for issues like this?
>
> NAPI support was removed from mac80211 six months ago, but I guess we
> could try to get it back if we have a good reason:
>
> http://marc.info/?l=linux-wireless&m=136204135907491
Hmm. From what I understand NAPI is used for RX polling. My patch
addresses mainly WMI/HTT TX starvation.
There's another solution that I had in mind. Instead of:
for (;;) { dequeue(z); process; }
I did:
q = dequeue_all(z); for (;;) { dequeue(q); process; }
I.e. move all queued stuff at the worker entry and move it out of the
global queue, that can, and will be, having more stuff queued while
the worker does its job).
This way workers would exit/restart more often, but from what I tested
it didn't really solve the problem. Given enough traffic HTC worker
responsible for HTT TX gets overwhelmed eventually. You could try
limit how many frames a worker can process during one execution, but
how do you guess that? This starvation depends on how fast your CPU
is.
Thus I opted for sole cond_resched().
>> --- a/drivers/net/wireless/ath/ath10k/htt_rx.c
>> +++ b/drivers/net/wireless/ath/ath10k/htt_rx.c
>> @@ -1229,6 +1229,10 @@ static void ath10k_htt_rx_work(struct work_struct *work)
>> break;
>>
>> ath10k_htt_rx_process_skb(htt->ar, skb);
>> +
>> +#ifndef CONFIG_PREEMPT
>> + cond_resched();
>> +#endif
>
> Why the #ifndef? Why should we not call cond_resched() when PREEMPT is
> enabled? Does something negative happen then?
I think it should be okay. I saw the #ifndef thing in b43legacy and
thought it simply makes sense (although it's unsightly).
Michał.
^ permalink raw reply
* Re: [PATCH v2 0/4] ath10k: fixes
From: Luis R. Rodriguez @ 2013-08-27 7:59 UTC (permalink / raw)
To: Michal Kazior; +Cc: Luis R. Rodriguez, linux-wireless, ath10k
In-Reply-To: <CA+BoTQ=zVAab8KV2TwYJ=+wG0N7M4-oo-TgaE2qpxJO33d3oZQ@mail.gmail.com>
On Tue, Aug 27, 2013 at 07:42:39AM +0200, Michal Kazior wrote:
> On 26 August 2013 22:20, Luis R. Rodriguez <mcgrof@do-not-panic.com> wrote:
> > On Mon, Aug 26, 2013 at 1:53 AM, Michal Kazior <michal.kazior@tieto.com> wrote:
> >> ath10k: fix issues on non-preemptible systems
> >
> > This patch looks like a stable candidate fix. Please annotate as such
> > if you confirm. Also, I reviewed other ath10k "fixes" and I see no
> > practice of propagating any patches to stable yet. Can you please
> > start doing that? If there were patches which are already merged
> > upstream that should be propagated to stable then they can be
> > submitted as stable candidate patches.
>
> Good point.
>
> If this patch is to be propagated to stable the patch(set) needs some
> adjustments to avoid conflicts. Right now the patch touches a place
> that was introduced with "ath10k: move htt rx processing to worker" so
> the offending patch hunk should be moved to that patch.
>
> Actually the "ath10k: make the workqueue multithreaded" could also be
> a candidate for stable as it fixes AP beaconing during heavy TX
> traffic. I should've mentioned that in the commit log.
>
> I'll resend an updated patchset later today.
That one doesn't seem like a stable fix, it does quite a big change.
Luis
^ permalink raw reply
* Re: [PATCH v2 0/4] ath10k: fixes
From: Luis R. Rodriguez @ 2013-08-27 8:01 UTC (permalink / raw)
To: Kalle Valo; +Cc: Luis R. Rodriguez, linux-wireless, Michal Kazior, ath10k
In-Reply-To: <87mwo3mxil.fsf@kamboji.qca.qualcomm.com>
On Tue, Aug 27, 2013 at 09:57:22AM +0300, Kalle Valo wrote:
> "Luis R. Rodriguez" <mcgrof@do-not-panic.com> writes:
>
> > On Mon, Aug 26, 2013 at 1:53 AM, Michal Kazior <michal.kazior@tieto.com> wrote:
> >> ath10k: fix issues on non-preemptible systems
> >
> > This patch looks like a stable candidate fix. Please annotate as such
> > if you confirm. Also, I reviewed other ath10k "fixes" and I see no
> > practice of propagating any patches to stable yet. Can you please
> > start doing that? If there were patches which are already merged
> > upstream that should be propagated to stable then they can be
> > submitted as stable candidate patches.
>
> I disagree. The point of linux-stable is _not_ that we send all possible
> fixes to stable. Instead we should send fixes only which really matter
> to users and for which we have received bug reports. I haven't yet seen
> any fix for ath10k which should be a candidate for stable releases.
You don't need to wait for an issue to happen to consider it serious,
the description of the symptoms seem pretty bad to me, but its your
call in the end.
> If we start sending all ath10k fixes to stable it's just extra churn for
> both Greg and people working on ath10k.
I'm not asking for anything that has the word "fix" to be sent, I'm
asking them to be reviewed for stable consideration.
Luis
^ permalink raw reply
* Re: [rt2x00-users] [PATCH 3.11] rt2800: fix wrong TX power compensation
From: Stanislaw Gruszka @ 2013-08-27 8:00 UTC (permalink / raw)
To: Paul Menzel; +Cc: John W. Linville, Fabien ADAM, linux-wireless, users
In-Reply-To: <1377548398.4408.4.camel@mattotaupa>
On Mon, Aug 26, 2013 at 10:19:58PM +0200, Paul Menzel wrote:
> Could you please add which ones you have tested?
I checked 2 devices (3071 & 3070) but they have EXTERNAL_TX_ALC bit set.
I assume the fix is correct based on vendor driver and it fixes devices
which have no EXTERNAL_TX_ACL, but I can not tell what chipset that are.
Is possible that the same chipset can be configured with and without
EXTERNAL_TX_ALC.
> Is there a bug report about this?
Fabien reported problem on mailing list, I can add that as reference.
I hope it also fixes bug reported here:
https://bugzilla.redhat.com/show_bug.cgi?id=913631
but I haven't get confirmation about that from users yet.
Stanislaw
^ permalink raw reply
* [PATCH 3.11 v2] rt2800: fix wrong TX power compensation
From: Stanislaw Gruszka @ 2013-08-27 8:13 UTC (permalink / raw)
To: John W. Linville
Cc: Fabien ADAM, linux-wireless, users, Paul Menzel,
Gertjan van Wingerde
In-Reply-To: <20130827080001.GA2609@redhat.com>
We should not do temperature compensation on devices without
EXTERNAL_TX_ALC bit set (called DynamicTxAgcControl on vendor driver).
Such devices can have totally bogus TSSI parameters on the EEPROM,
but are still treated by us as valid and results in wrong TX power
calculations.
This fixes inability to connect to AP on slightly longer distance on
some Ralink chips/devices without EXTERNAL_TX_ALC configured.
Reference:
http://thread.gmane.org/gmane.linux.drivers.rt2x00.user/2263
Reported-and-tested-by: Fabien ADAM <id2ndr@crocobox.org>
Cc: stable@vger.kernel.org
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
---
drivers/net/wireless/rt2x00/rt2800lib.c | 7 +++++++
1 file changed, 7 insertions(+)
v1 -> v2: fix changelog
John,
If possible this should go to 3.11, -next & cc -stable is also fine as
usual.
Note that in -next version of the patch rt2x00_eeprom_read() should
be changed to rt2800_eeprom_read() do to commit
3e38d3daf881a78ac13e93504a8ac5777040797e
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
index 1f80ea5..a0119d3 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.c
+++ b/drivers/net/wireless/rt2x00/rt2800lib.c
@@ -2790,6 +2790,13 @@ static int rt2800_get_gain_calibration_delta(struct rt2x00_dev *rt2x00dev)
int i;
/*
+ * First check if temperature compensation is supported.
+ */
+ rt2x00_eeprom_read(rt2x00dev, EEPROM_NIC_CONF1, &eeprom);
+ if (!rt2x00_get_field16(eeprom, EEPROM_NIC_CONF1_EXTERNAL_TX_ALC))
+ return 0;
+
+ /*
* Read TSSI boundaries for temperature compensation from
* the EEPROM.
*
--
1.7.11.7
^ permalink raw reply related
* Re: [rt2x00-users] [PATCH 3.11] rt2800: fix wrong TX power compensation
From: Paul Menzel @ 2013-08-27 8:22 UTC (permalink / raw)
To: Stanislaw Gruszka; +Cc: Fabien ADAM, linux-wireless, users
In-Reply-To: <20130827080001.GA2609@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1192 bytes --]
Am Dienstag, den 27.08.2013, 10:00 +0200 schrieb Stanislaw Gruszka:
> On Mon, Aug 26, 2013 at 10:19:58PM +0200, Paul Menzel wrote:
> > Could you please add which ones you have tested?
>
> I checked 2 devices (3071 & 3070) but they have EXTERNAL_TX_ALC bit set.
> I assume the fix is correct based on vendor driver and it fixes devices
> which have no EXTERNAL_TX_ACL, but I can not tell what chipset that are.
> Is possible that the same chipset can be configured with and without
> EXTERNAL_TX_ALC.
I have the following device.
$ lsusb -s 004
Bus 002 Device 004: ID 148f:2870 Ralink Technology, Corp. RT2870 Wireless Adapter
How do I check if the bit is set? Sometimes the device disconnects when
being 10 meters away from the access point. The connection is also
slower than with an ath5k device right next to it.
> > Is there a bug report about this?
>
> Fabien reported problem on mailing list, I can add that as reference.
That would be great!
> I hope it also fixes bug reported here:
> https://bugzilla.redhat.com/show_bug.cgi?id=913631
> but I haven't get confirmation about that from users yet.
Understood!
Thanks,
Paul
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* Re: [rt2x00-users] [PATCH 3.11 v2] rt2800: fix wrong TX power compensation
From: Paul Menzel @ 2013-08-27 8:26 UTC (permalink / raw)
To: Stanislaw Gruszka; +Cc: John W. Linville, Fabien ADAM, linux-wireless, users
In-Reply-To: <20130827081340.GB2609@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 2223 bytes --]
Dear Stanislaw,
thank you for the updated patch. One last suggestion inline.
Am Dienstag, den 27.08.2013, 10:13 +0200 schrieb Stanislaw Gruszka:
> We should not do temperature compensation on devices without
> EXTERNAL_TX_ALC bit set (called DynamicTxAgcControl on vendor driver).
> Such devices can have totally bogus TSSI parameters on the EEPROM,
> but are still treated by us as valid and results in wrong TX power
> calculations.
>
> This fixes inability to connect to AP on slightly longer distance on
> some Ralink chips/devices without EXTERNAL_TX_ALC configured.
>
> Reference:
> http://thread.gmane.org/gmane.linux.drivers.rt2x00.user/2263
>
> Reported-and-tested-by: Fabien ADAM <id2ndr@crocobox.org>
> Cc: stable@vger.kernel.org
> Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
> Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>
> Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
> ---
> drivers/net/wireless/rt2x00/rt2800lib.c | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> v1 -> v2: fix changelog
>
> John,
>
> If possible this should go to 3.11, -next & cc -stable is also fine as
> usual.
>
> Note that in -next version of the patch rt2x00_eeprom_read() should
> be changed to rt2800_eeprom_read() do to commit
> 3e38d3daf881a78ac13e93504a8ac5777040797e
>
> diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
> index 1f80ea5..a0119d3 100644
> --- a/drivers/net/wireless/rt2x00/rt2800lib.c
> +++ b/drivers/net/wireless/rt2x00/rt2800lib.c
> @@ -2790,6 +2790,13 @@ static int rt2800_get_gain_calibration_delta(struct rt2x00_dev *rt2x00dev)
> int i;
>
> /*
> + * First check if temperature compensation is supported.
> + */
> + rt2x00_eeprom_read(rt2x00dev, EEPROM_NIC_CONF1, &eeprom);
> + if (!rt2x00_get_field16(eeprom, EEPROM_NIC_CONF1_EXTERNAL_TX_ALC))
> + return 0;
Could a (debug) message be printed that temperature compensations is not
supported? Not sure if that should be done in the library or the code
calling this function.
> +
> + /*
> * Read TSSI boundaries for temperature compensation from
> * the EEPROM.
> *
Thanks,
Paul
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* Re: [rt2x00-users] [PATCH 3.11] rt2800: fix wrong TX power compensation
From: Daniel Golle @ 2013-08-27 8:22 UTC (permalink / raw)
To: Stanislaw Gruszka
Cc: Paul Menzel, Fabien ADAM, linux-wireless@vger.kernel.org,
users@rt2x00.serialmonkey.com
In-Reply-To: <20130827080001.GA2609@redhat.com>
On 08/27/2013 10:00 AM, Stanislaw Gruszka wrote:
> On Mon, Aug 26, 2013 at 10:19:58PM +0200, Paul Menzel wrote:
>> Could you please add which ones you have tested?
>
> I checked 2 devices (3071 & 3070) but they have EXTERNAL_TX_ALC bit set.
> I assume the fix is correct based on vendor driver and it fixes devices
> which have no EXTERNAL_TX_ACL, but I can not tell what chipset that are.
> Is possible that the same chipset can be configured with and without
> EXTERNAL_TX_ALC.
At least for SoC (3352 and 5350) I know that there are devices with (e.g.
DIR-615 rev.H1) and without EXTERNAL_TX_ALC (e.g. ALL5002). I guess the same
applies for PCI modules.
^ permalink raw reply
* Re: [PATCH 0/3] ath10k: initial per-VDEV FW statistics implementation
From: Bartosz Markowski @ 2013-08-27 8:39 UTC (permalink / raw)
To: Kalle Valo; +Cc: ath10k, linux-wireless
In-Reply-To: <87txibmxk0.fsf@kamboji.qca.qualcomm.com>
On 27 August 2013 08:56, Kalle Valo <kvalo@qca.qualcomm.com> wrote:
> Bartosz Markowski <bartosz.markowski@tieto.com> writes:
>
>> FW 1.0.0.716 brings per-VDEV statistics. This patch-set implements
>> debugfs mechanism to fetch those. There's still few more fileds we
>> can read from the FW stats event, which are not covered here.
>>
>> Please note there's an ABI change in wmi_peer_stats structure, hence
>> the PEER statistics will be corrupted if used with older firmware
>> (e.g. 1.0.0.636)
>
> We need to support the older firmware, so please add a feature flag VDEV
> statistics so that we can detect which version of the struct needs to be
> used.
>
> Also I think you can fold patches 1 and 2.
OK, will do. Please drop this patch-set and I will send a single one.
--
Bartosz
^ permalink raw reply
* [PATCH] ath10k: implement per-VDEV FW statistics
From: Bartosz Markowski @ 2013-08-27 8:43 UTC (permalink / raw)
To: ath10k; +Cc: linux-wireless, Bartosz Markowski
The WMI_REQUEST_PEER_STAT command with latst (1.0.0.716) FW
can return per-VDEV statistics. Using debugfs we can fetch this info now.
This is a backward compatible change. In case of older FW the VDEV
statistics are simply not returned.
Signed-off-by: Bartosz Markowski <bartosz.markowski@tieto.com>
---
drivers/net/wireless/ath/ath10k/core.h | 22 ++++++++
drivers/net/wireless/ath/ath10k/debug.c | 54 +++++++++++++++++---
drivers/net/wireless/ath/ath10k/wmi.c | 4 +-
drivers/net/wireless/ath/ath10k/wmi.h | 85 ++++++++++++++++++++++++++-----
4 files changed, 144 insertions(+), 21 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/core.h b/drivers/net/wireless/ath/ath10k/core.h
index ab05c4c..f94482b 100644
--- a/drivers/net/wireless/ath/ath10k/core.h
+++ b/drivers/net/wireless/ath/ath10k/core.h
@@ -119,10 +119,27 @@ struct ath10k_wmi {
struct work_struct wmi_event_work;
};
+struct ath10k_vdev_stat {
+ u32 vdev_id;
+ struct wmi_snr_info vdev_snr;
+ u32 tx_frames_count[MAX_AC];
+ u32 rx_frames_count;
+ u32 multiple_retry_cnt[MAX_AC];
+ u32 fail_count[MAX_AC];
+ u32 rts_fail_count;
+ u32 rts_success_count;
+ u32 rts_err_count;
+ u32 rx_discard_count;
+ u32 ack_fail_count;
+ u32 tx_rate_history[MAX_TX_RATE_VALUES];
+ u32 bcn_rssi_history[MAX_RSSI_VALUES];
+};
+
struct ath10k_peer_stat {
u8 peer_macaddr[ETH_ALEN];
u32 peer_rssi;
u32 peer_tx_rate;
+ u32 peer_rx_rate;
};
struct ath10k_target_stats {
@@ -176,6 +193,8 @@ struct ath10k_target_stats {
s32 mpdu_errs;
/* VDEV STATS */
+ struct ath10k_vdev_stat vdev_stat[TARGET_NUM_VDEVS];
+ u8 vdevs;
/* PEER STATS */
u8 peers;
@@ -274,6 +293,9 @@ enum ath10k_fw_features {
/* wmi_mgmt_rx_hdr contains extra RSSI information */
ATH10K_FW_FEATURE_EXT_WMI_MGMT_RX = 0,
+ /* firmware support per-VEDV statistics */
+ ATH10K_FW_FEATURE_VDEV_STATS = 1,
+
/* keep last */
ATH10K_FW_FEATURE_COUNT,
};
diff --git a/drivers/net/wireless/ath/ath10k/debug.c b/drivers/net/wireless/ath/ath10k/debug.c
index 3d65594..4d240e1 100644
--- a/drivers/net/wireless/ath/ath10k/debug.c
+++ b/drivers/net/wireless/ath/ath10k/debug.c
@@ -228,25 +228,37 @@ void ath10k_debug_read_target_stats(struct ath10k *ar,
tmp += sizeof(struct wmi_pdev_stats);
}
- /* 0 or max vdevs */
- /* Currently firmware does not support VDEV stats */
if (num_vdev_stats) {
struct wmi_vdev_stats *vdev_stats;
+ struct ath10k_vdev_stat *s;
+
+ stats->vdevs = num_vdev_stats;
for (i = 0; i < num_vdev_stats; i++) {
vdev_stats = (struct wmi_vdev_stats *)tmp;
+ s = &stats->vdev_stat[i];
+
+ s->vdev_id = __le32_to_cpu(vdev_stats->vdev_id);
+ s->vdev_snr.beacon_snr =
+ __le32_to_cpu(vdev_stats->vdev_snr.beacon_snr);
+ s->vdev_snr.data_snr =
+ __le32_to_cpu(vdev_stats->vdev_snr.data_snr);
+
+ /* TODO:read remaining vdev stats */
+
tmp += sizeof(struct wmi_vdev_stats);
}
}
if (num_peer_stats) {
- struct wmi_peer_stats *peer_stats;
struct ath10k_peer_stat *s;
+ struct wmi_peer_stats_1 *peer_stats;
stats->peers = num_peer_stats;
for (i = 0; i < num_peer_stats; i++) {
- peer_stats = (struct wmi_peer_stats *)tmp;
+ peer_stats = (struct wmi_peer_stats_1 *)tmp;
+
s = &stats->peer_stat[i];
WMI_MAC_ADDR_TO_CHAR_ARRAY(&peer_stats->peer_macaddr,
@@ -255,7 +267,12 @@ void ath10k_debug_read_target_stats(struct ath10k *ar,
s->peer_tx_rate =
__le32_to_cpu(peer_stats->peer_tx_rate);
- tmp += sizeof(struct wmi_peer_stats);
+ if (test_bit(ATH10K_FW_FEATURE_VDEV_STATS,
+ ar->fw_features)) {
+ tmp += sizeof(struct wmi_peer_stats_2);
+ } else {
+ tmp += sizeof(struct wmi_peer_stats_1);
+ }
}
}
@@ -270,7 +287,7 @@ static ssize_t ath10k_read_fw_stats(struct file *file, char __user *user_buf,
struct ath10k *ar = file->private_data;
struct ath10k_target_stats *fw_stats;
char *buf = NULL;
- unsigned int len = 0, buf_len = 2500;
+ unsigned int len = 0, buf_len = 3000;
ssize_t ret_cnt = 0;
long left;
int i;
@@ -408,6 +425,27 @@ static ssize_t ath10k_read_fw_stats(struct file *file, char __user *user_buf,
len += scnprintf(buf + len, buf_len - len, "%30s %10d\n",
"MPDU errors (FCS, MIC, ENC)", fw_stats->mpdu_errs);
+ if (fw_stats->vdevs) {
+ len += scnprintf(buf + len, buf_len - len, "\n");
+ len += scnprintf(buf + len, buf_len - len, "%30s\n",
+ "ath10k VDEV stats");
+ len += scnprintf(buf + len, buf_len - len, "%30s\n\n",
+ "=================");
+ }
+
+ for (i = 0; i < fw_stats->vdevs; i++) {
+ len += scnprintf(buf + len, buf_len - len, "%30s %10u\n",
+ "VDEV ID", fw_stats->vdev_stat[i].vdev_id);
+ len += scnprintf(buf + len, buf_len - len, "%30s %10u\n",
+ "Beacon SNR",
+ fw_stats->vdev_stat[i].vdev_snr.beacon_snr);
+ len += scnprintf(buf + len, buf_len - len, "%30s %10u\n",
+ "Data SNR",
+ fw_stats->vdev_stat[i].vdev_snr.data_snr);
+ len += scnprintf(buf + len, buf_len - len, "\n");
+ }
+
+
len += scnprintf(buf + len, buf_len - len, "\n");
len += scnprintf(buf + len, buf_len - len, "%30s\n",
"ath10k PEER stats");
@@ -418,9 +456,9 @@ static ssize_t ath10k_read_fw_stats(struct file *file, char __user *user_buf,
len += scnprintf(buf + len, buf_len - len, "%30s %pM\n",
"Peer MAC address",
fw_stats->peer_stat[i].peer_macaddr);
- len += scnprintf(buf + len, buf_len - len, "%30s %u\n",
+ len += scnprintf(buf + len, buf_len - len, "%30s %10u\n",
"Peer RSSI", fw_stats->peer_stat[i].peer_rssi);
- len += scnprintf(buf + len, buf_len - len, "%30s %u\n",
+ len += scnprintf(buf + len, buf_len - len, "%30s %10u\n",
"Peer TX rate",
fw_stats->peer_stat[i].peer_tx_rate);
len += scnprintf(buf + len, buf_len - len, "\n");
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index 32fd5e7..3ebab3d 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -957,8 +957,10 @@ static void ath10k_wmi_service_ready_event_rx(struct ath10k *ar,
ar->phy_capability = __le32_to_cpu(ev->phy_capability);
ar->num_rf_chains = __le32_to_cpu(ev->num_rf_chains);
- if (ar->fw_version_build > 636)
+ if (ar->fw_version_build > 636) {
set_bit(ATH10K_FW_FEATURE_EXT_WMI_MGMT_RX, ar->fw_features);
+ set_bit(ATH10K_FW_FEATURE_VDEV_STATS, ar->fw_features);
+ }
if (ar->num_rf_chains > WMI_MAX_SPATIAL_STREAM) {
ath10k_warn("hardware advertises support for more spatial streams than it should (%d > %d)\n",
diff --git a/drivers/net/wireless/ath/ath10k/wmi.h b/drivers/net/wireless/ath/ath10k/wmi.h
index 08860c4..626bf02 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.h
+++ b/drivers/net/wireless/ath/ath10k/wmi.h
@@ -60,6 +60,11 @@
*
*/
+#define MAX_AC 4 /* Maximum value of access category */
+
+#define MAX_TX_RATE_VALUES 10 /* Max Tx rates */
+#define MAX_RSSI_VALUES 10 /* Max RSSI values */
+
/* Control Path */
struct wmi_cmd_hdr {
__le32 cmd_id;
@@ -1767,6 +1772,9 @@ struct wal_dbg_tx_stats {
/* wal pdev resets */
__le32 pdev_resets;
+ /* frames dropped due to non-availability of stateless TIDs */
+ __le32 stateless_tid_alloc_failure;
+
__le32 phy_underrun;
/* MPDU is more than txop limit */
@@ -1825,11 +1833,10 @@ enum wmi_stats_id {
struct wmi_request_stats_cmd {
__le32 stats_id;
-
- /*
- * Space to add parameters like
- * peer mac addr
- */
+ /* unique id identifying the VDEV, generated by the caller */
+ __le32 vdev_id;
+ /* peer MAC address */
+ struct wmi_mac_addr peer_macaddr;
} __packed;
/* Suspend option */
@@ -1878,7 +1885,6 @@ struct wmi_stats_event {
/*
* PDEV statistics
- * TODO: add all PDEV stats here
*/
struct wmi_pdev_stats {
__le32 chan_nf; /* Channel noise floor */
@@ -1891,24 +1897,79 @@ struct wmi_pdev_stats {
struct wal_dbg_stats wal; /* WAL dbg stats */
} __packed;
-/*
- * VDEV statistics
- * TODO: add all VDEV stats here
- */
+struct wmi_snr_info {
+ __le32 beacon_snr;
+ __le32 data_snr;
+} __packed;
+
struct wmi_vdev_stats {
+ /* unique id identifying the VDEV, generated by the caller */
__le32 vdev_id;
+ struct wmi_snr_info vdev_snr;
+ /*
+ * Total number of packets(per AC) that were successfully transmitted
+ * (with and without retries, including multi-cast, broadcast)
+ */
+ __le32 tx_frm_cnt[MAX_AC];
+ /*
+ * Total number of packets that were successfully received
+ * (after appropriate filter rules including multi-cast, broadcast)
+ */
+ __le32 rx_frm_cnt;
+ /*
+ * The number of MSDU packets and MMPDU frames per AC that the 802.11
+ * station successfully transmitted after more than one retransmission
+ * attempt
+ */
+ __le32 multiple_retry_cnt[MAX_AC];
+ /* Total number packets(per AC) failed to transmit */
+ __le32 fail_cnt[MAX_AC];
+ /*
+ * Total number of RTS/CTS sequence failures for transmission of a
+ * packet
+ */
+ __le32 rts_fail_cnt;
+ /*
+ * Total number of RTS/CTS sequence success for transmission of a
+ * packet
+ */
+ __le32 rts_succ_cnt;
+ /*
+ * The receive error count.
+ * HAL will provide the RxP FCS error global
+ */
+ __le32 rx_err_cnt;
+ /*
+ * The sum of the receive error count and dropped-receive-buffer
+ * error count. (FCS error)
+ */
+ __le32 rx_discard_cnt;
+ /*
+ * Total number packets failed transmit because of no ACK
+ * from the remote entity
+ */
+ __le32 ack_fail_cnt;
+ /* History of last ten transmit rate, in units of 500 kbit/sec */
+ __le32 tx_rate_history[MAX_TX_RATE_VALUES];
+ /* History of last ten Beacon rssi of the connected Bss */
+ __le32 bcn_rssi_history[MAX_RSSI_VALUES];
} __packed;
/*
* peer statistics.
- * TODO: add more stats
*/
-struct wmi_peer_stats {
+struct wmi_peer_stats_1 {
struct wmi_mac_addr peer_macaddr;
__le32 peer_rssi;
__le32 peer_tx_rate;
} __packed;
+struct wmi_peer_stats_2 {
+ struct wmi_peer_stats_1 wmi_peer_stats_1;
+ __le32 peer_rx_rate;
+} __packed;
+
+
struct wmi_vdev_create_cmd {
__le32 vdev_id;
__le32 vdev_type;
--
1.7.10
^ permalink raw reply related
* pull-request: mac80211 2013-08-27
From: Johannes Berg @ 2013-08-27 8:54 UTC (permalink / raw)
To: John Linville; +Cc: linux-wireless
[-- Attachment #1: Type: text/plain, Size: 1052 bytes --]
John,
I know it's late, but I have one straggler for the current cycle. If you
don't want to pull it any more, I guess it's not terribly important as
it only affects some APs (though those are affected badly and no
connection is possible.)
This patch fixes a regression with associating to some broken APs that
send an ECSA IE in their probe responses.
johannes
The following changes since commit 75a423f493ffdf741acae27bf179cd560f7813d7:
mac80211: ibss: fix ignored channel parameter (2013-08-21 15:33:08 +0200)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211.git for-john
for you to fetch changes up to d70b7616d9080ec9f868fbd31db5fd4341435d61:
mac80211: ignore (E)CSA in probe response frames (2013-08-23 17:05:12 +0200)
----------------------------------------------------------------
Johannes Berg (1):
mac80211: ignore (E)CSA in probe response frames
net/mac80211/mlme.c | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
^ permalink raw reply
* pull-request: mac80211-next 2013-08-27
From: Johannes Berg @ 2013-08-27 8:56 UTC (permalink / raw)
To: John Linville; +Cc: linux-wireless
[-- Attachment #1: Type: text/plain, Size: 2281 bytes --]
John,
And I also have some more changes for -next, just a few small fixes and
improvements, nothing really stands out.
johannes
The following changes since commit 27b3eb9c06a7193bdc9800cd00764a130343bc8a:
mac80211: add APIs to allow keeping connections after WoWLAN (2013-08-16 12:58:43 +0200)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git for-john
for you to fetch changes up to a98655387762394371b88cdfb8215884757978ab:
mac80211: fix change_interface queue assignments (2013-08-26 09:52:58 +0200)
----------------------------------------------------------------
Bob Copeland (1):
mac80211: assign seqnums for group QoS frames
Chun-Yeow Yeoh (1):
mac80211: only respond to probe request with mesh ID
Johannes Berg (3):
mac80211: minstrel_ht: don't use control.flags in TX status path
mac80211: move setting WIPHY_FLAG_SUPPORTS_SCHED_SCAN into drivers
mac80211: fix change_interface queue assignments
Vladimir Kondratiev (1):
cfg80211: add flags to cfg80211_rx_mgmt()
Wei Yongjun (1):
mac80211_hwsim: fix error return code in init_mac80211_hwsim()
drivers/net/wireless/ath/ath6kl/wmi.c | 7 +++----
drivers/net/wireless/ath/wil6210/wmi.c | 2 +-
drivers/net/wireless/brcm80211/brcmfmac/p2p.c | 4 ++--
drivers/net/wireless/mac80211_hwsim.c | 4 +++-
drivers/net/wireless/mwifiex/util.c | 4 ++--
drivers/net/wireless/ti/wlcore/main.c | 3 ++-
include/net/cfg80211.h | 3 ++-
include/uapi/linux/nl80211.h | 16 ++++++++++++++++
net/mac80211/iface.c | 19 +++++++++++--------
net/mac80211/main.c | 3 ---
net/mac80211/mesh.c | 3 +++
net/mac80211/rc80211_minstrel_ht.c | 3 +--
net/mac80211/rx.c | 3 +--
net/mac80211/tx.c | 6 ++++--
net/wireless/mlme.c | 4 ++--
net/wireless/nl80211.c | 6 ++++--
net/wireless/nl80211.h | 2 +-
17 files changed, 58 insertions(+), 34 deletions(-)
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 801 bytes --]
^ permalink raw reply
* [PATCH 1/2] staging: vt6656: rxtx.c: s_vFillRTSHead change if/else to switch on byPktype
From: Malcolm Priestley @ 2013-08-27 8:56 UTC (permalink / raw)
To: gregkh; +Cc: linux-wireless
Allowing fall through where necessary.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
---
drivers/staging/vt6656/rxtx.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c
index e97bc40..e049a34 100644
--- a/drivers/staging/vt6656/rxtx.c
+++ b/drivers/staging/vt6656/rxtx.c
@@ -730,7 +730,9 @@ static void s_vFillRTSHead(struct vnt_private *pDevice, u8 byPktType,
* into account.
* Otherwise, we need to modified codes for them.
*/
- if (byPktType == PK_TYPE_11GB || byPktType == PK_TYPE_11GA) {
+ switch (byPktType) {
+ case PK_TYPE_11GB:
+ case PK_TYPE_11GA:
if (byFBOption == AUTO_FB_NONE)
vnt_rxtx_rts_g_head(pDevice, &head->rts_g,
psEthHeader, byPktType, cbFrameLength,
@@ -739,7 +741,8 @@ static void s_vFillRTSHead(struct vnt_private *pDevice, u8 byPktType,
vnt_rxtx_rts_g_fb_head(pDevice, &head->rts_g_fb,
psEthHeader, byPktType, cbFrameLength,
bNeedAck, wCurrentRate, byFBOption);
- } else if (byPktType == PK_TYPE_11A) {
+ break;
+ case PK_TYPE_11A:
if (byFBOption == AUTO_FB_NONE)
vnt_rxtx_rts_ab_head(pDevice, &head->rts_ab,
psEthHeader, byPktType, cbFrameLength,
@@ -748,7 +751,8 @@ static void s_vFillRTSHead(struct vnt_private *pDevice, u8 byPktType,
vnt_rxtx_rts_a_fb_head(pDevice, &head->rts_a_fb,
psEthHeader, byPktType, cbFrameLength,
bNeedAck, wCurrentRate, byFBOption);
- } else if (byPktType == PK_TYPE_11B) {
+ break;
+ case PK_TYPE_11B:
vnt_rxtx_rts_ab_head(pDevice, &head->rts_ab,
psEthHeader, byPktType, cbFrameLength,
bNeedAck, wCurrentRate, byFBOption);
--
1.8.1.2
^ permalink raw reply related
* [PATCH 2/2] staging: vt6656: rxtx.c s_vFillRTSHead PK_TYPE_11A allow fall through AUTO_FB_NONE
From: Malcolm Priestley @ 2013-08-27 8:58 UTC (permalink / raw)
To: gregkh; +Cc: linux-wireless
byFBOption == AUTO_FB_NONE (0) is the same as PK_TYPE_11B
Reverse if condition to break and allow fall through.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
---
drivers/staging/vt6656/rxtx.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/staging/vt6656/rxtx.c b/drivers/staging/vt6656/rxtx.c
index e049a34..463a8d5 100644
--- a/drivers/staging/vt6656/rxtx.c
+++ b/drivers/staging/vt6656/rxtx.c
@@ -743,15 +743,12 @@ static void s_vFillRTSHead(struct vnt_private *pDevice, u8 byPktType,
bNeedAck, wCurrentRate, byFBOption);
break;
case PK_TYPE_11A:
- if (byFBOption == AUTO_FB_NONE)
- vnt_rxtx_rts_ab_head(pDevice, &head->rts_ab,
- psEthHeader, byPktType, cbFrameLength,
- bNeedAck, wCurrentRate, byFBOption);
- else
+ if (byFBOption) {
vnt_rxtx_rts_a_fb_head(pDevice, &head->rts_a_fb,
psEthHeader, byPktType, cbFrameLength,
bNeedAck, wCurrentRate, byFBOption);
- break;
+ break;
+ }
case PK_TYPE_11B:
vnt_rxtx_rts_ab_head(pDevice, &head->rts_ab,
psEthHeader, byPktType, cbFrameLength,
--
1.8.1.2
^ permalink raw reply related
* Re: [rt2x00-users] [PATCH 3.11] rt2800: fix wrong TX power compensation
From: Stanislaw Gruszka @ 2013-08-27 9:07 UTC (permalink / raw)
To: Paul Menzel; +Cc: Fabien ADAM, linux-wireless, users
In-Reply-To: <1377591765.5019.23.camel@mattotaupa>
On Tue, Aug 27, 2013 at 10:22:45AM +0200, Paul Menzel wrote:
> > I checked 2 devices (3071 & 3070) but they have EXTERNAL_TX_ALC bit set.
> > I assume the fix is correct based on vendor driver and it fixes devices
> > which have no EXTERNAL_TX_ACL, but I can not tell what chipset that are.
> > Is possible that the same chipset can be configured with and without
> > EXTERNAL_TX_ALC.
>
> I have the following device.
>
> $ lsusb -s 004
> Bus 002 Device 004: ID 148f:2870 Ralink Technology, Corp. RT2870 Wireless Adapter
>
> How do I check if the bit is set? Sometimes the device disconnects when
> being 10 meters away from the access point. The connection is also
> slower than with an ath5k device right next to it.
If you compiled kernel with DEBUGFS support, you can check that by:
mount -t debugfs debugfs /sys/kernel/debug/
cd /sys/kernel/debug/ieee80211/phy0/rt2800usb/register/
echo "0x001b" > eeprom_offset
cat eeprom_value
Second less significant bit is EXTERNAL_TX_ALC .
I think your device has EXTERNAL_TX_ACL since it's older chip, but who
knows ...
Stanislaw
^ permalink raw reply
* Re: [rt2x00-users] [PATCH 3.11 v2] rt2800: fix wrong TX power compensation
From: Stanislaw Gruszka @ 2013-08-27 9:13 UTC (permalink / raw)
To: Paul Menzel; +Cc: John W. Linville, Fabien ADAM, linux-wireless, users
In-Reply-To: <1377591967.5019.25.camel@mattotaupa>
On Tue, Aug 27, 2013 at 10:26:07AM +0200, Paul Menzel wrote:
> > /*
> > + * First check if temperature compensation is supported.
> > + */
> > + rt2x00_eeprom_read(rt2x00dev, EEPROM_NIC_CONF1, &eeprom);
> > + if (!rt2x00_get_field16(eeprom, EEPROM_NIC_CONF1_EXTERNAL_TX_ALC))
> > + return 0;
>
> Could a (debug) message be printed that temperature compensations is not
> supported? Not sure if that should be done in the library or the code
> calling this function.
This is frequent path, so it will need to be a printk_once() based
message, but perhaps would be better to print chip capabilities
coded on the EEPROM together with "Chipset detected" message on
device initialization.
Anyway, we can add debugging on separate patch.
Stanislaw
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox