sonic-buildimage/platform/innovium/sonic-platform-modules-cameo/esqc610-56sq/utils/halt
Tony Titus fbd4e452c7
[201911] [Innovium] Add new platforms and config updates (#7545)
Update Innovium configs + Add new platforms supporting Innovium chips
2021-05-17 12:30:20 -07:00

20 lines
363 B
Bash
Executable File

#!/bin/sh
mr_reboot() {
sudo rmmod x86-64-cameo-esqc610-56sq
sudo i2cset -y 0 0x30 0xa1 0
}
if [ $# -eq 0 ] || [ $@ = "--halt" ] || [ $@ = "-f" ] || [ $@ = "--force" ]; then
#echo halt
sudo /sbin/halt
elif [ $@ = "-p" ] || [ $@ = "--reboot" ] || [ $@ = "--poweroff" ]; then
sync;sync
mr_reboot
else
echo "unsupported option"
fi