Skip to content

Commit 0ccf50d

Browse files
author
Kalle Valo
committed
Merge tag 'ath-next-20240402' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath
ath.git patches for v6.10 ath drivers now have no remaining sparse warnings, otherwise smaller fixes and some refactoring. ath11k * P2P support for QCA6390, WCN6855 and QCA2066
2 parents b68b2be + f09e3b7 commit 0ccf50d

File tree

34 files changed

+660
-218
lines changed

34 files changed

+660
-218
lines changed

drivers/net/wireless/ath/ath10k/thermal.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ static ssize_t ath10k_thermal_show_temp(struct device *dev,
100100
spin_unlock_bh(&ar->data_lock);
101101

102102
/* display in millidegree celsius */
103-
ret = snprintf(buf, PAGE_SIZE, "%d\n", temperature * 1000);
103+
ret = sysfs_emit(buf, "%d\n", temperature * 1000);
104104
out:
105105
mutex_unlock(&ar->conf_mutex);
106106
return ret;

drivers/net/wireless/ath/ath10k/wmi.c

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1763,12 +1763,32 @@ void ath10k_wmi_put_wmi_channel(struct ath10k *ar, struct wmi_channel *ch,
17631763

17641764
int ath10k_wmi_wait_for_service_ready(struct ath10k *ar)
17651765
{
1766-
unsigned long time_left;
1766+
unsigned long time_left, i;
17671767

17681768
time_left = wait_for_completion_timeout(&ar->wmi.service_ready,
17691769
WMI_SERVICE_READY_TIMEOUT_HZ);
1770-
if (!time_left)
1771-
return -ETIMEDOUT;
1770+
if (!time_left) {
1771+
/* Sometimes the PCI HIF doesn't receive interrupt
1772+
* for the service ready message even if the buffer
1773+
* was completed. PCIe sniffer shows that it's
1774+
* because the corresponding CE ring doesn't fires
1775+
* it. Workaround here by polling CE rings once.
1776+
*/
1777+
ath10k_warn(ar, "failed to receive service ready completion, polling..\n");
1778+
1779+
for (i = 0; i < CE_COUNT; i++)
1780+
ath10k_hif_send_complete_check(ar, i, 1);
1781+
1782+
time_left = wait_for_completion_timeout(&ar->wmi.service_ready,
1783+
WMI_SERVICE_READY_TIMEOUT_HZ);
1784+
if (!time_left) {
1785+
ath10k_warn(ar, "polling timed out\n");
1786+
return -ETIMEDOUT;
1787+
}
1788+
1789+
ath10k_warn(ar, "service ready completion received, continuing normally\n");
1790+
}
1791+
17721792
return 0;
17731793
}
17741794

drivers/net/wireless/ath/ath11k/Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ ath11k-y += core.o \
1818
dbring.o \
1919
hw.o \
2020
pcic.o \
21-
fw.o
21+
fw.o \
22+
p2p.o
2223

2324
ath11k-$(CONFIG_ATH11K_DEBUGFS) += debugfs.o debugfs_htt_stats.o debugfs_sta.o
2425
ath11k-$(CONFIG_NL80211_TESTMODE) += testmode.o

drivers/net/wireless/ath/ath11k/core.c

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
247247
},
248248

249249
.interface_modes = BIT(NL80211_IFTYPE_STATION) |
250-
BIT(NL80211_IFTYPE_AP),
250+
BIT(NL80211_IFTYPE_AP) |
251+
BIT(NL80211_IFTYPE_P2P_DEVICE) |
252+
BIT(NL80211_IFTYPE_P2P_CLIENT) |
253+
BIT(NL80211_IFTYPE_P2P_GO),
251254
.supports_monitor = false,
252255
.full_monitor_mode = false,
253256
.supports_shadow_regs = true,
@@ -416,7 +419,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
416419
},
417420

418421
.interface_modes = BIT(NL80211_IFTYPE_STATION) |
419-
BIT(NL80211_IFTYPE_AP),
422+
BIT(NL80211_IFTYPE_AP) |
423+
BIT(NL80211_IFTYPE_P2P_DEVICE) |
424+
BIT(NL80211_IFTYPE_P2P_CLIENT) |
425+
BIT(NL80211_IFTYPE_P2P_GO),
420426
.supports_monitor = false,
421427
.full_monitor_mode = false,
422428
.supports_shadow_regs = true,
@@ -501,7 +507,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
501507
},
502508

503509
.interface_modes = BIT(NL80211_IFTYPE_STATION) |
504-
BIT(NL80211_IFTYPE_AP),
510+
BIT(NL80211_IFTYPE_AP) |
511+
BIT(NL80211_IFTYPE_P2P_DEVICE) |
512+
BIT(NL80211_IFTYPE_P2P_CLIENT) |
513+
BIT(NL80211_IFTYPE_P2P_GO),
505514
.supports_monitor = false,
506515
.supports_shadow_regs = true,
507516
.idle_ps = true,
@@ -750,7 +759,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
750759
},
751760

752761
.interface_modes = BIT(NL80211_IFTYPE_STATION) |
753-
BIT(NL80211_IFTYPE_AP),
762+
BIT(NL80211_IFTYPE_AP) |
763+
BIT(NL80211_IFTYPE_P2P_DEVICE) |
764+
BIT(NL80211_IFTYPE_P2P_CLIENT) |
765+
BIT(NL80211_IFTYPE_P2P_GO),
754766
.supports_monitor = false,
755767
.full_monitor_mode = false,
756768
.supports_shadow_regs = true,

drivers/net/wireless/ath/ath11k/debugfs.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// SPDX-License-Identifier: BSD-3-Clause-Clear
22
/*
33
* Copyright (c) 2018-2020 The Linux Foundation. All rights reserved.
4-
* Copyright (c) 2021-2023 Qualcomm Innovation Center, Inc. All rights reserved.
4+
* Copyright (c) 2021-2024 Qualcomm Innovation Center, Inc. All rights reserved.
55
*/
66

77
#include <linux/vmalloc.h>
@@ -980,7 +980,7 @@ int ath11k_debugfs_pdev_create(struct ath11k_base *ab)
980980
debugfs_create_file("simulate_fw_crash", 0600, ab->debugfs_soc, ab,
981981
&fops_simulate_fw_crash);
982982

983-
debugfs_create_file("soc_dp_stats", 0600, ab->debugfs_soc, ab,
983+
debugfs_create_file("soc_dp_stats", 0400, ab->debugfs_soc, ab,
984984
&fops_soc_dp_stats);
985985

986986
if (ab->hw_params.sram_dump.start != 0)

0 commit comments

Comments
 (0)