Revert "brcmfmac: Disable power management"
authorPhil Elwell <phil@raspberrypi.org>
Wed, 13 Nov 2019 16:28:10 +0000 (16:28 +0000)
committerpopcornmix <popcornmix@gmail.com>
Wed, 1 Jul 2020 15:33:10 +0000 (16:33 +0100)
Shortly after the release of the Pi 3B, a loss of SSH connectivity
over WiFi was traced to the power management handling, so power
management was disabled. And so it has remained ever since.

Enabling power management saves 55mA (~270mW) on a Pi 4B, so is very
much worth the minimal effort of reverting this patch, which was
squashed and rebased many times since then to the commit hash is
meaningless.

Signed-off-by: Phil Elwell <phil@raspberrypi.org>
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c

index 74e9b32..d6ae70f 100644 (file)
@@ -2767,8 +2767,6 @@ brcmf_cfg80211_set_power_mgmt(struct wiphy *wiphy, struct net_device *ndev,
         * preference in cfg struct to apply this to
         * FW later while initializing the dongle
         */
-       pr_info("power management disabled\n");
-       enabled = false;
        cfg->pwr_save = enabled;
        if (!check_vif_up(ifp->vif)) {
 
@@ -2782,7 +2780,7 @@ brcmf_cfg80211_set_power_mgmt(struct wiphy *wiphy, struct net_device *ndev,
                brcmf_dbg(INFO, "Do not enable power save for P2P clients\n");
                pm = PM_OFF;
        }
-       brcmf_dbg(INFO, "power save %s\n", (pm ? "enabled" : "disabled"));
+       brcmf_err("power save %s\n", (pm ? "enabled" : "disabled"));
 
        err = brcmf_fil_cmd_int_set(ifp, BRCMF_C_SET_PM, pm);
        if (err) {