mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "André Eikmeyer" <dev@deq.rocks>
To: arend.vanspriel@broadcom.com
Cc: asahi@lists.linux.dev, brcm80211-dev-list.pdl@broadcom.com,
	brcm80211@lists.linux.dev, dberlin@dberlin.org,
	frankyl@broadcom.com, gustavoars@kernel.org, j@jannau.net,
	kees@kernel.org, kvalo@kernel.org,
	linux-hardening@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-wireless@vger.kernel.org, marcan@marcan.st,
	meuleman@broadcom.com, michael.reeves077@gmail.com,
	pieterpg@broadcom.com, vanhoefm@gmail.com
Subject: Re: [PATCH 05/13] wifi: brcmfmac: Negotiate PCIe mailbox transport with firmware
Date: Fri, 6 Nov 2026 15:36:12 +0100	[thread overview]
Message-ID: <20261106153612.2aadef2a@kait2en-mbp15-1> (raw)
In-Reply-To: <20261103135856.3676311-7-arend.vanspriel@broadcom.com>

Hi Michael,

I tested 01, 04 and 05 on a T2 Macbook Air 9,1 (BCM4377/4). IIRC should be 
the same chip as on T2 Macbook 15,4.

Arend, with the patch we get D3 ACK on s2idle and s3. So this basically
renders the D3 ACK WoWL workaround patch obsolete, you recently acked.
So it will suspend now without refusing d3cold transition, but BT is still
dead on resume, which is a separate issue. Just mentioning... 

Anyways Michael, the patch as acked now will fail on resume with

  brcmf_pcie_send_mb_data: Failed to send H2D mailbox data (-5)

brcmf_pcie_pm_leave_D3() sends D0_INFORM while devinfo->state is still
DOWN, hence we get an -EIO, so the driver falls back to remove and 
re-probe. The Asahi tree sets the state before D0_INFORM. With that
change my 4377 resumes without reset.


--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pcie.c
@@ -2838,10 +2838,10 @@ static int brcmf_pcie_pm_leave_D3(struct device *dev)
        /* Check if device is still up and running, if so we are ready */
        if (brcmf_pcie_read_pcie32(devinfo, devinfo->reginfo->intmask) != 0) {
                brcmf_dbg(PCIE, "Try to wakeup device....\n");
+               devinfo->state = BRCMFMAC_PCIE_STATE_UP;
                if (brcmf_pcie_send_mb_data(devinfo, BRCMF_H2D_HOST_D0_INFORM))
                        goto cleanup;
                brcmf_dbg(PCIE, "Hot resume, continue....\n");
-               devinfo->state = BRCMFMAC_PCIE_STATE_UP;
                brcmf_pcie_select_core(devinfo, BCMA_CORE_PCIE2);
                brcmf_bus_change_state(bus, BRCMF_BUS_UP);
                brcmf_pcie_intr_enable(devinfo);
@@ -2851,6 +2851,7 @@ static int brcmf_pcie_pm_leave_D3(struct device *dev)
        }

 cleanup:
+       devinfo->state = BRCMFMAC_PCIE_STATE_DOWN;
        brcmf_chip_detach(devinfo->ci);
        devinfo->ci = NULL;
        pdev = devinfo->pdev;

Feel free to fold it into v2, or I can send it as a follow-up if the
series is already applied.

Andre

  reply	other threads:[~2026-11-06 14:36 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-25 13:43 [PATCH 00/13] wifi: brcmfmac: Add BCM4388 support Michael Reeves via B4 Relay
2026-09-25 13:43 ` [PATCH 01/13] wifi: brcmfmac: pcie: Report the detected chip ID to the bus Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 02/13] wifi: brcmfmac: Match complete firmware capability names Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 03/13] wifi: brcmfmac: Fall back to RSSI-only default join preferences Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 04/13] wifi: brcmfmac: Support newer PCIe core startup and interrupts Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 05/13] wifi: brcmfmac: Negotiate PCIe mailbox transport with firmware Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-11-06 14:36     ` André Eikmeyer [this message]
2026-11-06 17:36       ` Arend van Spriel
2026-11-06 18:18         ` André Eikmeyer
2026-11-07  7:23           ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 06/13] wifi: brcmfmac: Load signed PCIe firmware images Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 07/13] wifi: brcmfmac: Use event_msgs_ext for event masks Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 08/13] wifi: brcmfmac: Handle larger firmware band lists Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 09/13] wifi: brcmfmac: Accept newer BSS information versions Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 10/13] wifi: brcmfmac: Support versioned scan parameter layouts Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 11/13] wifi: brcmfmac: Support versioned join requests Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 12/13] wifi: brcmfmac: Handle extended PMK command payloads Michael Reeves via B4 Relay
2026-11-03 13:58   ` Arend van Spriel
2026-09-25 13:43 ` [PATCH 13/13] wifi: brcmfmac: Add BCM4388 support Michael Reeves via B4 Relay
2026-11-02 20:36   ` Janne Grunau
2026-11-03 13:58   ` Arend van Spriel
2026-10-07 12:54 ` [PATCH 00/13] " Arend van Spriel
2026-11-01 19:27 ` Arend van Spriel
2026-11-02 20:46   ` Janne Grunau
2026-11-03 13:51     ` Arend van Spriel
2026-11-02  0:42 ` Neal Gompa
2026-11-02 16:58   ` Arend van Spriel
2026-11-05 21:44     ` Neal Gompa

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261106153612.2aadef2a@kait2en-mbp15-1 \
    --to=dev@deq.rocks \
    --cc=arend.vanspriel@broadcom.com \
    --cc=asahi@lists.linux.dev \
    --cc=brcm80211-dev-list.pdl@broadcom.com \
    --cc=brcm80211@lists.linux.dev \
    --cc=dberlin@dberlin.org \
    --cc=frankyl@broadcom.com \
    --cc=gustavoars@kernel.org \
    --cc=j@jannau.net \
    --cc=kees@kernel.org \
    --cc=kvalo@kernel.org \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=marcan@marcan.st \
    --cc=meuleman@broadcom.com \
    --cc=michael.reeves077@gmail.com \
    --cc=pieterpg@broadcom.com \
    --cc=vanhoefm@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®