/usr/include/freeipmi/api/ipmi-sensor-cmds-api.h is in libfreeipmi-dev 1.1.5-3ubuntu3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 | /*
* Copyright (C) 2003-2012 FreeIPMI Core Team
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
#ifndef _IPMI_SENSOR_CMDS_API_H
#define _IPMI_SENSOR_CMDS_API_H
#ifdef __cplusplus
extern "C" {
#endif
#include <stdint.h>
#include <freeipmi/api/ipmi-api.h>
#include <freeipmi/fiid/fiid.h>
/*
* ipmi_cmd* functions return 0 on success, -1 on error.
*
* obj_cmd_rs must be for the function's respective fiid template
* response.
*
*/
/* achu: as of IPMI 2.0 hysteresis_mask reserved for future - write as 0xFF */
int ipmi_cmd_set_sensor_hysteresis (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t hysteresis_mask,
uint8_t positive_going_threshold_hysteresis_value,
uint8_t negative_going_threshold_hysteresis_value,
fiid_obj_t obj_cmd_rs);
/* achu: as of IPMI 2.0 hysteresis_mask reserved for future - write as 0xFF */
int ipmi_cmd_get_sensor_hysteresis (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t hysteresis_mask,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_set_sensor_thresholds (ipmi_ctx_t ctx,
uint8_t sensor_number,
const uint8_t *lower_non_critical_threshold,
const uint8_t *lower_critical_threshold,
const uint8_t *lower_non_recoverable_threshold,
const uint8_t *upper_non_critical_threshold,
const uint8_t *upper_critical_threshold,
const uint8_t *upper_non_recoverable_threshold,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_thresholds (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_set_sensor_event_enable (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t event_message_action,
uint8_t scanning_on_this_sensor,
uint8_t all_event_messages,
uint16_t assertion_event_bitmask,
uint16_t deassertion_event_bitmask,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_set_sensor_event_enable_threshold (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t event_message_action,
uint8_t scanning_on_this_sensor,
uint8_t all_event_messages,
uint8_t assertion_event_lower_non_critical_going_low,
uint8_t assertion_event_lower_non_critical_going_high,
uint8_t assertion_event_lower_critical_going_low,
uint8_t assertion_event_lower_critical_going_high,
uint8_t assertion_event_lower_non_recoverable_going_low,
uint8_t assertion_event_lower_non_recoverable_going_high,
uint8_t assertion_event_upper_non_critical_going_low,
uint8_t assertion_event_upper_non_critical_going_high,
uint8_t assertion_event_upper_critical_going_low,
uint8_t assertion_event_upper_critical_going_high,
uint8_t assertion_event_upper_non_recoverable_going_low,
uint8_t assertion_event_upper_non_recoverable_going_high,
uint8_t deassertion_event_lower_non_critical_going_low,
uint8_t deassertion_event_lower_non_critical_going_high,
uint8_t deassertion_event_lower_critical_going_low,
uint8_t deassertion_event_lower_critical_going_high,
uint8_t deassertion_event_lower_non_recoverable_going_low,
uint8_t deassertion_event_lower_non_recoverable_going_high,
uint8_t deassertion_event_upper_non_critical_going_low,
uint8_t deassertion_event_upper_non_critical_going_high,
uint8_t deassertion_event_upper_critical_going_low,
uint8_t deassertion_event_upper_critical_going_high,
uint8_t deassertion_event_upper_non_recoverable_going_low,
uint8_t deassertion_event_upper_non_recoverable_going_high,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_set_sensor_event_enable_discrete (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t event_message_action,
uint8_t scanning_on_this_sensor,
uint8_t all_event_messages,
uint8_t assertion_event_state_bit_0,
uint8_t assertion_event_state_bit_1,
uint8_t assertion_event_state_bit_2,
uint8_t assertion_event_state_bit_3,
uint8_t assertion_event_state_bit_4,
uint8_t assertion_event_state_bit_5,
uint8_t assertion_event_state_bit_6,
uint8_t assertion_event_state_bit_7,
uint8_t assertion_event_state_bit_8,
uint8_t assertion_event_state_bit_9,
uint8_t assertion_event_state_bit_10,
uint8_t assertion_event_state_bit_11,
uint8_t assertion_event_state_bit_12,
uint8_t assertion_event_state_bit_13,
uint8_t assertion_event_state_bit_14,
uint8_t deassertion_event_state_bit_0,
uint8_t deassertion_event_state_bit_1,
uint8_t deassertion_event_state_bit_2,
uint8_t deassertion_event_state_bit_3,
uint8_t deassertion_event_state_bit_4,
uint8_t deassertion_event_state_bit_5,
uint8_t deassertion_event_state_bit_6,
uint8_t deassertion_event_state_bit_7,
uint8_t deassertion_event_state_bit_8,
uint8_t deassertion_event_state_bit_9,
uint8_t deassertion_event_state_bit_10,
uint8_t deassertion_event_state_bit_11,
uint8_t deassertion_event_state_bit_12,
uint8_t deassertion_event_state_bit_13,
uint8_t deassertion_event_state_bit_14,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_event_enable (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_event_enable_threshold (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_event_enable_discrete (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_re_arm_sensor_events (ipmi_ctx_t ctx,
uint8_t sensor_number,
uint8_t re_arm_all_event_status_from_this_sensor,
uint16_t *re_arm_assertion_event,
uint16_t *re_arm_deassertion_event,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_re_arm_sensor_events_ipmb (ipmi_ctx_t ctx,
uint8_t channel_number,
uint8_t slave_address,
uint8_t lun,
uint8_t sensor_number,
uint8_t re_arm_all_event_status_from_this_sensor,
uint16_t *re_arm_assertion_event,
uint16_t *re_arm_deassertion_event,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_reading (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_reading_ipmb (ipmi_ctx_t ctx,
uint8_t channel_number,
uint8_t slave_address,
uint8_t lun,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_reading_threshold (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
int ipmi_cmd_get_sensor_reading_discrete (ipmi_ctx_t ctx,
uint8_t sensor_number,
fiid_obj_t obj_cmd_rs);
#ifdef __cplusplus
}
#endif
#endif /* ipmi-sensor-cmds-api.h */
|