| // Copyright 2019 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.device.power.test; |
| |
| using zx; |
| using fuchsia.device; |
| |
| protocol TestDevice { |
| /// Add Test Device with some powerargs |
| AddDeviceWithPowerArgs(vector<fuchsia.device.DevicePowerStateInfo> info, |
| vector<fuchsia.device.DevicePerformanceStateInfo> perf_state_info, bool make_visible) -> () error zx.status; |
| /// Get current power state of the device |
| GetCurrentDevicePowerState() -> (fuchsia.device.DevicePowerState cur_state) error zx.status; |
| /// Get the suspend reason of the last suspend call |
| GetCurrentSuspendReason() -> (uint8 cur_suspend_reason) error zx.status; |
| /// Get current performance state of the device |
| GetCurrentDevicePerformanceState() -> (int32 cur_state) error zx.status; |
| /// Get current auto suspend status and deepest_sleep_state |
| GetCurrentDeviceAutoSuspendConfig() -> (bool enabled, |
| fuchsia.device.DevicePowerState deepest_sleep_state) error zx.status; |
| }; |