diff --git a/device/celestica/x86_64-cel_e1031-r0/platform_reboot b/device/celestica/x86_64-cel_e1031-r0/platform_reboot new file mode 100755 index 000000000000..3bcaf6a8af09 --- /dev/null +++ b/device/celestica/x86_64-cel_e1031-r0/platform_reboot @@ -0,0 +1,9 @@ +#!/bin/bash + +declare -r CPLD_SETREG_PATH="/sys/bus/platform/devices/e1031.smc/setreg" + +sync ; sync +umount -fa > /dev/null 2&>1 + +# Board level power cycle +echo "0x0113 0xAA" > ${CPLD_SETREG_PATH} diff --git a/device/celestica/x86_64-cel_e1031-r0/platform_update_reboot_cause b/device/celestica/x86_64-cel_e1031-r0/platform_update_reboot_cause new file mode 100755 index 000000000000..9ffb2129c87f --- /dev/null +++ b/device/celestica/x86_64-cel_e1031-r0/platform_update_reboot_cause @@ -0,0 +1,8 @@ +#!/bin/bash + +REBOOT_USER=$(logname) +REBOOT_TIME=$(date) +declare -r REBOOT_CAUSE_FILE="/host/reboot-cause/reboot-cause.txt" + +echo "User issued 'reboot' with platform-specific command [User: ${REBOOT_USER}, Time: ${REBOOT_TIME}]" > ${REBOOT_CAUSE_FILE} +sync