a569bfc9eb
#### Why I did it Backport https://github.com/sonic-net/sonic-buildimage/pull/13246 to 202012 branch. In case of warm/fast reboot, the hardware reboot cause will NOT be cleared because CPLD will not be touched in this flow. To not confuse the reboot cause determine logic, the leftover hardware reboot cause shall be skipped by the platform API, platform API will return the 'REBOOT_CAUSE_NON_HARDWARE' instead of the "hardware" reboot cause. #### How I did it Check the proc cmdline to see whether the last reboot is a warm or fast reboot, if yes skip checking the leftover hardware reboot cause. #### How to verify it a. Manual test: > 1. Perform a power loss > 2. Perform a warm/fast reboot > 3. check the reboot cause should be "warm-reboot" or "fast-reboot" instead of "power loss" b. Run reboot cause related regression test. |
||
---|---|---|
.. | ||
barefoot | ||
broadcom | ||
cavium | ||
centec | ||
centec-arm64 | ||
checkout | ||
generic | ||
innovium | ||
marvell | ||
marvell-arm64 | ||
marvell-armhf | ||
mellanox | ||
nephos | ||
p4 | ||
pddf | ||
template | ||
vs |