| 1 | /* SPDX-License-Identifier: GPL-2.0-or-later */ |
| 2 | |
| 3 | #ifndef _INTEL_COMMON_RESET_H_ |
| 4 | #define _INTEL_COMMON_RESET_H_ |
| 5 | |
| 6 | #include <efi/efi_datatype.h> |
| 7 | |
| 8 | /* |
| 9 | * Implement SoC specific global reset (i.e. a reset of both host and |
| 10 | * ME partitions). Usually the ME is asked to perform the reset first. |
| 11 | * If that doesn't work out, fall back to a manual global reset. |
| 12 | */ |
| 13 | void do_global_reset(void); |
| 14 | |
| 15 | /* Prepare for reset, run do_global_reset(), halt. */ |
| 16 | __noreturn void global_reset(void); |
| 17 | |
| 18 | /* |
| 19 | * Return PCH Reset Status |
| 20 | * The return status can be between EfiResetCold, EfiResetWarm, EfiResetShutdown |
| 21 | * or EfiResetPlatformSpecific. |
| 22 | * |
| 23 | * If reset type if `EfiResetPlatformSpecific` then relying on pch_reset_data structure |
| 24 | * to know if the reset type is a global reset. |
| 25 | */ |
| 26 | efi_return_status_t fsp_get_pch_reset_status(void); |
| 27 | |
| 28 | /* |
| 29 | * Issue power off due to low battery |
| 30 | * |
| 31 | * Call this function to power off the platform if the battery level is critically low. |
| 32 | */ |
| 33 | __noreturn void do_low_battery_poweroff(void); |
| 34 | |
| 35 | #endif /* _INTEL_COMMON_RESET_H_ */ |