diff options
author | Rafał Miłecki <rafal@milecki.pl> | 2020-02-06 11:36:15 +0100 |
---|---|---|
committer | Rafał Miłecki <rafal@milecki.pl> | 2020-02-06 11:36:15 +0100 |
commit | aca274091ad3b50b770c0dd44f3ceefe8095d528 (patch) | |
tree | c9f2b67316f49194ef59737dab771d4af4b366d2 /package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch | |
parent | 71de48bd375bbde9b70ccf94b03c3f9c2aae5f21 (diff) | |
download | upstream-aca274091ad3b50b770c0dd44f3ceefe8095d528.tar.gz upstream-aca274091ad3b50b770c0dd44f3ceefe8095d528.tar.bz2 upstream-aca274091ad3b50b770c0dd44f3ceefe8095d528.zip |
mac80211: brcm: backport remaining 5.6 kernel patches
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Diffstat (limited to 'package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch')
-rw-r--r-- | package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch b/package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch new file mode 100644 index 0000000000..5ec2e9b131 --- /dev/null +++ b/package/kernel/mac80211/patches/brcm/118-v5.6-brcmfmac-sdio-Fix-OOB-interrupt-initialization-on-br.patch @@ -0,0 +1,57 @@ +From 8c8e60fb86a90a30721bbd797f58f96b3980dcc1 Mon Sep 17 00:00:00 2001 +From: Jean-Philippe Brucker <jean-philippe@linaro.org> +Date: Thu, 26 Dec 2019 10:20:33 +0100 +Subject: [PATCH] brcmfmac: sdio: Fix OOB interrupt initialization on brcm43362 + +Commit 262f2b53f679 ("brcmfmac: call brcmf_attach() just before calling +brcmf_bus_started()") changed the initialization order of the brcmfmac +SDIO driver. Unfortunately since brcmf_sdiod_intr_register() is now +called before the sdiodev->bus_if initialization, it reads the wrong +chip ID and fails to initialize the GPIO on brcm43362. Thus the chip +cannot send interrupts and fails to probe: + +[ 12.517023] brcmfmac: brcmf_sdio_bus_rxctl: resumed on timeout +[ 12.531214] ieee80211 phy0: brcmf_bus_started: failed: -110 +[ 12.536976] ieee80211 phy0: brcmf_attach: dongle is not responding: err=-110 +[ 12.566467] brcmfmac: brcmf_sdio_firmware_callback: brcmf_attach failed + +Initialize the bus interface earlier to ensure that +brcmf_sdiod_intr_register() properly sets up the OOB interrupt. + +BugLink: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=908438 +Fixes: 262f2b53f679 ("brcmfmac: call brcmf_attach() just before calling brcmf_bus_started()") +Signed-off-by: Jean-Philippe Brucker <jean-philippe@linaro.org> +Reviewed-by: Arend van Spriel <arend.vanspriel@broadcom.com> +Signed-off-by: Kalle Valo <kvalo@codeaurora.org> +--- + .../net/wireless/broadcom/brcm80211/brcmfmac/sdio.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c ++++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/sdio.c +@@ -4243,6 +4243,12 @@ static void brcmf_sdio_firmware_callback + } + + if (err == 0) { ++ /* Assign bus interface call back */ ++ sdiod->bus_if->dev = sdiod->dev; ++ sdiod->bus_if->ops = &brcmf_sdio_bus_ops; ++ sdiod->bus_if->chip = bus->ci->chip; ++ sdiod->bus_if->chiprev = bus->ci->chiprev; ++ + /* Allow full data communication using DPC from now on. */ + brcmf_sdiod_change_state(bus->sdiodev, BRCMF_SDIOD_DATA); + +@@ -4259,12 +4265,6 @@ static void brcmf_sdio_firmware_callback + + sdio_release_host(sdiod->func1); + +- /* Assign bus interface call back */ +- sdiod->bus_if->dev = sdiod->dev; +- sdiod->bus_if->ops = &brcmf_sdio_bus_ops; +- sdiod->bus_if->chip = bus->ci->chip; +- sdiod->bus_if->chiprev = bus->ci->chiprev; +- + err = brcmf_alloc(sdiod->dev, sdiod->settings); + if (err) { + brcmf_err("brcmf_alloc failed\n"); |