blob: e364ca749bb3577b56c3984bb90a9b28bbf107ac [file] [log] [blame]
Carol Wang79064a82019-12-24 13:34:03 +08001description: >
2 Implement to schedule Epoch time to power on/off the Host.
3properties:
4 - name: ScheduledTime
5 type: uint64
6 default: 0
7 description: >
Patrick Williamsa1347412022-12-06 10:56:22 -06008 ScheduledTime is a date time when the host will be powered on/off. The
9 time is the Epoch time, number of seconds since 1 Jan 1970 00::00::00
10 UTC.
Carol Wang79064a82019-12-24 13:34:03 +080011
Patrick Williamsa1347412022-12-06 10:56:22 -060012 When ScheduledTime is 0, it means the functionality is disabled. When
13 ScheduledTime is smaller than current time, error InvalidTime will be
14 thrown. When the controller detects the ScheduledTime has passed, it
15 will execute the ScheduledTransition and reset the value to 0. Once
16 the transition starts, there won't be any retries. When the real time
17 changes, the controller shall check if the time is still in the
18 future. If so, it will stop the existing timer and restart it with new
19 wait time. Otherwise, stop the existing timer and execute the
20 ScheduledTransition. When ScheduledTime is reached, but the host is
21 not ready to power on/off, e.g. when BMC is rebooting, BMC shall set
22 the host ScheduledTransition after it is ready.
Carol Wang79064a82019-12-24 13:34:03 +080023 errors:
Patrick Williams8da396c2022-03-14 14:21:02 -050024 - xyz.openbmc_project.ScheduledTime.Error.InvalidTime
Carol Wang79064a82019-12-24 13:34:03 +080025
Carol Wang8c364d92020-03-13 14:38:59 +080026 - name: ScheduledTransition
Carol Wang79064a82019-12-24 13:34:03 +080027 type: enum[xyz.openbmc_project.State.Host.Transition]
Patrick Williams8da396c2022-03-14 14:21:02 -050028 default: "On"
Carol Wang79064a82019-12-24 13:34:03 +080029 description: >
Patrick Williamsa1347412022-12-06 10:56:22 -060030 The desired power transition to support scheduled power on/off. The
31 default operation supports scheduled power on.