Skip to content

Fix toggle in bl2 stage#382

Open
BenReed161 wants to merge 1 commit into
Microsemi:masterfrom
BenReed161:bl2-fw-toggle-fix
Open

Fix toggle in bl2 stage#382
BenReed161 wants to merge 1 commit into
Microsemi:masterfrom
BenReed161:bl2-fw-toggle-fix

Conversation

@BenReed161
Copy link
Copy Markdown
Collaborator

@BenReed161 BenReed161 commented May 21, 2026

re-order the toggle, configuration and firmware first since we are
toggling whilst running in BL2. Add to the BL2 toggle and main-fw toggle
a no-poll option to sending the command (we don't want switchtec to poll in bl2 since
it could render i2c bus unresponsive in a bl2 toggle). Firmware takes longer
to toggle due to image CRC verfication, so we send without polling and give some
time for it to finish CRC checks. (usleep)

Add switchtec_cmd_nopoll as a alternative to polling ver

Add a no-retry function for Gen6 to match previous

re-order the toggle, configuration and firmware first since we are
toggling whilst running in BL2. Add to the BL2 toggle and main-fw toggle
a no-poll option to sending the command (we don't want switchtec to poll in bl2 since
it could render i2c bus unresponsive in a bl2 toggle). Firmware takes longer
to toggle due to image CRC verfication, so we send without polling and give some
time for it to finish CRC checks. (usleep)

Add switchtec_cmd_nopoll as a alternative to polling ver

Add a no-retry function for Gen6 to match previous
@BenReed161 BenReed161 force-pushed the bl2-fw-toggle-fix branch from 38d8242 to f7387a6 Compare May 21, 2026 21:02
Comment thread lib/fw.c
if (ret)
return ret;
cmd.toggle_fw = 0;
usleep(5000000);
Copy link
Copy Markdown
Collaborator

@lsgunth lsgunth May 21, 2026

Choose a reason for hiding this comment

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

This sleep is a bit suspect. Should it be there? If so, I think it needs a big comment above it.

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