Skip to content

MATTER-7270: Update provision script to add pinset argument for boards with external flash - #277

Merged
Arghya Dutta (silabs-ArghyaD) merged 3 commits into
release_2.10-1.6.1from
fix/provision_script_for_external_flash
Nov 6, 2026
Merged

Arghya Dutta (silabs-ArghyaD) merged 3 commits into
release_2.10-1.6.1from
fix/provision_script_for_external_flash

Conversation

@silabs-ArghyaD

@silabs-ArghyaD Arghya Dutta (silabs-ArghyaD) commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

Issue Link - MATTER-7270

Problem / Feature

  1. For boards with internal and external flash, we need to use the pinset argument for commander manufacturing userdata erase command (only used for 917 boards in the script).
    According to platform team, "without the pinset argument, commander is trying to erase the internal flash. Using --pinset 2 is the correct way of erasing user data on these boards which has internal and external flash."
    Doc ref - pinset-configuration

  2. The gfw binaries in matter_support didn't update after this cherry-pick PR merged into matter_provisioning.
    The PR to update the binaries in matter_support was not opened by the CICD as the binary had changes less than 0-byte - link.

DEBUG: Checking library files in /opt/github/runner/_work/matter_provisioning/matter_provisioning/matter_support/provision/images for 0-byte changes...
DEBUG: File: si917_core.rps (delta: 0 bytes)
DEBUG:   -> Reverting si917_core.rps (zero byte delta)
DEBUG:   -> Successfully reverted si917_core.rps
DEBUG: File: si917y_core.rps (delta: 0 bytes)
DEBUG:   -> Reverting si917y_core.rps (zero byte delta)
DEBUG:   -> Successfully reverted si917y_core.rps
INFO: Library processing complete:
INFO:   Files reverted: 2
INFO:   Files kept: 0

So I've downloaded the binaries from CICD artifacts and manually updated them in this PR.

Change overview

  • Added getBoardInfo function to fetch board part number.
  • Hardcoded ERASE_USERDATA_PINSET2_BOARDS set as didn't find any particular field to distinguish them. For example, the debug part SiWG917M111MGTBA is same for both brd4338a (which doesn't need pinset argument) and brd9084b (which needs pinset argument).
  • Manually updated the gfw binaries from - CICD artifacts

Testing

  • Tested provisioning with the updated script and binaries for both brd4338a and brd9084b. The script is successfully fetching the part number and adding the pinset argument only for the required board.
  • The above test was done with boards connected using both IP and wired.

@cursor

cursor Bot commented Nov 5, 2026 •

Copy link
Copy Markdown

PR Summary

Medium Risk
Changes the manufacturing erase path during Si917 flashing; incorrect board matching or probe failures could leave userdata uncleared or use the wrong pinset on mixed internal/external flash boards.

Overview
For Si917 auto provisioning, the pre-flash manufacturing erase userdata step now adds --pinset 2 when the connected board is one of the BRD9084A–D variants that use external flash, so Commander erases userdata on the correct flash instead of defaulting to internal flash.

Board detection is done via a new getBoardInfo helper that runs commander adapter probe (honoring serial/IP connection args) and parses BRD####X part numbers from the output against a hardcoded allowlist.

Reviewed by Cursor Bugbot for commit 4f0c71a. Configure here.

@arun-silabs arun-silabs left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@Sarthak-Shaha

sarthak shaha (Sarthak-Shaha) commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

What is the file mode change?

@silabs-ArghyaD

Copy link
Copy Markdown
Contributor Author

What is the file mode change?

As I copied the files after downloading and extracting them from the CICD artifacts, they became inexecutable (lost +x), so Git recorded a mode-only flip. Common after download/extract without preserving +x.

I've added back the +x to those .s37 files and they are removed from the diff as there were no content changes. My changes are only supposed to update the .rps files.

@silabs-ArghyaD
Arghya Dutta (silabs-ArghyaD) merged commit f3c5fc7 into release_2.10-1.6.1 Nov 6, 2026
2 checks passed
@silabs-ArghyaD
Arghya Dutta (silabs-ArghyaD) deleted the fix/provision_script_for_external_flash branch November 6, 2026 15:20
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.

4 participants