description: >
    Implement to provide drive state management.

properties:
    - name: Rebuilding
      type: boolean
      default: false
      description: >
          Describes if the drive is currently rebuilding.
    - name: RequestedDriveTransition
      type: enum[self.Transition]
      default: "NotSupported"
      description: >
          The desired Drive transition
    - name: CurrentDriveState
      type: enum[self.DriveState]
      default: "Unknown"
      description: >
          The current state of the Drive and is a read-only property.
      flags:
          - readonly
    - name: LastRebootTime
      type: uint64
      default: maxint
      description: >
          Time when the Drive last rebooted represented in EpochTime.
          The time reference should be based on the BMC's time.
          If not supported, it will be represented as maxint.
      flags:
          - readonly

enumerations:
    - name: Transition
      description: >
          The desired transition for the Drive
      values:
          - name: "Reboot"
            description: >
                The Drive should be rebooted.
          - name: "HardReboot"
            description: >
                The Drive should be non-gracefully rebooted.
          - name: "Powercycle"
            description: >
                The Drive should be powercycled.
          - name: "None"
            description: >
                No transition is in progress.
          - name: "NotSupported"
            description: >
                Transition request is not supported.

    - name: DriveState
      description: >
          The current state of the Drive
      values:
          - name: "Unknown"
            description: >
                The Drive State is unknown.
          - name: "Ready"
            description: >
                Ready implies all services started and are running successfully
          - name: "NotReady"
            description: >
                Not ready implies not all services have started or are not
                running successfully
          - name: "Offline"
            description: >
                The Drive is ready, but waiting for external action to enable it
          - name: "Debug"
            description: >
                The Drive is ready and in debug mode. The functionalities might
                be limited
          - name: "UpdateInProgress"
            description: >
                UpdateInProgress implies the Drive is in firmware update mode.
                Current DriveState will be set to "UpdateInProgress" while
                starting firmware download and reset to "Ready", once activation
                is done or error occurs during update process.
