Skip to content

Conversation

@Foutete
Copy link
Contributor

@Foutete Foutete commented Aug 14, 2025

This PR adds the support for Broadcom SoC's bcm2711 and bcm2712 in snagrecover.
It has been developed and tested using Raspberry Pi CM4 and CM5.

I use pyfatfs python module so I added it to the project dependencies.

@Foutete Foutete force-pushed the broadcom_recoveries branch 2 times, most recently from 890f4e6 to f59468d Compare August 18, 2025 08:01
Copy link
Collaborator

@rgantois rgantois left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! I've requested a few minor changes. You're also going to have to rebase on the latest master branch as there currently are some conflicts. It also seems like some CI tests have failed, please take a look at those as well.

Thanks!

The load_fw() function currently consistently checks the format of the
requested firmware file, and emits a warning if it looks like a text file. Or,
the pending snagrecover support for BCM SoCs requires loading a firmware file
which is actually expected to be in text format. Thus, a non-relevant warning
will be emitted in this case.

Allow making this firmware file format check optional to avoid non-relevant
warnings when a text format is expected.

Signed-off-by: François Foltete <[email protected]>
The load_fw() function verifies if the requested firmware has a valid
configuration, gets its path and loads it all in one go. Or the pending
snagrecover support for BCM SoCs requires a way of resolving firmware paths
without immediately loading them.

To provide this feature and improve error reporting, separate getting the
firmware's path and loading it into two separate functions.

Signed-off-by: François Foltete <[email protected]>
Add the recovery process for broadcom SoCs bcm2711 and bcm2712.
These SoCs are used in Raspberry Pi Compute Module 4 and 5
respectively.

The recovery process is as follows:
  1. Send FSBL to ROM Code
  2. The FSBL functions as a file server client,
     we answer its requests.
  3. Voilà

Signed-off-by: François Foltete <[email protected]>
Add recovery documentation for Broadcom SoCs
bcm 2711|2712.

Signed-off-by: François Foltete <[email protected]>
@Foutete Foutete force-pushed the broadcom_recoveries branch from f59468d to 2baaa31 Compare August 22, 2025 10:09
@rgantois
Copy link
Collaborator

LGTM, there's one small linter error remaining but I'll handle that one separately.

@rgantois rgantois merged commit 367e670 into bootlin:main Aug 25, 2025
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants