Skip to content

Parser changes to support parsing of multi-asic device minigraph#4222

Merged
arlakshm merged 27 commits intosonic-net:masterfrom
SuvarnaMeenakshi:multiasic_minigraph
May 4, 2020
Merged

Parser changes to support parsing of multi-asic device minigraph#4222
arlakshm merged 27 commits intosonic-net:masterfrom
SuvarnaMeenakshi:multiasic_minigraph

Conversation

@SuvarnaMeenakshi
Copy link
Contributor

- What I did
In case of multiasic platform, a single minigraph.xml will be present for the device. This minigraph.xml will include device specific data and internal asic specific data. The current parser assumes that the minigraph will have data specific to a single device. In a multiple asic minigraph.xml, each asic data will be modelled as a separate device. With this change, expectation is to be able to parse and generate configuration for all asics of the device.
Apart from this, port_config.ini will have a new column to provide "asic_port_name". This name be a combination of "port name in asic" and "asic name".

- How I did it

  1. Made changes to portconfig.py to parse the new column if it exists and create a new mapping to map alias to asic_port_name which will be used in minigraph.py
  2. minigraph.py updated to accept a new parameter "hostname" which will define the name of specific host/ASIC that is of interest and configuration will be generated for this host. If "hostname" is not provided, this will be the same as what is defined in minigraph.xml.

- How to verify it
Generated config_db.json before and after the parser changes for a single asic device. No change observed.
- Description for the changelog

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

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants