|
Zephyr Project API 4.3.99
A Scalable Open Source RTOS
|
System-wide power state management via SCMI. More...
Files | |
| file | system.h |
| Header file for the SCMI System Power Management Protocol. | |
Data Structures | |
| struct | scmi_system_power_state_config |
| System power state configuration. More... | |
Macros | |
| #define | SCMI_SYSTEM_POWER_PROTOCOL_SUPPORTED_VERSION 0x20001 |
Enumerations | |
| enum | scmi_system_message { SCMI_SYSTEM_MSG_PROTOCOL_VERSION = 0x0 , SCMI_SYSTEM_MSG_PROTOCOL_ATTRIBUTES = 0x1 , SCMI_SYSTEM_MSG_MESSAGE_ATTRIBUTES = 0x2 , SCMI_SYSTEM_MSG_POWER_STATE_SET = 0x3 , SCMI_SYSTEM_MSG_POWER_STATE_NOTIFY = 0x5 , SCMI_SYSTEM_MSG_NEGOTIATE_PROTOCOL_VERSION = 0x10 } |
| System protocol command message IDs. More... | |
Functions | |
| int | scmi_system_protocol_version (uint32_t *version) |
| Get protocol version. | |
| int | scmi_system_protocol_attributes (uint32_t *attributes) |
| Get protocol attributes. | |
| int | scmi_system_protocol_message_attributes (uint32_t message_id, uint32_t *attributes) |
| Get protocol message attributes. | |
| int | scmi_system_protocol_version_negotiate (uint32_t version) |
| Negotiate protocol version. | |
| int | scmi_system_power_state_set (struct scmi_system_power_state_config *cfg) |
| Set system power state. | |
Standard SCMI System Power States | |
| #define | SCMI_SYSTEM_POWER_STATE_SHUTDOWN 0x00000000U |
| < Shutdown off | |
| #define | SCMI_SYSTEM_POWER_STATE_COLD_RESET 0x00000001U |
| Warm reset. | |
| #define | SCMI_SYSTEM_POWER_STATE_WARM_RESET 0x00000002U |
| Power up. | |
| #define | SCMI_SYSTEM_POWER_STATE_POWER_UP 0x00000003U |
| Suspend. | |
| #define | SCMI_SYSTEM_POWER_STATE_SUSPEND 0x00000004U |
System Power State flags | |
| #define | SCMI_SYSTEM_POWER_FLAG_FORCEFUL (0 << SCMI_SYSTEM_POWER_FLAG_SHIFT) |
| < Forceful request | |
| #define | SCMI_SYSTEM_POWER_FLAG_GRACEFUL (1 << SCMI_SYSTEM_POWER_FLAG_SHIFT) |
SCMI system message attributes | |
| #define | SCMI_SYSTEM_MSG_ATTR_SUSPEND (1 << SCMI_SYSTEM_MSG_ATTR_SUSPEND_SHIFT) |
| System suspend support. | |
| #define | SCMI_SYSTEM_MSG_ATTR_WARM_RESET (1 << SCMI_SYSTEM_MSG_ATTR_WARM_RESET_SHIFT) |
| System warm reset support. | |
System-wide power state management via SCMI.
| #define SCMI_SYSTEM_MSG_ATTR_SUSPEND (1 << SCMI_SYSTEM_MSG_ATTR_SUSPEND_SHIFT) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
System suspend support.
| #define SCMI_SYSTEM_MSG_ATTR_WARM_RESET (1 << SCMI_SYSTEM_MSG_ATTR_WARM_RESET_SHIFT) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
System warm reset support.
| #define SCMI_SYSTEM_POWER_FLAG_FORCEFUL (0 << SCMI_SYSTEM_POWER_FLAG_SHIFT) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
< Forceful request
Graceful request
| #define SCMI_SYSTEM_POWER_FLAG_GRACEFUL (1 << SCMI_SYSTEM_POWER_FLAG_SHIFT) |
| #define SCMI_SYSTEM_POWER_PROTOCOL_SUPPORTED_VERSION 0x20001 |
| #define SCMI_SYSTEM_POWER_STATE_COLD_RESET 0x00000001U |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Warm reset.
| #define SCMI_SYSTEM_POWER_STATE_POWER_UP 0x00000003U |
| #define SCMI_SYSTEM_POWER_STATE_SHUTDOWN 0x00000000U |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
< Shutdown off
Cold reset
| #define SCMI_SYSTEM_POWER_STATE_SUSPEND 0x00000004U |
| #define SCMI_SYSTEM_POWER_STATE_WARM_RESET 0x00000002U |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Power up.
| enum scmi_system_message |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
System protocol command message IDs.
| int scmi_system_power_state_set | ( | struct scmi_system_power_state_config * | cfg | ) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Set system power state.
| cfg | pointer to power state configuration |
| 0 | if successful |
| negative | errno if failure |
| int scmi_system_protocol_attributes | ( | uint32_t * | attributes | ) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Get protocol attributes.
| attributes | Protocol attributes |
| 0 | if successful |
| negative | errno if failure |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Get protocol message attributes.
| message_id | Message ID of the message |
| attributes | Message attributes |
| 0 | if successful |
| negative | errno if failure |
| int scmi_system_protocol_version | ( | uint32_t * | version | ) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Get protocol version.
| version | Protocol version |
| 0 | if successful |
| negative | errno if failure |
| int scmi_system_protocol_version_negotiate | ( | uint32_t | version | ) |
#include </__w/bridle/bridle/workspace/zephyr/include/zephyr/drivers/firmware/scmi/system.h>
Negotiate protocol version.
| version | desired protocol version |
| 0 | if successful |
| negative | errno if failure |