34c95327f5
- Why I did it The field 'subport' represents the index of the split port within a physical port. For example, if a port is split into 4, the subport of the first logical port is 1, the subport of the second logical port is 2, and so on. In xcvrd, the CMIS manager uses the subport to calculate the lane mask, which is used to control the data path per lane. In Nvidia platform, the subport is missing and is always set to 0. According to the xcvrd code, when subport=0, it will always correspond to the first logical port. Therefore, if we shut down any logical port that is not the first one, we will see the operational status of the first logical port also becomes down. This PR aims to add the subport field to CONFIG DB and prevent such scenarios. This is applicable only for static default breakout mode. For DPB, subport calculation will happen on the fly (changes are not in Sonic yet). (Subport HLD: HLD of subport: [link to the HLD document]) - How I did it I have added the 'subport' field to all relevant Nvidia hwsku.json files (minigraph generation is based on them). Additionally, I introduced the new 'subport' field to portconfig.py, so that sonic-cfggen will be able to generate the minigraph with it. In this file, I also fixed an error that caused all attributes from hwsku.json to be applied only to the first logical ports associated with a physical port. Furthermore, I updated hwsku_json_checker to include the new field and applied a fix to the sample_hwsku.json file. sample_hwsku.json is the file that sonic-config-engine's unit tests rely on for its tests. Previously, it only included attributes for the first logical port of a split physical port. For example, if Ethernet4, a 4-lane port, was split into 2 ports, then sample_hwsku.json included only the entry for Ethernet4, with no entry for Ethernet6. This misalignment with the structure of other hwsku.json files has been corrected as well. - How to verify it Ensure that each logical port has the correct value of 'subport' in CONFIG DB, and that shutting down a logical port affects only that port and not other ports in the split. |
||
---|---|---|
.. | ||
x86_64-mlnx_lssn2700-r0 | ||
x86_64-mlnx_msn2010-r0 | ||
x86_64-mlnx_msn2100-r0 | ||
x86_64-mlnx_msn2410-r0 | ||
x86_64-mlnx_msn2700_simx-r0 | ||
x86_64-mlnx_msn2700-r0 | ||
x86_64-mlnx_msn2700a1-r0 | ||
x86_64-mlnx_msn2740-r0 | ||
x86_64-mlnx_msn3420-r0 | ||
x86_64-mlnx_msn3700_simx-r0 | ||
x86_64-mlnx_msn3700-r0 | ||
x86_64-mlnx_msn3700c-r0 | ||
x86_64-mlnx_msn3800-r0 | ||
x86_64-mlnx_msn4410-r0 | ||
x86_64-mlnx_msn4600-r0 | ||
x86_64-mlnx_msn4600c-r0 | ||
x86_64-mlnx_msn4700_simx-r0 | ||
x86_64-mlnx_msn4700-r0 | ||
x86_64-mlnx_x86-r5.0.1400 | ||
x86_64-nvidia_sn2201-r0 | ||
x86_64-nvidia_sn4800_simx-r0 | ||
x86_64-nvidia_sn4800-r0 | ||
x86_64-nvidia_sn5600_simx-r0 | ||
x86_64-nvidia_sn5600-r0 |