1description: >
2    Implement the watchdog function.
3
4methods:
5    - name: ResetTimeRemaining
6      description: >
7          Resets the time remaining to the configured interval.
8          This is equivalent to reading the Interval and writing it
9          into the TimeRemaining. Optionally the watchdog can be enabled
10          during the reset process.
11      parameters:
12        - name: EnableWatchdog
13          type: boolean
14          description: >
15              If true the watchdog will be enabled when the reset
16              is performed.
17      errors:
18        - xyz.openbmc_project.Common.Error.InternalFailure
19
20properties:
21    - name: Initialized
22      type: boolean
23      description: >
24          Whether the host has configured the watchdog yet.
25      default: false
26    - name: Enabled
27      type: boolean
28      description: >
29          The watchdog is enabled or not.
30      default: false
31    - name: ExpireAction
32      type: enum[self.Action]
33      description: >
34          The action the watchdog should perform when it expires.
35      default: 'HardReset'
36    - name: Interval
37      type: uint64
38      description: >
39          Time interval to arm the watchdog, in milli-second.
40      default: 30000
41    - name: TimeRemaining
42      type: uint64
43      description: >
44          Time remaining before timeout, in milli-second.
45          Setting this property can re-arm the watchdog.
46      default: 0
47    - name: CurrentTimerUse
48      type: enum[self.TimerUse]
49      description: >
50          The host defined user of this timer.
51      default: 'Reserved'
52    - name: ExpiredTimerUse
53      type: enum[self.TimerUse]
54      description: >
55          The timer user at the time of expiration.
56      default: 'Reserved'
57
58enumerations:
59   - name: Action
60     description: >
61       The type of action to perform.
62     values:
63       - name: 'None'
64         description: >
65           Do nothing.
66       - name: 'HardReset'
67         description: >
68           Perform a reset of the system.
69       - name: 'PowerOff'
70         description: >
71           Perform a power off of the system.
72       - name: 'PowerCycle'
73         description: >
74           Perform a power cycle of the system.
75
76   - name: TimerUse
77     description: >
78       The type of timer use.
79     values:
80       - name: 'Reserved'
81         description: >
82           Reserved.
83       - name: 'BIOSFRB2'
84         description: >
85           BIOS FRB2.
86       - name: 'BIOSPOST'
87         description: >
88           BIOS POST.
89       - name: 'OSLoad'
90         description: >
91           OS Load.
92       - name: SMSOS
93         description: >
94           SMS OS.
95       - name: 'OEM'
96         description: >
97           OEM.
98
99signals:
100    - name: Timeout
101      description: >
102        Watchdog timeout event signal
103      properties:
104         - name: Action
105           type: enum[self.Action]
106           description: >
107             The action taken during the watchdog timeout event.
108