All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arend van Spriel <arend.vanspriel@broadcom.com>
To: "Rafał Miłecki" <zajec5@gmail.com>, linux-wireless@vger.kernel.org
Cc: brcm80211-dev-list.pdl@broadcom.com,
	brcm80211-dev-list@cypress.com,
	"Rafał Miłecki" <rafal@milecki.pl>
Subject: Re: [DEBUG PATCH] brcmfmac: add firmware watchdog running on host machine
Date: Thu, 16 Aug 2018 14:04:30 +0200	[thread overview]
Message-ID: <5B75684E.9010102@broadcom.com> (raw)
In-Reply-To: <20180815180101.15087-1-zajec5@gmail.com>

On 8/15/2018 8:01 PM, Rafał Miłecki wrote:
> From: Rafał Miłecki <rafal@milecki.pl>
>
> It may happen for FullMAC firmware to crash. It should be detected and
> ideally somehow handled by a driver.
>
> Since commit ff4445a8502c ("brcmfmac: expose device memory to
> devcoredump subsystem") brcmfmac has BRCMF_E_PSM_WATCHDOG event handler
> but it wasn't enough to detect all kind of crashes. E.g. Netgear R8000
> (BCM4709A0 + 3 x BCM43602) user was exepriencing firmware crashes that
> never resulted in passing BRCMF_E_PSM_WATCHDOG to the host driver.

Thanks, Rafał

The PSM watchdog is actually not a firmware crash. It means the lower 
part of the stack, which runs in the d11 core aka PSM, did not complete 
its work in the required timing budget.

> That made me implement this trivial software watchdog that simply checks
> periodically if firmware still replies to the commands.
>
> Luckily this patch DOES NOT seem to be needed anymore since the commit
> 8a3ab2f38f16 ("brcmfmac: trigger memory dump upon firmware halt
> signal"). That change allows brcmfmac to detect firmware crashes
> successfully.

It can still miss a firmware crash if it happens really soon. Those 
crashes mostly happens when trying to load firmware for chip revision A 
on chip with revision B due to differences in code contained in ROM.

Regards,
Arend

> This patch is being posted for research/debugging purposes only. It
> SHOULD NOT be applied until someone notices a firmware crash that
> doesn't trigger the BRCMF_D2H_DEV_FWHALT signal.
>
> Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
> ---

      parent reply	other threads:[~2018-08-16 15:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-15 18:01 [DEBUG PATCH] brcmfmac: add firmware watchdog running on host machine Rafał Miłecki
2018-08-16 10:45 ` Kalle Valo
2018-08-16 12:04 ` Arend van Spriel [this message]

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=5B75684E.9010102@broadcom.com \
    --to=arend.vanspriel@broadcom.com \
    --cc=brcm80211-dev-list.pdl@broadcom.com \
    --cc=brcm80211-dev-list@cypress.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=rafal@milecki.pl \
    --cc=zajec5@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.