int
fill_hdr_ipmi_kcs (uint8_t lun,
                   uint8_t fn,
                   fiid_obj_t obj_kcs_hdr)
{
  if (!IPMI_BMC_LUN_VALID (lun)
      || !IPMI_NET_FN_VALID (fn)
      || !fiid_obj_valid (obj_kcs_hdr))
    {
      SET_ERRNO (EINVAL);
      return (-1);
    }

  if (FIID_OBJ_TEMPLATE_COMPARE (obj_kcs_hdr, tmpl_hdr_kcs) < 0)
    {
      ERRNO_TRACE (errno);
      return (-1);
    }

  FILL_FIID_OBJ_CLEAR (obj_kcs_hdr);
  FILL_FIID_OBJ_SET (obj_kcs_hdr, "lun", lun);
  FILL_FIID_OBJ_SET (obj_kcs_hdr, "net_fn", fn);

  return (0);
}
Esempio n. 2
0
int
fill_ipmb_msg_hdr (uint8_t rs_addr,
                   uint8_t net_fn,
                   uint8_t rs_lun,
                   uint8_t rq_addr,
                   uint8_t rq_lun,
                   uint8_t rq_seq,
                   fiid_obj_t obj_ipmb_msg_hdr)
{
  uint8_t checksum_buf[1024];
  int checksum_len;
  uint8_t checksum;

  if (!IPMI_NET_FN_VALID (net_fn)
      || !IPMI_BMC_LUN_VALID (rs_lun)
      || !IPMI_BMC_LUN_VALID (rq_lun)
      || (rq_seq > IPMI_IPMB_REQUESTER_SEQUENCE_NUMBER_MAX)
      || !fiid_obj_valid (obj_ipmb_msg_hdr))
    {
      SET_ERRNO (EINVAL);
      return (-1);
    }

  if (FIID_OBJ_TEMPLATE_COMPARE (obj_ipmb_msg_hdr, tmpl_ipmb_msg_hdr_rq) < 0)
    {
      ERRNO_TRACE (errno);
      return (-1);
    }

  FILL_FIID_OBJ_CLEAR (obj_ipmb_msg_hdr);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "rs_addr", rs_addr);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "net_fn", net_fn);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "rs_lun", rs_lun);

  if ((checksum_len = fiid_obj_get_block (obj_ipmb_msg_hdr,
                                          "rs_addr",
                                          "net_fn",
                                          checksum_buf,
                                          1024)) < 0)
    {
      FIID_OBJECT_ERROR_TO_ERRNO (obj_ipmb_msg_hdr);
      return (-1);
    }

  checksum = ipmi_checksum (checksum_buf, checksum_len);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "checksum1", checksum);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "rq_addr", rq_addr);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "rq_lun", rq_lun);
  FILL_FIID_OBJ_SET (obj_ipmb_msg_hdr, "rq_seq", rq_seq);

  return (0);
}
int
fill_cmd_set_command_enables (uint8_t channel_number,
                              uint8_t net_fn,
                              uint8_t operation,
                              uint8_t lun,
                              uint8_t *enable_disable_bitmask,
                              unsigned int enable_disable_bitmask_len,
                              uint32_t net_fn_data,
                              fiid_obj_t obj_cmd_rq)
{
  if (!IPMI_CHANNEL_NUMBER_VALID (channel_number)
      || !IPMI_NET_FN_VALID (net_fn)
      || !IPMI_FIRMWARE_FIREWALL_COMMAND_DISCOVERY_OPERATION_VALID (operation)
      || !IPMI_BMC_LUN_VALID (lun)
      || !enable_disable_bitmask
      || enable_disable_bitmask_len < IPMI_FIRMWARE_FIREWALL_COMMAND_DISCOVERY_ENABLE_DISABLE_BITMASK_LEN
      || !fiid_obj_valid (obj_cmd_rq))
    {
      SET_ERRNO (EINVAL);
      return (-1);
    }
  
  if (FIID_OBJ_TEMPLATE_COMPARE (obj_cmd_rq, tmpl_cmd_set_command_enables_rq) < 0)
    {
      ERRNO_TRACE (errno);
      return (-1);
    }

  FILL_FIID_OBJ_CLEAR (obj_cmd_rq);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "cmd", IPMI_CMD_SET_COMMAND_ENABLES);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "channel_number", channel_number);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved1", 0);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn", net_fn);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "operation", operation);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "lun", lun);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved2", 0);
  FILL_FIID_OBJ_SET_DATA (obj_cmd_rq,
                          "enable_disable_mask",
                          enable_disable_bitmask,
                          IPMI_FIRMWARE_FIREWALL_COMMAND_DISCOVERY_ENABLE_DISABLE_BITMASK_LEN);
  if (net_fn == IPMI_NET_FN_GROUP_EXTENSION_RQ
      || net_fn == IPMI_NET_FN_GROUP_EXTENSION_RS)
    {
      uint8_t tmp = net_fn_data;
      FILL_FIID_OBJ_SET_DATA (obj_cmd_rq, "net_fn_data", &tmp, 1);
    }
  else if (net_fn == IPMI_NET_FN_OEM_GROUP_RQ
           || net_fn == IPMI_NET_FN_OEM_GROUP_RS)
    FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn_data", net_fn_data);
  
  return (0);
}
int
fill_cmd_get_command_sub_function_enables (uint8_t channel_number,
                                           uint8_t net_fn,
                                           uint8_t lun,
                                           uint8_t command,
                                           uint32_t net_fn_data,
                                           fiid_obj_t obj_cmd_rq)
{
  if (!IPMI_CHANNEL_NUMBER_VALID (channel_number)
      || !IPMI_NET_FN_VALID (net_fn)
      || !IPMI_BMC_LUN_VALID (lun)
      || !fiid_obj_valid (obj_cmd_rq))
    {
      SET_ERRNO (EINVAL);
      return (-1);
    }
  
  if (FIID_OBJ_TEMPLATE_COMPARE (obj_cmd_rq, tmpl_cmd_get_command_sub_function_enables_rq) < 0)
    {
      ERRNO_TRACE (errno);
      return (-1);
    }

  FILL_FIID_OBJ_CLEAR (obj_cmd_rq);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "cmd", IPMI_CMD_GET_COMMAND_SUB_FUNCTION_ENABLES);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "channel_number", channel_number);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved1", 0);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn", net_fn);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved2", 0);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "lun", lun);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved3", 0);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "command", command);
  if (net_fn == IPMI_NET_FN_GROUP_EXTENSION_RQ
      || net_fn == IPMI_NET_FN_GROUP_EXTENSION_RS)
    {
      uint8_t tmp = net_fn_data;
      FILL_FIID_OBJ_SET_DATA (obj_cmd_rq, "net_fn_data", &tmp, 1);
    }
  else if (net_fn == IPMI_NET_FN_OEM_GROUP_RQ
           || net_fn == IPMI_NET_FN_OEM_GROUP_RS)
    FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn_data", net_fn_data);
  
  return (0);
}
int
fill_cmd_get_configurable_commands (uint8_t channel_number,
                                    uint8_t net_fn,
                                    uint8_t operation,
                                    uint8_t lun,
                                    uint32_t net_fn_data,
                                    fiid_obj_t obj_cmd_rq)
{
  if (!IPMI_CHANNEL_NUMBER_VALID (channel_number)
      || !IPMI_NET_FN_VALID (net_fn)
      || !IPMI_FIRMWARE_FIREWALL_COMMAND_DISCOVERY_OPERATION_VALID (operation)
      || !IPMI_BMC_LUN_VALID (lun)
      || !fiid_obj_valid (obj_cmd_rq))
    {
      SET_ERRNO (EINVAL);
      return (-1);
    }
  
  if (FIID_OBJ_TEMPLATE_COMPARE (obj_cmd_rq, tmpl_cmd_get_configurable_commands_rq) < 0)
    {
      ERRNO_TRACE (errno);
      return (-1);
    }

  FILL_FIID_OBJ_CLEAR (obj_cmd_rq);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "cmd", IPMI_CMD_GET_CONFIGURABLE_COMMANDS);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "channel_number", channel_number);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved1", 0);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn", net_fn);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "operation", operation);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "lun", lun);
  FILL_FIID_OBJ_SET (obj_cmd_rq, "reserved2", 0);
  if (net_fn == IPMI_NET_FN_GROUP_EXTENSION_RQ
      || net_fn == IPMI_NET_FN_GROUP_EXTENSION_RS)
    {
      uint8_t tmp = net_fn_data;
      FILL_FIID_OBJ_SET_DATA (obj_cmd_rq, "net_fn_data", &tmp, 1);
    }
  else if (net_fn == IPMI_NET_FN_OEM_GROUP_RQ
           || net_fn == IPMI_NET_FN_OEM_GROUP_RS)
    FILL_FIID_OBJ_SET (obj_cmd_rq, "net_fn_data", net_fn_data);
  
  return (0);
}
Esempio n. 6
0
int
ipmi_completion_code_strerror_r (uint8_t cmd,
                                 uint8_t netfn,
                                 uint8_t comp_code,
                                 char *errstr,
                                 size_t len)
{
    if (!errstr)
    {
        SET_ERRNO (EINVAL);
        return (-1);
    }

    switch (comp_code)
    {
    case IPMI_COMP_CODE_COMMAND_SUCCESS:
        SNPRINTF_RETURN (IPMI_COMP_CODE_COMMAND_SUCCESS_STR);

    case IPMI_COMP_CODE_NODE_BUSY:
        SNPRINTF_RETURN (IPMI_COMP_CODE_NODE_BUSY_STR);

    case IPMI_COMP_CODE_INVALID_COMMAND:
        SNPRINTF_RETURN (IPMI_COMP_CODE_INVALID_COMMAND_STR);

    case IPMI_COMP_CODE_COMMAND_INVALID_FOR_LUN:
        SNPRINTF_RETURN (IPMI_COMP_CODE_COMMAND_INVALID_FOR_LUN_STR);

    case IPMI_COMP_CODE_COMMAND_TIMEOUT:
        SNPRINTF_RETURN (IPMI_COMP_CODE_COMMAND_TIMEOUT_STR);

    case IPMI_COMP_CODE_OUT_OF_SPACE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_OUT_OF_SPACE_STR);

    case IPMI_COMP_CODE_RESERVATION_CANCELLED:
        SNPRINTF_RETURN (IPMI_COMP_CODE_RESERVATION_CANCELLED_STR);

    case IPMI_COMP_CODE_REQUEST_DATA_TRUNCATED:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUEST_DATA_TRUNCATED_STR);

    case IPMI_COMP_CODE_REQUEST_DATA_LENGTH_INVALID:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUEST_DATA_LENGTH_INVALID_STR);

    case IPMI_COMP_CODE_REQUEST_DATA_LENGTH_LIMIT_EXCEEDED:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUEST_DATA_LENGTH_LIMIT_EXCEEDED_STR);

    case IPMI_COMP_CODE_PARAMETER_OUT_OF_RANGE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_PARAMETER_OUT_OF_RANGE_STR);

    case IPMI_COMP_CODE_CANNOT_RETURN_REQUESTED_NUMBER_OF_BYTES:
        SNPRINTF_RETURN (IPMI_COMP_CODE_CANNOT_RETURN_REQUESTED_NUMBER_OF_BYTES_STR);

    case IPMI_COMP_CODE_REQUESTED_SENSOR_DATA_OR_RECORD_NOT_PRESENT:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUESTED_SENSOR_DATA_OR_RECORD_NOT_PRESENT_STR);

    case IPMI_COMP_CODE_INVALID_DATA_FIELD_IN_REQUEST:
        SNPRINTF_RETURN (IPMI_COMP_CODE_INVALID_DATA_FIELD_IN_REQUEST_STR);

    case IPMI_COMP_CODE_COMMAND_ILLEGAL_FOR_SENSOR_OR_RECORD_TYPE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_COMMAND_ILLEGAL_FOR_SENSOR_OR_RECORD_TYPE_STR);

    case IPMI_COMP_CODE_COMMAND_RESPONSE_COULD_NOT_BE_PROVIDED:
        SNPRINTF_RETURN (IPMI_COMP_CODE_COMMAND_RESPONSE_COULD_NOT_BE_PROVIDED_STR);

    case IPMI_COMP_CODE_CANNOT_EXECUTE_DUPLICATE_REQUEST:
        SNPRINTF_RETURN (IPMI_COMP_CODE_CANNOT_EXECUTE_DUPLICATE_REQUEST_STR);

    case IPMI_COMP_CODE_SDR_REPOSITORY_IN_UPDATE_MODE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_SDR_REPOSITORY_IN_UPDATE_MODE_STR);

    case IPMI_COMP_CODE_DEVICE_IN_FIRMWARE_UPDATE_MODE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_DEVICE_IN_FIRMWARE_UPDATE_MODE_STR);

    case IPMI_COMP_CODE_BMC_INITIALIZATION_IN_PROGRESS:
        SNPRINTF_RETURN (IPMI_COMP_CODE_BMC_INITIALIZATION_IN_PROGRESS_STR);

    case IPMI_COMP_CODE_DESTINATION_UNAVAILABLE:
        SNPRINTF_RETURN (IPMI_COMP_CODE_DESTINATION_UNAVAILABLE_STR);

    case IPMI_COMP_CODE_INSUFFICIENT_PRIVILEGE_LEVEL:
        SNPRINTF_RETURN (IPMI_COMP_CODE_INSUFFICIENT_PRIVILEGE_LEVEL_STR);

    case IPMI_COMP_CODE_REQUEST_PARAMETER_NOT_SUPPORTED:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUEST_PARAMETER_NOT_SUPPORTED_STR);

    case IPMI_COMP_CODE_REQUEST_PARAMETER_ILLEGAL:
        SNPRINTF_RETURN (IPMI_COMP_CODE_REQUEST_PARAMETER_ILLEGAL_STR);

    case IPMI_COMP_CODE_UNSPECIFIED_ERROR:
        SNPRINTF_RETURN (IPMI_COMP_CODE_UNSPECIFIED_ERROR_STR);
    }

    /* Device Specific OEM completion codes */
    if (IPMI_COMP_CODE_DEVICE_SPECIFIC_CODES (comp_code))
        SNPRINTF_RETURN ("Device specific (OEM) completion code %02Xh.", comp_code);

    /* Command specific completion codes */
    if (IPMI_COMP_CODE_COMMAND_SPECIFIC_CODES (comp_code))
    {
        if (!IPMI_NET_FN_VALID (netfn))
        {
            SET_ERRNO (EINVAL);
            return (-1);
        }

        switch (netfn)
        {
        case IPMI_NET_FN_CHASSIS_RQ:
        case IPMI_NET_FN_CHASSIS_RS:

            switch (cmd)
            {
            case IPMI_CMD_SET_SYSTEM_BOOT_OPTIONS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_BOOT_OPTIONS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_BOOT_OPTIONS_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_BOOT_OPTIONS_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_BOOT_OPTIONS_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_BOOT_OPTIONS_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_BOOT_OPTIONS_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_BOOT_OPTIONS_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_BOOT_OPTIONS_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_SYSTEM_BOOT_OPTIONS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_BOOT_OPTIONS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_BOOT_OPTIONS_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            }
            break;
        case IPMI_NET_FN_BRIDGE_RQ:
        case IPMI_NET_FN_BRIDGE_RS:
            break;

        case IPMI_NET_FN_SENSOR_EVENT_RQ:
        case IPMI_NET_FN_SENSOR_EVENT_RS:
            switch (cmd)
            {
            case IPMI_CMD_SET_PEF_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_PEF_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_PEF_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_PEF_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_PEF_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_SET_LAST_PROCESSED_EVENT_ID:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_LAST_PROCESSED_EVENT_ID_SEL_ERASE_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_LAST_PROCESSED_EVENT_ID_SEL_ERASE_IN_PROGRESS_STR);
                }
                break;

            case IPMI_CMD_GET_LAST_PROCESSED_EVENT_ID:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_LAST_PROCESSED_EVENT_ID_SEL_ERASE_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_LAST_PROCESSED_EVENT_ID_SEL_ERASE_IN_PROGRESS_STR);
                }
                break;
            case IPMI_CMD_ALERT_IMMEDIATE:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_ALERT_ALREADY_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ALERT_ALREADY_IN_PROGRESS_STR);

                case IPMI_COMP_CODE_ALERT_IPMI_MESSAGING_SESSION_ACTIVE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ALERT_IPMI_MESSAGING_SESSION_ACTIVE_STR);
                }
                break;
            case IPMI_CMD_SET_SENSOR_READING_AND_EVENT_STATUS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SENSOR_READING_OR_STATUS_NOT_SETTABLE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SENSOR_READING_OR_STATUS_NOT_SETTABLE_STR);

                case IPMI_COMP_CODE_EVENT_DATA_BYTES_NOT_SETTABLE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_EVENT_DATA_BYTES_NOT_SETTABLE_STR);
                }
                break;
            }
            break;

        case IPMI_NET_FN_APP_RQ:
        case IPMI_NET_FN_APP_RS:
            switch (cmd)
            {
            case IPMI_CMD_SET_COMMAND_ENABLES:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_COMMAND_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_COMMAND_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND_STR);
                }
                break;
            case IPMI_CMD_SET_COMMAND_SUB_FUNCTION_ENABLES:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_COMMAND_SUB_FUNCTION_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_COMMAND_SUB_FUNCTION_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND_STR);
                }
                break;
            case IPMI_CMD_GET_COMMAND_SUB_FUNCTION_ENABLES:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_COMMAND_SUB_FUNCTION_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_COMMAND_SUB_FUNCTION_ENABLES_ATTMPT_TO_ENABLE_AN_UNSUPPORTED_OR_UNCONFIGURABLE_COMMAND_STR);
                }
                break;
            case IPMI_CMD_RESET_WATCHDOG_TIMER:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_RESET_WATCHDOG_TIMER_ATTEMPT_TO_START_UNINITIALIZED_WATCHDOG:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_RESET_WATCHDOG_TIMER_ATTEMPT_TO_START_UNINITIALIZED_WATCHDOG_STR);
                }
                break;
            case IPMI_CMD_GET_MESSAGE:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_MESSAGE_DATA_NOT_AVAILABLE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_MESSAGE_DATA_NOT_AVAILABLE_STR);
                }
                break;
            case IPMI_CMD_SEND_MESSAGE:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SEND_MESSAGE_INVALID_SESSION_HANDLE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SEND_MESSAGE_INVALID_SESSION_HANDLE_STR);
                case IPMI_COMP_CODE_SEND_MESSAGE_LOST_ARBITRATION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SEND_MESSAGE_LOST_ARBITRATION_STR);
                case IPMI_COMP_CODE_SEND_MESSAGE_BUS_ERROR:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SEND_MESSAGE_BUS_ERROR_STR);
                case IPMI_COMP_CODE_SEND_MESSAGE_NAK_ON_WRITE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SEND_MESSAGE_NAK_ON_WRITE_STR);
                }
                break;
            case IPMI_CMD_SET_SYSTEM_INFO_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SYSTEM_INFO_PARAMETERS_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_SYSTEM_INFO_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_SYSTEM_INFO_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SYSTEM_INFO_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_GET_SESSION_CHALLENGE:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_SESSION_CHALLENGE_INVALID_USERNAME:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SESSION_CHALLENGE_INVALID_USERNAME_STR);
                case IPMI_COMP_CODE_GET_SESSION_CHALLENGE_NULL_USERNAME_NOT_ENABLED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SESSION_CHALLENGE_NULL_USERNAME_NOT_ENABLED_STR);
                }
                break;
            case IPMI_CMD_ACTIVATE_SESSION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SESSION_SLOT_AVAILABLE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SESSION_SLOT_AVAILABLE_STR);
                case IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SLOT_AVAILABLE_FOR_GIVEN_USER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SLOT_AVAILABLE_FOR_GIVEN_USER_STR);
                case IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SLOT_AVAILABLE_TO_SUPPORT_USER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_NO_SLOT_AVAILALBE_TO_SUPPORT_USER_STR);
                case IPMI_COMP_CODE_ACTIVATE_SESSION_SESSION_SEQ_NUM_OUT_OF_RANGE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_SESSION_SEQ_NUM_OUT_OF_RANGE_STR);
                case IPMI_COMP_CODE_ACTIVATE_SESSION_INVALID_SESSION_ID:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_INVALID_SESSION_ID_STR);
                case IPMI_COMP_CODE_ACTIVATE_SESSION_EXCEEDS_PRIVILEGE_LEVEL:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_SESSION_EXCEEDS_PRIVILEGE_LEVEL_STR);
                }
                break;
            case IPMI_CMD_SET_SESSION_PRIVILEGE_LEVEL:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_REQUESTED_LEVEL_NOT_AVAILABLE_FOR_USER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_REQUESTED_LEVEL_NOT_AVAILABLE_FOR_USER_STR);
                case IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_REQUESTED_LEVEL_EXCEEDS_USER_PRIVILEGE_LIMIT:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_REQUESTED_LEVEL_EXCEEDS_USER_PRIVILEGE_LIMIT_STR);
                case IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_CANNOT_DISABLE_USER_LEVEL_AUTHENTICATION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SESSION_PRIVILEGE_LEVEL_CANNOT_DISABLE_USER_LEVEL_AUTHENTICATION_STR);
                }
                break;
            case IPMI_CMD_CLOSE_SESSION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_CLOSE_SESSION_INVALID_SESSION_ID_IN_REQUEST:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_CLOSE_SESSION_INVALID_SESSION_ID_IN_REQUEST_STR);
                }
                break;
            case IPMI_CMD_SET_CHANNEL_ACCESS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_CHANNEL_ACCESS_SET_NOT_SUPPORTED_ON_SELECTED_CHANNEL:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_ACCESS_SET_NOT_SUPPORTED_ON_SELECTED_CHANNEL_STR);
                case IPMI_COMP_CODE_SET_CHANNEL_ACCESS_ACCESS_MODE_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_ACCESS_ACCESS_MODE_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_GET_CHANNEL_ACCESS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_CHANNEL_ACCESS_COMMAND_NOT_SUPPORTED_FOR_SELECTED_CHANNEL:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_CHANNEL_ACCESS_COMMAND_NOT_SUPPORTED_FOR_SELECTED_CHANNEL_STR);
                }
                break;
            case IPMI_CMD_SET_USER_PASSWORD_COMMAND:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_USER_PASSWORD_COMMAND_PASSWORD_TEST_FAILED_PASSWORD_SIZE_CORRECT:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_USER_PASSWORD_COMMAND_PASSWORD_TEST_FAILED_PASSWORD_SIZE_CORRECT_STR);
                case IPMI_COMP_CODE_SET_USER_PASSWORD_COMMAND_PASSWORD_TEST_FAILED_PASSWORD_SIZE_INCORRECT:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_USER_PASSWORD_COMMAND_PASSWORD_TEST_FAILED_PASSWORD_SIZE_INCORRECT_STR);
                }
                break;
            case IPMI_CMD_ACTIVATE_PAYLOAD:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_ALREADY_ACTIVE_ON_ANOTHER_SESSION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_ALREADY_ACTIVE_ON_ANOTHER_SESSION_STR);
                case IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_TYPE_IS_DISABLED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_TYPE_IS_DISABLED_STR);
                case IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_ACTIVATION_LIMIT_REACHED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_PAYLOAD_PAYLOAD_ACTIVATION_LIMIT_REACHED_STR);
                case IPMI_COMP_CODE_ACTIVATE_PAYLOAD_CANNOT_ACTIVATE_PAYLOAD_WITH_ENCRYPTION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_PAYLOAD_CANNOT_ACTIVATE_PAYLOAD_WITH_ENCRYPTION_STR);
                case IPMI_COMP_CODE_ACTIVATE_PAYLOAD_CANNOT_ACTIVATE_PAYLOAD_WITHOUT_ENCRYPTION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_ACTIVATE_PAYLOAD_CANNOT_ACTIVATE_PAYLOAD_WITHOUT_ENCRYPTION_STR);
                }
                break;
            case IPMI_CMD_DEACTIVATE_PAYLOAD:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_DEACTIVATE_PAYLOAD_PAYLOAD_ALREADY_DEACTIVATED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_DEACTIVATE_PAYLOAD_PAYLOAD_ALREADY_DEACTIVATED_STR);
                case IPMI_COMP_CODE_DEACTIVATE_PAYLOAD_PAYLOAD_TYPE_IS_DISABLED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_DEACTIVATE_PAYLOAD_PAYLOAD_TYPE_IS_DISABLED_STR);
                }
                break;
            case IPMI_CMD_GET_CHANNEL_PAYLOAD_VERSION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_CHANNEL_PAYLOAD_VERSION_PAYLOAD_TYPE_NOT_AVAILABLE_ON_GIVEN_CHANNEL:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_CHANNEL_PAYLOAD_VERSION_PAYLOAD_TYPE_NOT_AVAILABLE_ON_GIVEN_CHANNEL_STR);
                }
                break;
            case IPMI_CMD_GET_CHANNEL_OEM_PAYLOAD_INFO:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_CHANNEL_OEM_PAYLOAD_INFO_OEM_PAYLOAD_IANA_OR_PAYLOAD_ID_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_CHANNEL_OEM_PAYLOAD_INFO_OEM_PAYLOAD_IANA_OR_PAYLOAD_ID_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_MASTER_WRITE_READ:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_MASTER_WRITE_READ_LOST_ARBITRATION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_MASTER_WRITE_READ_LOST_ARBITRATION_STR);
                case IPMI_COMP_CODE_MASTER_WRITE_READ_BUS_ERROR:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_MASTER_WRITE_READ_BUS_ERROR_STR);
                case IPMI_COMP_CODE_MASTER_WRITE_READ_NAK_ON_WRITE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_MASTER_WRITE_READ_NAK_ON_WRITE_STR);
                case IPMI_COMP_CODE_MASTER_WRITE_READ_TRUNCATED_READ:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_MASTER_WRITE_READ_TRUNCATED_READ_STR);
                }
            case IPMI_CMD_SUSPEND_RESUME_PAYLOAD_ENCRYPTION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_OPERATION_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_OPERATION_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_OPERATION_NOT_ALLOWED_UNDER_PRESENT_CONFIGURATION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_OPERATION_NOT_ALLOWED_UNDER_PRESENT_CONFIGURATION_STR);
                case IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_ENCRYPTION_IS_NOT_AVAILABLE_FOR_SESSION:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_ENCRYPTION_IS_NOT_AVAILABLE_FOR_SESSION_STR);
                case IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_PAYLOAD_INSTANCE_NOT_PRESENTLY_ACTIVE:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SUSPEND_RESUME_PAYLOAD_ENCRYPTION_PAYLOAD_INSTANCE_NOT_PRESENTLY_ACTIVE_STR);
                }
                break;
            case IPMI_CMD_SET_CHANNEL_SECURITY_KEYS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_CANNOT_PERFORM_SET_CONFIRM_KEY_IS_LOCKED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_CANNOT_PERFORM_SET_CONFIRM_KEY_IS_LOCKED_STR);
                case IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_INSUFFICIENT_KEY_BYTES:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_INSUFFICIENT_KEY_BYTES_STR);
                case IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_TOO_MANY_KEY_BYTES:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_TOO_MANY_KEY_BYTES_STR);
                case IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_KEY_VALUE_DOES_NOT_MEET_CRITERIA:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_KEY_VALUE_DOES_NOT_MEET_CRITERIA_STR);
                case IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_KR_IS_NOT_USED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_CHANNEL_SECURITY_KEYS_KR_IS_NOT_USED_STR);
                }
                break;
            }
            break;

        case IPMI_NET_FN_FIRMWARE_RQ:
        case IPMI_NET_FN_FIRMWARE_RS:
            break;

        case IPMI_NET_FN_STORAGE_RQ:
        case IPMI_NET_FN_STORAGE_RS:
            switch(cmd)
            {
            case IPMI_CMD_READ_FRU_DATA:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_READ_FRU_DATA_FRU_DEVICE_BUSY:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_READ_FRU_DATA_FRU_DEVICE_BUSY_STR);
                }
                break;
            case IPMI_CMD_WRITE_FRU_DATA:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_WRITE_FRU_DATA_WRITE_PROTECTED_OFFSET:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_WRITE_FRU_DATA_WRITE_PROTECTED_OFFSET_STR);
                case IPMI_COMP_CODE_WRITE_FRU_DATA_FRU_DEVICE_BUSY:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_WRITE_FRU_DATA_FRU_DEVICE_BUSY_STR);
                }
                break;
            case IPMI_CMD_GET_SEL_ENTRY:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_SEL_ENTRY_SEL_ERASE_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SEL_ENTRY_SEL_ERASE_IN_PROGRESS_STR);
                }
                break;
            case IPMI_CMD_DELETE_SEL_ENTRY:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_DELETE_SEL_ENTRY_SEL_OPERATION_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_DELETE_SEL_ENTRY_SEL_OPERATION_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_DELETE_SEL_ENTRY_SEL_ERASE_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_DELETE_SEL_ENTRY_SEL_ERASE_IN_PROGRESS_STR);
                }
                break;
            }
            break;

        case IPMI_NET_FN_TRANSPORT_RQ:
        case IPMI_NET_FN_TRANSPORT_RS:
            switch (cmd)
            {
            case IPMI_CMD_SET_SOL_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SOL_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_SOL_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_SOL_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SOL_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_SET_LAN_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_LAN_CONFIGURATION_PARAMETERS_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_LAN_CONFIGURATION_PARAMETERS:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_LAN_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_LAN_CONFIGURATION_PARAMETERS_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            case IPMI_CMD_SET_SERIAL_MODEM_CONFIGURATION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_PARAMETER_NOT_SUPPORTED_STR);
                case IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_INVALID_SET_IN_PROGRESS:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_INVALID_SET_IN_PROGRESS_STR);
                case IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_WRITE_READ_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_WRITE_READ_ONLY_PARAMETER_STR);
                case IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_READ_WRITE_ONLY_PARAMETER:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_SET_SERIAL_MODEM_CONFIGURATION_READ_WRITE_ONLY_PARAMETER_STR);
                }
                break;
            case IPMI_CMD_GET_SERIAL_MODEM_CONFIGURATION:
                switch (comp_code)
                {
                case IPMI_COMP_CODE_GET_SERIAL_MODEM_CONFIGURATION_PARAMETER_NOT_SUPPORTED:
                    SNPRINTF_RETURN (IPMI_COMP_CODE_GET_SERIAL_MODEM_CONFIGURATION_PARAMETER_NOT_SUPPORTED_STR);
                }
                break;
            }
            break;

        default:
            SET_ERRNO (EINVAL);
            return (-1);
        }

        SNPRINTF_RETURN ("No error message found for command "
                         "%02Xh, network function %02Xh, and completion code %02Xh.  "
                         "Please report to <*****@*****.**>",
                         cmd,
                         netfn,
                         comp_code);
    }

    SNPRINTF_RETURN ("Unknown completion code %02Xh for command %02Xh and network function %02Xh.",
                     comp_code,
                     cmd,
                     netfn);
}