Skip to content

Commit e40fa65

Browse files
committed
Merge tag 'wireless-drivers-next-2021-04-23' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next
Kalle Valo says: ==================== wireless-drivers-next patches for v5.13 Third, and final, set of patches for v5.13. We got one more week before the merge window and this includes from that extra week. Smaller features to rtw88 and mt76, but mostly this contains fixes. rtw88 * 8822c: Add gap-k calibration to improve long range performance mt76 * parse rate power limits from DT * debugfs file to test firmware crash * debugfs to disable NAPI threaded mode ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2 parents 8f8590d + 9382531 commit e40fa65

81 files changed

Lines changed: 3428 additions & 1157 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎Documentation/devicetree/bindings/net/wireless/mediatek,mt76.yaml‎

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,90 @@ properties:
7272
led-sources:
7373
maxItems: 1
7474

75+
power-limits:
76+
type: object
77+
additionalProperties: false
78+
patternProperties:
79+
"^r[0-9]+":
80+
type: object
81+
additionalProperties: false
82+
properties:
83+
regdomain:
84+
$ref: /schemas/types.yaml#/definitions/string
85+
description:
86+
Regdomain refers to a legal regulatory region. Different
87+
countries define different levels of allowable transmitter
88+
power, time that a channel can be occupied, and different
89+
available channels
90+
enum:
91+
- FCC
92+
- ETSI
93+
- JP
94+
95+
patternProperties:
96+
"^txpower-[256]g$":
97+
type: object
98+
additionalProperties: false
99+
patternProperties:
100+
"^b[0-9]+$":
101+
type: object
102+
additionalProperties: false
103+
properties:
104+
channels:
105+
$ref: /schemas/types.yaml#/definitions/uint32-array
106+
minItems: 2
107+
maxItems: 2
108+
description:
109+
Pairs of first and last channel number of the selected
110+
band
111+
112+
rates-cck:
113+
$ref: /schemas/types.yaml#/definitions/uint8-array
114+
minItems: 4
115+
maxItems: 4
116+
description:
117+
4 half-dBm per-rate power limit values
118+
119+
rates-ofdm:
120+
$ref: /schemas/types.yaml#/definitions/uint8-array
121+
minItems: 8
122+
maxItems: 8
123+
description:
124+
8 half-dBm per-rate power limit values
125+
126+
rates-mcs:
127+
$ref: /schemas/types.yaml#/definitions/uint8-matrix
128+
description:
129+
Sets of per-rate power limit values for 802.11n/802.11ac
130+
rates for multiple channel bandwidth settings.
131+
Each set starts with the number of channel bandwidth
132+
settings for which the rate set applies, followed by
133+
either 8 or 10 power limit values. The order of the
134+
channel bandwidth settings is 20, 40, 80 and 160 MHz.
135+
maxItems: 4
136+
items:
137+
minItems: 9
138+
maxItems: 11
139+
140+
rates-ru:
141+
$ref: /schemas/types.yaml#/definitions/uint8-matrix
142+
description:
143+
Sets of per-rate power limit values for 802.11ax rates
144+
for multiple channel bandwidth or resource unit settings.
145+
Each set starts with the number of channel bandwidth or
146+
resource unit settings for which the rate set applies,
147+
followed by 12 power limit values. The order of the
148+
channel resource unit settings is RU26, RU52, RU106,
149+
RU242/SU20, RU484/SU40, RU996/SU80 and RU2x996/SU160.
150+
items:
151+
minItems: 13
152+
maxItems: 13
153+
154+
txs-delta:
155+
$ref: /schemas/types.yaml#/definitions/uint32-array
156+
description:
157+
Half-dBm power delta for different numbers of antennas
158+
75159
required:
76160
- compatible
77161
- reg
@@ -93,6 +177,29 @@ examples:
93177
led {
94178
led-sources = <2>;
95179
};
180+
181+
power-limits {
182+
r0 {
183+
regdomain = "FCC";
184+
txpower-5g {
185+
b0 {
186+
channels = <36 48>;
187+
rates-ofdm = /bits/ 8 <23 23 23 23 23 23 23 23>;
188+
rates-mcs = /bits/ 8 <1 23 23 23 23 23 23 23 23 23 23>,
189+
<3 22 22 22 22 22 22 22 22 22 22>;
190+
rates-ru = /bits/ 8 <3 22 22 22 22 22 22 22 22 22 22 22 22>,
191+
<4 20 20 20 20 20 20 20 20 20 20 20 20>;
192+
};
193+
b1 {
194+
channels = <100 181>;
195+
rates-ofdm = /bits/ 8 <14 14 14 14 14 14 14 14>;
196+
rates-mcs = /bits/ 8 <4 14 14 14 14 14 14 14 14 14 14>;
197+
txs-delta = <12 9 6>;
198+
rates-ru = /bits/ 8 <7 14 14 14 14 14 14 14 14 14 14 14 14>;
199+
};
200+
};
201+
};
202+
};
96203
};
97204
};
98205

‎drivers/net/wireless/ath/ath10k/htc.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -669,7 +669,7 @@ static int ath10k_htc_send_bundle(struct ath10k_htc_ep *ep,
669669

670670
ath10k_dbg(ar, ATH10K_DBG_HTC,
671671
"bundle tx status %d eid %d req count %d count %d len %d\n",
672-
ret, ep->eid, skb_queue_len(&ep->tx_req_head), cn, bundle_skb->len);
672+
ret, ep->eid, skb_queue_len(&ep->tx_req_head), cn, skb_len);
673673
return ret;
674674
}
675675

‎drivers/net/wireless/ath/ath10k/wmi-tlv.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -592,6 +592,9 @@ static void ath10k_wmi_event_tdls_peer(struct ath10k *ar, struct sk_buff *skb)
592592
GFP_ATOMIC
593593
);
594594
break;
595+
default:
596+
kfree(tb);
597+
return;
595598
}
596599

597600
exit:

‎drivers/net/wireless/ath/ath11k/mhi.c‎

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -349,10 +349,19 @@ int ath11k_mhi_register(struct ath11k_pci *ab_pci)
349349
mhi_ctrl->read_reg = ath11k_mhi_op_read_reg;
350350
mhi_ctrl->write_reg = ath11k_mhi_op_write_reg;
351351

352-
if (ab->hw_rev == ATH11K_HW_QCA6390_HW20)
353-
ath11k_mhi_config = &ath11k_mhi_config_qca6390;
354-
else if (ab->hw_rev == ATH11K_HW_QCN9074_HW10)
352+
switch (ab->hw_rev) {
353+
case ATH11K_HW_QCN9074_HW10:
355354
ath11k_mhi_config = &ath11k_mhi_config_qcn9074;
355+
break;
356+
case ATH11K_HW_QCA6390_HW20:
357+
ath11k_mhi_config = &ath11k_mhi_config_qca6390;
358+
break;
359+
default:
360+
ath11k_err(ab, "failed assign mhi_config for unknown hw rev %d\n",
361+
ab->hw_rev);
362+
mhi_free_controller(mhi_ctrl);
363+
return -EINVAL;
364+
}
356365

357366
ret = mhi_register_controller(mhi_ctrl, ath11k_mhi_config);
358367
if (ret) {

‎drivers/net/wireless/ath/ath11k/qmi.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2514,7 +2514,7 @@ static int ath11k_qmi_event_load_bdf(struct ath11k_qmi *qmi)
25142514

25152515
ret = ath11k_qmi_request_target_cap(ab);
25162516
if (ret < 0) {
2517-
ath11k_warn(ab, "failed to requeqst qmi target capabilities: %d\n",
2517+
ath11k_warn(ab, "failed to request qmi target capabilities: %d\n",
25182518
ret);
25192519
return ret;
25202520
}

‎drivers/net/wireless/ath/ath9k/htc_drv_init.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ static unsigned int ath9k_regread(void *hw_priv, u32 reg_offset)
246246
if (unlikely(r)) {
247247
ath_dbg(common, WMI, "REGISTER READ FAILED: (0x%04x, %d)\n",
248248
reg_offset, r);
249-
return -EIO;
249+
return -1;
250250
}
251251

252252
return be32_to_cpu(val);

‎drivers/net/wireless/ath/ath9k/hw.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ static bool ath9k_hw_read_revisions(struct ath_hw *ah)
286286

287287
srev = REG_READ(ah, AR_SREV);
288288

289-
if (srev == -EIO) {
289+
if (srev == -1) {
290290
ath_err(ath9k_hw_common(ah),
291291
"Failed to read SREV register");
292292
return false;

‎drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ static void _brcmf_set_multicast_list(struct work_struct *work)
151151
/* Send down the multicast list first. */
152152
cnt = netdev_mc_count(ndev);
153153
buflen = sizeof(cnt) + (cnt * ETH_ALEN);
154-
buf = kmalloc(buflen, GFP_ATOMIC);
154+
buf = kmalloc(buflen, GFP_KERNEL);
155155
if (!buf)
156156
return;
157157
bufp = buf;

‎drivers/net/wireless/marvell/libertas_tf/libertas_tf.h‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,7 +453,6 @@ struct cmd_ds_802_11_beacon_set {
453453
u8 beacon[MRVL_MAX_BCN_SIZE];
454454
};
455455

456-
struct lbtf_private;
457456
struct cmd_ctrl_node;
458457

459458
/** Function Prototype Declaration */

‎drivers/net/wireless/mediatek/mt76/debugfs.c‎

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,32 @@ mt76_reg_get(void *data, u64 *val)
2525
DEFINE_DEBUGFS_ATTRIBUTE(fops_regval, mt76_reg_get, mt76_reg_set,
2626
"0x%08llx\n");
2727

28+
static int
29+
mt76_napi_threaded_set(void *data, u64 val)
30+
{
31+
struct mt76_dev *dev = data;
32+
33+
if (!mt76_is_mmio(dev))
34+
return -EOPNOTSUPP;
35+
36+
if (dev->napi_dev.threaded != val)
37+
return dev_set_threaded(&dev->napi_dev, val);
38+
39+
return 0;
40+
}
41+
42+
static int
43+
mt76_napi_threaded_get(void *data, u64 *val)
44+
{
45+
struct mt76_dev *dev = data;
46+
47+
*val = dev->napi_dev.threaded;
48+
return 0;
49+
}
50+
51+
DEFINE_DEBUGFS_ATTRIBUTE(fops_napi_threaded, mt76_napi_threaded_get,
52+
mt76_napi_threaded_set, "%llu\n");
53+
2854
int mt76_queues_read(struct seq_file *s, void *data)
2955
{
3056
struct mt76_dev *dev = dev_get_drvdata(s->private);
@@ -102,6 +128,8 @@ struct dentry *mt76_register_debugfs(struct mt76_dev *dev)
102128
debugfs_create_u32("regidx", 0600, dir, &dev->debugfs_reg);
103129
debugfs_create_file_unsafe("regval", 0600, dir, dev,
104130
&fops_regval);
131+
debugfs_create_file_unsafe("napi_threaded", 0600, dir, dev,
132+
&fops_napi_threaded);
105133
debugfs_create_blob("eeprom", 0400, dir, &dev->eeprom);
106134
if (dev->otp.data)
107135
debugfs_create_blob("otp", 0400, dir, &dev->otp);

0 commit comments

Comments
 (0)