AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 1 | /* |
| 2 | // Copyright (c) 2018 Intel Corporation |
| 3 | // |
| 4 | // Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | // you may not use this file except in compliance with the License. |
| 6 | // You may obtain a copy of the License at |
| 7 | // |
| 8 | // http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | // |
| 10 | // Unless required by applicable law or agreed to in writing, software |
| 11 | // distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | // See the License for the specific language governing permissions and |
| 14 | // limitations under the License. |
| 15 | */ |
| 16 | #pragma once |
Jayaprakash Mutyala | 70bd063 | 2020-10-23 06:24:55 +0000 | [diff] [blame^] | 17 | #include <openssl/crypto.h> |
| 18 | |
Sumanth Bhat | e4e633e | 2019-05-14 12:13:57 +0000 | [diff] [blame] | 19 | #include <array> |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 20 | #include <ipmid/api.hpp> |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 21 | #include <string> |
| 22 | |
| 23 | namespace ipmi |
| 24 | { |
| 25 | |
| 26 | static constexpr uint8_t maxIpmiChannels = 16; |
Richard Marian Thomaiyar | a39208e | 2018-12-08 17:27:11 +0530 | [diff] [blame] | 27 | static constexpr uint8_t currentChNum = 0xE; |
Vernon Mauery | 735ee95 | 2019-02-15 13:38:52 -0800 | [diff] [blame] | 28 | static constexpr uint8_t invalidChannel = 0xff; |
jayaprakash Mutyala | 0e2dbee | 2019-12-26 13:03:04 +0000 | [diff] [blame] | 29 | static constexpr const uint8_t ccActionNotSupportedForChannel = 0x82; |
| 30 | static constexpr const uint8_t ccAccessModeNotSupportedForChannel = 0x83; |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 31 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 32 | /** |
Sumanth Bhat | e4e633e | 2019-05-14 12:13:57 +0000 | [diff] [blame] | 33 | * @array of privilege levels |
| 34 | */ |
| 35 | extern const std::array<std::string, PRIVILEGE_OEM + 1> privList; |
| 36 | |
| 37 | /** |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 38 | * @enum Channel Protocol Type (refer spec sec 6.4) |
| 39 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 40 | enum class EChannelProtocolType : uint8_t |
| 41 | { |
| 42 | na = 0x00, |
| 43 | ipmbV10 = 0x01, |
| 44 | icmbV11 = 0x02, |
| 45 | reserved = 0x03, |
| 46 | ipmiSmbus = 0x04, |
| 47 | kcs = 0x05, |
| 48 | smic = 0x06, |
| 49 | bt10 = 0x07, |
| 50 | bt15 = 0x08, |
| 51 | tMode = 0x09, |
| 52 | oem = 0x1C, |
| 53 | }; |
| 54 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 55 | /** |
| 56 | * @enum Channel Medium Type (refer spec sec 6.5) |
| 57 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 58 | enum class EChannelMediumType : uint8_t |
| 59 | { |
| 60 | reserved = 0x00, |
| 61 | ipmb = 0x01, |
| 62 | icmbV10 = 0x02, |
| 63 | icmbV09 = 0x03, |
| 64 | lan8032 = 0x04, |
| 65 | serial = 0x05, |
| 66 | otherLan = 0x06, |
| 67 | pciSmbus = 0x07, |
| 68 | smbusV11 = 0x08, |
| 69 | smbusV20 = 0x09, |
| 70 | usbV1x = 0x0A, |
| 71 | usbV2x = 0x0B, |
| 72 | systemInterface = 0x0C, |
| 73 | oem = 0x60, |
| 74 | unknown = 0x82, |
| 75 | }; |
| 76 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 77 | /** |
| 78 | * @enum Channel Session Type (refer spec sec 22.24 - |
| 79 | * response data byte 5) |
| 80 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 81 | enum class EChannelSessSupported : uint8_t |
| 82 | { |
| 83 | none = 0, |
| 84 | single = 1, |
| 85 | multi = 2, |
| 86 | any = 3, |
| 87 | }; |
| 88 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 89 | /** |
| 90 | * @enum Channel Access Mode (refer spec sec 6.6) |
| 91 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 92 | enum class EChannelAccessMode : uint8_t |
| 93 | { |
| 94 | disabled = 0, |
| 95 | preboot = 1, |
| 96 | alwaysAvail = 2, |
| 97 | shared = 3, |
| 98 | }; |
| 99 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 100 | /** |
| 101 | * @enum Authentication Types (refer spec sec 13.6 - IPMI |
| 102 | * Session Header) |
| 103 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 104 | enum class EAuthType : uint8_t |
| 105 | { |
| 106 | none = (1 << 0x0), |
| 107 | md2 = (1 << 0x1), |
| 108 | md5 = (1 << 0x2), |
| 109 | reserved = (1 << 0x3), |
| 110 | straightPasswd = (1 << 0x4), |
| 111 | oem = (1 << 0x5), |
| 112 | }; |
| 113 | |
Saravanan Palanisamy | b5a0f16 | 2019-03-04 18:34:44 +0530 | [diff] [blame] | 114 | // TODO: Remove duplicate 'PayloadType' definition from netipmid's message.hpp |
| 115 | // to phosphor-ipmi-host/include |
| 116 | /** |
| 117 | * @enum Payload Types (refer spec sec 13.27.3) |
| 118 | */ |
| 119 | enum class PayloadType : uint8_t |
| 120 | { |
| 121 | IPMI = 0x00, |
| 122 | SOL = 0x01, |
| 123 | OPEN_SESSION_REQUEST = 0x10, |
| 124 | OPEN_SESSION_RESPONSE = 0x11, |
| 125 | RAKP1 = 0x12, |
| 126 | RAKP2 = 0x13, |
| 127 | RAKP3 = 0x14, |
| 128 | RAKP4 = 0x15, |
| 129 | INVALID = 0xFF, |
| 130 | }; |
| 131 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 132 | /** |
| 133 | * @enum Access mode for channel access set/get (refer spec |
| 134 | * sec 22.22 - request byte 2[7:6]) |
| 135 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 136 | typedef enum |
| 137 | { |
| 138 | doNotSet = 0x00, |
| 139 | nvData = 0x01, |
| 140 | activeData = 0x02, |
| 141 | reserved = 0x03, |
| 142 | } EChannelActionType; |
| 143 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 144 | /** |
| 145 | * @enum Access set flag to determine changes that has to be updated |
| 146 | * in channel access data configuration. |
| 147 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 148 | enum AccessSetFlag |
| 149 | { |
| 150 | setAccessMode = (1 << 0), |
| 151 | setUserAuthEnabled = (1 << 1), |
| 152 | setMsgAuthEnabled = (1 << 2), |
| 153 | setAlertingEnabled = (1 << 3), |
| 154 | setPrivLimit = (1 << 4), |
| 155 | }; |
| 156 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 157 | /** @struct ChannelAccess |
| 158 | * |
| 159 | * Structure to store channel access related information, defined in IPMI |
| 160 | * specification and used in Get / Set channel access (refer spec sec 22.22 |
| 161 | * & 22.23) |
| 162 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 163 | struct ChannelAccess |
| 164 | { |
| 165 | uint8_t accessMode; |
| 166 | bool userAuthDisabled; |
| 167 | bool perMsgAuthDisabled; |
| 168 | bool alertingDisabled; |
| 169 | uint8_t privLimit; |
| 170 | }; |
| 171 | |
Richard Marian Thomaiyar | 6e1ba9e | 2018-11-29 06:29:21 +0530 | [diff] [blame] | 172 | /** @struct ChannelInfo |
| 173 | * |
| 174 | * Structure to store data about channel information, which identifies each |
| 175 | * channel type and information as defined in IPMI specification. (refer spec |
| 176 | * sec 22.22 & 22.23) |
| 177 | */ |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 178 | struct ChannelInfo |
| 179 | { |
| 180 | uint8_t mediumType; |
| 181 | uint8_t protocolType; |
| 182 | uint8_t sessionSupported; |
| 183 | bool isIpmi; // Is session IPMI |
| 184 | // This is used in Get LAN Configuration parameter. |
| 185 | // This holds the supported AuthTypes for a given channel. |
| 186 | uint8_t authTypeSupported; |
| 187 | }; |
| 188 | |
| 189 | /** @brief determines valid channel |
| 190 | * |
| 191 | * @param[in] chNum- channel number |
| 192 | * |
| 193 | * @return true if valid, false otherwise |
| 194 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 195 | bool isValidChannel(const uint8_t chNum); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 196 | |
| 197 | /** @brief determines whether channel device exist |
| 198 | * |
| 199 | * @param[in] chNum - channel number |
| 200 | * |
| 201 | * @return true if valid, false otherwise |
| 202 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 203 | bool doesDeviceExist(const uint8_t chNum); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 204 | |
| 205 | /** @brief determines whether privilege limit is valid |
| 206 | * |
| 207 | * @param[in] privLimit - Privilege limit |
| 208 | * |
| 209 | * @return true if valid, false otherwise |
| 210 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 211 | bool isValidPrivLimit(const uint8_t privLimit); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 212 | |
| 213 | /** @brief determines whether access mode is valid |
| 214 | * |
| 215 | * @param[in] accessMode - Access mode |
| 216 | * |
| 217 | * @return true if valid, false otherwise |
| 218 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 219 | bool isValidAccessMode(const uint8_t accessMode); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 220 | |
| 221 | /** @brief determines valid authentication type based on channel number |
| 222 | * |
| 223 | * @param[in] chNum - channel number |
| 224 | * @param[in] authType - authentication type |
| 225 | * |
| 226 | * @return true if valid, false otherwise |
| 227 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 228 | bool isValidAuthType(const uint8_t chNum, const EAuthType& authType); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 229 | |
| 230 | /** @brief determines supported session type of a channel |
| 231 | * |
| 232 | * @param[in] chNum - channel number |
| 233 | * |
| 234 | * @return EChannelSessSupported - supported session type |
| 235 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 236 | EChannelSessSupported getChannelSessionSupport(const uint8_t chNum); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 237 | |
| 238 | /** @brief determines number of active sessions on a channel |
| 239 | * |
| 240 | * @param[in] chNum - channel number |
| 241 | * |
| 242 | * @return numer of active sessions |
| 243 | */ |
Richard Marian Thomaiyar | a45cb34 | 2018-12-03 15:08:59 +0530 | [diff] [blame] | 244 | int getChannelActiveSessions(const uint8_t chNum); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 245 | |
Vernon Mauery | 5831712 | 2018-11-28 11:02:43 -0800 | [diff] [blame] | 246 | /** @brief determines maximum transfer size for a channel |
| 247 | * |
| 248 | * @param[in] chNum - channel number |
| 249 | * |
| 250 | * @return maximum bytes that can be transferred on this channel |
| 251 | */ |
| 252 | size_t getChannelMaxTransferSize(uint8_t chNum); |
| 253 | |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 254 | /** @brief initializes channel management |
| 255 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 256 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 257 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 258 | Cc ipmiChannelInit(); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 259 | |
| 260 | /** @brief provides channel info details |
| 261 | * |
| 262 | * @param[in] chNum - channel number |
| 263 | * @param[out] chInfo - channel info details |
| 264 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 265 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 266 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 267 | Cc getChannelInfo(const uint8_t chNum, ChannelInfo& chInfo); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 268 | |
| 269 | /** @brief provides channel access data |
| 270 | * |
| 271 | * @param[in] chNum - channel number |
| 272 | * @param[out] chAccessData -channel access data |
| 273 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 274 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 275 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 276 | Cc getChannelAccessData(const uint8_t chNum, ChannelAccess& chAccessData); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 277 | |
Richard Marian Thomaiyar | a39208e | 2018-12-08 17:27:11 +0530 | [diff] [blame] | 278 | /** @brief provides function to convert current channel number (0xE) |
| 279 | * |
| 280 | * @param[in] chNum - channel number as requested in commands. |
Vernon Mauery | 5ed3959 | 2019-05-14 09:16:53 -0700 | [diff] [blame] | 281 | * @param[in] devChannel - channel number as provided by device (not 0xE) |
Richard Marian Thomaiyar | 30b0112 | 2019-04-03 15:46:03 +0530 | [diff] [blame] | 282 | * |
| 283 | * @return same channel number or proper channel number for current channel |
| 284 | * number (0xE). |
| 285 | */ |
Vernon Mauery | 5ed3959 | 2019-05-14 09:16:53 -0700 | [diff] [blame] | 286 | static inline uint8_t convertCurrentChannelNum(const uint8_t chNum, |
| 287 | const uint8_t devChannel) |
Richard Marian Thomaiyar | 30b0112 | 2019-04-03 15:46:03 +0530 | [diff] [blame] | 288 | { |
| 289 | if (chNum == currentChNum) |
| 290 | { |
Vernon Mauery | 5ed3959 | 2019-05-14 09:16:53 -0700 | [diff] [blame] | 291 | return devChannel; |
Richard Marian Thomaiyar | 30b0112 | 2019-04-03 15:46:03 +0530 | [diff] [blame] | 292 | } |
| 293 | return chNum; |
| 294 | } |
| 295 | |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 296 | /** @brief to set channel access data |
| 297 | * |
| 298 | * @param[in] chNum - channel number |
| 299 | * @param[in] chAccessData - channel access data |
| 300 | * @param[in] setFlag - flag to indicate updatable fields |
| 301 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 302 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 303 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 304 | Cc setChannelAccessData(const uint8_t chNum, const ChannelAccess& chAccessData, |
| 305 | const uint8_t setFlag); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 306 | |
| 307 | /** @brief to get channel access data persistent data |
| 308 | * |
| 309 | * @param[in] chNum - channel number |
| 310 | * @param[out] chAccessData - channel access data |
| 311 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 312 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 313 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 314 | Cc getChannelAccessPersistData(const uint8_t chNum, |
| 315 | ChannelAccess& chAccessData); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 316 | |
| 317 | /** @brief to set channel access data persistent data |
| 318 | * |
| 319 | * @param[in] chNum - channel number |
| 320 | * @param[in] chAccessData - channel access data |
| 321 | * @param[in] setFlag - flag to indicate updatable fields |
| 322 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 323 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 324 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 325 | Cc setChannelAccessPersistData(const uint8_t chNum, |
| 326 | const ChannelAccess& chAccessData, |
| 327 | const uint8_t setFlag); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 328 | |
| 329 | /** @brief provides supported authentication type for the channel |
| 330 | * |
| 331 | * @param[in] chNum - channel number |
| 332 | * @param[out] authTypeSupported - supported authentication type |
| 333 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 334 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 335 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 336 | Cc getChannelAuthTypeSupported(const uint8_t chNum, uint8_t& authTypeSupported); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 337 | |
| 338 | /** @brief provides enabled authentication type for the channel |
| 339 | * |
| 340 | * @param[in] chNum - channel number |
| 341 | * @param[in] priv - privilege |
| 342 | * @param[out] authType - enabled authentication type |
| 343 | * |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 344 | * @return ccSuccess for success, others for failure. |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 345 | */ |
NITIN SHARMA | b541a5a | 2019-07-18 12:46:59 +0000 | [diff] [blame] | 346 | Cc getChannelEnabledAuthType(const uint8_t chNum, const uint8_t priv, |
| 347 | EAuthType& authType); |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 348 | |
Johnathan Mantey | 74a2102 | 2018-12-13 13:17:56 -0800 | [diff] [blame] | 349 | /** @brief Retrieves the LAN channel name from the IPMI channel number |
| 350 | * |
| 351 | * @param[in] chNum - IPMI channel number |
| 352 | * |
| 353 | * @return the LAN channel name (i.e. eth0) |
| 354 | */ |
Richard Marian Thomaiyar | 55768e3 | 2019-03-02 22:54:37 +0530 | [diff] [blame] | 355 | std::string getChannelName(const uint8_t chNum); |
Johnathan Mantey | 74a2102 | 2018-12-13 13:17:56 -0800 | [diff] [blame] | 356 | |
Vernon Mauery | 735ee95 | 2019-02-15 13:38:52 -0800 | [diff] [blame] | 357 | /** @brief Retrieves the LAN channel number from the IPMI channel name |
| 358 | * |
| 359 | * @param[in] chName - IPMI channel name (i.e. eth0) |
| 360 | * |
| 361 | * @return the LAN channel number |
| 362 | */ |
| 363 | uint8_t getChannelByName(const std::string& chName); |
| 364 | |
Ayushi Smriti | 6fd812d | 2019-04-12 18:51:31 +0000 | [diff] [blame] | 365 | /** @brief determines whether payload type is valid |
| 366 | * |
| 367 | * @param[in] payload type - Payload Type |
| 368 | * |
| 369 | * @return true if valid, false otherwise |
| 370 | */ |
| 371 | bool isValidPayloadType(const PayloadType payloadType); |
| 372 | |
AppaRao Puli | 071f3f2 | 2018-05-24 16:45:30 +0530 | [diff] [blame] | 373 | } // namespace ipmi |