XPm_SystemShutdown - 2023.1 English

Standalone Library Documentation: BSP and Libraries Document Collection (UG643)

Document ID
UG643
Release Date
2023-05-16
Version
2023.1 English

This function can be used by a privileged PU to shut down or restart the complete device.

Note: In either case the PMU will call XPm_InitSuspendCb for each of the other PUs, allowing them to gracefully shut down. If a PU is asleep it will be woken up by the PMU. The PU making the XPm_SystemShutdown should perform its own suspend procedure after calling this API. It will not receive an init suspend callback.

Prototype

XStatus XPm_SystemShutdown(u32 type, u32 subtype);

Parameters

The following table lists the XPm_SystemShutdown function arguments.

Table 1. XPm_SystemShutdown Arguments
Type Name Description
u32 type Should the system be restarted automatically?
  • PM_SHUTDOWN : no restart requested, system will be powered off permanently
  • PM_RESTART : restart is requested, system will go through a full reset
u32 subtype Restart subtype (SYSTEM or PS_ONLY or SUBSYSTEM)

Returns

XST_SUCCESS if successful else XST_FAILURE or an error code or a reason code