1 /* 2 * Copyright (C) 2003-2015 FreeIPMI Core Team 3 * 4 * This program is free software: you can redistribute it and/or modify 5 * it under the terms of the GNU General Public License as published by 6 * the Free Software Foundation, either version 3 of the License, or 7 * (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program. If not, see <http://www.gnu.org/licenses/>. 16 * 17 */ 18 /*****************************************************************************\ 19 * Copyright (C) 2009-2015 Lawrence Livermore National Security, LLC. 20 * Produced at Lawrence Livermore National Laboratory (cf, DISCLAIMER). 21 * Written by Albert Chu <chu11@llnl.gov> 22 * LLNL-CODE-413270 23 * 24 * This file is part of Ipmi-Dcmi, tools and libraries to support the 25 * data center manageability interface (DCMI). For details, see 26 * http://www.llnl.gov/linux/. 27 * 28 * Ipmi-Dcmi is free software; you can redistribute it and/or modify 29 * it under the terms of the GNU General Public License as published by the 30 * Free Software Foundation; either version 3 of the License, or (at your 31 * option) any later version. 32 * 33 * Ipmi-Dcmi is distributed in the hope that it will be useful, but 34 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 35 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 36 * for more details. 37 * 38 * You should have received a copy of the GNU General Public License along 39 * with Ipmi-Dcmi. If not, see <http://www.gnu.org/licenses/>. 40 \*****************************************************************************/ 41 42 #ifndef IPMI_ERROR_DCMI_UTIL_H 43 #define IPMI_ERROR_DCMI_UTIL_H 44 45 #ifdef __cplusplus 46 extern "C" { 47 #endif 48 49 #include <stdint.h> 50 #include <sys/types.h> 51 #include <freeipmi/fiid/fiid.h> 52 53 /* returns 0 on success, -1 on error */ 54 int ipmi_completion_code_dcmi_strerror_r (uint8_t cmd, 55 uint8_t netfn, 56 uint8_t comp_code, 57 char *errstr, 58 size_t len); 59 60 /* returns 0 on success, -1 on error */ 61 int ipmi_completion_code_dcmi_strerror_cmd_r (fiid_obj_t obj_cmd, 62 uint8_t netfn, 63 char *errstr, 64 size_t len); 65 66 #ifdef __cplusplus 67 } 68 #endif 69 70 #endif /* IPMI_ERROR_DCMI_UTIL_H */ 71