-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Add platform_asic file to each platform folder in sonic-device-data based package #8542
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
Conversation
9ae7ace
to
06ca952
Compare
This pull request introduces 5 alerts and fixes 5 when merging 06ca952ea9f36f9734cb3c4a785de4175b5ceb44 into 26c6e7f - view on LGTM.com new alerts:
fixed alerts:
In reply to: 903559173 |
This pull request introduces 5 alerts and fixes 5 when merging d2d518f1c3f2e75ed3d473e14ffaf9b2a17a2df6 into 5ff87e1 - view on LGTM.com new alerts:
fixed alerts:
In reply to: 904557767 |
i do not think asic vendor and platform vendor are strict hiercharical, suggest not to introduce such hierachy. In reply to: 904871309 |
22c5aac
to
3c6da4c
Compare
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
broadcom
this is available for sonic-broadcom-dnx.bin not in sonic-broadcom.bin
can you differ? #Resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Technically they are using the same CONFIGURED_PLATFORM. So I cannot differentiate them by this dimention. We could improve in future.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is a must fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please sync with judy
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed the files under dnx platforms. I decided not reduce package content and keep the build/installation behavior as before.
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all arista devices are only available for sonic-broadcom.swi image, not sonic-broadcom.bin image, can you differentiate that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are using the same CONFIGURED_PLATFORM (broadcom). So I cannot differentiate them by this dimention. If we have ground truth about bootloader for each platform, we could improve in future.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is a must fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please sync with ying.
3f29360
to
54d7d12
Compare
Could you please describe a use-case or intention behind this? Also, are you planning to update platform porting guide with this info? Thank you in advance. In reply to: 922882822 |
Updated PR description. In reply to: 922888780 |
81e18ec
to
af21056
Compare
@qiluo-msft , to avoid adding In reply to: 924671625 |
Thanks for the feedback!
In reply to: 924671625 |
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be dnx #Closed
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dnx #Closed
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dnx #Closed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed all 3. Please check.
…ice-data" This reverts commit 101ee10e1f1b0e03bb662c0342b48e2107663f31.
705e52a
to
2ccb0e6
Compare
@arunlk-dell Could you help review? |
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
broadcom-dnx
@@ -0,0 +1 @@ | |||
broadcom |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i do not know what this is. this is common, it should be included in both broadcom and broadcom-dnx
others lgtm. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why I did it
Add platform_asic file to each platform folder in sonic-device-data package. The file content will be used as the ground truth of mapping from PLATFORM_STRING to switch ASIC family.
One use case of the mapping is to prevent installing a wrong image, which targets for other ASIC platforms. For example, currently we have several ONIE images naming as sonic-*.bin, it's easy to mistakenly install the wrong image. With this mapping built into image, we could fetch the ONIE platform string, and figure out which ASIC it is using, and check we are installing the correct image.
After this PR merged, each platform vendor has to add one mandatory text file
device/PLATFORM_VENDOR/PLATFORM_STRING/platform_asic
, with the content of the platform's switch ASIC family.You can get a list of the ASIC platforms by
ls -b platform | cat
. Currently the options areAlso support
How I did it
How to verify it
Test one image on DUT. And check the folders under
/usr/share/sonic/device
Which release branch to backport (provide reason below if selected)