[PATCH ath-next v2 2/2] wifi: ath12k: request firmware-2.bin directly
From: Julius Bairaktaris
Date: Sat Nov 14 2026 - 17:21:55 EST
ath12k requests the optional firmware-2.bin with
firmware_request_nowarn() and uses API 1 when the request fails.
firmware_request_nowarn() only silences the kernel's warning. It does
not set FW_OPT_NOFALLBACK_SYSFS, so with
CONFIG_FW_LOADER_USER_HELPER_FALLBACK=y the lookup of a missing file
falls back to sysfs and sends a firmware uevent, which user space such
as OpenWrt's procd hotplug handler reports as a missing firmware file.
Request the file with request_firmware_direct(), which sets
FW_OPT_NOFALLBACK_SYSFS, so a missing file is not passed to user space.
This is the same change as for ath11k.
Signed-off-by: Julius Bairaktaris <julius@xxxxxxxxxxxxxx>
---
v2:
- target ath-next in the subject
- name the code path that produces the message and why request_firmware_direct() avoids it
- drop the Assisted-by trailer
- rebased on ath-next 1be6c8d3027d, no code change
- new patch, same change for ath12k
v1: https://lore.kernel.org/all/20260910071838.1983652-1-julius@xxxxxxxxxxxxxx/
drivers/net/wireless/ath/ath12k/fw.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/net/wireless/ath/ath12k/fw.c b/drivers/net/wireless/ath/ath12k/fw.c
index 22074653cbb8..842830d2bfa3 100644
--- a/drivers/net/wireless/ath/ath12k/fw.c
+++ b/drivers/net/wireless/ath/ath12k/fw.c
@@ -15,10 +15,12 @@ static int ath12k_fw_request_firmware_api_n(struct ath12k_base *ab,
struct ath12k_fw_ie *hdr;
const u8 *data;
__le32 *timestamp;
+ char path[100];
- ab->fw.fw = ath12k_core_firmware_request(ab, name);
- if (IS_ERR(ab->fw.fw)) {
- ret = PTR_ERR(ab->fw.fw);
+ ath12k_core_create_firmware_path(ab, name, path, sizeof(path));
+
+ ret = request_firmware_direct(&ab->fw.fw, path, ab->dev);
+ if (ret) {
ath12k_dbg(ab, ATH12K_DBG_BOOT, "failed to load %s: %d\n", name, ret);
ab->fw.fw = NULL;
return ret;
--
2.53.0