fidl_fuchsia_power_observability__common/
fidl_fuchsia_power_observability__common.rs

1// WARNING: This file is machine generated by fidlgen.
2
3#![warn(clippy::all)]
4#![allow(unused_parens, unused_mut, unused_imports, nonstandard_style)]
5
6use bitflags::bitflags;
7use fidl::encoding::{MessageBufFor, ProxyChannelBox, ResourceDialect};
8use futures::future::{self, MaybeDone, TryFutureExt};
9use zx_status;
10
11/// The number of current active epolls, recorded when epolls become
12/// active / inactive and if we attempted to suspend, but failed
13/// because there were active epolls.
14pub const ACTIVE_EPOLLS_COUNT: &str = "active_epolls_count";
15
16/// The name of current active wake locks, recorded when wake locks
17/// become active and if we attempted to suspend, but failed because
18/// there were active wake locks.
19pub const ACTIVE_WAKE_LOCK_NAMES: &str = "active_wake_lock_names";
20
21/// The name of current inactive wake locks, recorded when wake locks
22/// become inactive and if we attempted to suspend, but failed
23/// because there were active wake locks.
24pub const INACTIVE_WAKE_LOCK_NAMES: &str = "inactive_wake_lock_names";
25
26/// Timestamp in nanos, for the end of resume callback processing.
27/// Resume is not gated on phase completion.
28/// Event is recorded in SUSPEND_EVENTS_NODE.
29pub const RESUME_CALLBACK_PHASE_END_AT: &str = "resume_callbacks_ended_at_ns";
30
31/// Timestamp in nanos, for the start of resume callback processing.
32/// Resume is not gated on phase completion.
33/// Event is recorded in SUSPEND_EVENTS_NODE.
34pub const RESUME_CALLBACK_PHASE_START_AT: &str = "resume_callbacks_started_at_ns";
35
36/// Timestamp in nanos at which suspend was attempted.
37pub const SUSPEND_ATTEMPTED_AT: &str = "attempted_at_ns";
38
39/// Timestamp in nanos for when a suspend attempt was blocked internally.
40/// Suspend may be repeatedly blocked until all suspend locks and suspend
41/// blockers have been dropped.
42pub const SUSPEND_ATTEMPT_BLOCKED_AT: &str = "attempt_blocked_at_ns";
43
44/// Timestamp in nanos for when at least one suspend blocker is acquired.
45/// This occurs when an internal procedure needs to prevent suspension.
46/// For example, when servicing a wake lease request, system-activity-governor
47/// will acquire a suspend blocker for the lifetime of the wake lease token.
48/// This prevents suspension even while the underlying power broker lease is
49/// pending.
50pub const SUSPEND_BLOCKER_ACQUIRED_AT: &str = "suspend_blocker_acquired_at_ns";
51
52/// Timestamp in nanos for when the last suspend blocker is dropped.
53pub const SUSPEND_BLOCKER_DROPPED_AT: &str = "suspend_blocker_dropped_at_ns";
54
55/// Timestamp in nanos, for the end of suspend callback processing.
56/// Suspend is gated on phase completion.
57/// Event is recorded in SUSPEND_EVENTS_NODE.
58pub const SUSPEND_CALLBACK_PHASE_END_AT: &str = "suspend_callbacks_ended_at_ns";
59
60/// Timestamp in nanos, for the start of suspend callback processing.
61/// Suspend is gated on phase completion.
62/// Event is recorded in SUSPEND_EVENTS_NODE.
63pub const SUSPEND_CALLBACK_PHASE_START_AT: &str = "suspend_callbacks_started_at_ns";
64
65/// Label of an inspect node tallying suspend events.
66pub const SUSPEND_EVENTS_NODE: &str = "suspend_events";
67
68/// Timestamp in nanos for resume, after an unsuccessful suspend.
69pub const SUSPEND_FAILED_AT: &str = "failed_at_ns";
70
71/// The number of failed suspends.
72pub const SUSPEND_FAIL_COUNT: &str = "fail_count";
73
74/// The duration of time last spent in operations leading to suspend,
75/// excluding the time actually spent suspended.
76///
77/// TODO: b/354239403 - make this string also end with `_ns` to be consistent
78/// with the conventions above.
79pub const SUSPEND_LAST_DURATION: &str = "last_time_in_suspend_operations";
80
81/// The error code related to the last suspend operation.
82pub const SUSPEND_LAST_FAILED_ERROR: &str = "last_failed_error";
83
84/// The duration of time last spent in suspend.
85pub const SUSPEND_LAST_TIMESTAMP: &str = "last_time_in_suspend_ns";
86
87/// Timestamp in nanos for when suspend requests will be blocked because a
88/// suspend lock is acquired. This event occurs right before a request to the
89/// suspend HAL is made.
90pub const SUSPEND_LOCK_ACQUIRED_AT: &str = "suspend_lock_acquired_at_ns";
91
92/// Timestamp in nanos for when a suspend lock is dropped. This event occurs
93/// after a response from the suspend HAL is received and handled by SAG.
94pub const SUSPEND_LOCK_DROPPED_AT: &str = "suspend_lock_dropped_at_ns";
95
96/// The requested future system state.
97pub const SUSPEND_REQUESTED_STATE: &str = "requested_power_state";
98
99/// Timestamp in nanos for resume, after a successful suspend.
100pub const SUSPEND_RESUMED_AT: &str = "resumed_at_ns";
101
102/// Label of an inspect node keeping suspend statistics.
103pub const SUSPEND_STATS_NODE: &str = "suspend_stats";
104
105/// The number of successful suspends.
106pub const SUSPEND_SUCCESS_COUNT: &str = "success_count";
107
108/// The current state of wake leases, as tracked by SAG.
109/// The wake lease event history is tracked separately in SUSPEND_EVENTS_NODE.
110pub const WAKE_LEASES_NODE: &str = "wake_leases";
111
112/// Timestamp in nanos for when a wake lease was created.
113pub const WAKE_LEASE_CREATED_AT: &str = "wake_lease_created_at_ns";
114
115/// Timestamp in nanos for a wake lease is dropped.
116pub const WAKE_LEASE_DROPPED_AT: &str = "wake_lease_dropped_at_ns";
117
118/// The kernel object ID of the token vended to the client.
119pub const WAKE_LEASE_ITEM_CLIENT_TOKEN_KOID: &str = "wake_lease_client_token_koid";
120
121/// The error message. For example, if the underlying power broker lease failed
122/// to be satisfied.
123pub const WAKE_LEASE_ITEM_ERROR: &str = "error";
124
125/// The name of the wake lease as requested by the client.
126pub const WAKE_LEASE_ITEM_NAME: &str = "wake_lease_name";
127
128/// The time since boot when the wake lease was created in nanoseconds.
129pub const WAKE_LEASE_ITEM_NODE_CREATED_AT: &str = "wake_lease_created_at";
130
131/// The status of the wake lease.
132pub const WAKE_LEASE_ITEM_STATUS: &str = "wake_lease_status";
133
134/// Lease requested in power broker is awaiting satisfaction in the power
135/// topology.
136pub const WAKE_LEASE_ITEM_STATUS_AWAITING_SATISFACTION: &str = "pending";
137
138/// Lease requested in power broker failed to be satisfied.
139pub const WAKE_LEASE_ITEM_STATUS_FAILED_SATISFACTION: &str = "failed";
140
141/// Lease requested in power broker is satisfied by the current state of the
142/// power topology.
143pub const WAKE_LEASE_ITEM_STATUS_SATISFIED: &str = "satisfied";
144
145/// The type of wake lease.
146pub const WAKE_LEASE_ITEM_TYPE: &str = "wake_lease_type";
147
148/// Lease that blocks the system from dropping below the Application Activity
149/// 'Active' state.
150pub const WAKE_LEASE_ITEM_TYPE_APPLICATION_ACTIVITY: &str = "application_activity";
151
152/// Lease that blocks suspension of the hardware platform.
153pub const WAKE_LEASE_ITEM_TYPE_WAKE: &str = "wake";
154
155/// Timestamp in nanos for when a wake lease failed to be satisfied by power broker.
156pub const WAKE_LEASE_SATISFACTION_FAILED_AT: &str = "wake_lease_satisfaction_failed_at_ns";
157
158/// Timestamp in nanos for when a wake lease is satisfaction with power broker.
159pub const WAKE_LEASE_SATISFIED_AT: &str = "wake_lease_satisfied_at_ns";
160
161mod internal {
162    use super::*;
163}