aboutsummaryrefslogtreecommitdiff
path: root/package
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2024-01-26 17:10:31 +0100
committerÁlvaro Fernández Rojas <noltari@gmail.com>2024-01-26 18:29:22 +0100
commit8dcc695633034adcbcb6a05d922c108eee7e7ace (patch)
treea0f68c7ff165cecff6dd627c1a63d925581acbcc /package
parent1b3259eb5cdcfecbfae7809b8a9febdbe22ac65f (diff)
mac80211: brcm: remove alternative DT firmware names patch
This patch has been reverted in the Raspberry Pi linux repository. Also refresh the rest of the patches. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'package')
-rw-r--r--package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch2
-rw-r--r--package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch8
-rw-r--r--package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch6
-rw-r--r--package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch2
-rw-r--r--package/kernel/mac80211/patches/brcm/865-brcmfmac-Read-alternative-firmware-names-from-DT.patch191
-rw-r--r--package/kernel/mac80211/patches/subsys/780-avoid-crashing-missing-band.patch2
6 files changed, 10 insertions, 201 deletions
diff --git a/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch b/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch
index 54abb4d425..474fb3fdbe 100644
--- a/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch
+++ b/package/kernel/mac80211/patches/ath9k/512-ath9k_channelbw_debugfs.patch
@@ -79,7 +79,7 @@
}
--- a/drivers/net/wireless/ath/ath9k/common-debug.c
+++ b/drivers/net/wireless/ath/ath9k/common-debug.c
-@@ -316,3 +316,55 @@ void ath9k_cmn_debug_eeprom(struct dentr
+@@ -315,3 +315,55 @@ void ath9k_cmn_debug_eeprom(struct dentr
&fops_eeprom);
}
EXPORT_SYMBOL(ath9k_cmn_debug_eeprom);
diff --git a/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch b/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch
index e09bbc08ea..c54dbbb188 100644
--- a/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch
+++ b/package/kernel/mac80211/patches/ath9k/542-ath9k_debugfs_diag.patch
@@ -1,8 +1,8 @@
--- a/drivers/net/wireless/ath/ath9k/debug.c
+++ b/drivers/net/wireless/ath/ath9k/debug.c
-@@ -1562,6 +1562,50 @@ static const struct file_operations fops
- #endif
-
+@@ -1468,6 +1468,50 @@ void ath9k_deinit_debug(struct ath_softc
+ ath9k_cmn_spectral_deinit_debug(&sc->spec_priv);
+ }
+static ssize_t read_file_diag(struct file *file, char __user *user_buf,
+ size_t count, loff_t *ppos)
@@ -51,7 +51,7 @@
int ath9k_init_debug(struct ath_hw *ah)
{
struct ath_common *common = ath9k_hw_common(ah);
-@@ -1589,6 +1633,8 @@ int ath9k_init_debug(struct ath_hw *ah)
+@@ -1491,6 +1535,8 @@ int ath9k_init_debug(struct ath_hw *ah)
debugfs_create_file("gpio_led", S_IWUSR,
sc->debug.debugfs_phy, sc, &fops_gpio_led);
#endif
diff --git a/package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch b/package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch
index 00451061f2..8b399f4b4c 100644
--- a/package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch
+++ b/package/kernel/mac80211/patches/ath9k/543-ath9k_entropy_from_adc.patch
@@ -55,7 +55,7 @@
ops->spectral_scan_config = ar9003_hw_spectral_scan_config;
--- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c
-@@ -870,7 +870,8 @@ static void ath9k_init_txpower_limits(st
+@@ -871,7 +871,8 @@ static void ath9k_init_txpower_limits(st
if (ah->caps.hw_caps & ATH9K_HW_CAP_5GHZ)
ath9k_init_band_txpower(sc, NL80211_BAND_5GHZ);
@@ -65,7 +65,7 @@
}
static const struct ieee80211_iface_limit if_limits[] = {
-@@ -1048,6 +1049,18 @@ static void ath9k_set_hw_capab(struct at
+@@ -1049,6 +1050,18 @@ static void ath9k_set_hw_capab(struct at
wiphy_ext_feature_set(hw->wiphy, NL80211_EXT_FEATURE_CAN_REPLACE_PTK0);
}
@@ -84,7 +84,7 @@
int ath9k_init_device(u16 devid, struct ath_softc *sc,
const struct ath_bus_ops *bus_ops)
{
-@@ -1095,6 +1108,8 @@ int ath9k_init_device(u16 devid, struct
+@@ -1096,6 +1109,8 @@ int ath9k_init_device(u16 devid, struct
wiphy_read_of_freq_limits(hw->wiphy);
diff --git a/package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch b/package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch
index 6d1820ecb7..752a4980a4 100644
--- a/package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch
+++ b/package/kernel/mac80211/patches/ath9k/553-ath9k_of_gpio_mask.patch
@@ -13,7 +13,7 @@
static int ath9k_init_softc(u16 devid, struct ath_softc *sc,
const struct ath_bus_ops *bus_ops)
{
-@@ -803,6 +809,9 @@ static int ath9k_init_softc(u16 devid, s
+@@ -804,6 +810,9 @@ static int ath9k_init_softc(u16 devid, s
if (ret)
goto err_hw;
diff --git a/package/kernel/mac80211/patches/brcm/865-brcmfmac-Read-alternative-firmware-names-from-DT.patch b/package/kernel/mac80211/patches/brcm/865-brcmfmac-Read-alternative-firmware-names-from-DT.patch
deleted file mode 100644
index 22e26e7698..0000000000
--- a/package/kernel/mac80211/patches/brcm/865-brcmfmac-Read-alternative-firmware-names-from-DT.patch
+++ /dev/null
@@ -1,191 +0,0 @@
-From 4e32024cbb14230af3048e249e84f8c2b25ce45a Mon Sep 17 00:00:00 2001
-From: Phil Elwell <phil@raspberrypi.com>
-Date: Thu, 28 Oct 2021 15:03:16 +0100
-Subject: [PATCH] brcmfmac: Read alternative firmware names from DT
-
-Add the ability to load the names of alternative firmwares from the
-Device Tree node. This permits separate firmwares for 43436s and 43438
-and allows downstream firmwares to coexist with upstream.
-
-Signed-off-by: Phil Elwell <phil@raspberrypi.com>
----
- .../wireless/broadcom/brcm80211/brcmfmac/of.c | 36 ++++++++++++++
- .../wireless/broadcom/brcm80211/brcmfmac/of.h | 7 +++
- .../broadcom/brcm80211/brcmfmac/sdio.c | 47 +++++++++++++++++--
- 3 files changed, 87 insertions(+), 3 deletions(-)
-
---- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c
-+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.c
-@@ -11,6 +11,7 @@
- #include "debug.h"
- #include "core.h"
- #include "common.h"
-+#include "firmware.h"
- #include "of.h"
-
- static int brcmf_of_get_country_codes(struct device *dev,
-@@ -175,3 +176,38 @@ void brcmf_of_probe(struct device *dev,
- sdio->oob_irq_nr = irq;
- sdio->oob_irq_flags = irqf;
- }
-+
-+struct brcmf_firmware_mapping *
-+brcmf_of_fwnames(struct device *dev, u32 *fwname_count)
-+{
-+ struct device_node *np = dev->of_node;
-+ struct brcmf_firmware_mapping *fwnames;
-+ struct device_node *map_np, *fw_np;
-+ int of_count;
-+ int count = 0;
-+
-+ map_np = of_get_child_by_name(np, "firmwares");
-+ of_count = of_get_child_count(map_np);
-+ if (!of_count)
-+ return NULL;
-+
-+ fwnames = devm_kcalloc(dev, of_count,
-+ sizeof(struct brcmf_firmware_mapping),
-+ GFP_KERNEL);
-+
-+ for_each_child_of_node(map_np, fw_np)
-+ {
-+ struct brcmf_firmware_mapping *cur = &fwnames[count];
-+
-+ if (of_property_read_u32(fw_np, "chipid", &cur->chipid) ||
-+ of_property_read_u32(fw_np, "revmask", &cur->revmask))
-+ continue;
-+ cur->fw_base = of_get_property(fw_np, "fw_base", NULL);
-+ if (cur->fw_base)
-+ count++;
-+ }
-+
-+ *fwname_count = count;
-+
-+ return count ? fwnames : NULL;
-+}
---- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.h
-+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/of.h
-@@ -5,9 +5,20 @@
- #ifdef CONFIG_OF
- void brcmf_of_probe(struct device *dev, enum brcmf_bus_type bus_type,
- struct brcmf_mp_device *settings);
-+#ifdef CPTCFG_BRCMFMAC_SDIO
-+struct brcmf_firmware_mapping *
-+brcmf_of_fwnames(struct device *dev, u32 *map_count);
-+#endif
- #else
- static void brcmf_of_probe(struct device *dev, enum brcmf_bus_type bus_type,
- struct brcmf_mp_device *settings)
- {
- }
-+#ifdef CPTCFG_BRCMFMAC_SDIO
-+static struct brcmf_firmware_mapping *
-+brcmf_of_fwnames(struct device *dev, u32 *map_count)
-+{
-+ return NULL;
-+}
-+#endif
- #endif /* CONFIG_OF */
---- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c
-+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c
-@@ -35,6 +35,7 @@
- #include "core.h"
- #include "common.h"
- #include "bcdc.h"
-+#include "of.h"
-
- #define DCMD_RESP_TIMEOUT msecs_to_jiffies(2500)
- #define CTL_DONE_TIMEOUT msecs_to_jiffies(2500)
-@@ -632,7 +633,7 @@ MODULE_FIRMWARE(BRCMF_FW_DEFAULT_PATH "b
- /* per-board firmware binaries */
- MODULE_FIRMWARE(BRCMF_FW_DEFAULT_PATH "brcmfmac*-sdio.*.bin");
-
--static const struct brcmf_firmware_mapping brcmf_sdio_fwnames[] = {
-+static const struct brcmf_firmware_mapping sdio_fwnames[] = {
- BRCMF_FW_ENTRY(BRCM_CC_43143_CHIP_ID, 0xFFFFFFFF, 43143),
- BRCMF_FW_ENTRY(BRCM_CC_43241_CHIP_ID, 0x0000001F, 43241B0),
- BRCMF_FW_ENTRY(BRCM_CC_43241_CHIP_ID, 0x00000020, 43241B4),
-@@ -660,6 +661,9 @@ static const struct brcmf_firmware_mappi
- BRCMF_FW_ENTRY(CY_CC_43752_CHIP_ID, 0xFFFFFFFF, 43752)
- };
-
-+static const struct brcmf_firmware_mapping *brcmf_sdio_fwnames = sdio_fwnames;
-+static u32 brcmf_sdio_fwnames_count = ARRAY_SIZE(sdio_fwnames);
-+
- #define TXCTL_CREDITS 2
-
- static void pkt_align(struct sk_buff *p, int len, int align)
-@@ -4201,6 +4205,9 @@ static const struct brcmf_bus_ops brcmf_
- #define BRCMF_SDIO_FW_NVRAM 1
- #define BRCMF_SDIO_FW_CLM 2
-
-+static struct brcmf_fw_request *
-+brcmf_sdio_prepare_fw_request(struct brcmf_sdio *bus);
-+
- static void brcmf_sdio_firmware_callback(struct device *dev, int err,
- struct brcmf_fw_request *fwreq)
- {
-@@ -4216,6 +4223,22 @@ static void brcmf_sdio_firmware_callback
-
- brcmf_dbg(TRACE, "Enter: dev=%s, err=%d\n", dev_name(dev), err);
-
-+ if (err && brcmf_sdio_fwnames != sdio_fwnames) {
-+ /* Try again with the standard firmware names */
-+ brcmf_sdio_fwnames = sdio_fwnames;
-+ brcmf_sdio_fwnames_count = ARRAY_SIZE(sdio_fwnames);
-+ kfree(fwreq);
-+ fwreq = brcmf_sdio_prepare_fw_request(bus);
-+ if (!fwreq) {
-+ err = -ENOMEM;
-+ goto fail;
-+ }
-+ err = brcmf_fw_get_firmwares(dev, fwreq,
-+ brcmf_sdio_firmware_callback);
-+ if (!err)
-+ return;
-+ }
-+
- if (err)
- goto fail;
-
-@@ -4426,7 +4449,7 @@ brcmf_sdio_prepare_fw_request(struct brc
-
- fwreq = brcmf_fw_alloc_request(bus->ci->chip, bus->ci->chiprev,
- brcmf_sdio_fwnames,
-- ARRAY_SIZE(brcmf_sdio_fwnames),
-+ brcmf_sdio_fwnames_count,
- fwnames, ARRAY_SIZE(fwnames));
- if (!fwreq)
- return NULL;
-@@ -4446,6 +4469,9 @@ struct brcmf_sdio *brcmf_sdio_probe(stru
- struct brcmf_sdio *bus;
- struct workqueue_struct *wq;
- struct brcmf_fw_request *fwreq;
-+ struct brcmf_firmware_mapping *of_fwnames, *fwnames = NULL;
-+ const int fwname_size = sizeof(struct brcmf_firmware_mapping);
-+ u32 of_fw_count;
-
- brcmf_dbg(TRACE, "Enter\n");
-
-@@ -4528,6 +4554,21 @@ struct brcmf_sdio *brcmf_sdio_probe(stru
-
- brcmf_dbg(INFO, "completed!!\n");
-
-+ of_fwnames = brcmf_of_fwnames(sdiodev->dev, &of_fw_count);
-+ if (of_fwnames)
-+ fwnames = devm_kcalloc(sdiodev->dev,
-+ of_fw_count + brcmf_sdio_fwnames_count,
-+ fwname_size, GFP_KERNEL);
-+
-+ if (fwnames) {
-+ /* The array is scanned in order, so overrides come first */
-+ memcpy(fwnames, of_fwnames, of_fw_count * fwname_size);
-+ memcpy(fwnames + of_fw_count, sdio_fwnames,
-+ brcmf_sdio_fwnames_count * fwname_size);
-+ brcmf_sdio_fwnames = fwnames;
-+ brcmf_sdio_fwnames_count += of_fw_count;
-+ }
-+
- fwreq = brcmf_sdio_prepare_fw_request(bus);
- if (!fwreq) {
- ret = -ENOMEM;
diff --git a/package/kernel/mac80211/patches/subsys/780-avoid-crashing-missing-band.patch b/package/kernel/mac80211/patches/subsys/780-avoid-crashing-missing-band.patch
index 2bc11efd00..4bbd786043 100644
--- a/package/kernel/mac80211/patches/subsys/780-avoid-crashing-missing-band.patch
+++ b/package/kernel/mac80211/patches/subsys/780-avoid-crashing-missing-band.patch
@@ -18,7 +18,7 @@ Signed-off-by: David Bauer <mail@david-bauer.net>
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
-@@ -2422,6 +2422,13 @@ static void sta_stats_decode_rate(struct
+@@ -2423,6 +2423,13 @@ static void sta_stats_decode_rate(struct
sband = local->hw.wiphy->bands[band];