soc/intel: Use centralized emergency battery shutdown hook
Migrate the low-battery power-off sequence in Intel common reset logic to use platform_handle_emergency_low_battery(). This ensures that all Intel-based boards benefit from the unified ChromeOS battery alert flow (LED notification and ELOG recording) without duplicating the logic in the SOC layer. BUG=none BRANCH=none TEST=Verified that low-battery shutdown on Intel platforms still correctly logs ELOG and triggers visual alerts via the new hook. Change-Id: I37c15a1f7dd5acee10389c0521e8c9b2f2d90d42 Signed-off-by: Subrata Banik <subratabanik@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/91411 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Kapil Porwal <kapilporwal@google.com>
This commit is contained in:
parent
a96f1a464b
commit
b50c219557
1 changed files with 2 additions and 6 deletions
|
|
@ -1,10 +1,9 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0-only */
|
||||
|
||||
#include <arch/cache.h>
|
||||
#include <bootsplash.h>
|
||||
#include <cf9_reset.h>
|
||||
#include <console/console.h>
|
||||
#include <delay.h>
|
||||
#include <elog.h>
|
||||
#include <halt.h>
|
||||
#include <reset.h>
|
||||
|
||||
|
|
@ -26,10 +25,7 @@ void do_board_reset(void)
|
|||
|
||||
void do_low_battery_poweroff(void)
|
||||
{
|
||||
if (CONFIG(PLATFORM_HAS_LOW_BATTERY_INDICATOR)) {
|
||||
elog_add_event_byte(ELOG_TYPE_LOW_BATTERY_INDICATOR, ELOG_FW_ISSUE_SHUTDOWN);
|
||||
delay(CONFIG_PLATFORM_POST_RENDER_DELAY_SEC);
|
||||
}
|
||||
platform_handle_emergency_low_battery();
|
||||
|
||||
poweroff();
|
||||
halt();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue