Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Mellanox] Use the explicit mst device of SPC during fw-upgrade #98

Closed
wants to merge 2 commits into from

Conversation

vivekrnv
Copy link
Owner

@vivekrnv vivekrnv commented May 3, 2024

Why I did it

mlxfwmanager on smartwitch will show more than 1 device. Thus update the mlnx-fw-upgrade script to operate explicitly on Spectrum PCI device.

Work item tracking
  • Microsoft ADO (number only):

How I did it

  1. Used the mlxfwmanager --query-format XML command to get the output in XML format and used xmlstarlet cmd to parse the output
    Example cmd output:
<Devices>
    <Device pciName="/dev/mst/mt41692_pciconf0" type="BlueField3" psid="MT_0000001139" partNumber="BF3-COM-DPU_QP_Ax">
      <Versions>
        <FW current="32.41.1000" available="N/A"/>
      </Versions>
      <MACs Base_Mac="N/A" />
      <GUIDs Base_Guid="N/A" />
      <Status>No matching image found</Status>
      <Description>NVIDIA BlueField-3 DPU based COM express; IPN QP</Description>
    </Device>
    <Device pciName="/dev/mst/mt53104_pci_cr0" type="Spectrum3" psid="MT_0000001189" partNumber="MSN4280-WS2RXO_Ax">
      <Versions>
        <FW current="30_2012_4038-006" available="N/A"/>
      </Versions>
      <MACs Base_Mac="N/A" />
      <Status>No matching image found</Status>
      <Description>NVIDIA Spectrum-3 based 400GbE 2U Ethernet Smart-Switch with ONIE; 28 ports QSFP-DD; 4 DPUs; 2 power supplies (AC); x86 CPU - 16 Cores; Secure-boot Capable; standard depth; C2P airflow; Tool-less Rail Kit</Description>
    </Device>
</Devices>
  1. Exclusively operate on the PCI device inferred from the output to Wait, fetch psid and Current FW version
  2. Use awk for a reliable extraction of Available FW output

How to verify it

Verify the script if it upgrades FW properly during switch init and during reboot.

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205
  • 202211
  • 202305

Tested branch (Please provide the tested image version)

Description for the changelog

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

Signed-off-by: Vivek Reddy <vkarri@nvidia.com>
@vivekrnv vivekrnv marked this pull request as ready for review May 8, 2024 23:08
@vivekrnv vivekrnv closed this May 9, 2024
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.

3 participants