blob: e8e46a5fabe7400f402a45700ae501b04ad0fee1 [file] [log] [blame]
Chris Austenac4604a2015-10-13 12:43:27 -05001#ifndef __HOST_IPMI_SEN_HANDLER_H__
2#define __HOST_IPMI_SEN_HANDLER_H__
3
Chris Austen0012e9b2015-10-22 01:37:46 -05004#include <stdint.h>
5
Chris Austenac4604a2015-10-13 12:43:27 -05006// IPMI commands for net functions.
7enum ipmi_netfn_sen_cmds
8{
Chris Austen10ccc0f2015-12-10 18:27:04 -06009 IPMI_CMD_GET_SENSOR_READING = 0x2D,
Chris Austenac4604a2015-10-13 12:43:27 -050010 IPMI_CMD_GET_SENSOR_TYPE = 0x2F,
11 IPMI_CMD_SET_SENSOR = 0x30,
Chris Austenac4604a2015-10-13 12:43:27 -050012};
13
Chris Austen0012e9b2015-10-22 01:37:46 -050014#define MAX_DBUS_PATH 128
15struct dbus_interface_t {
16 uint8_t sensornumber;
17 uint8_t sensortype;
18
19 char bus[MAX_DBUS_PATH];
20 char path[MAX_DBUS_PATH];
21 char interface[MAX_DBUS_PATH];
22};
Tomd700e762016-09-20 18:24:13 +053023
24int set_sensor_dbus_state_s(uint8_t , const char *, const char *);
25int set_sensor_dbus_state_y(uint8_t , const char *, const uint8_t);
26int find_openbmc_path(const char *, const uint8_t , dbus_interface_t *);
Chris Austenac4604a2015-10-13 12:43:27 -050027#endif