Skip to content

Conversation

@cbrune
Copy link
Contributor

@cbrune cbrune commented Mar 8, 2016

Add switch silicon vendor string to the image discovery default paths
During image discovery, ONIE looks for installer names in the
following order:

1.  onie-installer-<cpu_arch>-<hw_vendor>_<machine>-r<machine_revision>
2.  onie-installer-<cpu_arch>-<hw_vendor>_<machine>
3.  onie-installer-<hw_vendor>_<machine>
4.  onie-installer-<cpu_arch>
5.  onie-installer

With the advent of ONIE enabled systems supporting multiple switch
silicon vendors, step 4 has become ambiguous.

This patch adds an additional step to the ONIE waterfall that includes
the switch silicon vendor. In the above waterfall this new step would
be between steps 3 and 4. The new step looks like:

  onie-installer-<cpu_arch>-<switch_silicon_vendor>

Before the change the kvm_x86_64 machine waterfall discovery looks
like this:

<cpu_arch>            = x86_64
<hw_vendor>_<machine> = kvm_x86_64

Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64-r0 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer ...

After the changing, using a completely fictitious silicon vendor, the
waterfall looks like:

<switch_silicon_vendor> = qemu

Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64-r0 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-qemu ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer ...

Technically the same information is contained in step 3
onie-installer-<hw_vendor>_<machine>, however the new file name is
more generic and will be easier for customers to maintain when using
multiple platforms.

Imagine the case of a customer who has multiple x86 hardware platforms,
from different hardware vendors, using different switch silicon. Also
imagine NOS installers that target a specific switch silicon.

The customer could maintain NOS installers named as in step 2 and be
OK, however, that is a lot of files to manage.

Using the new step <cpu_arch>-<switch_silicon_vendor> the end
customer could target all of the x86 platforms from a particular
silicon vendor with a single NOS image.

Curt Brune added 2 commits February 19, 2016 12:59
During image discovery, ONIE looks for installer names in the
following order:

1.  onie-installer-<cpu_arch>-<hw_vendor>_<machine>-r<machine_revision>
2.  onie-installer-<cpu_arch>-<hw_vendor>_<machine>
3.  onie-installer-<hw_vendor>_<machine>
4.  onie-installer-<cpu_arch>
5.  onie-installer

With the advent of ONIE enabled systems supporting multiple switch
silicon vendors, step 4 has become ambiguous.

This patch adds an additional step to the ONIE waterfall that includes
the switch silicon vendor.  In the above waterfall this new step would
be between steps 3 and 4.  The new step looks like:

  onie-installer-<cpu_arch>-<switch_silicon_vendor>

Before the change the kvm_x86_64 machine waterfall discovery looks
like this:

<cpu_arch>            = x86_64
<hw_vendor>_<machine> = kvm_x86_64

Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64-r0 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer ...

After the changing, using a completely fictitious silicon vendor, the
waterfall looks like:

<switch_silicon_vendor> = qemu

Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64-r0 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-kvm_x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64-qemu ...
Info: Fetching http://10.0.2.2/onie-installer-x86_64 ...
Info: Fetching http://10.0.2.2/onie-installer ...

Technically the same information is contained in step opencomputeproject#3
"onie-installer-<hw_vendor>_<machine>", however the new file name is
more generic and will be easier for customers to maintain when using
multiple platforms.

Imagine the case of a customer who has multiple x86 hardware platforms,
from different hardware vendors, using different switch silicon.  Also
imagine NOS installers that target a specific switch silicon.

The customer could maintain NOS installers named as in step opencomputeproject#2 and be
OK, however, that is a lot of files to manage.

Using the new step "<cpu_arch>-<switch_silicon_vendor>" the end
customer could target all of the x86 platforms from a particular
silicon vendor with a single NOS image.
To each machine.make, where the switch silicon vendor is known, add a
line of the form:

  SWITCH_ASIC_VENDOR = <silicon_vendor>

For machines where the switch silicon vendor is unknown the string
will default to "unknown".

The following silicon vendor to string mapping is used:

Silicon Vendor   |   string                                                                                                
=================+==========                                                                                               
Broadcom         |   bcm                                                                                                   
Centec           |   centec                                                                                                
Mellanox         |   mlnx                                                                                                  
QEMU             |   qemu (for the virtual machines)
@cbrune
Copy link
Contributor Author

cbrune commented Mar 15, 2016

Pushed to master:

  • 0cef1ea Update each machine.make to specify switch silicon vendor
  • 4492b04 Add switch silicon vendor string to the image discovery default paths

@cbrune cbrune closed this Mar 15, 2016
@cbrune cbrune deleted the silicon-waterfall branch April 19, 2016 21:39
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.

1 participant