Skip to content
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

DellEMC Z9264f LED profile changes #3376

Merged
merged 1 commit into from
Aug 23, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ start)
;;

stop)
/usr/local/bin/z9100_platform.sh deinit
/usr/local/bin/z9264f_platform.sh deinit
echo "done."

;;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,22 @@ switch_board_modsel() {
python /usr/bin/pcisysfs.py --set --offset $hex --val 0x10 --res $resource > /dev/null 2>&1
done
}

# Copy led_proc_init.soc file according to the HWSKU
init_switch_port_led() {
device="/usr/share/sonic/device"
platform=$(/usr/local/bin/sonic-cfggen -H -v DEVICE_METADATA.localhost.platform)
hwsku=$(cat /etc/sonic/config_db.json | grep "hwsku" | cut -d ":" -f2 | sed 's/"//g' | sed 's/,//g'| xargs )

led_proc_init="$device/$platform/$hwsku/led_proc_init.soc"
# Remove old HWSKU LED file..
rm -rf $device/$platform/led_proc_init.soc

if [ -e $led_proc_init ] && [ ! -e $device/$platform/led_proc_init.soc ]; then
cp $led_proc_init $device/$platform/
fi
}

init_devnum

if [ "$1" == "init" ]; then
Expand All @@ -98,6 +114,7 @@ if [ "$1" == "init" ]; then
switch_board_qsfp_mux "new_device"
switch_board_qsfp "new_device"
switch_board_modsel
init_switch_port_led
python /usr/bin/qsfp_irq_enable.py

elif [ "$1" == "deinit" ]; then
Expand Down