| // Copyright 2025 The Fuchsia Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| library fuchsia.hardware.power.statecontrol; |
| |
| /// Why the system is shutting down. |
| // Contact OWNERS before adding a new value. |
| @available(added=29) |
| type ShutdownReason = flexible enum { |
| /// The end user of the device initiated the shutdown. |
| /// |
| /// DO NOT USE for any code path not directly related to an end user explicit shutdown action. |
| /// Use DEVELOPER_REQUEST below instead. |
| USER_REQUEST = 1; |
| |
| /// The developer initiated the shutdown, typically via a shell command or similar interface, |
| /// including within an automated test. |
| DEVELOPER_REQUEST = 2; |
| |
| /// A new system update has been downloaded. |
| SYSTEM_UPDATE = 3; |
| |
| /// Applying the system update has failed. |
| RETRY_SYSTEM_UPDATE = 4; |
| |
| /// The device has crossed the high temperature threshold. |
| HIGH_TEMPERATURE = 5; |
| |
| /// The device is about to perform an FDR. |
| FACTORY_DATA_RESET = 6; |
| |
| /// Sessionmgr has failed. |
| SESSION_FAILURE = 7; |
| |
| /// A critical system component has failed. |
| CRITICAL_COMPONENT_FAILURE = 8; |
| |
| /// A boot partition change was effected. |
| ZBI_SWAP = 9; |
| |
| /// The system hit a critical low threshold of available memory. |
| OUT_OF_MEMORY = 10; |
| |
| /// The Netstack component is changing versions. |
| NETSTACK_MIGRATION = 11; |
| |
| /// An Android-initiated shutdown reason that Starnix doesn't recognize. |
| ANDROID_UNEXPECTED_REASON = 12; |
| |
| /// Android called for the "RescueParty". |
| ANDROID_RESCUE_PARTY = 13; |
| |
| /// A critical Android process failed. |
| ANDROID_CRITICAL_PROCESS_FAILURE = 14; |
| }; |