1a2056e9cSWilly Tu // Copyright 2021 Google LLC 2a2056e9cSWilly Tu // 3a2056e9cSWilly Tu // Licensed under the Apache License, Version 2.0 (the "License"); 4a2056e9cSWilly Tu // you may not use this file except in compliance with the License. 5a2056e9cSWilly Tu // You may obtain a copy of the License at 6a2056e9cSWilly Tu // 7a2056e9cSWilly Tu // http://www.apache.org/licenses/LICENSE-2.0 8a2056e9cSWilly Tu // 9a2056e9cSWilly Tu // Unless required by applicable law or agreed to in writing, software 10a2056e9cSWilly Tu // distributed under the License is distributed on an "AS IS" BASIS, 11a2056e9cSWilly Tu // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12a2056e9cSWilly Tu // See the License for the specific language governing permissions and 13a2056e9cSWilly Tu // limitations under the License. 14a2056e9cSWilly Tu 158cfa4c44Slinyuny #pragma once 168cfa4c44Slinyuny 178cfa4c44Slinyuny #include "handler.hpp" 188cfa4c44Slinyuny 198cfa4c44Slinyuny #include <ipmid/api.h> 208cfa4c44Slinyuny 21ff3cd8e9SWilly Tu #include <ipmid/api-types.hpp> 22*444b5ea4SPatrick Williams 23b4e3704cSWilly Tu #include <span> 24ff3cd8e9SWilly Tu #include <vector> 25ff3cd8e9SWilly Tu 268cfa4c44Slinyuny namespace google 278cfa4c44Slinyuny { 288cfa4c44Slinyuny namespace ipmi 298cfa4c44Slinyuny { 308cfa4c44Slinyuny 318cfa4c44Slinyuny struct HostPowerOffRequest 328cfa4c44Slinyuny { 338cfa4c44Slinyuny // Delay in seconds. 348cfa4c44Slinyuny uint32_t delay; 358cfa4c44Slinyuny } __attribute__((packed)); 368cfa4c44Slinyuny 378cfa4c44Slinyuny // Disable the fallback watchdog with given time delay and Power Off Host 38b4e3704cSWilly Tu Resp hostPowerOff(std::span<const uint8_t> data, 39ff3cd8e9SWilly Tu const HandlerInterface* handler); 408cfa4c44Slinyuny 418cfa4c44Slinyuny } // namespace ipmi 428cfa4c44Slinyuny } // namespace google 43