1*a2056e9cSWilly Tu // Copyright 2021 Google LLC 2*a2056e9cSWilly Tu // 3*a2056e9cSWilly Tu // Licensed under the Apache License, Version 2.0 (the "License"); 4*a2056e9cSWilly Tu // you may not use this file except in compliance with the License. 5*a2056e9cSWilly Tu // You may obtain a copy of the License at 6*a2056e9cSWilly Tu // 7*a2056e9cSWilly Tu // http://www.apache.org/licenses/LICENSE-2.0 8*a2056e9cSWilly Tu // 9*a2056e9cSWilly Tu // Unless required by applicable law or agreed to in writing, software 10*a2056e9cSWilly Tu // distributed under the License is distributed on an "AS IS" BASIS, 11*a2056e9cSWilly Tu // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12*a2056e9cSWilly Tu // See the License for the specific language governing permissions and 13*a2056e9cSWilly Tu // limitations under the License. 14*a2056e9cSWilly Tu 152d4836dbSJaghathiswari Rankappagounder Natarajan #pragma once 162d4836dbSJaghathiswari Rankappagounder Natarajan 1749f23ad9SPatrick Venture #include "handler.hpp" 1849f23ad9SPatrick Venture 192c9e1625SWilliam A. Kennington III #include <ipmid/api.h> 202d4836dbSJaghathiswari Rankappagounder Natarajan 212d4836dbSJaghathiswari Rankappagounder Natarajan namespace google 222d4836dbSJaghathiswari Rankappagounder Natarajan { 232d4836dbSJaghathiswari Rankappagounder Natarajan namespace ipmi 242d4836dbSJaghathiswari Rankappagounder Natarajan { 252d4836dbSJaghathiswari Rankappagounder Natarajan 262d4836dbSJaghathiswari Rankappagounder Natarajan // Handle the pcie slot count command. 272d4836dbSJaghathiswari Rankappagounder Natarajan // Sys can query the number of pcie slots. 2845fad1bbSPatrick Venture ipmi_ret_t pcieSlotCount(const uint8_t* reqBuf, uint8_t* replyBuf, 29c87de558SPatrick Venture size_t* dataLen, HandlerInterface* handler); 302d4836dbSJaghathiswari Rankappagounder Natarajan 312d4836dbSJaghathiswari Rankappagounder Natarajan // Handle the pcie slot to i2c bus mapping command. 322d4836dbSJaghathiswari Rankappagounder Natarajan // Sys can query which i2c bus is routed to which pcie slot. 3345fad1bbSPatrick Venture ipmi_ret_t pcieSlotI2cBusMapping(const uint8_t* reqBuf, uint8_t* replyBuf, 34c87de558SPatrick Venture size_t* dataLen, HandlerInterface* handler); 352d4836dbSJaghathiswari Rankappagounder Natarajan 362d4836dbSJaghathiswari Rankappagounder Natarajan } // namespace ipmi 372d4836dbSJaghathiswari Rankappagounder Natarajan } // namespace google 38