-
Notifications
You must be signed in to change notification settings - Fork 273
Confusing switches terminology
In SONiC environment, switch terminology can be confusing, for example a small 32 port switch can be referred as "switch", "chassis", "ASIC" or "SAI switch" and they to some degree means the same from coding perspective.
- Chassis - Enclosure box (standalone or rack mount) where one or more physical switches are located, it can also be modular (using line cards, were chassis contains master board, and line card connects physically via connector). Line card usually contains it's own switching ASIC.
- Silicon - also meaning "silicon die", usually enclosed in a physical chip which is put on PCB board inside a switch chassis
- ASIC - Application-Specific Integrated Circuit, example is "switching ASIC" or "DSP", in a form of a silicon die. Usually there is only 1 ASIC on a silicon die, but physically die can hold multiple independent ASICs for space, size and cost optimization.
- Switching ASIC - ASIC that is strictly design to perform network traffic switching/routing. In SONiC context, usually "ASIC" is referred to "Switching ASIC". Switching ASICs are usually quite big since they perform a lot of operations especially in 100G environment, and they require a lot of cooling.
- PCB - Printed Circuit Board, a board inside chassis that holds all electronic components, including 1 or more silicon dies, which 1 or more is switching ASIC.
- Switch - Usually referred as entire physical chassis that is rack mounted. In SONiC can also be referring to "SAI switch".
- SAI switch - Switch instance which was created using create_switch API from vendor SAI (libsai.so)
In most simple scenario 32 port switch, will be in a form of rack mount chassis, will contain 1 PCB board and 1 ASIC. Vendor will provide SAI library which will be able to create 1 SAI switch. In more complex scenario, we could have a board which holds 2 ASICs from the same vendor, then SAI library would be able to instantiate 2 SAI switches. In even more complex scenario, we could have a chassis with 4 line cards, and each line card will hold separate ASIC, they could be different so vendor would need to provide 4 different SAI libraries, and each of them would be able to instantiate 1 switch.
In case of brcm gearbox scenario, in the chassis there is 1 main ASIC and other ASIC, first one can instantiate 1 SAI switch, but 2nd, can instantiate 8 SAI switches. Two SAI libraries are required to handle this.
In most simple words, a chassis may contain multiple switches and multiple ASICs to which libsai.so can instantiate multiple SAI switches.
Syncd can only link to 1 libsai.so, so if vendor will provide multiple libraries to control switch, multiple syncd must be running which they are connected to 1 orchagent, or each syncd have it's own orchagent process.