Skip to content

Support for Multiple Firmwares - #2331

Open
JaiOCP wants to merge 1 commit into
opencomputeproject:masterfrom
JaiOCP:FW
Open

Support for Multiple Firmwares#2331
JaiOCP wants to merge 1 commit into
opencomputeproject:masterfrom
JaiOCP:FW

Conversation

@JaiOCP

@JaiOCP JaiOCP commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Modern switches have embedded controller to run firmware for low latency applications.
This PR bring in support for installing and monitoring firmware based on the hardware support.

Older PR #2319 is closed

Signed-off-by: JaiOCP <jai.kumar@broadcom.com>
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@JaiOCP

JaiOCP commented Aug 13, 2026

Copy link
Copy Markdown
Contributor Author

@kcudnik @AnandhiDhanabalan @crameshk @eladnachman @gananthateerta @eladnachman @tjchadaga

Please approve this PR as the old one is closed.
All the review comments are addressed there.
#2319

@kcudnik

kcudnik commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

why you are closing colder PR and creating new ones ? i already review older one and now i need to revierw again this one, i saw you do it already multiple times, this makes review proces lot harder

@JaiOCP

JaiOCP commented Aug 17, 2026

Copy link
Copy Markdown
Contributor Author

why you are closing colder PR and creating new ones ? i already review older one and now i need to revierw again this one, i saw you do it already multiple times, this makes review proces lot harder

Kamil,
PR gets diverged so much that no new rebase or squash works. It infact makes commit history very messy with lots of new merges showing up in the audit record.

@JaiOCP

JaiOCP commented Aug 17, 2026

Copy link
Copy Markdown
Contributor Author

@AnandhiDhanabalan Can you please approve the PR urgently? We need to close on this for next release.

@tjchadaga

Copy link
Copy Markdown
Collaborator

why you are closing colder PR and creating new ones ? i already review older one and now i need to revierw again this one, i saw you do it already multiple times, this makes review proces lot harder

Kamil, PR gets diverged so much that no new rebase or squash works. It infact makes commit history very messy with lots of new merges showing up in the audit record.

Jai, you should be able to squash commit, rebase and fix this issue. Please reach out before you close the PRs, I can try to fix it for you

@AnandhiDhanabalan AnandhiDhanabalan 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.

@JaiOCP , thanks for addressing the comments. I noticed a few from the previous PR are still pending, so I’ve re-added them here. Could you please check?

Comment thread inc/saifw.h

/** Firmware operational state is in error */
SAI_FW_OP_STATE_ERROR,
} sai_fw_op_state_t;

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.

For ASICs with async FW loading, transitional states are needed:

SAI_FW_OP_STATE_LOADING,   // image transfer in progress 
SAI_FW_OP_STATE_STOPPING,  // graceful shutdown in progress

Comment thread inc/saifw.h
* @default ""
*/
SAI_FW_ATTR_FW_FILE_AND_PATH_NAME,

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.

The Problem:
Given N FW objects returned by SAI_SWITCH_ATTR_FW, NOS has no standard way to identify which fw_id to manage when it needs to, say, upgrade the TAM firmware instance. Today the only distinguishing information is SAI_FW_ATTR_FW_FILE_AND_PATH_NAME — a vendor-specific deployment path that NOS cannot portably interpret.

The Ask:
A unique, READ_ONLY functional identifier per FW instance — either in sai_fw_inst_t directly or as a SAI attribute — that NOS can use as a stable key to map a fw_id to its role/type.

Comment thread doc/fw/SAI-FW-API.md

---

## 4.0 Example Workflow

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.

We discussed how notification can be handled with existing infra sai_switch_asic_sdk_health_event_notification_fn during the review, but same is not captured in the md file.
also this infra does not give the f/w object id today. It assumes single f/w.
This needs to be extended to handle multiple f/w notification

typedef void (*sai_switch_asic_sdk_health_event_notification_fn)(
        _In_ sai_object_id_t switch_id,
        _In_ sai_switch_asic_sdk_health_severity_t severity,
        _In_ sai_timespec_t timestamp,
        _In_ sai_switch_asic_sdk_health_category_t category,
        _In_ sai_switch_health_data_t data,
        _In_ const sai_u8_list_t description);

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.

5 participants