* [RFCv3 2/3] nl80211: Support >4096 byte NEW_WIPHY event nlmsg
From: Denis Kenzior @ 2019-09-06 15:43 UTC (permalink / raw)
To: linux-wireless, johannes; +Cc: Denis Kenzior
In-Reply-To: <20190906154303.9303-1-denkenz@gmail.com>
For historical reasons, NEW_WIPHY messages generated by dumps or
GET_WIPHY commands were limited to 4096 bytes. This was due to the
fact that the kernel only allocated 4k buffers prior to commit
9063e21fb026 ("netlink: autosize skb lengthes"). Once the sizes of
NEW_WIPHY messages exceeded these sizes, split dumps were introduced.
Any new, non-legacy data was added only to messages using split-dumps
(including filtered dumps).
However, split-dumping has quite a significant overhead. On cards
tested, split dumps generated message sizes 1.7-1.8x compared to
non-split dumps, while still comfortably fitting into an 8k buffer. The
kernel now expects userspace to provide 16k buffers by default, and 32k
buffers are possible.
The kernel netlink layer is now much smarter and utilizes certain
heuristics for figuring out what buffer sizes userspace provides, so it
can allocate optimally sized buffers for netlink messages accordingly.
This commit changes the split logic so that messages are packed more
compactly into the (potentially) larger buffers provided by userspace.
If large-enough buffers are provided, then split dumps will generate a
single netlink NEW_WIPHY message for each wiphy being dumped, removing
any overhead.
Signed-off-by: Denis Kenzior <denkenz@gmail.com>
---
net/wireless/nl80211.c | 222 +++++++++++++++++++++--------------------
1 file changed, 112 insertions(+), 110 deletions(-)
Changes since last version:
- Patch completely rewritten based on Johannes' feedback. We now try to
pack as many attributes as can fit into the current message. If the
application uses large enough buffers (typically 8k is sufficient as
of the time of this writing), then no splitting is even required.
- Rewrote the commit description based on Johannes' git history
findings. E.g. the kernel was at fault for the 4096 byte buffer size
limits and not userspace.
- Patch 3 was dropped as it was no longer required
Other thoughts:
- I tested the split dump with 3k, 4k and 8k userspace buffers and
things seem to work as expected.
- The code in case '3' is quite complex, but it does try to support a
message running out of room in the middle of a channel dump and
restarting from where it left off in the next split message. Perhaps
this can be simplified, but it seems this capability is useful.
Please take extra care when reviewing this.
- I dropped the split and restart logic in case 13 as no current driver
besides iwlwifi seems to support the attributes here, and the
attributes appear to be quite small anyway.
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index ff6200fcd492..03421f66eea3 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -1854,8 +1854,8 @@ static int nl80211_send_pmsr_capa(struct cfg80211_registered_device *rdev,
struct nl80211_dump_wiphy_state {
s64 filter_wiphy;
long start;
- long split_start, band_start, chan_start, capa_start;
- bool split;
+ long split_start, band_start, chan_start;
+ bool legacy;
};
static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
@@ -1867,8 +1867,9 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
struct nlattr *nl_bands, *nl_band;
struct nlattr *nl_freqs, *nl_freq;
struct nlattr *nl_cmds;
- enum nl80211_band band;
struct ieee80211_channel *chan;
+ void *last_good_pos = 0;
+ void *last_channel_pos;
int i;
const struct ieee80211_txrx_stypes *mgmt_stypes =
rdev->wiphy.mgmt_stypes;
@@ -1939,9 +1940,9 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
if ((rdev->wiphy.flags & WIPHY_FLAG_TDLS_EXTERNAL_SETUP) &&
nla_put_flag(msg, NL80211_ATTR_TDLS_EXTERNAL_SETUP))
goto nla_put_failure;
+
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 1:
if (nla_put(msg, NL80211_ATTR_CIPHER_SUITES,
@@ -1986,17 +1987,16 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
}
}
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 2:
if (nl80211_put_iftypes(msg, NL80211_ATTR_SUPPORTED_IFTYPES,
rdev->wiphy.interface_modes))
goto nla_put_failure;
+
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 3:
nl_bands = nla_nest_start_noflag(msg,
@@ -2004,81 +2004,78 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
if (!nl_bands)
goto nla_put_failure;
- for (band = state->band_start;
- band < NUM_NL80211_BANDS; band++) {
+ /* Position in the buffer if we added a set of channel info */
+ last_channel_pos = 0;
+
+ while (state->band_start < NUM_NL80211_BANDS) {
struct ieee80211_supported_band *sband;
- sband = rdev->wiphy.bands[band];
+ sband = rdev->wiphy.bands[state->band_start];
- if (!sband)
+ if (!sband) {
+ state->band_start++;
continue;
+ }
- nl_band = nla_nest_start_noflag(msg, band);
+ nl_band = nla_nest_start_noflag(msg, state->band_start);
if (!nl_band)
- goto nla_put_failure;
+ goto band_put_failure;
- switch (state->chan_start) {
- case 0:
- if (nl80211_send_band_rateinfo(msg, sband))
- goto nla_put_failure;
- state->chan_start++;
- if (state->split)
- break;
- /* fall through */
- default:
- /* add frequencies */
- nl_freqs = nla_nest_start_noflag(msg,
- NL80211_BAND_ATTR_FREQS);
- if (!nl_freqs)
- goto nla_put_failure;
+ if (!state->chan_start &&
+ nl80211_send_band_rateinfo(msg, sband))
+ goto band_put_failure;
+
+ nl_freqs = nla_nest_start_noflag(msg,
+ NL80211_BAND_ATTR_FREQS);
+ if (!nl_freqs)
+ goto band_put_failure;
- for (i = state->chan_start - 1;
- i < sband->n_channels;
- i++) {
- nl_freq = nla_nest_start_noflag(msg,
- i);
- if (!nl_freq)
- goto nla_put_failure;
+ while (state->chan_start < sband->n_channels) {
+ nl_freq = nla_nest_start_noflag(msg,
+ state->chan_start);
+ if (!nl_freq)
+ goto chan_put_failure;
- chan = &sband->channels[i];
+ chan = &sband->channels[state->chan_start];
- if (nl80211_msg_put_channel(
- msg, &rdev->wiphy, chan,
- state->split))
- goto nla_put_failure;
+ if (nl80211_msg_put_channel(msg, &rdev->wiphy,
+ chan,
+ !state->legacy))
+ goto chan_put_failure;
- nla_nest_end(msg, nl_freq);
- if (state->split)
- break;
- }
- if (i < sband->n_channels)
- state->chan_start = i + 2;
- else
- state->chan_start = 0;
- nla_nest_end(msg, nl_freqs);
+ nla_nest_end(msg, nl_freq);
+ state->chan_start++;
+ last_channel_pos = nlmsg_get_pos(msg);
}
+chan_put_failure:
+ if (!last_channel_pos)
+ goto nla_put_failure;
+
+ nlmsg_trim(msg, last_channel_pos);
+ nla_nest_end(msg, nl_freqs);
nla_nest_end(msg, nl_band);
- if (state->split) {
- /* start again here */
- if (state->chan_start)
- band--;
+ if (state->chan_start < sband->n_channels)
break;
- }
+
+ state->chan_start = 0;
+ state->band_start++;
}
- nla_nest_end(msg, nl_bands);
- if (band < NUM_NL80211_BANDS)
- state->band_start = band + 1;
- else
- state->band_start = 0;
+band_put_failure:
+ if (!last_channel_pos)
+ goto nla_put_failure;
+
+ nla_nest_end(msg, nl_bands);
- /* if bands & channels are done, continue outside */
- if (state->band_start == 0 && state->chan_start == 0)
- state->split_start++;
- if (state->split)
+ if (state->band_start < NUM_NL80211_BANDS)
break;
+
+ state->band_start = 0;
+
+ last_good_pos = nlmsg_get_pos(msg);
+ state->split_start++;
/* fall through */
case 4:
nl_cmds = nla_nest_start_noflag(msg,
@@ -2089,7 +2086,7 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
i = nl80211_add_commands_unsplit(rdev, msg);
if (i < 0)
goto nla_put_failure;
- if (state->split) {
+ if (!state->legacy) {
CMD(crit_proto_start, CRIT_PROTOCOL_START);
CMD(crit_proto_stop, CRIT_PROTOCOL_STOP);
if (rdev->wiphy.flags & WIPHY_FLAG_HAS_CHANNEL_SWITCH)
@@ -2105,9 +2102,8 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
#undef CMD
nla_nest_end(msg, nl_cmds);
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 5:
if (rdev->ops->remain_on_channel &&
@@ -2123,20 +2119,17 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
if (nl80211_send_mgmt_stypes(msg, mgmt_stypes))
goto nla_put_failure;
+
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 6:
#ifdef CONFIG_PM
- if (nl80211_send_wowlan(msg, rdev, state->split))
+ if (nl80211_send_wowlan(msg, rdev, !state->legacy))
goto nla_put_failure;
- state->split_start++;
- if (state->split)
- break;
-#else
- state->split_start++;
#endif
+ last_good_pos = nlmsg_get_pos(msg);
+ state->split_start++;
/* fall through */
case 7:
if (nl80211_put_iftypes(msg, NL80211_ATTR_SOFTWARE_IFTYPES,
@@ -2144,12 +2137,11 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
goto nla_put_failure;
if (nl80211_put_iface_combinations(&rdev->wiphy, msg,
- state->split))
+ !state->legacy))
goto nla_put_failure;
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- if (state->split)
- break;
/* fall through */
case 8:
if ((rdev->wiphy.flags & WIPHY_FLAG_HAVE_AP_SME) &&
@@ -2160,10 +2152,10 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
features = rdev->wiphy.features;
/*
* We can only add the per-channel limit information if the
- * dump is split, otherwise it makes it too big. Therefore
- * only advertise it in that case.
+ * dump is for a non-legacy message, otherwise it makes it too
+ * big. Therefore only advertise it in that case.
*/
- if (state->split)
+ if (!state->legacy)
features |= NL80211_FEATURE_ADVERTISE_CHAN_LIMITS;
if (nla_put_u32(msg, NL80211_ATTR_FEATURE_FLAGS, features))
goto nla_put_failure;
@@ -2182,19 +2174,19 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
/*
* Any information below this point is only available to
- * applications that can deal with it being split. This
- * helps ensure that newly added capabilities don't break
- * older tools by overrunning their buffers.
- *
- * We still increment split_start so that in the split
- * case we'll continue with more data in the next round,
- * but break unconditionally so unsplit data stops here.
+ * applications that are not legacy, e.g. ones that requested
+ * a split-dump or using large buffers. This helps ensure
+ * that newly added capabilities don't break older tools by
+ * overrunning their buffers.
*/
- state->split_start++;
-
- if (!state->split)
+ if (state->legacy) {
state->split_start = 0;
- break;
+ break;
+ }
+
+ last_good_pos = nlmsg_get_pos(msg);
+ state->split_start++;
+ /* Fall through */
case 9:
if (rdev->wiphy.extended_capabilities &&
(nla_put(msg, NL80211_ATTR_EXT_CAPA,
@@ -2235,8 +2227,9 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
nla_nest_end(msg, attr);
}
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 10:
if (nl80211_send_coalesce(msg, rdev))
goto nla_put_failure;
@@ -2251,8 +2244,9 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
rdev->wiphy.max_ap_assoc_sta))
goto nla_put_failure;
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 11:
if (rdev->wiphy.n_vendor_commands) {
const struct nl80211_vendor_cmd_info *info;
@@ -2287,8 +2281,10 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
}
nla_nest_end(msg, nested);
}
+
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 12:
if (rdev->wiphy.flags & WIPHY_FLAG_HAS_CHANNEL_SWITCH &&
nla_put_u8(msg, NL80211_ATTR_MAX_CSA_COUNTERS,
@@ -2329,8 +2325,9 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
nla_nest_end(msg, nested);
}
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 13:
if (rdev->wiphy.num_iftype_ext_capab &&
rdev->wiphy.iftype_ext_capab) {
@@ -2341,8 +2338,7 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
if (!nested)
goto nla_put_failure;
- for (i = state->capa_start;
- i < rdev->wiphy.num_iftype_ext_capab; i++) {
+ for (i = 0; i < rdev->wiphy.num_iftype_ext_capab; i++) {
const struct wiphy_iftype_ext_capab *capab;
capab = &rdev->wiphy.iftype_ext_capab[i];
@@ -2361,14 +2357,8 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
goto nla_put_failure;
nla_nest_end(msg, nested_ext_capab);
- if (state->split)
- break;
}
nla_nest_end(msg, nested);
- if (i < rdev->wiphy.num_iftype_ext_capab) {
- state->capa_start = i + 1;
- break;
- }
}
if (nla_put_u32(msg, NL80211_ATTR_BANDS,
@@ -2397,14 +2387,16 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
goto nla_put_failure;
}
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 14:
if (nl80211_send_pmsr_capa(rdev, msg))
goto nla_put_failure;
+ last_good_pos = nlmsg_get_pos(msg);
state->split_start++;
- break;
+ /* Fall through */
case 15:
if (rdev->wiphy.akm_suites &&
nla_put(msg, NL80211_ATTR_AKM_SUITES,
@@ -2421,8 +2413,14 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
return 0;
nla_put_failure:
- genlmsg_cancel(msg, hdr);
- return -EMSGSIZE;
+ if ((state->legacy && state->split_start < 9) ||
+ !last_good_pos) {
+ genlmsg_cancel(msg, hdr);
+ return -EMSGSIZE;
+ }
+
+ nlmsg_trim(msg, last_good_pos);
+ goto finish;
}
static int nl80211_dump_wiphy_parse(struct sk_buff *skb,
@@ -2445,7 +2443,7 @@ static int nl80211_dump_wiphy_parse(struct sk_buff *skb,
goto out;
}
- state->split = tb[NL80211_ATTR_SPLIT_WIPHY_DUMP];
+ state->legacy = !tb[NL80211_ATTR_SPLIT_WIPHY_DUMP];
if (tb[NL80211_ATTR_WIPHY])
state->filter_wiphy = nla_get_u32(tb[NL80211_ATTR_WIPHY]);
if (tb[NL80211_ATTR_WDEV])
@@ -2526,7 +2524,7 @@ static int nl80211_dump_wiphy(struct sk_buff *skb, struct netlink_callback *cb)
* We can then retry with the larger buffer.
*/
if ((ret == -ENOBUFS || ret == -EMSGSIZE) &&
- !skb->len && !state->split &&
+ !skb->len && state->legacy &&
cb->min_dump_alloc < 4096) {
cb->min_dump_alloc = 4096;
state->split_start = 0;
@@ -2558,6 +2556,8 @@ static int nl80211_get_wiphy(struct sk_buff *skb, struct genl_info *info)
struct cfg80211_registered_device *rdev = info->user_ptr[0];
struct nl80211_dump_wiphy_state state = {};
+ state.legacy = true;
+
msg = nlmsg_new(4096, GFP_KERNEL);
if (!msg)
return -ENOMEM;
@@ -14737,6 +14737,8 @@ void nl80211_notify_wiphy(struct cfg80211_registered_device *rdev,
WARN_ON(cmd != NL80211_CMD_NEW_WIPHY &&
cmd != NL80211_CMD_DEL_WIPHY);
+ state.legacy = true;
+
msg = nlmsg_new(NLMSG_DEFAULT_SIZE, GFP_KERNEL);
if (!msg)
return;
--
2.19.2
^ permalink raw reply related
* [RFCv3 3/3] nl80211: Send large new_wiphy events
From: Denis Kenzior @ 2019-09-06 15:43 UTC (permalink / raw)
To: linux-wireless, johannes; +Cc: Denis Kenzior
In-Reply-To: <20190906154303.9303-1-denkenz@gmail.com>
Send large NEW_WIPHY events on a new multicast group so that clients
that can accept larger messages do not need to round-trip to the kernel
and perform extra filtered wiphy dumps.
A new multicast group is introduced and the large message is sent before
the legacy message. This way clients that listen on both multicast
groups can ignore duplicate legacy messages if needed.
Signed-off-by: Denis Kenzior <denkenz@gmail.com>
---
include/uapi/linux/nl80211.h | 31 +++++++++++++++++++++++++++++++
net/wireless/nl80211.c | 34 ++++++++++++++++++++++++++++++++--
2 files changed, 63 insertions(+), 2 deletions(-)
Changes in this version:
- Updated the docs based on Johannes' feedback
- Added WARN_ON in case the large message building fails (e.g. our
buffer size needs to be increased)
- Minor style fixes based on Johannes' feedback
- Added a missing skb_get to take an extra reference when sending
NEW/DEL INTERFACE events.
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index beee59c831a7..7a125cb4d9d9 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -50,6 +50,7 @@
#define NL80211_MULTICAST_GROUP_MLME "mlme"
#define NL80211_MULTICAST_GROUP_VENDOR "vendor"
#define NL80211_MULTICAST_GROUP_NAN "nan"
+#define NL80211_MULTICAST_GROUP_CONFIG2 "config2"
#define NL80211_MULTICAST_GROUP_TESTMODE "testmode"
#define NL80211_EDMG_BW_CONFIG_MIN 4
@@ -267,8 +268,30 @@
* @NL80211_CMD_NEW_WIPHY: Newly created wiphy, response to get request
* or rename notification. Has attributes %NL80211_ATTR_WIPHY and
* %NL80211_ATTR_WIPHY_NAME.
+ *
+ * Note that when %NL80211_CMD_NEW_WIPHY is being sent as an event, it
+ * will be multicast on two groups: "config" and "config2". The messages
+ * on the two multicast groups will be different. On "config" multicast
+ * group, %NL80211_CMD_NEW_WIPHY messages will be 'reduced' size and will
+ * only contain legacy information. This is due to historical kernel
+ * behavior that limited such messages to 4096 bytes. The "config2"
+ * multicast group was introduced to support applications that can
+ * allocate larger buffers and can thus accept new wiphy events with
+ * the full set of information included. Messages on the "config2"
+ * multicast group are sent before the "config" multicast group.
+ *
+ * There are no limits (outside of netlink protocol limits) on
+ * message sizes that can be sent over the "config2" multicast group. It
+ * is assumed that applications utilizing "config2" multicast group
+ * utilize buffers that are inherently large enough or can utilize
+ * MSG_PEEK/MSG_TRUNC in the netlink transport in order to allocate big
+ * enough buffers.
* @NL80211_CMD_DEL_WIPHY: Wiphy deleted. Has attributes
* %NL80211_ATTR_WIPHY and %NL80211_ATTR_WIPHY_NAME.
+ * Note that when %NL80211_CMD_DEL_WIPHY is being sent as an event, it
+ * will be multicast on two groups: "config" and "config2". Messages on
+ * the "config2" multicast group are sent before the "config" multicast
+ * group.
*
* @NL80211_CMD_GET_INTERFACE: Request an interface's configuration;
* either a dump request for all interfaces or a specific get with a
@@ -281,10 +304,18 @@
* be sent from userspace to request creation of a new virtual interface,
* then requires attributes %NL80211_ATTR_WIPHY, %NL80211_ATTR_IFTYPE and
* %NL80211_ATTR_IFNAME.
+ * Note that when %NL80211_CMD_NEW_INTERFACE is being sent as an event, it
+ * will be multicast on two groups: "config" and "config2". Messages on
+ * the "config2" multicast group are sent before the "config" multicast
+ * group.
* @NL80211_CMD_DEL_INTERFACE: Virtual interface was deleted, has attributes
* %NL80211_ATTR_IFINDEX and %NL80211_ATTR_WIPHY. Can also be sent from
* userspace to request deletion of a virtual interface, then requires
* attribute %NL80211_ATTR_IFINDEX.
+ * Note that when %NL80211_CMD_DEL_INTERFACE is being sent as an event, it
+ * will be multicast on two groups: "config" and "config2". Messages on
+ * the "config2" multicast group are sent before the "config" multicast
+ * group.
*
* @NL80211_CMD_GET_KEY: Get sequence counter information for a key specified
* by %NL80211_ATTR_KEY_IDX and/or %NL80211_ATTR_MAC.
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 03421f66eea3..68f496c0c0a4 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -46,6 +46,7 @@ enum nl80211_multicast_groups {
NL80211_MCGRP_MLME,
NL80211_MCGRP_VENDOR,
NL80211_MCGRP_NAN,
+ NL80211_MCGRP_CONFIG2,
NL80211_MCGRP_TESTMODE /* keep last - ifdef! */
};
@@ -56,6 +57,7 @@ static const struct genl_multicast_group nl80211_mcgrps[] = {
[NL80211_MCGRP_MLME] = { .name = NL80211_MULTICAST_GROUP_MLME },
[NL80211_MCGRP_VENDOR] = { .name = NL80211_MULTICAST_GROUP_VENDOR },
[NL80211_MCGRP_NAN] = { .name = NL80211_MULTICAST_GROUP_NAN },
+ [NL80211_MCGRP_CONFIG2] = { .name = NL80211_MULTICAST_GROUP_CONFIG2 },
#ifdef CONFIG_NL80211_TESTMODE
[NL80211_MCGRP_TESTMODE] = { .name = NL80211_MULTICAST_GROUP_TESTMODE }
#endif
@@ -1856,6 +1858,7 @@ struct nl80211_dump_wiphy_state {
long start;
long split_start, band_start, chan_start;
bool legacy;
+ bool large_message;
};
static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
@@ -2414,7 +2417,7 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *rdev,
nla_put_failure:
if ((state->legacy && state->split_start < 9) ||
- !last_good_pos) {
+ !last_good_pos || state->large_message) {
genlmsg_cancel(msg, hdr);
return -EMSGSIZE;
}
@@ -14732,14 +14735,37 @@ void nl80211_notify_wiphy(struct cfg80211_registered_device *rdev,
enum nl80211_commands cmd)
{
struct sk_buff *msg;
+ size_t alloc_size;
struct nl80211_dump_wiphy_state state = {};
WARN_ON(cmd != NL80211_CMD_NEW_WIPHY &&
cmd != NL80211_CMD_DEL_WIPHY);
+ if (cmd == NL80211_CMD_NEW_WIPHY) {
+ state.large_message = true;
+ alloc_size = 8192UL;
+ } else {
+ alloc_size = NLMSG_DEFAULT_SIZE;
+ }
+
+ msg = nlmsg_new(alloc_size, GFP_KERNEL);
+ if (!msg)
+ goto legacy;
+
+ if (WARN_ON(nl80211_send_wiphy(rdev, cmd, msg, 0, 0, 0, &state) < 0)) {
+ nlmsg_free(msg);
+ goto legacy;
+ }
+
+ genlmsg_multicast_netns(&nl80211_fam, wiphy_net(&rdev->wiphy), msg, 0,
+ NL80211_MCGRP_CONFIG2, GFP_KERNEL);
+
+legacy:
+ state.large_message = false;
state.legacy = true;
- msg = nlmsg_new(NLMSG_DEFAULT_SIZE, GFP_KERNEL);
+ alloc_size = NLMSG_DEFAULT_SIZE;
+ msg = nlmsg_new(alloc_size, GFP_KERNEL);
if (!msg)
return;
@@ -14767,6 +14793,10 @@ void nl80211_notify_iface(struct cfg80211_registered_device *rdev,
return;
}
+ /* We will be sending the same message twice, grab an extra ref */
+ msg = skb_get(msg);
+ genlmsg_multicast_netns(&nl80211_fam, wiphy_net(&rdev->wiphy), msg, 0,
+ NL80211_MCGRP_CONFIG2, GFP_KERNEL);
genlmsg_multicast_netns(&nl80211_fam, wiphy_net(&rdev->wiphy), msg, 0,
NL80211_MCGRP_CONFIG, GFP_KERNEL);
}
--
2.19.2
^ permalink raw reply related
* Re: [PATCH] mt76: mt7615: enable SCS by default
From: Toke Høiland-Jørgensen @ 2019-09-06 17:44 UTC (permalink / raw)
To: Lorenzo Bianconi, nbd; +Cc: lorenzo.bianconi, linux-wireless, ryder.lee, royluo
In-Reply-To: <5933942ffd23f71b925cc6be26e9918fd663ed46.1567783646.git.lorenzo@kernel.org>
Lorenzo Bianconi <lorenzo@kernel.org> writes:
> Enable Smart Carrier Sense algorithm by default in order to improve
> performances in a noisy environment
What does that do (the algorithm, that is)? :)
-Toke
^ permalink raw reply
* [PATCH] net: enable wireless core features with WIRELESS_ALLCONFIG
From: Mark Salyzyn @ 2019-09-06 18:05 UTC (permalink / raw)
To: linux-kernel
Cc: kernel-team, Mark Salyzyn, Johannes Berg, David S. Miller,
linux-wireless, netdev, stable
In embedded environments the requirements are to be able to pick and
chose which features one requires built into the kernel. If an
embedded environment wants to supports loading modules that have been
kbuilt out of tree, there is a need to enable hidden configurations
for core features to provide the API surface for them to load.
Introduce CONFIG_WIRELESS_ALLCONFIG to select all wireless core
features by activating all the hidden configuration options, without
having to specifically select any wireless module(s).
Signed-off-by: Mark Salyzyn <salyzyn@android.com>
Cc: kernel-team@android.com
Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: stable@vger.kernel.org # 4.19
---
net/wireless/Kconfig | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig
index 67f8360dfcee..0d32350e1729 100644
--- a/net/wireless/Kconfig
+++ b/net/wireless/Kconfig
@@ -17,6 +17,20 @@ config WEXT_SPY
config WEXT_PRIV
bool
+config WIRELESS_ALLCONFIG
+ bool "allconfig for wireless core"
+ select WIRELESS_EXT
+ select WEXT_CORE
+ select WEXT_PROC
+ select WEXT_SPY
+ select WEXT_PRIV
+ help
+ Config option used to enable all the wireless core functionality
+ used by modules.
+
+ If you are not building a kernel to be used for a variety of
+ out-of-kernel built wireless modules, say N here.
+
config CFG80211
tristate "cfg80211 - wireless configuration API"
depends on RFKILL || !RFKILL
--
2.23.0.187.g17f5b7556c-goog
^ permalink raw reply related
* [PATCH] ath9k_htc: release allocated buffer if timed out
From: Navid Emamdoost @ 2019-09-06 18:26 UTC (permalink / raw)
Cc: emamd001, smccaman, kjlu, Navid Emamdoost, QCA ath9k Development,
Kalle Valo, David S. Miller, linux-wireless, netdev, linux-kernel
In htc_config_pipe_credits, htc_setup_complete, and htc_connect_service
if time out happens, the allocated buffer needs to be released.
Otherwise there will be memory leak.
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
---
drivers/net/wireless/ath/ath9k/htc_hst.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/wireless/ath/ath9k/htc_hst.c b/drivers/net/wireless/ath/ath9k/htc_hst.c
index 1bf63a4efb4c..d091c8ebdcf0 100644
--- a/drivers/net/wireless/ath/ath9k/htc_hst.c
+++ b/drivers/net/wireless/ath/ath9k/htc_hst.c
@@ -170,6 +170,7 @@ static int htc_config_pipe_credits(struct htc_target *target)
time_left = wait_for_completion_timeout(&target->cmd_wait, HZ);
if (!time_left) {
dev_err(target->dev, "HTC credit config timeout\n");
+ kfree_skb(skb);
return -ETIMEDOUT;
}
@@ -205,6 +206,7 @@ static int htc_setup_complete(struct htc_target *target)
time_left = wait_for_completion_timeout(&target->cmd_wait, HZ);
if (!time_left) {
dev_err(target->dev, "HTC start timeout\n");
+ kfree_skb(skb);
return -ETIMEDOUT;
}
@@ -277,6 +279,7 @@ int htc_connect_service(struct htc_target *target,
if (!time_left) {
dev_err(target->dev, "Service connection timeout for: %d\n",
service_connreq->service_id);
+ kfree_skb(skb);
return -ETIMEDOUT;
}
--
2.17.1
^ permalink raw reply related
* Re: [PATCH] net: enable wireless core features with WIRELESS_ALLCONFIG
From: Marcel Holtmann @ 2019-09-06 18:31 UTC (permalink / raw)
To: Mark Salyzyn
Cc: linux-kernel, kernel-team, Johannes Berg, David S. Miller,
linux-wireless, netdev, stable
In-Reply-To: <20190906180551.163714-1-salyzyn@android.com>
Hi Mark,
> In embedded environments the requirements are to be able to pick and
> chose which features one requires built into the kernel. If an
> embedded environment wants to supports loading modules that have been
> kbuilt out of tree, there is a need to enable hidden configurations
> for core features to provide the API surface for them to load.
>
> Introduce CONFIG_WIRELESS_ALLCONFIG to select all wireless core
> features by activating all the hidden configuration options, without
> having to specifically select any wireless module(s).
>
> Signed-off-by: Mark Salyzyn <salyzyn@android.com>
> Cc: kernel-team@android.com
> Cc: Johannes Berg <johannes@sipsolutions.net>
> Cc: "David S. Miller" <davem@davemloft.net>
> Cc: linux-wireless@vger.kernel.org
> Cc: netdev@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: stable@vger.kernel.org # 4.19
> ---
> net/wireless/Kconfig | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig
> index 67f8360dfcee..0d32350e1729 100644
> --- a/net/wireless/Kconfig
> +++ b/net/wireless/Kconfig
> @@ -17,6 +17,20 @@ config WEXT_SPY
> config WEXT_PRIV
> bool
>
> +config WIRELESS_ALLCONFIG
> + bool "allconfig for wireless core"
> + select WIRELESS_EXT
> + select WEXT_CORE
> + select WEXT_PROC
> + select WEXT_SPY
> + select WEXT_PRIV
> + help
> + Config option used to enable all the wireless core functionality
> + used by modules.
> +
> + If you are not building a kernel to be used for a variety of
> + out-of-kernel built wireless modules, say N here.
> +
this looks rather legacy Wireless Extension (wext) specific. So it might be better to clearly name the option “legacy” and “wext” to not confuse anybody running an actual modern driver and userspace.
Regards
Marcel
^ permalink raw reply
* [PATCH] ath9k: release allocated buffer if timed out
From: Navid Emamdoost @ 2019-09-06 18:59 UTC (permalink / raw)
Cc: emamd001, smccaman, kjlu, Navid Emamdoost, QCA ath9k Development,
Kalle Valo, David S. Miller, linux-wireless, netdev, linux-kernel
In ath9k_wmi_cmd, the allocated network buffer needs to be released
if timeout happens. Otherwise memory will be leaked.
Signed-off-by: Navid Emamdoost <navid.emamdoost@gmail.com>
---
drivers/net/wireless/ath/ath9k/wmi.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/wireless/ath/ath9k/wmi.c b/drivers/net/wireless/ath/ath9k/wmi.c
index d1f6710ca63b..cdc146091194 100644
--- a/drivers/net/wireless/ath/ath9k/wmi.c
+++ b/drivers/net/wireless/ath/ath9k/wmi.c
@@ -336,6 +336,7 @@ int ath9k_wmi_cmd(struct wmi *wmi, enum wmi_cmd_id cmd_id,
ath_dbg(common, WMI, "Timeout waiting for WMI command: %s\n",
wmi_cmd_to_name(cmd_id));
mutex_unlock(&wmi->op_mutex);
+ kfree_skb(skb);
return -ETIMEDOUT;
}
--
2.17.1
^ permalink raw reply related
* [PATCH v2] net: enable wireless core features with LEGACY_WEXT_ALLCONFIG
From: Mark Salyzyn @ 2019-09-06 19:24 UTC (permalink / raw)
To: linux-kernel
Cc: kernel-team, Mark Salyzyn, Johannes Berg, David S. Miller,
Marcel Holtmann, linux-wireless, netdev, stable
In embedded environments the requirements are to be able to pick and
chose which features one requires built into the kernel. If an
embedded environment wants to supports loading modules that have been
kbuilt out of tree, there is a need to enable hidden configurations
for legacy wireless core features to provide the API surface for
them to load.
Introduce CONFIG_LEGACY_WEXT_ALLCONFIG to select all legacy wireless
extension core features by activating in turn all the associated
hidden configuration options, without having to specifically select
any wireless module(s).
Signed-off-by: Mark Salyzyn <salyzyn@android.com>
Cc: kernel-team@android.com
Cc: Johannes Berg <johannes@sipsolutions.net>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Cc: stable@vger.kernel.org # 4.19
---
v2: change name and documentation to CONFIG_LEGACY_WEXT_ALLCONFIG
---
net/wireless/Kconfig | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig
index 67f8360dfcee..0d646cf28de5 100644
--- a/net/wireless/Kconfig
+++ b/net/wireless/Kconfig
@@ -17,6 +17,20 @@ config WEXT_SPY
config WEXT_PRIV
bool
+config LEGACY_WEXT_ALLCONFIG
+ bool "allconfig for legacy wireless extensions"
+ select WIRELESS_EXT
+ select WEXT_CORE
+ select WEXT_PROC
+ select WEXT_SPY
+ select WEXT_PRIV
+ help
+ Config option used to enable all the legacy wireless extensions to
+ the core functionality used by add-in modules.
+
+ If you are not building a kernel to be used for a variety of
+ out-of-kernel built wireless modules, say N here.
+
config CFG80211
tristate "cfg80211 - wireless configuration API"
depends on RFKILL || !RFKILL
--
2.23.0.187.g17f5b7556c-goog
^ permalink raw reply related
* [PATCH] ath10k: restore QCA9880-AR1A (v1) detection
From: Christian Lamparter @ 2019-09-06 21:54 UTC (permalink / raw)
To: linux-wireless, ath10k; +Cc: Kalle Valo
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
index a0b4d265c6eb..347bb92e4130 100644
--- a/drivers/net/wireless/ath/ath10k/pci.c
+++ b/drivers/net/wireless/ath/ath10k/pci.c
@@ -3490,7 +3490,7 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
struct ath10k_bus_params bus_params = {};
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
int (*pci_soft_reset)(struct ath10k *ar);
int (*pci_hard_reset)(struct ath10k *ar);
u32 (*targ_cpu_to_ce_addr)(struct ath10k *ar, u32 addr);
@@ -3500,6 +3500,7 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
pci_soft_reset = ath10k_pci_warm_reset;
pci_hard_reset = ath10k_pci_qca988x_chip_reset;
targ_cpu_to_ce_addr = ath10k_pci_qca988x_targ_cpu_to_ce_addr;
@@ -3619,25 +3620,34 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
goto err_deinit_irq;
}
+ bus_params.dev_type = ATH10K_DEV_TYPE_LL;
+ bus_params.link_can_suspend = true;
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ bus_params.chip_id =
+ ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (bus_params.chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ bus_params.chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
goto err_free_irq;
}
- bus_params.dev_type = ATH10K_DEV_TYPE_LL;
- bus_params.link_can_suspend = true;
bus_params.chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
- if (bus_params.chip_id == 0xffffffff) {
- ath10k_err(ar, "failed to get chip id\n");
- goto err_free_irq;
- }
+ if (bus_params.chip_id == 0xffffffff)
+ goto err_unsupported;
- if (!ath10k_pci_chip_is_supported(pdev->device, bus_params.chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, bus_params.chip_id);
+ if (!ath10k_pci_chip_is_supported(pdev->device, bus_params.chip_id))
goto err_free_irq;
- }
ret = ath10k_core_register(ar, &bus_params);
if (ret) {
@@ -3647,6 +3657,10 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_rx_retry_sync(ar);
--
2.23.0
^ permalink raw reply related
* Re: [PATCH] iwlwifi: Extended Key ID support for mvm and dvm
From: Alexander Wetzel @ 2019-09-06 20:41 UTC (permalink / raw)
To: johannes, luciano.coelho; +Cc: linux-wireless, linuxwifi
In-Reply-To: <20190819180540.2855-1-alexander@wetzel-home.de>
Am 19.08.19 um 20:05 schrieb Alexander Wetzel:
> All iwlwifi cards below the 22000 series are able to handle multiple
> keyids per STA and allow the selection of the encryption key per MPDU.
>
> These are therefore fully compatible with the Extended Key ID support
> implementation in mac80211.
>
> Enable Extended Key ID support for all dvm cards and the mvm cards not
> using the incompatible new Tx API introduced for the 22000 series.
>
> Signed-off-by: Alexander Wetzel <alexander@wetzel-home.de>
> ---
>
> This is basically the V3 of the patch, but the other patches were part
> of series and this here is the first standalone version.
>
> V1: https://patchwork.kernel.org/patch/10931879/
> V2: https://patchwork.kernel.org/patch/11024137/
>
> V1 become deprecated due to redesigning the Extended Key ID support API.
> V2 became deprecated due to the discovery that the 22000 is not (yet)
> able to support Extended Key ID.
>
> The patch is still super trivial, but I cross checked that Extended Key
> ID support is enabled with my old 3168 card and disabled with my new
> AX200 card.
For what it's worth:
I just upgraded my test AP from the initial AC 3168 to an AC 9560 card
after the AC 201 turned out to be incompatible (for now).
So I can now confirm that Extended Key ID is also working with this card
and the patch here. (Tested against my "reference" system using an old
Intel Ultimate-N 6300.)
Alexander
^ permalink raw reply
* Re: [PATCH v2] net: enable wireless core features with LEGACY_WEXT_ALLCONFIG
From: Greg KH @ 2019-09-06 23:30 UTC (permalink / raw)
To: Mark Salyzyn
Cc: linux-kernel, kernel-team, Johannes Berg, David S. Miller,
Marcel Holtmann, linux-wireless, netdev, stable
In-Reply-To: <20190906192403.195620-1-salyzyn@android.com>
On Fri, Sep 06, 2019 at 12:24:00PM -0700, Mark Salyzyn wrote:
> In embedded environments the requirements are to be able to pick and
> chose which features one requires built into the kernel. If an
> embedded environment wants to supports loading modules that have been
> kbuilt out of tree, there is a need to enable hidden configurations
> for legacy wireless core features to provide the API surface for
> them to load.
>
> Introduce CONFIG_LEGACY_WEXT_ALLCONFIG to select all legacy wireless
> extension core features by activating in turn all the associated
> hidden configuration options, without having to specifically select
> any wireless module(s).
>
> Signed-off-by: Mark Salyzyn <salyzyn@android.com>
> Cc: kernel-team@android.com
> Cc: Johannes Berg <johannes@sipsolutions.net>
> Cc: "David S. Miller" <davem@davemloft.net>
> Cc: Marcel Holtmann <marcel@holtmann.org>
> Cc: linux-wireless@vger.kernel.org
> Cc: netdev@vger.kernel.org
> Cc: linux-kernel@vger.kernel.org
> Cc: stable@vger.kernel.org # 4.19
> ---
> v2: change name and documentation to CONFIG_LEGACY_WEXT_ALLCONFIG
> ---
> net/wireless/Kconfig | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig
> index 67f8360dfcee..0d646cf28de5 100644
> --- a/net/wireless/Kconfig
> +++ b/net/wireless/Kconfig
> @@ -17,6 +17,20 @@ config WEXT_SPY
> config WEXT_PRIV
> bool
>
> +config LEGACY_WEXT_ALLCONFIG
> + bool "allconfig for legacy wireless extensions"
> + select WIRELESS_EXT
> + select WEXT_CORE
> + select WEXT_PROC
> + select WEXT_SPY
> + select WEXT_PRIV
> + help
> + Config option used to enable all the legacy wireless extensions to
> + the core functionality used by add-in modules.
> +
> + If you are not building a kernel to be used for a variety of
> + out-of-kernel built wireless modules, say N here.
> +
> config CFG80211
> tristate "cfg80211 - wireless configuration API"
> depends on RFKILL || !RFKILL
> --
> 2.23.0.187.g17f5b7556c-goog
>
How is this patch applicable to stable kernels???
^ permalink raw reply
* Re: [PATCH] mt76: mt7615: enable SCS by default
From: Lorenzo Bianconi @ 2019-09-07 5:07 UTC (permalink / raw)
To: Toke Høiland-Jørgensen
Cc: Lorenzo Bianconi, Felix Fietkau, Lorenzo Bianconi, linux-wireless,
Ryder Lee, Roy Luo
In-Reply-To: <87mufhz5e9.fsf@toke.dk>
>
> Lorenzo Bianconi <lorenzo@kernel.org> writes:
>
> > Enable Smart Carrier Sense algorithm by default in order to improve
> > performances in a noisy environment
>
> What does that do (the algorithm, that is)? :)
>
> -Toke
Hi Toke,
it is used for tuning device sensitivity according to RTS error rate
and False CCA reported by the radio (e.g decrease radio sensitivity to
cut off interference stations).
It has been ported from vendor sdk.
https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next.git/commit/drivers/net/wireless/mediatek/mt76/mt7615?id=49de79ad9a748c86277f39613ade72dc56421454
Regards,
Lorenzo
^ permalink raw reply
* Re: pull-request: iwlwifi-next 2019-09-06
From: Kalle Valo @ 2019-09-07 7:24 UTC (permalink / raw)
To: Luca Coelho; +Cc: linux-wireless, linuxwifi, david.e.box, joe.konno
In-Reply-To: <ed169588021b846217aa86cbf2576a1375653065.camel@coelho.fi>
Luca Coelho <luca@coelho.fi> writes:
> Here's a batch of patches intended for v5.4. This includes the last
> patchset 4 patchsets I sent. Usual development work. More details
> about the contents in the tag
> description.
>
> I pushed this to my pending branch and I got results from kbuildbot to
> some of the series, but I didn't get any results yet from the two last
> v2 series I sent. I'll let you know if I get any results in the next
> couple of days.
Yesterday evening I pulled this to my pending branch and I did get a
success report from kbuildbot.
> Please let me know if there are any issues.
>
> Cheers,
> Luca.
>
>
> The following changes since commit a18da8f6194978c2b32a8367fb0df81cc6417848:
>
> Merge tag 'mt76-for-kvalo-2019-09-05' of https://github.com/nbd168/wireless (2019-09-06 11:59:32 +0300)
>
> are available in the Git repository at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next.git tags/iwlwifi-next-for-kalle-2019-09-06
Pulled, thanks Luca.
--
Kalle Valo
^ permalink raw reply
* pull-request: wireless-drivers-next 2019-09-07
From: Kalle Valo @ 2019-09-07 8:01 UTC (permalink / raw)
To: David Miller; +Cc: linux-wireless, netdev, linux-kernel
Hi Dave,
here's a pull request to net-next for v5.4, more info below. Please let
me know if there are any problems.
Kalle
The following changes since commit 67538eb5c00f08d7fe27f1bb703098b17302bdc0:
Merge branch 'mvpp2-per-cpu-buffers' (2019-09-02 12:07:46 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next.git tags/wireless-drivers-next-for-davem-2019-09-07
for you to fetch changes up to 67e974c3ae21c8ced474eae3ce9261a6f827e95c:
Merge tag 'iwlwifi-next-for-kalle-2019-09-06' of git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next (2019-09-07 10:21:07 +0300)
----------------------------------------------------------------
wireless-drivers-next patches for 5.4
Second set of patches for 5.4. Lots of changes for iwlwifi and mt76,
but also smaller changes to other drivers.
Major changes:
iwlwifi
* remove broken and unused runtime power management mode for PCIe
devices, removes IWLWIFI_PCIE_RTPM Kconfig option as well
* support new ACPI value for per-platform antenna gain
* support for single antenna diversity
* support for new WoWLAN FW API
brcmfmac
* add reset debugfs file for testing firmware restart
mt76
* DFS pattern detector for mt7615 (DFS channels not enabled yet)
* Channel Switch Announcement (CSA) support for mt7615
* new device support for mt76x0
* support for more ciphers in mt7615
* smart carrier sense on mt7615
* survey support on mt7615
* multiple interfaces on mt76x02u
rtw88
* enable MSI interrupt
----------------------------------------------------------------
Alex Malamud (2):
iwlwifi: LTR updates
iwlwifi: Set w-pointer upon resume according to SN
Andy Shevchenko (3):
hostap: use %*ph to print small buffer
brcmfmac: use %*ph to print small buffer
zd1211rw: use %*ph to print small buffer
Ayala Beker (2):
iwlwifi: scan: add support for new scan request command version
iwlwifi: scan: don't pass large argument by value
Beker Ayala (1):
iwlwifi: mvm: fix scan config command size
Christoph Hellwig (1):
iwlwifi: stop passing bogus gfp flags arguments to dma_alloc_coherent
Colin Ian King (4):
rtw88: remove redundant assignment to pointer debugfs_topdir
brcmfmac: remove redundant assignment to pointer hash
ipw2x00: fix spelling mistake "initializationg" -> "initialization"
bcma: fix incorrect update of BCMA_CORE_PCI_MDIO_DATA
Dan Carpenter (1):
rtw88: Fix an error message
Emmanuel Grumbach (20):
iwlwifi: mvm: remove redundant condition in iwl_mvm_set_hw_rfkill_state
iwlwifi: mvm: start to remove the code for d0i3
iwlwifi: remove all the d0i3 references
iwlwifi: mvm: remove the tx defer for d0i3
iwlwifi: mvm: remove the d0i3 entry/exit flow
iwlwifi: mvm: iwl_mvm_wowlan_config_key_params is for wowlan only
iwlwifi: mvm: remove d0i3_ap_sta_id
iwlwifi: mvm: remove iwl_mvm_update_d0i3_power_mode
iwlwifi: mvm: remove last leftovers of d0i3
iwlwifi: remove CMD_HIGH_PRIO
iwlwifi: trans: remove suspending flag
iwlwifi: remove the code under IWLWIFI_PCIE_RTPM
iwlwifi: remove runtime_pm_mode
iwlwifi: remove the opmode's d0i3 handlers
iwlwifi: pcie: remove the refs / unrefs from the transport
iwlwifi: pcie: remove some more d0i3 code from the transport
iwlwifi: remove the d0i3 related module parameters
iwlwifi: remove pm_runtime completely
iwlwifi: mvm: simplify the channel switch flow for newer firmware
iwlwifi: mvm: don't log un-decrypted frames
Felix Fietkau (16):
mt76: round up length on mt76_wr_copy
mt76: mt7615: clean up FWDL TXQ during/after firmware upload
mt76: mt7603: enable hardware rate up/down selection
mt76: mt7615: move mt7615_mcu_set_rates to mac.c
mt76: mt7615: reset rate index/counters on rate table update
mt76: mt7615: sync with mt7603 rate control changes
mt76: mt7615: fix using VHT STBC rates
mt76: mt7615: fix PS buffering of action frames
mt76: mt7615: fix invalid fallback rates
mt76: mt7603: fix invalid fallback rates
mt76: mt7615: add missing register initialization
mt76: mt7615: apply calibration-free data from OTP
mt76: dma: reset q->rx_head on rx reset
mt76: stop rx aggregation on station removal
mt76: do not send BAR frame on tx aggregation flush stop
mt76: remove offchannel check in tx scheduling
Gil Adam (1):
iwlwifi: support per-platform antenna gain
Guenter Roeck (1):
rtw88: drop unused rtw_coex_coex_dm_reset()
Gustavo A. R. Silva (1):
zd1211rw: zd_usb: Use struct_size() helper
Haim Dreyfuss (4):
iwlwifi: remove unused regdb_ptrs allocation
iwlwifi: add support for suspend-resume flow for new device generation
iwlwifi: add sta_id to WOWLAN_CONFIG_CMD
iwlwifi: mvm: add support for single antenna diversity
Hariprasad Kelam (1):
iwlwifi: fix warning iwl-trans.h is included more than once
Ilan Peer (1):
iwlwifi: mvm: Block 26-tone RU OFDMA transmissions
Ilia Lin (1):
iwlwifi: Send DQA enable command only if TVL is on
Jia-Ju Bai (1):
brcm80211: Avoid possible null-pointer dereferences in wlc_phy_radio_init_2056()
Jian-Hong Pan (1):
rtw88: pci: Move a mass of jobs in hw IRQ to soft IRQ
Johannes Berg (5):
iwlwifi: mvm: remove unnecessary forward declarations
iwlwifi: mvm: use FW thermal monitoring regardless of CONFIG_THERMAL
iwlwifi: api: fix FTM struct documentation
iwlwifi: mvm: drop BA sessions on too many old-SN frames
iwlwifi: mvm: handle BAR_FRAME_RELEASE (0xc2) notification
Kalle Valo (2):
Merge tag 'mt76-for-kvalo-2019-09-05' of https://github.com/nbd168/wireless
Merge tag 'iwlwifi-next-for-kalle-2019-09-06' of git://git.kernel.org/.../iwlwifi/iwlwifi-next
Larry Finger (14):
rtlwifi: rtl8192cu: Fix value set in descriptor
rtlwifi: rtl_pci: Fix memory leak when hardware init fails
rtlwifi: rtl8192ee: Remove unused GET_XXX and SET_XXX
rtlwifi: rtl8192ee: Replace local bit manipulation macros
rtlwifi: rtl8192ee: Convert macros that set descriptor
rtlwifi: rtl8192ee: Convert inline routines to little-endian words
rtlwifi: rtl8192ee: Remove some variable initializations
rtlwifi: rtl8192cu: Remove unused GET_XXX and SET_XXX
rtlwifi: rtl8192cu: Replace local bit manipulation macros
rtlwifi: rtl8192cu: Convert macros that set descriptor
rtlwifi: rtl8192cu: Convert inline routines to little-endian words
rtlwifi: rtl8821ae: Fix incorrect returned values
rtlwifi: rtl8188ee: Fix incorrect returned values
rtlwifi: rtl8192ce: Fix incorrect returned values
Lorenzo Bianconi (33):
mt76: mt7615: fix sparse warnings: warning: restricted __le16 degrades to integer
mt76: mt7615: introduce mt7615_regd_notifier
mt76: mt7615: add hw dfs pattern detector support
mt76: mt7615: do not perform txcalibration before cac is complited
mt76: mt7615: add csa support
mt76: mt7615: add radar pattern test knob to debugfs
mt76: mt7615: fall back to sw encryption for unsupported ciphers
mt76: mt7615: always release sem in mt7615_load_patch
mt76: mt7615: introduce mt7615_mcu_send_ram_firmware routine
mt76: mt76u: fix typo in mt76u_fill_rx_sg
mt76: mt76x0u: add support to TP-Link T2UHP
mt76: mt7615: move mt7615_mac_get_key_info in mac.c
mt76: mt7615: add mt7615_mac_wtbl_addr routine
mt76: mt7615: introduce mt7615_mac_wtbl_set_key routine
mt76: mt7615: remove wtbl_sec_key definition
mt76: mt7615: add set_key_cmd and mt76_wcid to mt7615_mac_wtbl_set_key signature
mt76: introduce mt76_mmio_read_copy routine
mt76: mt7615: fix MT7615_WATCHDOG_TIME definition
mt76: mt7603: fix watchdog rescheduling in mt7603_set_channel
mt76: mt7615: rework locking scheme for mt7615_set_channel
mt76: mt7615: add Smart Carrier Sense support
mt76: mt76x02: introduce mt76x02_pre_tbtt_enable and mt76x02_beacon_enable macros
mt76: mt76x02: do not copy beacon skb in mt76x02_mac_set_beacon_enable
mt76: mt76x02u: enable multi-vif support
mt76: mt76x02u: enable survey support
mt76: mt7603: move survey_time in mt76_dev
mt76: mt7615: enable survey support
mt76: move mt76_tx_tasklet in mt76 module
mt76: mt7603: remove unnecessary mcu queue initialization
mt76: mt7615: add BIP_CMAC_128 cipher support
mt76: add default implementation for mt76_sw_scan/mt76_sw_scan_complete
mt76: mt7615: introduce mt7615_txwi_to_txp utility routine
mt76: mt7615: add support to read temperature from mcu
Luca Coelho (12):
iwlwifi: bump FW API to 49 for 22000 series
iwlwifi: mvm: remove check for lq_sta in __iwl_mvm_rs_tx_status()
iwlwifi: bump FW API to 50 for 22000 series
iwlwifi: remove duplicate FW string definitions
iwlwifi: remove unnecessary IWL_DEVICE_AX200_COMMON definition
iwlwifi: separate elements from cfg that are needed by trans_alloc
iwlwifi: pcie: use the cfg we passed to iwl_trans_pcie_alloc()
iwlwifi: pcie: move some cfg mangling from trans_pcie_alloc to probe
iwlwifi: pcie: set iwl_trans->cfg later in the probe function
iwlwifi: pass the iwl_config_trans_params when needed
iwlwifi: add a pointer to the trans_cfg directly in trans
iwlwifi: always access the trans configuration via trans
Mordechay Goodstein (1):
iwlwifi: mvm: name magic numbers with enum
Oliver Neukum (1):
zd1211rw: remove false assertion from zd_mac_clear()
Rafał Miłecki (3):
brcmfmac: get chip's default RAM info during PCIe setup
brcmfmac: add stub version of brcmf_debugfs_get_devdir()
brcmfmac: add "reset" debugfs entry for testing reset
Ryder Lee (8):
mt76: mt7615: add 4 WMM sets support
mt76: mt7615: update cw_min/max related settings
mt76: Add paragraphs to describe the config symbols fully
mt76: mt7603: fix some checkpatch warnings
mt76: mt7615: fix some checkpatch warnings
mt76: mt76x02: fix some checkpatch warnings
mt76: switch to SPDX tag instead of verbose boilerplate text
mt76: fix some checkpatch warnings
Shahar S Matityahu (24):
iwlwifi: dbg: move monitor recording functionality from header file
iwlwifi: dbg: move debug recording stop from trans to op mode
iwlwifi: dbg: support debug recording suspend resume command
iwlwifi: add ldbg config cmd debug print
iwlwifi: dbg_ini: align dbg tlv functions names to a single format
iwlwifi: dbg: add debug periphery registers to 9000 device family
iwlwifi: dbg_ini: maintain buffer allocations from trans instead of TLVs buffer
iwlwifi: dbg_ini: use linked list to store debug TLVs
iwlwifi: dbg_ini: remove periphery phy and aux regions handling
iwlwifi: dbg_ini: use function to check if ini dbg mode is on
iwlwifi: dbg_ini: verify debug TLVs at allocation phase
iwlwifi: dbg_ini: remove debug flow TLV
iwlwifi: dbg: align wrt log prints to the same format
iwlwifi: dbg_ini: separate cfg and dump flows to different modules
iwlwifi: dbg_ini: use linked list for dump TLVs during dump creation
iwlwifi: dbg_ini: move tx fifo data into fw runtime
iwlwifi: dbg_ini: make a single ops struct for paging collect
iwlwifi: dbg_ini: use regions ops array instead of switch case in dump flow
iwlwifi: add iwl_tlv_array_len()
iwlwifi: dbg_ini: remove apply point, switch to time point API
iwlwifi: fw api: add DRAM buffer allocation command
iwlwifi: dbg_ini: fix dump structs doc
iwlwifi: dbg_ini: remove periodic trigger
iwlwifi: dbg: remove iwl_fw_cancel_dumps function
Shaul Triebitz (2):
iwlwifi: mvm: add the skb length to a print
iwlwifi: pass the iwl_trans instead of cfg to some functions
Stanislaw Gruszka (9):
rt2x00: do not set IEEE80211_TX_STAT_AMPDU_NO_BACK on tx status
mt76: usb: fix endian in mt76u_copy
mt76: usb: remove unneeded {put,get}_unaligned
mt76: mt76x02: use params->ssn value directly
mt76: mt7603: use params->ssn value directly
mt76: mt7615: use params->ssn value directly
mt76: make mt76_rx_convert static
mt76: mt76x0: remove redundant chandef copy
mt76: mt76x0: remove unneeded return value on set channel
Tova Mussai (2):
iwlwifi: allocate bigger nvm data in case of UHB
iwlwifi: mvm: look for the first supported channel when add/remove phy ctxt
Valdis Kletnieks (1):
rtlwifi: fix non-kerneldoc comment in usb.c
Wei Yongjun (2):
rtw88: fix seq_file memory leak
rtlwifi: Fix file release memory leak
Wenwen Wang (1):
airo: fix memory leaks
Xulin Sun (1):
brcmfmac: replace strncpy() by strscpy()
Yu-Yen Ting (1):
rtw88: pci: enable MSI interrupt
YueHaibing (3):
rtlwifi: remove unused variables 'RTL8712_SDIO_EFUSE_TABLE' and 'MAX_PGPKT_SIZE'
bcma: remove two unused variables
mt76: mt7603: use devm_platform_ioremap_resource() to simplify code
zhong jiang (1):
hostap: remove set but not used variable 'copied' in prism2_io_debug_proc_read
drivers/bcma/driver_mips.c | 16 -
drivers/bcma/driver_pci.c | 4 +-
.../broadcom/brcm80211/brcmfmac/cfg80211.c | 22 +-
.../wireless/broadcom/brcm80211/brcmfmac/chip.c | 6 +-
.../wireless/broadcom/brcm80211/brcmfmac/chip.h | 1 +
.../wireless/broadcom/brcm80211/brcmfmac/core.c | 25 +
.../wireless/broadcom/brcm80211/brcmfmac/debug.h | 4 +
.../wireless/broadcom/brcm80211/brcmfmac/msgbuf.c | 1 -
.../wireless/broadcom/brcm80211/brcmfmac/pcie.c | 6 +
.../broadcom/brcm80211/brcmsmac/phy/phy_n.c | 2 +-
drivers/net/wireless/cisco/airo.c | 11 +-
drivers/net/wireless/intel/ipw2x00/ipw2200.c | 2 +-
drivers/net/wireless/intel/iwlwifi/Kconfig | 14 -
drivers/net/wireless/intel/iwlwifi/cfg/1000.c | 14 +-
drivers/net/wireless/intel/iwlwifi/cfg/2000.c | 26 +-
drivers/net/wireless/intel/iwlwifi/cfg/22000.c | 46 +-
drivers/net/wireless/intel/iwlwifi/cfg/5000.c | 18 +-
drivers/net/wireless/intel/iwlwifi/cfg/6000.c | 44 +-
drivers/net/wireless/intel/iwlwifi/cfg/7000.c | 10 +-
drivers/net/wireless/intel/iwlwifi/cfg/8000.c | 10 +-
drivers/net/wireless/intel/iwlwifi/cfg/9000.c | 10 +-
drivers/net/wireless/intel/iwlwifi/dvm/devices.c | 3 +-
drivers/net/wireless/intel/iwlwifi/dvm/led.c | 5 +-
drivers/net/wireless/intel/iwlwifi/dvm/mac80211.c | 4 +-
drivers/net/wireless/intel/iwlwifi/dvm/main.c | 12 +-
drivers/net/wireless/intel/iwlwifi/dvm/power.c | 3 +-
drivers/net/wireless/intel/iwlwifi/dvm/tx.c | 5 +-
drivers/net/wireless/intel/iwlwifi/fw/acpi.h | 12 +
.../net/wireless/intel/iwlwifi/fw/api/commands.h | 7 +
drivers/net/wireless/intel/iwlwifi/fw/api/d3.h | 6 +-
.../net/wireless/intel/iwlwifi/fw/api/dbg-tlv.h | 102 +-
drivers/net/wireless/intel/iwlwifi/fw/api/debug.h | 83 +-
.../net/wireless/intel/iwlwifi/fw/api/location.h | 4 +-
drivers/net/wireless/intel/iwlwifi/fw/api/mac.h | 4 +
drivers/net/wireless/intel/iwlwifi/fw/api/phy.h | 7 +
drivers/net/wireless/intel/iwlwifi/fw/api/power.h | 12 +
drivers/net/wireless/intel/iwlwifi/fw/api/rs.h | 18 +-
drivers/net/wireless/intel/iwlwifi/fw/api/rx.h | 32 +
drivers/net/wireless/intel/iwlwifi/fw/api/scan.h | 55 +-
drivers/net/wireless/intel/iwlwifi/fw/dbg.c | 1155 +++++++-------------
drivers/net/wireless/intel/iwlwifi/fw/dbg.h | 121 +-
drivers/net/wireless/intel/iwlwifi/fw/error-dump.h | 38 +-
drivers/net/wireless/intel/iwlwifi/fw/file.h | 29 +-
drivers/net/wireless/intel/iwlwifi/fw/img.h | 9 -
drivers/net/wireless/intel/iwlwifi/fw/init.c | 2 -
drivers/net/wireless/intel/iwlwifi/fw/paging.c | 6 +-
drivers/net/wireless/intel/iwlwifi/fw/runtime.h | 23 +-
drivers/net/wireless/intel/iwlwifi/fw/smem.c | 2 +-
drivers/net/wireless/intel/iwlwifi/iwl-config.h | 51 +-
drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.c | 236 ++--
drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.h | 36 +-
drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h | 1 -
drivers/net/wireless/intel/iwlwifi/iwl-drv.c | 30 +-
.../net/wireless/intel/iwlwifi/iwl-eeprom-parse.c | 21 +-
.../net/wireless/intel/iwlwifi/iwl-eeprom-parse.h | 4 +-
.../net/wireless/intel/iwlwifi/iwl-eeprom-read.c | 14 +-
drivers/net/wireless/intel/iwlwifi/iwl-fh.h | 6 +-
drivers/net/wireless/intel/iwlwifi/iwl-io.c | 21 +-
drivers/net/wireless/intel/iwlwifi/iwl-io.h | 18 +-
drivers/net/wireless/intel/iwlwifi/iwl-modparams.h | 9 +-
drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.c | 60 +-
drivers/net/wireless/intel/iwlwifi/iwl-op-mode.h | 27 +-
drivers/net/wireless/intel/iwlwifi/iwl-prph.h | 5 +
drivers/net/wireless/intel/iwlwifi/iwl-trans.c | 16 -
drivers/net/wireless/intel/iwlwifi/iwl-trans.h | 150 +--
drivers/net/wireless/intel/iwlwifi/mvm/constants.h | 1 +
drivers/net/wireless/intel/iwlwifi/mvm/d3.c | 224 +---
drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c | 154 +--
drivers/net/wireless/intel/iwlwifi/mvm/fw.c | 183 +++-
drivers/net/wireless/intel/iwlwifi/mvm/led.c | 6 +-
drivers/net/wireless/intel/iwlwifi/mvm/mac-ctxt.c | 9 +-
drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c | 424 ++-----
drivers/net/wireless/intel/iwlwifi/mvm/mvm.h | 150 +--
drivers/net/wireless/intel/iwlwifi/mvm/nvm.c | 4 +-
drivers/net/wireless/intel/iwlwifi/mvm/ops.c | 480 +-------
drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c | 11 +-
drivers/net/wireless/intel/iwlwifi/mvm/power.c | 82 +-
drivers/net/wireless/intel/iwlwifi/mvm/rs-fw.c | 19 +-
drivers/net/wireless/intel/iwlwifi/mvm/rs.c | 8 +-
drivers/net/wireless/intel/iwlwifi/mvm/rx.c | 18 +-
drivers/net/wireless/intel/iwlwifi/mvm/rxmq.c | 115 +-
drivers/net/wireless/intel/iwlwifi/mvm/scan.c | 98 +-
drivers/net/wireless/intel/iwlwifi/mvm/sta.c | 29 +-
drivers/net/wireless/intel/iwlwifi/mvm/tdls.c | 9 -
.../net/wireless/intel/iwlwifi/mvm/time-event.c | 8 +-
drivers/net/wireless/intel/iwlwifi/mvm/tt.c | 12 +-
drivers/net/wireless/intel/iwlwifi/mvm/tx.c | 9 +-
drivers/net/wireless/intel/iwlwifi/mvm/utils.c | 19 +-
.../wireless/intel/iwlwifi/pcie/ctxt-info-gen3.c | 4 +-
drivers/net/wireless/intel/iwlwifi/pcie/drv.c | 326 ++----
drivers/net/wireless/intel/iwlwifi/pcie/internal.h | 38 +-
drivers/net/wireless/intel/iwlwifi/pcie/rx.c | 77 +-
.../net/wireless/intel/iwlwifi/pcie/trans-gen2.c | 19 +-
drivers/net/wireless/intel/iwlwifi/pcie/trans.c | 380 +++----
drivers/net/wireless/intel/iwlwifi/pcie/tx-gen2.c | 52 +-
drivers/net/wireless/intel/iwlwifi/pcie/tx.c | 176 ++-
.../net/wireless/intersil/hostap/hostap_download.c | 6 +-
drivers/net/wireless/intersil/hostap/hostap_plx.c | 3 +-
drivers/net/wireless/intersil/hostap/hostap_proc.c | 3 +-
drivers/net/wireless/mediatek/mt76/agg-rx.c | 36 +-
drivers/net/wireless/mediatek/mt76/debugfs.c | 13 +-
drivers/net/wireless/mediatek/mt76/dma.c | 21 +-
drivers/net/wireless/mediatek/mt76/dma.h | 13 +-
drivers/net/wireless/mediatek/mt76/eeprom.c | 13 +-
drivers/net/wireless/mediatek/mt76/mac80211.c | 78 +-
drivers/net/wireless/mediatek/mt76/mcu.c | 13 +-
drivers/net/wireless/mediatek/mt76/mmio.c | 28 +-
drivers/net/wireless/mediatek/mt76/mt76.h | 43 +-
drivers/net/wireless/mediatek/mt76/mt7603/Kconfig | 6 +-
drivers/net/wireless/mediatek/mt76/mt7603/beacon.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7603/core.c | 2 +-
.../net/wireless/mediatek/mt76/mt7603/debugfs.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7603/dma.c | 17 +-
drivers/net/wireless/mediatek/mt76/mt7603/eeprom.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7603/init.c | 6 +-
drivers/net/wireless/mediatek/mt76/mt7603/mac.c | 14 +-
drivers/net/wireless/mediatek/mt76/mt7603/main.c | 41 +-
drivers/net/wireless/mediatek/mt76/mt7603/mcu.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7603/mt7603.h | 1 -
drivers/net/wireless/mediatek/mt76/mt7603/pci.c | 2 +-
drivers/net/wireless/mediatek/mt76/mt7603/soc.c | 5 +-
drivers/net/wireless/mediatek/mt76/mt7615/Kconfig | 7 +-
drivers/net/wireless/mediatek/mt76/mt7615/Makefile | 3 +-
.../net/wireless/mediatek/mt76/mt7615/debugfs.c | 91 ++
drivers/net/wireless/mediatek/mt76/mt7615/dma.c | 12 +-
drivers/net/wireless/mediatek/mt76/mt7615/eeprom.c | 38 +
drivers/net/wireless/mediatek/mt76/mt7615/init.c | 80 +-
drivers/net/wireless/mediatek/mt76/mt7615/mac.c | 733 ++++++++++++-
drivers/net/wireless/mediatek/mt76/mt7615/mac.h | 28 +
drivers/net/wireless/mediatek/mt76/mt7615/main.c | 111 +-
drivers/net/wireless/mediatek/mt76/mt7615/mcu.c | 474 ++++----
drivers/net/wireless/mediatek/mt76/mt7615/mcu.h | 54 +-
drivers/net/wireless/mediatek/mt76/mt7615/mt7615.h | 99 +-
drivers/net/wireless/mediatek/mt76/mt7615/pci.c | 1 +
drivers/net/wireless/mediatek/mt76/mt7615/regs.h | 75 ++
drivers/net/wireless/mediatek/mt76/mt76x0/Kconfig | 12 +-
drivers/net/wireless/mediatek/mt76/mt76x0/main.c | 17 +-
drivers/net/wireless/mediatek/mt76/mt76x0/mt76x0.h | 2 +-
drivers/net/wireless/mediatek/mt76/mt76x0/pci.c | 15 +-
.../net/wireless/mediatek/mt76/mt76x0/pci_mcu.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x0/phy.c | 49 +-
drivers/net/wireless/mediatek/mt76/mt76x0/phy.h | 10 +-
drivers/net/wireless/mediatek/mt76/mt76x0/usb.c | 28 +-
.../net/wireless/mediatek/mt76/mt76x0/usb_mcu.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02.h | 45 +-
.../net/wireless/mediatek/mt76/mt76x02_beacon.c | 83 +-
.../net/wireless/mediatek/mt76/mt76x02_debugfs.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_dfs.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_dfs.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_dma.h | 13 +-
.../net/wireless/mediatek/mt76/mt76x02_eeprom.c | 13 +-
.../net/wireless/mediatek/mt76/mt76x02_eeprom.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_mac.c | 29 +-
drivers/net/wireless/mediatek/mt76/mt76x02_mac.h | 15 +-
drivers/net/wireless/mediatek/mt76/mt76x02_mcu.c | 26 +-
drivers/net/wireless/mediatek/mt76/mt76x02_mcu.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_mmio.c | 24 +-
drivers/net/wireless/mediatek/mt76/mt76x02_phy.c | 16 +-
drivers/net/wireless/mediatek/mt76/mt76x02_phy.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_regs.h | 41 +-
drivers/net/wireless/mediatek/mt76/mt76x02_trace.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_trace.h | 16 +-
drivers/net/wireless/mediatek/mt76/mt76x02_txrx.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_usb.h | 13 +-
.../net/wireless/mediatek/mt76/mt76x02_usb_core.c | 13 +-
.../net/wireless/mediatek/mt76/mt76x02_usb_mcu.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x02_util.c | 75 +-
drivers/net/wireless/mediatek/mt76/mt76x2/Kconfig | 14 +-
drivers/net/wireless/mediatek/mt76/mt76x2/eeprom.c | 23 +-
drivers/net/wireless/mediatek/mt76/mt76x2/eeprom.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/init.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/mac.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/mac.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/mcu.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/mcu.h | 16 +-
drivers/net/wireless/mediatek/mt76/mt76x2/mt76x2.h | 13 +-
.../net/wireless/mediatek/mt76/mt76x2/mt76x2u.h | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/pci.c | 13 +-
.../net/wireless/mediatek/mt76/mt76x2/pci_init.c | 14 +-
.../net/wireless/mediatek/mt76/mt76x2/pci_main.c | 15 +-
.../net/wireless/mediatek/mt76/mt76x2/pci_mcu.c | 17 +-
.../net/wireless/mediatek/mt76/mt76x2/pci_phy.c | 13 +-
drivers/net/wireless/mediatek/mt76/mt76x2/phy.c | 18 +-
drivers/net/wireless/mediatek/mt76/mt76x2/usb.c | 14 +-
.../net/wireless/mediatek/mt76/mt76x2/usb_init.c | 20 +-
.../net/wireless/mediatek/mt76/mt76x2/usb_mac.c | 13 +-
.../net/wireless/mediatek/mt76/mt76x2/usb_main.c | 24 +-
.../net/wireless/mediatek/mt76/mt76x2/usb_mcu.c | 13 +-
.../net/wireless/mediatek/mt76/mt76x2/usb_phy.c | 13 +-
drivers/net/wireless/mediatek/mt76/trace.c | 13 +-
drivers/net/wireless/mediatek/mt76/trace.h | 22 +-
drivers/net/wireless/mediatek/mt76/tx.c | 44 +-
drivers/net/wireless/mediatek/mt76/usb.c | 60 +-
drivers/net/wireless/mediatek/mt76/usb_trace.c | 13 +-
drivers/net/wireless/mediatek/mt76/usb_trace.h | 24 +-
drivers/net/wireless/mediatek/mt76/util.c | 13 +-
drivers/net/wireless/mediatek/mt76/util.h | 4 +-
drivers/net/wireless/ralink/rt2x00/rt2x00dev.c | 3 -
drivers/net/wireless/realtek/rtlwifi/debug.c | 2 +-
drivers/net/wireless/realtek/rtlwifi/efuse.c | 17 -
drivers/net/wireless/realtek/rtlwifi/pci.c | 2 +
.../net/wireless/realtek/rtlwifi/rtl8188ee/trx.h | 14 +-
.../net/wireless/realtek/rtlwifi/rtl8192ce/trx.h | 6 +-
.../net/wireless/realtek/rtlwifi/rtl8192cu/mac.c | 8 +-
.../net/wireless/realtek/rtlwifi/rtl8192cu/trx.c | 272 ++---
.../net/wireless/realtek/rtlwifi/rtl8192cu/trx.h | 529 ++++-----
.../net/wireless/realtek/rtlwifi/rtl8192ee/trx.c | 314 +++---
.../net/wireless/realtek/rtlwifi/rtl8192ee/trx.h | 861 +++++++--------
.../net/wireless/realtek/rtlwifi/rtl8821ae/trx.h | 10 +-
drivers/net/wireless/realtek/rtlwifi/usb.c | 16 +-
drivers/net/wireless/realtek/rtw88/coex.c | 7 +-
drivers/net/wireless/realtek/rtw88/debug.c | 4 +-
drivers/net/wireless/realtek/rtw88/pci.c | 70 +-
drivers/net/wireless/zydas/zd1211rw/zd_chip.c | 3 +-
drivers/net/wireless/zydas/zd1211rw/zd_mac.c | 1 -
drivers/net/wireless/zydas/zd1211rw/zd_usb.c | 11 +-
216 files changed, 5206 insertions(+), 6244 deletions(-)
create mode 100644 drivers/net/wireless/mediatek/mt76/mt7615/debugfs.c
^ permalink raw reply
* Re: pull-request: wireless-drivers-next 2019-09-07
From: David Miller @ 2019-09-07 8:34 UTC (permalink / raw)
To: kvalo; +Cc: linux-wireless, netdev, linux-kernel
In-Reply-To: <87blvwlelw.fsf@kamboji.qca.qualcomm.com>
From: Kalle Valo <kvalo@codeaurora.org>
Date: Sat, 07 Sep 2019 11:01:15 +0300
> here's a pull request to net-next for v5.4, more info below. Please let
> me know if there are any problems.
Pulled, thanks Kalle.
^ permalink raw reply
* [bug report] nl80211: Fix possible Spectre-v1 for CQM RSSI thresholds
From: Dan Carpenter @ 2019-09-07 13:02 UTC (permalink / raw)
To: masashi.honma; +Cc: linux-wireless
Hello Masashi Honma,
The patch 1222a1601488: "nl80211: Fix possible Spectre-v1 for CQM
RSSI thresholds" from Sep 25, 2018, leads to the following static
checker warning:
net/wireless/nl80211.c:10820 cfg80211_cqm_rssi_update()
warn: disabling speculation after use: 'i'
net/wireless/nl80211.c
10804 last = wdev->cqm_config->last_rssi_event_value;
10805 hyst = wdev->cqm_config->rssi_hyst;
10806 n = wdev->cqm_config->n_rssi_thresholds;
10807
10808 for (i = 0; i < n; i++)
10809 if (last < wdev->cqm_config->rssi_thresholds[i])
^^^^^^^^^^^^^^^^^^
We've already used "i" as an index.
10810 break;
10811
10812 low_index = i - 1;
10813 if (low_index >= 0) {
10814 low_index = array_index_nospec(low_index, n);
^^^^^^^^^^^^^^^^^^
10815 low = wdev->cqm_config->rssi_thresholds[low_index] - hyst;
10816 } else {
10817 low = S32_MIN;
10818 }
10819 if (i < n) {
10820 i = array_index_nospec(i, n);
^^^^^^^^^^^^^^^^^^
So this seems like closing the barn door after the horses have left.
10821 high = wdev->cqm_config->rssi_thresholds[i] + hyst - 1;
10822 } else {
10823 high = S32_MAX;
10824 }
regards,
dan carpenter
^ permalink raw reply
* Re: pull-request: iwlwifi-next 2019-09-06
From: Luca Coelho @ 2019-09-07 15:11 UTC (permalink / raw)
To: Kalle Valo; +Cc: linux-wireless, linuxwifi, david.e.box, joe.konno
In-Reply-To: <87h85owov3.fsf@codeaurora.org>
On Sat, 2019-09-07 at 10:24 +0300, Kalle Valo wrote:
> Luca Coelho <luca@coelho.fi> writes:
>
> > Here's a batch of patches intended for v5.4. This includes the last
> > patchset 4 patchsets I sent. Usual development work. More details
> > about the contents in the tag
> > description.
> >
> > I pushed this to my pending branch and I got results from kbuildbot to
> > some of the series, but I didn't get any results yet from the two last
> > v2 series I sent. I'll let you know if I get any results in the next
> > couple of days.
>
> Yesterday evening I pulled this to my pending branch and I did get a
> success report from kbuildbot.
Great! Yesterday evening I got a "build incomplete" message and again
the same today.
> > Please let me know if there are any issues.
> >
> > Cheers,
> > Luca.
> >
> >
> > The following changes since commit a18da8f6194978c2b32a8367fb0df81cc6417848:
> >
> > Merge tag 'mt76-for-kvalo-2019-09-05' of https://github.com/nbd168/wireless (2019-09-06 11:59:32 +0300)
> >
> > are available in the Git repository at:
> >
> > git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next.git tags/iwlwifi-next-for-kalle-2019-09-06
>
> Pulled, thanks Luca.
Thanks!
--
Luca.
^ permalink raw reply
* [PATCH] libertas: use mesh_wdev->ssid instead of priv->mesh_ssid
From: Lubomir Rintel @ 2019-09-07 15:18 UTC (permalink / raw)
To: Kalle Valo
Cc: libertas-dev, linux-wireless, netdev, linux-kernel,
Lubomir Rintel
With the commit e86dc1ca4676 ("Libertas: cfg80211 support") we've lost
the ability to actually set the Mesh SSID from userspace.
NL80211_CMD_SET_INTERFACE with NL80211_ATTR_MESH_ID sets the mesh point
interface's ssid field. Let's use that one for the Libertas Mesh
operation
Signed-off-by: Lubomir Rintel <lkundrak@v3.sk>
---
drivers/net/wireless/marvell/libertas/dev.h | 2 --
drivers/net/wireless/marvell/libertas/mesh.c | 31 +++++++++++++-------
drivers/net/wireless/marvell/libertas/mesh.h | 3 +-
3 files changed, 21 insertions(+), 15 deletions(-)
diff --git a/drivers/net/wireless/marvell/libertas/dev.h b/drivers/net/wireless/marvell/libertas/dev.h
index 4691349300265..4b6e05a8e5d54 100644
--- a/drivers/net/wireless/marvell/libertas/dev.h
+++ b/drivers/net/wireless/marvell/libertas/dev.h
@@ -58,8 +58,6 @@ struct lbs_private {
#ifdef CONFIG_LIBERTAS_MESH
struct lbs_mesh_stats mstats;
uint16_t mesh_tlv;
- u8 mesh_ssid[IEEE80211_MAX_SSID_LEN + 1];
- u8 mesh_ssid_len;
u8 mesh_channel;
#endif
diff --git a/drivers/net/wireless/marvell/libertas/mesh.c b/drivers/net/wireless/marvell/libertas/mesh.c
index 2315fdff56c2f..2747c957d18c9 100644
--- a/drivers/net/wireless/marvell/libertas/mesh.c
+++ b/drivers/net/wireless/marvell/libertas/mesh.c
@@ -86,6 +86,7 @@ static int lbs_mesh_config_send(struct lbs_private *priv,
static int lbs_mesh_config(struct lbs_private *priv, uint16_t action,
uint16_t chan)
{
+ struct wireless_dev *mesh_wdev;
struct cmd_ds_mesh_config cmd;
struct mrvl_meshie *ie;
@@ -105,10 +106,17 @@ static int lbs_mesh_config(struct lbs_private *priv, uint16_t action,
ie->val.active_protocol_id = MARVELL_MESH_PROTO_ID_HWMP;
ie->val.active_metric_id = MARVELL_MESH_METRIC_ID;
ie->val.mesh_capability = MARVELL_MESH_CAPABILITY;
- ie->val.mesh_id_len = priv->mesh_ssid_len;
- memcpy(ie->val.mesh_id, priv->mesh_ssid, priv->mesh_ssid_len);
+
+ if (priv->mesh_dev) {
+ mesh_wdev = priv->mesh_dev->ieee80211_ptr;
+ ie->val.mesh_id_len = mesh_wdev->mesh_id_up_len;
+ memcpy(ie->val.mesh_id, mesh_wdev->ssid,
+ mesh_wdev->mesh_id_up_len);
+ }
+
ie->len = sizeof(struct mrvl_meshie_val) -
- IEEE80211_MAX_SSID_LEN + priv->mesh_ssid_len;
+ IEEE80211_MAX_SSID_LEN + ie->val.mesh_id_len;
+
cmd.length = cpu_to_le16(sizeof(struct mrvl_meshie_val));
break;
case CMD_ACT_MESH_CONFIG_STOP:
@@ -117,8 +125,8 @@ static int lbs_mesh_config(struct lbs_private *priv, uint16_t action,
return -1;
}
lbs_deb_cmd("mesh config action %d type %x channel %d SSID %*pE\n",
- action, priv->mesh_tlv, chan, priv->mesh_ssid_len,
- priv->mesh_ssid);
+ action, priv->mesh_tlv, chan, ie->val.mesh_id_len,
+ ie->val.mesh_id);
return __lbs_mesh_config_send(priv, &cmd, action, priv->mesh_tlv);
}
@@ -863,12 +871,6 @@ int lbs_init_mesh(struct lbs_private *priv)
/* Stop meshing until interface is brought up */
lbs_mesh_config(priv, CMD_ACT_MESH_CONFIG_STOP, 1);
- if (priv->mesh_tlv) {
- sprintf(priv->mesh_ssid, "mesh");
- priv->mesh_ssid_len = 4;
- ret = 1;
- }
-
return ret;
}
@@ -997,6 +999,13 @@ static int lbs_add_mesh(struct lbs_private *priv)
mesh_wdev->iftype = NL80211_IFTYPE_MESH_POINT;
mesh_wdev->wiphy = priv->wdev->wiphy;
+
+ if (priv->mesh_tlv) {
+ sprintf(mesh_wdev->ssid, "mesh");
+ mesh_wdev->mesh_id_up_len = 4;
+ ret = 1;
+ }
+
mesh_wdev->netdev = mesh_dev;
mesh_dev->ml_priv = priv;
diff --git a/drivers/net/wireless/marvell/libertas/mesh.h b/drivers/net/wireless/marvell/libertas/mesh.h
index dfe22c91aade0..1561018f226fd 100644
--- a/drivers/net/wireless/marvell/libertas/mesh.h
+++ b/drivers/net/wireless/marvell/libertas/mesh.h
@@ -24,8 +24,7 @@ void lbs_remove_mesh(struct lbs_private *priv);
static inline bool lbs_mesh_activated(struct lbs_private *priv)
{
- /* Mesh SSID is only programmed after successful init */
- return priv->mesh_ssid_len != 0;
+ return !!priv->mesh_tlv;
}
int lbs_mesh_set_channel(struct lbs_private *priv, u8 channel);
--
2.21.0
^ permalink raw reply related
* Re: [PATCH] ath10k: restore QCA9880-AR1A (v1) detection
From: Sasha Levin @ 2019-09-07 21:43 UTC (permalink / raw)
To: Sasha Levin, Christian Lamparter, linux-wireless, ath10k
Cc: Kalle Valo, stable, stable
In-Reply-To: <20190906215423.23589-1-chunkeey@gmail.com>
Hi,
[This is an automated email]
This commit has been processed because it contains a "Fixes:" tag,
fixing commit: 1a7fecb766c8 ath10k: reset chip before reading chip_id in probe.
The bot has tested the following trees: v5.2.13, v4.19.71, v4.14.142, v4.9.191, v4.4.191.
v5.2.13: Failed to apply! Possible dependencies:
6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
v4.19.71: Failed to apply! Possible dependencies:
31324d17976e ("ath10k: support extended board data download for dual-band QCA9984")
5849ed48d226 ("ath10k: refactoring needed for extended board data download")
6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
7c2dd6154fc2 ("ath10k: add device type enum to ath10k_bus_params")
ba94c753ccb4 ("ath10k: add QMI message handshake for wcn3990 client")
c0d8d565787c ("ath10k: add struct ath10k_bus_params")
de8781d7e74d ("ath10k: disable interface pause wow config for integrated chipset")
f1908735f141 ("ath10k: allow ATH10K_SNOC with COMPILE_TEST")
v4.14.142: Failed to apply! Possible dependencies:
0fa4fbe9b8cf ("ath10k: add hif power-up/power-down methods")
17f5559e0da5 ("ath10k: platform driver for WCN3990 SNOC WLAN module")
2a1e1ad3fd37 ("ath10k: Add support for 64 bit ce descriptor")
50c51f394e68 ("ath10k: do not mix spaces and tabs in Kconfig")
5dac5f3772f6 ("ath10k: Use dma_addr_t for ce buffers to support 64bit target")
6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
7f9befbb555d ("ath10k: move pktlog_filter out of ath10k_debug")
84efe7f6ebc5 ("ath10k: map HTC services to tx/rx pipes for wcn3990")
a0aedd6e0b57 ("ath10k: build ce layer in ath10k core module")
a6a793f98786 ("ath10k: vote for hardware resources for WCN3990")
a6e149a9ff03 ("ath10k: add hif start/stop methods for wcn3990 snoc layer")
ba94c753ccb4 ("ath10k: add QMI message handshake for wcn3990 client")
c0d8d565787c ("ath10k: add struct ath10k_bus_params")
c963a683e701 ("ath10k: add resource init and deinit for WCN3990")
d390509bdf50 ("ath10k: add hif tx methods for wcn3990")
dafa42036012 ("ath10k: use 64-bit crash dump timestamps")
e2fcf60c6fe8 ("ath10k: detach coredump.c from debug.c")
f1908735f141 ("ath10k: allow ATH10K_SNOC with COMPILE_TEST")
f25b9f285a0e ("ath10k: refactor firmware crashdump code to coredump.c")
v4.9.191: Failed to apply! Possible dependencies:
0fa4fbe9b8cf ("ath10k: add hif power-up/power-down methods")
17f5559e0da5 ("ath10k: platform driver for WCN3990 SNOC WLAN module")
4db66499df91 ("ath10k: add initial USB support")
50c51f394e68 ("ath10k: do not mix spaces and tabs in Kconfig")
5524ddd4c1f1 ("ath10k: select WANT_DEV_COREDUMP")
6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
84efe7f6ebc5 ("ath10k: map HTC services to tx/rx pipes for wcn3990")
a0aedd6e0b57 ("ath10k: build ce layer in ath10k core module")
a6a793f98786 ("ath10k: vote for hardware resources for WCN3990")
a6e149a9ff03 ("ath10k: add hif start/stop methods for wcn3990 snoc layer")
ba94c753ccb4 ("ath10k: add QMI message handshake for wcn3990 client")
c0d8d565787c ("ath10k: add struct ath10k_bus_params")
c963a683e701 ("ath10k: add resource init and deinit for WCN3990")
cec17c382140 ("ath10k: add per peer htt tx stats support for 10.4")
d390509bdf50 ("ath10k: add hif tx methods for wcn3990")
d96db25d2025 ("ath10k: add initial SDIO support")
f1908735f141 ("ath10k: allow ATH10K_SNOC with COMPILE_TEST")
v4.4.191: Failed to apply! Possible dependencies:
0b523ced9a3c ("ath10k: add basic skeleton to support ahb")
0d87c9208a17 ("ath10k: expose hif ops for ahb")
133df0f849bc ("ath10k: add chip and bus halt logic in ahb")
14854bfd9daa ("ath10k: add reset ctrl related functions in ahb")
1c44fcb9234c ("ath10k: include irq related functions in ahb")
4ddb3299aa49 ("ath10k: make ath10k_pci_read32/write32() ops more generic")
6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
704dc4e36769 ("ath10k: add resource init and deinit in ahb")
7f8e79cdc253 ("ath10k: add helper functions in ahb.c for reg rd/wr")
8beff219c528 ("ath10k: add clock ctrl related functions in ahb")
f52f517189de ("ath10k: make some of ath10k_pci_* func reusable")
NOTE: The patch will not be queued to stable trees until it is upstream.
How should we proceed with this patch?
--
Thanks,
Sasha
^ permalink raw reply
* Slow performance (~30mbps) with Intel 9260 (and 8265, 3168) using 5G
From: Qu Wenruo @ 2019-09-07 22:45 UTC (permalink / raw)
To: linuxwifi, linux-wireless
[-- Attachment #1.1: Type: text/plain, Size: 2814 bytes --]
Hi,
Recent upgraded my wifi adapter from 8265 to 9260 of my ThinkPad X1C 6th
gen.
However the initial test is producing some unacceptable results:
Furthermore, my desktop (intel 3168), and the original 8265 of my laptop
also reproduce the same result.
Kernels are the same 5.2.11-arch1-1-ARCH across my laptop and desktop.
Tried lts (4.19) on my laptop, the same result.
Even under Windows, it's all the same.
[ 5] local 240e:3a1:c40:6c0::278 port 43334 connected to
240e:3a1:c40:6c0::16b port 5201
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 4.95 MBytes 41.5 Mbits/sec 0 219 KBytes
[ 5] 1.00-2.00 sec 2.44 MBytes 20.5 Mbits/sec 0 248 KBytes
[ 5] 2.00-3.00 sec 1.58 MBytes 13.3 Mbits/sec 1 1.39 KBytes
[ 5] 3.00-4.00 sec 1.10 MBytes 9.21 Mbits/sec 44 194 KBytes
[ 5] 4.00-5.00 sec 4.39 MBytes 36.8 Mbits/sec 0 226 KBytes
[ 5] 5.00-6.00 sec 4.39 MBytes 36.8 Mbits/sec 0 247 KBytes
[ 5] 6.00-7.00 sec 4.39 MBytes 36.8 Mbits/sec 0 257 KBytes
[ 5] 7.00-8.00 sec 4.57 MBytes 38.3 Mbits/sec 0 259 KBytes
[ 5] 8.00-9.00 sec 3.84 MBytes 32.2 Mbits/sec 0 259 KBytes
[ 5] 9.00-10.00 sec 4.39 MBytes 36.8 Mbits/sec 0 261 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Retr
[ 5] 0.00-10.00 sec 36.0 MBytes 30.2 Mbits/sec 45 sender
[ 5] 0.00-10.02 sec 34.9 MBytes 29.2 Mbits/sec
receiver
Yep, less than 40mbps using 5G.
While I can even feel obvious lag when using ssh, some quick keystroke
will easily cause a lag.
I though it's the Linux support causing problem (even I'm using Arch
with 5.2 kernel) for the newer 9260 card, then I switched back to 8265.
But the same problem still exists!!
What makes things even stranger, under Windows, it's all the same result.
To exclude the problem of the AP, my android phone can easily get over
200mbps through the same AP.
Furthermore, I tested my desktop which has an Intel 3168 card, and to my
surprise, it's the same result less than 40mbps.
Although it doesn't really hurt as both my desktop and laptop is mostly
connected through ethernet, it still doesn't make sense to me.
Here is the dmesg of my laptop. (Please ignore the perf buffer warning,
as I also tried to trace iwlwifi:* and iwlwifi_msg:* events)
https://paste.fedoraproject.org/paste/d5TO6kvbBOwQ~tkLgDbXsQ/raw
The iw list output:
https://paste.fedoraproject.org/paste/QKIOLyItCLcwTJoan8Wd3g/raw
Any ideas how this could happen to 3 different intel cards on two
different systems? (Although all running the same Arch kernel and latest
firmware)
Thanks,
Qu
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply
* stable backports for "ath10k: restore QCA9880-AR1A (v1) detection"
From: Christian Lamparter @ 2019-09-07 23:18 UTC (permalink / raw)
To: linux-wireless, ath10k, Sasha Levin; +Cc: Kalle Valo, stable
In-Reply-To: <20190907214359.1C52A21835@mail.kernel.org>
[-- Attachment #1: Type: text/plain, Size: 1515 bytes --]
Hello,
On Saturday, September 7, 2019 11:43:58 PM CEST Sasha Levin wrote:
> This commit has been processed because it contains a "Fixes:" tag,
> fixing commit: 1a7fecb766c8 ath10k: reset chip before reading chip_id in probe.
>
> The bot has tested the following trees: v5.2.13, v4.19.71, v4.14.142, v4.9.191, v4.4.191.
>
> v5.2.13: Failed to apply! Possible dependencies:
> 6d084ac27ab4 ("ath10k: initialise struct ath10k_bus params to zero")
The bot is right. Either add that patch or remove the "= {};" from the patch
that was sent to linux-wireless (based on "wireless-testing.git").
Alternatively, I've also added patches (as file attachments, I did this in
the hopes of fooling patchwork and the bots at least a bit... as well as
parking the patches for later). That said, I think this will go horribly
wrong because of this response. Since It has been a long time since I needed
a multi-version patch so I'm sorry for not being up-to-date with the latest
for-stable meta.
> v4.19.71: Failed to apply! Possible dependencies:
> 31324d17976e ("ath10k: support extended board data download for dual-band QCA9984")
> [...] too much
> [...]: [...]
>
> NOTE: The patch will not be queued to stable trees until it is upstream.
>
> How should we proceed with this patch?
You could let loose your ci-bot on the attached patches and see if they would
do the trick. I'm very optimistic that this will need some more time though.
So, "let's cross that bridge whenever we get there."
Cheers,
Christian
[-- Attachment #2: 4-9-ath10k-restore-QCA9880-AR1A-v1-detection.patch --]
[-- Type: text/x-patch, Size: 3151 bytes --]
From 38ac13d668f237941c8b77f16375f8f0e4de966a Mon Sep 17 00:00:00 2001
From: Christian Lamparter <chunkeey@gmail.com>
Date: Mon, 25 Mar 2019 13:50:19 +0100
Subject: [PATCH 4.9] ath10k: restore QCA9880-AR1A (v1) detection
To: linux-wireless@vger.kernel.org,
ath10k@lists.infradead.org
Cc: Kalle Valo <kvalo@codeaurora.org>
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org # 4.9
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
--- a/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:07:21.374565470 +0200
+++ b/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:17:15.365912133 +0200
@@ -3172,7 +3172,7 @@ static int ath10k_pci_probe(struct pci_d
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
u32 chip_id;
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
int (*pci_soft_reset)(struct ath10k *ar);
int (*pci_hard_reset)(struct ath10k *ar);
u32 (*targ_cpu_to_ce_addr)(struct ath10k *ar, u32 addr);
@@ -3181,6 +3181,7 @@ static int ath10k_pci_probe(struct pci_d
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
pci_soft_reset = ath10k_pci_warm_reset;
pci_hard_reset = ath10k_pci_qca988x_chip_reset;
targ_cpu_to_ce_addr = ath10k_pci_qca988x_targ_cpu_to_ce_addr;
@@ -3300,6 +3301,19 @@ static int ath10k_pci_probe(struct pci_d
goto err_deinit_irq;
}
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
@@ -3312,11 +3326,8 @@ static int ath10k_pci_probe(struct pci_d
goto err_free_irq;
}
- if (!ath10k_pci_chip_is_supported(pdev->device, chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, chip_id);
- goto err_free_irq;
- }
+ if (!ath10k_pci_chip_is_supported(pdev->device, chip_id))
+ goto err_unsupported;
ret = ath10k_core_register(ar, chip_id);
if (ret) {
@@ -3326,6 +3337,10 @@ static int ath10k_pci_probe(struct pci_d
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_rx_retry_sync(ar);
[-- Attachment #3: 4-4-ath10k-restore-QCA9880-AR1A-v1-detection.patch --]
[-- Type: text/x-patch, Size: 2884 bytes --]
From 38ac13d668f237941c8b77f16375f8f0e4de966a Mon Sep 17 00:00:00 2001
From: Christian Lamparter <chunkeey@gmail.com>
Date: Mon, 25 Mar 2019 13:50:19 +0100
Subject: [PATCH 4.4] ath10k: restore QCA9880-AR1A (v1) detection
To: linux-wireless@vger.kernel.org,
ath10k@lists.infradead.org
Cc: Kalle Valo <kvalo@codeaurora.org>
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org # 4.4
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
--- a/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:07:21.374565470 +0200
+++ b/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:17:15.365912133 +0200
@@ -2988,12 +2988,13 @@ static int ath10k_pci_probe(struct pci_d
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
u32 chip_id;
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
switch (pci_dev->device) {
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
break;
case QCA6164_2_1_DEVICE_ID:
case QCA6174_2_1_DEVICE_ID:
@@ -3087,6 +3088,19 @@ static int ath10k_pci_probe(struct pci_d
goto err_deinit_irq;
}
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
@@ -3099,11 +3113,8 @@ static int ath10k_pci_probe(struct pci_d
goto err_free_irq;
}
- if (!ath10k_pci_chip_is_supported(pdev->device, chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, chip_id);
- goto err_free_irq;
- }
+ if (!ath10k_pci_chip_is_supported(pdev->device, chip_id))
+ goto err_unsupported;
ret = ath10k_core_register(ar, chip_id);
if (ret) {
@@ -3113,6 +3124,10 @@ static int ath10k_pci_probe(struct pci_d
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_kill_tasklet(ar);
[-- Attachment #4: 4-14-ath10k-restore-QCA9880-AR1A-v1-detection.patch --]
[-- Type: text/x-patch, Size: 3153 bytes --]
From 38ac13d668f237941c8b77f16375f8f0e4de966a Mon Sep 17 00:00:00 2001
From: Christian Lamparter <chunkeey@gmail.com>
Date: Mon, 25 Mar 2019 13:50:19 +0100
Subject: [PATCH 4.14] ath10k: restore QCA9880-AR1A (v1) detection
To: linux-wireless@vger.kernel.org,
ath10k@lists.infradead.org
Cc: Kalle Valo <kvalo@codeaurora.org>
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org # 4.14
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
--- a/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:07:21.374565470 +0200
+++ b/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:17:15.365912133 +0200
@@ -3202,7 +3202,7 @@ static int ath10k_pci_probe(struct pci_d
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
u32 chip_id;
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
int (*pci_soft_reset)(struct ath10k *ar);
int (*pci_hard_reset)(struct ath10k *ar);
u32 (*targ_cpu_to_ce_addr)(struct ath10k *ar, u32 addr);
@@ -3211,6 +3211,7 @@ static int ath10k_pci_probe(struct pci_d
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
pci_soft_reset = ath10k_pci_warm_reset;
pci_hard_reset = ath10k_pci_qca988x_chip_reset;
targ_cpu_to_ce_addr = ath10k_pci_qca988x_targ_cpu_to_ce_addr;
@@ -3331,6 +3332,19 @@ static int ath10k_pci_probe(struct pci_d
goto err_deinit_irq;
}
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
@@ -3343,11 +3357,8 @@ static int ath10k_pci_probe(struct pci_d
goto err_free_irq;
}
- if (!ath10k_pci_chip_is_supported(pdev->device, chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, chip_id);
- goto err_free_irq;
- }
+ if (!ath10k_pci_chip_is_supported(pdev->device, chip_id))
+ goto err_unsupported;
ret = ath10k_core_register(ar, chip_id);
if (ret) {
@@ -3357,6 +3368,10 @@ static int ath10k_pci_probe(struct pci_d
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_rx_retry_sync(ar);
[-- Attachment #5: 4-19-ath10k-restore-QCA9880-AR1A-v1-detection.patch --]
[-- Type: text/x-patch, Size: 3153 bytes --]
From 38ac13d668f237941c8b77f16375f8f0e4de966a Mon Sep 17 00:00:00 2001
From: Christian Lamparter <chunkeey@gmail.com>
Date: Mon, 25 Mar 2019 13:50:19 +0100
Subject: [PATCH 4.19] ath10k: restore QCA9880-AR1A (v1) detection
To: linux-wireless@vger.kernel.org,
ath10k@lists.infradead.org
Cc: Kalle Valo <kvalo@codeaurora.org>
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org # 4.19
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
--- a/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:07:21.374565470 +0200
+++ b/drivers/net/wireless/ath/ath10k/pci.c 2019-09-08 00:17:15.365912133 +0200
@@ -3483,7 +3483,7 @@ static int ath10k_pci_probe(struct pci_d
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
u32 chip_id;
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
int (*pci_soft_reset)(struct ath10k *ar);
int (*pci_hard_reset)(struct ath10k *ar);
u32 (*targ_cpu_to_ce_addr)(struct ath10k *ar, u32 addr);
@@ -3493,6 +3493,7 @@ static int ath10k_pci_probe(struct pci_d
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
pci_soft_reset = ath10k_pci_warm_reset;
pci_hard_reset = ath10k_pci_qca988x_chip_reset;
targ_cpu_to_ce_addr = ath10k_pci_qca988x_targ_cpu_to_ce_addr;
@@ -3612,6 +3613,19 @@ static int ath10k_pci_probe(struct pci_d
goto err_deinit_irq;
}
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
@@ -3624,11 +3638,8 @@ static int ath10k_pci_probe(struct pci_d
goto err_free_irq;
}
- if (!ath10k_pci_chip_is_supported(pdev->device, chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, chip_id);
- goto err_free_irq;
- }
+ if (!ath10k_pci_chip_is_supported(pdev->device, chip_id))
+ goto err_unsupported;
ret = ath10k_core_register(ar, chip_id);
if (ret) {
@@ -3638,6 +3649,10 @@ static int ath10k_pci_probe(struct pci_d
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_rx_retry_sync(ar);
[-- Attachment #6: 5-2-ath10k-restore-QCA9880-AR1A-v1-detection.patch --]
[-- Type: text/x-patch, Size: 3553 bytes --]
From 38ac13d668f237941c8b77f16375f8f0e4de966a Mon Sep 17 00:00:00 2001
From: Christian Lamparter <chunkeey@gmail.com>
Date: Mon, 25 Mar 2019 13:50:19 +0100
Subject: [PATCH 5.2] ath10k: restore QCA9880-AR1A (v1) detection
To: linux-wireless@vger.kernel.org,
ath10k@lists.infradead.org
Cc: Kalle Valo <kvalo@codeaurora.org>
This patch restores the old behavior that read
the chip_id on the QCA988x before resetting the
chip. This needs to be done in this order since
the unsupported QCA988x AR1A chips fall off the
bus when resetted. Otherwise the next MMIO Op
after the reset causes a BUS ERROR and panic.
Cc: stable@vger.kernel.org # 5.2
Fixes: 1a7fecb766c8 ("ath10k: reset chip before reading chip_id in probe")
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
---
drivers/net/wireless/ath/ath10k/pci.c | 36 +++++++++++++++++++--------
1 file changed, 25 insertions(+), 11 deletions(-)
diff --git a/drivers/net/wireless/ath/ath10k/pci.c b/drivers/net/wireless/ath/ath10k/pci.c
--- a/drivers/net/wireless/ath/ath10k/pci.c
+++ b/drivers/net/wireless/ath/ath10k/pci.c
@@ -3490,7 +3490,7 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
struct ath10k_pci *ar_pci;
enum ath10k_hw_rev hw_rev;
struct ath10k_bus_params bus_params;
- bool pci_ps;
+ bool pci_ps, is_qca988x = false;
int (*pci_soft_reset)(struct ath10k *ar);
int (*pci_hard_reset)(struct ath10k *ar);
u32 (*targ_cpu_to_ce_addr)(struct ath10k *ar, u32 addr);
@@ -3500,6 +3500,7 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
case QCA988X_2_0_DEVICE_ID:
hw_rev = ATH10K_HW_QCA988X;
pci_ps = false;
+ is_qca988x = true;
pci_soft_reset = ath10k_pci_warm_reset;
pci_hard_reset = ath10k_pci_qca988x_chip_reset;
targ_cpu_to_ce_addr = ath10k_pci_qca988x_targ_cpu_to_ce_addr;
@@ -3619,25 +3620,34 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
goto err_deinit_irq;
}
+ bus_params.dev_type = ATH10K_DEV_TYPE_LL;
+ bus_params.link_can_suspend = true;
+ /* Read CHIP_ID before reset to catch QCA9880-AR1A v1 devices that
+ * fall off the bus during chip_reset. These chips have the same pci
+ * device id as the QCA9880 BR4A or 2R4E. So that's why the check.
+ */
+ if (is_qca988x) {
+ bus_params.chip_id =
+ ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
+ if (bus_params.chip_id != 0xffffffff) {
+ if (!ath10k_pci_chip_is_supported(pdev->device,
+ bus_params.chip_id))
+ goto err_unsupported;
+ }
+ }
+
ret = ath10k_pci_chip_reset(ar);
if (ret) {
ath10k_err(ar, "failed to reset chip: %d\n", ret);
goto err_free_irq;
}
- bus_params.dev_type = ATH10K_DEV_TYPE_LL;
- bus_params.link_can_suspend = true;
bus_params.chip_id = ath10k_pci_soc_read32(ar, SOC_CHIP_ID_ADDRESS);
- if (bus_params.chip_id == 0xffffffff) {
- ath10k_err(ar, "failed to get chip id\n");
- goto err_free_irq;
- }
+ if (bus_params.chip_id == 0xffffffff)
+ goto err_unsupported;
- if (!ath10k_pci_chip_is_supported(pdev->device, bus_params.chip_id)) {
- ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
- pdev->device, bus_params.chip_id);
+ if (!ath10k_pci_chip_is_supported(pdev->device, bus_params.chip_id))
goto err_free_irq;
- }
ret = ath10k_core_register(ar, &bus_params);
if (ret) {
@@ -3647,6 +3657,10 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
return 0;
+err_unsupported:
+ ath10k_err(ar, "device %04x with chip_id %08x isn't supported\n",
+ pdev->device, bus_params.chip_id);
+
err_free_irq:
ath10k_pci_free_irq(ar);
ath10k_pci_rx_retry_sync(ar);
--
2.23.0
^ permalink raw reply
* Re: [PATCH] wireless-regdb: Fix ranges of EU countries as they are harmonized since 2014...
From: Seth Forshee @ 2019-09-07 23:56 UTC (permalink / raw)
To: Emil Petersky; +Cc: linux-wireless, wireless-regdb
In-Reply-To: <bf327181-521b-e1ce-c5c8-81b828fc65b6@streamunlimited.com>
On Mon, Aug 05, 2019 at 04:19:16PM +0200, Emil Petersky wrote:
> This patch unites entries for EU countries, as they have been harmonized
> latest by July 2014...
> EU decision 2005/513/EC:
> https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:02005D0513-20070213
> EU decision 2006/771/EC:
> https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:02008D0432-20080611
>
> Signed-off-by: Emil Petersky <emil.petersky@streamunlimited.com>
Thanks for this patch, and especially for all the references you
provided. Sorry it's taken a while to get back -- I've been checking the
changes against the links which took quite some time, and I have pretty
limited time for reviewing these patches.
Overall this looks good, however when I try to apply it I get an error
that the patch is corrupt. Can you try resending?
I also get warnings from git about trailing whitespace, and I've noted a
couple other trivial whitespace issues below, if you wouldn't mind
fixing those up before resending.
> @@ -167,23 +185,30 @@ country BF: DFS-FCC
> #
> # Note: The transmit power limits in the 5250-5350 MHz and 5470-5725 MHz bands
> # can be raised by 3 dBm if TPC is enabled. Refer to BDS EN 301 893 for details.
> +#
> +# BG as part of EU/CEPT accepted decisions 2005/513/EC (5GHz RLAN, EN 301 893)
> +# and 2006/771/EC (amended by 2008/432/EC, Short-Range Devices, EN 300 440)
> +# EU decision 2005/513/EC: https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:02005D0513-20070213
> +# EU decision 2006/771/EC: https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX:02008D0432-20080611
> +# BG: https://crc.bg/files/_en/Electronic_Communications_Revised_EN1.pdf
> +# BG: acceptance of 2006/771/EC https://crc.bg/files/Pravila_06_12_2018.pdf
> +
> country BG: DFS-ETSI
This is the only place where you added a blank line between the comment
and the country. Let's remove that for consistency.
> # Wideband data transmission systems (WDTS) in the 2.4GHz ISM band, ref:
> # I.22 of the List, BDS EN 300 328
> - (2402 - 2482 @ 40), (20)
> + (2400 - 2483.5 @ 40), (100 mW)
> # 5 GHz Radio Local Area Networks (RLANs), ref:
> # II.H01 of the List, BDS EN 301 893
> - (5170 - 5250 @ 80), (23), AUTO-BW, wmmrule=ETSI
> - (5250 - 5330 @ 80), (20), DFS, AUTO-BW, wmmrule=ETSI
> + (5150 - 5250 @ 80), (200 mW), NO-OUTDOOR, AUTO-BW, wmmrule=ETSI
> + (5250 - 5350 @ 80), (100 mW), NO-OUTDOOR, DFS, AUTO-BW, wmmrule=ETSI
> # II.H01 of the List, I.54 from the List, BDS EN 301 893
> - (5490 - 5710 @ 160), (27), DFS, wmmrule=ETSI
> - # Short range devices (SRDs) in the 5725-5875 MHz frequency range, ref:
> + (5470 - 5725 @ 160), (500 mW), DFS, wmmrule=ETSI
> + # short range devices (ETSI EN 300 440-1)
> # I.43 of the List, BDS EN 300 440-2, BDS EN 300 440-1
> - (5725 - 5875 @ 80), (14)
> - # 60 GHz Multiple-Gigabit RLAN Systems, ref:
> + (5725 - 5875 @ 80), (25 mW)
> + # 60 GHz band channels 1-4 (ETSI EN 302 567)
> # II.H03 of the List, BDS EN 302 567-2
> - (57000 - 66000 @ 2160), (40), NO-OUTDOOR
> -
> + (57000 - 66000 @ 2160), (40)
> country BH: DFS-JP
You removed the blank line between the BG rules and BH here.
Thanks,
Seth
^ permalink raw reply
* Re: [bug report] nl80211: Fix possible Spectre-v1 for CQM RSSI thresholds
From: Masashi Honma @ 2019-09-08 0:55 UTC (permalink / raw)
To: Dan Carpenter; +Cc: linux-wireless
In-Reply-To: <20190907130234.GA32057@mwanda>
On 2019/09/07 22:02, Dan Carpenter wrote:
> The patch 1222a1601488: "nl80211: Fix possible Spectre-v1 for CQM
> RSSI thresholds" from Sep 25, 2018, leads to the following static
> checker warning:
>
> net/wireless/nl80211.c:10820 cfg80211_cqm_rssi_update()
> warn: disabling speculation after use: 'i'
Thanks.
I will send a patch to prevent accessing to rssi_thresholds[n].
Regards,
Masashi Honma.
^ permalink raw reply
* [PATCH] nl80211: Fix possible Spectre-v1 for CQM RSSI thresholds
From: Masashi Honma @ 2019-09-08 0:56 UTC (permalink / raw)
To: johannes; +Cc: linux-wireless, dan.carpenter, Masashi Honma
commit 1222a16014888ed9733c11e221730d4a8196222b "nl80211: Fix possible
Spectre-v1 for CQM RSSI thresholds" requires one more fix to prevent
accessing to rssi_thresholds[n]. Because user can control
rssi_thresholds[i] values to make i reach to n. For example,
rssi_thresholds = {-400, -300, -200, -100} when last is -34.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
---
net/wireless/nl80211.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 3e30e18d1d89..773b22654c23 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -10805,9 +10805,11 @@ static int cfg80211_cqm_rssi_update(struct cfg80211_registered_device *rdev,
hyst = wdev->cqm_config->rssi_hyst;
n = wdev->cqm_config->n_rssi_thresholds;
- for (i = 0; i < n; i++)
+ for (i = 0; i < n; i++) {
+ i = array_index_nospec(i, n);
if (last < wdev->cqm_config->rssi_thresholds[i])
break;
+ }
low_index = i - 1;
if (low_index >= 0) {
--
2.17.1
^ permalink raw reply related
* [PATCH 0/9] rtlwifi: Remove special macros used to manipulate RX and TX descriptors
From: Larry Finger @ 2019-09-08 4:03 UTC (permalink / raw)
To: kvalo; +Cc: linux-wireless, pkshih, Larry Finger
These patches continue the set of changes that remove the special macros
to read or write the RX and TX descriptors. The bit manipulations in the
__le32 words use GENMASK() and BIT() operations.
The final patch removes unused macros for C2H operations.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Larry Finger (9):
rtlwifi: rtl8723ae: Remove unused GET_XXX and SET_XXX macros
rtlwifi: rtl8723ae: Replace local bit manipulation macros
rtlwifi: rtl8723ae: Convert macros that set descriptor
rtlwifi: rtl8723ae: Convert inline routines to little-endian words
rtlwifi: rtl8723be: Remove unused SET_XXX and GET_XXX macros
rtlwifi: rtl8723be: Replace local bit manipulation macros
rtlwifi: rtl8723be: Convert macros that set descriptor
rtlwifi: rtl8723be: Convert inline routines to little-endian words
rtlwifi: rtl8188ee: rtl8192ce: rtl8192de: rtl8723ae: rtl8821ae: Remove
some unused bit manipulation macros
drivers/net/wireless/realtek/rtlwifi/base.h | 27 -
.../wireless/realtek/rtlwifi/rtl8188ee/def.h | 29 -
.../wireless/realtek/rtlwifi/rtl8192ce/def.h | 33 -
.../wireless/realtek/rtlwifi/rtl8192de/def.h | 31 -
.../wireless/realtek/rtlwifi/rtl8723ae/def.h | 31 -
.../wireless/realtek/rtlwifi/rtl8723ae/trx.c | 212 ++---
.../wireless/realtek/rtlwifi/rtl8723ae/trx.h | 794 +++++++-----------
.../wireless/realtek/rtlwifi/rtl8723be/trx.c | 236 +++---
.../wireless/realtek/rtlwifi/rtl8723be/trx.h | 718 ++++++++--------
.../wireless/realtek/rtlwifi/rtl8821ae/def.h | 31 -
10 files changed, 922 insertions(+), 1220 deletions(-)
--
2.23.0
^ 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