blob: bedd42732a7d37970474b56078ec81857a92d899 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
|
/*
* Arm SCP/MCP Software
* Copyright (c) 2019-2020, Arm Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*
* Description:
* System Control and Management Interface (SCMI) support for Reset Domain
* Management Protocol.
*/
#ifndef INTERNAL_SCMI_RESET_DOMAIN_H
#define INTERNAL_SCMI_RESET_DOMAIN_H
#include <stdint.h>
/*!
* \addtogroup GroupModules Modules
* \{
*/
/*!
* \defgroup GroupSCMI_RESET SCMI Reset Domain Management Protocol.
* \{
*/
#define SCMI_PROTOCOL_VERSION_RESET_DOMAIN UINT32_C(0x10000)
#define SCMI_RESET_STATE_ARCH (0 << 31)
#define SCMI_RESET_STATE_IMPL (1 << 31)
/*
* PROTOCOL_ATTRIBUTES
*/
struct scmi_reset_domain_protocol_attributes_p2a {
int32_t status;
uint32_t attributes;
};
/* Value for scmi_reset_domain_attributes_p2a:flags */
#define SCMI_RESET_DOMAIN_ATTR_ASYNC (1UL << 31)
#define SCMI_RESET_DOMAIN_ATTR_NOTIF (1UL << 30)
/* Value for scmi_reset_domain_attributes_p2a:latency */
#define SCMI_RESET_DOMAIN_ATTR_LATENCY_UNSUPPORTED 0xFFFFFFFF
/* Macro for scmi_reset_domain_attributes_p2a:name */
#define SCMI_RESET_DOMAIN_ATTR_NAME_SZ 16
struct scmi_reset_domain_attributes_a2p {
uint32_t domain_id;
};
struct scmi_reset_domain_attributes_p2a {
int32_t status;
uint32_t flags;
uint32_t latency;
uint8_t name[SCMI_RESET_DOMAIN_ATTR_NAME_SZ];
};
/*
* RESET
*/
/* Values for scmi_reset_domain_request_p2a:flags */
#define SCMI_RESET_DOMAIN_ASYNC (1 << 2)
#define SCMI_RESET_DOMAIN_EXPLICIT (1 << 1)
#define SCMI_RESET_DOMAIN_AUTO (1 << 0)
#define SCMI_RESET_DOMAIN_FLAGS_MASK \
(SCMI_RESET_DOMAIN_ASYNC | SCMI_RESET_DOMAIN_EXPLICIT | \
SCMI_RESET_DOMAIN_AUTO)
struct scmi_reset_domain_request_a2p {
uint32_t domain_id;
uint32_t flags;
uint32_t reset_state;
};
struct scmi_reset_domain_request_p2a {
int32_t status;
};
/*
* RESET_NOTIFY
*/
/* Values for scmi_reset_notify_p2a:flags */
#define SCMI_RESET_DOMAIN_DO_NOTIFY (1 << 0)
struct scmi_reset_domain_notify_a2p {
uint32_t domain_id;
uint32_t notify_enable;
};
struct scmi_reset_domain_notify_p2a {
int32_t status;
};
/*
* RESET_COMPLETE
*/
struct scmi_reset_domain_complete_p2a {
int32_t status;
uint32_t domain_id;
};
/*
* RESET_ISSUED
*/
struct scmi_reset_domain_issued_p2a {
uint32_t agent_id;
uint32_t domain_id;
uint32_t reset_state;
};
/*!
* \}
*/
/*!
* \}
*/
#endif /* INTERNAL_SCMI_RESET_DOMAIN_H */
|