-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Pddf_support_dell_platforms: Add PDDF support for s52xx dell platforms. #18849
base: master
Are you sure you want to change the base?
Pddf_support_dell_platforms: Add PDDF support for s52xx dell platforms. #18849
Conversation
@srideepDell Please review the PR. |
@lguohan @zhangyanzhao -- please assign @srideepDell , @rvasanthm , @thaj-deen , @vpsubramaniam , @arunlk-dell to review this Dell platform PR. Also, @FuzailBrcm and @leeprecy from Broadcom, who have expertise in PDDF. Thanks! |
@jeff-yin , no need to assign. please have reviewer to sign off, then we can merge. |
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.
From the UT logs, Hardware Revision is displayed as "N/A". Could you please check it?.
Also, please attach sonic-mgmt test results.
@leeprecy @geans-pin |
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.
could you please use https://github.com/sonic-net/sonic-buildimage/blob/master/platform/broadcom/sonic-platform-modules-dell/common/ipmihelper.py instead of redefining ipmihelper in each platform.
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 switch_board_sfp/ switch_board_qsfp is not deinitialized like it is done for other platforms?.
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 done as part of s52xxf_platform.sh under deinitialized.
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.
media_down is not used in platform init file. Check the same for all the platform init files.
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.
Implemented changes similar to other platform init files.
@@ -128,8 +128,7 @@ switch_board_led_default() { | |||
install_python_api_package() { | |||
device="/usr/share/sonic/device" | |||
platform=$(/usr/local/bin/sonic-cfggen -H -v DEVICE_METADATA.localhost.platform) | |||
|
|||
pip3 install $device/$platform/sonic_platform-1.0-py3-none-any.whl | |||
rv=$(pip3 install $device/$platform/sonic_platform-1.0-py3-none-any.whl --force-reinstall -q --root-user-action=ignore) |
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 --force-reinstall option and --root-user-action rules added here?.
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.
return value rv is unused here.
@@ -0,0 +1,125 @@ | |||
#!/usr/bin/env python |
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 it be python or python3 ?
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 Python, ensures that the script is executed with the Python interpreter found in the user’s environment, regardless of where Python is installed on the system.
|
||
return True | ||
|
||
def main(): |
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 see main is dummy. is that fine ?
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.
Fine and serving as a placeholder.
@@ -31,40 +31,75 @@ override_dh_auto_build: | |||
python3 -m build --wheel --no-isolation --outdir $(MOD_SRC_DIR)/$${mod}/modules; \ | |||
cd $(MOD_SRC_DIR); \ | |||
elif [ $$mod = "z9264f" ]; then \ | |||
cp $(COMMON_DIR)/dell_fpga_ocores.c $(MOD_SRC_DIR)/$${mod}/modules/dell_z9264f_fpga_ocores.c; \ |
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.
What is the change here ?
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.
What is the change here ?
No change.
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.
can you remove this from diff then ?
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.
sure
e2939e9
to
b1ef642
Compare
dd59ad1
to
1626173
Compare
Changed to use from the common folder. |
I have ran sonic-mgmt test for the dell platforms in pddf mode and added required function as part of sonic-mgmt test. Also addressed review comments. Attaching latest UT logs and sonic-mgmt test case report. Some of the test cases are failed due to name mismatch from the platform.json which will resolved in the future enhancements whenever newer pddf updates. Platforms s5232f and s5248f does not have platform.json. s5248f will have platform.json from https://github.com/sonic-net/sonic-buildimage/pull/20287/files and s5232f will have platform.json in future updates. s5212f_logs.txt |
/azpw ms_conflict |
@@ -0,0 +1,16 @@ | |||
#!/bin/bash | |||
sys_eeprom "delete_device" |
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.
following four are not defined in the script
Why I did it
Add PDDF support for the dell s52xx platforms.
How I did it
Add PDDF configuration files, scripts and python files.
How to verify it
To switch to PDDF mode run the below command and wait for the system to be ready.
pddf_util.py -d switch-pddf
Run the PDDF commnads
systemctl | grep -i pddf
pddf_fanutil direction
pddf_fanutil getspeed
pddf_fanutil numfans
pddf_fanutil status
pddf_psuutil mfrinfo
pddf_psuutil numpsus
pddf_psuutil seninfo
pddf_psuutil status
pddf_thermalutil gettemp
pddf_thermalutil numthermals
pddf_ledutil getstatusled SYS_LED
pddf_ledutil getstatusled FAN_LED
pddf_ledutil getstatusled FANTRAY1_LED
pddf_ledutil getstatusled FANTRAY2_LED
pddf_ledutil getstatusled FANTRAY3_LED
pddf_ledutil getstatusled FANTRAY4_LED
Note: To switch back to non PDDF mode check help on pddf_util.py -help
Unit Test results:
s5232f_pddf_logs.txt
s5248f_pddf_logs.txt
s5296_pddf_logs.txt
s5212f_pddf_logs.txt
s5224f_pddf_logs.txt
A picture of a cute animal (not mandatory but encouraged)