OpenBIC
OpenSource Bridge-IC
plat_pldm_monitor.c File Reference
#include <logging/log.h>
#include "sensor.h"
#include "hal_gpio.h"
#include "pldm.h"
#include "pmbus.h"
#include "plat_fru.h"
#include "plat_gpio.h"
#include "plat_pldm_monitor.h"
#include "plat_class.h"
#include "plat_led.h"
#include "plat_mctp.h"
Include dependency graph for plat_pldm_monitor.c:

Classes

struct  ssd_event_check
 

Macros

#define PLDM_OEM_ENTITY_LED   8192
 
#define PLDM_OEM_ENTITY_SSD_LED   8193
 
#define PLDM_OEM_ENTITY_NIC_TYPE   8194
 

Functions

 LOG_MODULE_REGISTER (plat_pldm_monitor)
 
void ssd_alert_check_ina230 (uint8_t idx, uint8_t *flag)
 
void ssd_alert_check_isl28022 (uint8_t idx, uint8_t *flag)
 
void ssd_alert_check_handler (struct k_work *work)
 
void ssd_alert_check (uint8_t group)
 
void ssd_present_check ()
 
void nic_present_check ()
 
void vr_status_mfr_specific_check_handler (struct k_work *work)
 
void vr_alert_check ()
 
uint8_t plat_pldm_set_state_effecter_state_handler (const uint8_t *buf, uint16_t len, uint8_t *resp, uint16_t *resp_len, struct pldm_state_effecter_info *info_p)
 
uint8_t plat_pldm_get_state_effecter_state_handler (const uint8_t *buf, uint16_t len, uint8_t *resp, uint16_t *resp_len, struct pldm_state_effecter_info *info_p)
 
void plat_pldm_load_state_effecter_table (void)
 

Variables

struct pldm_state_effecter_info plat_state_effecter_table []
 
uint8_t e1s_prsnt_pin [4][4]
 
uint8_t nic_prsnt_pin []
 
uint8_t pex_sensor_num_table []
 
uint8_t nic_power_ic_sensor_table []
 
uint8_t pex_1v25_power_ic_sensor_table []
 
uint8_t ssd_power_ic_sensor_table []
 
uint8_t e1s_sensor_table [SSD_MAX_NUMBER]
 

Macro Definition Documentation

◆ PLDM_OEM_ENTITY_LED

#define PLDM_OEM_ENTITY_LED   8192

◆ PLDM_OEM_ENTITY_NIC_TYPE

#define PLDM_OEM_ENTITY_NIC_TYPE   8194

◆ PLDM_OEM_ENTITY_SSD_LED

#define PLDM_OEM_ENTITY_SSD_LED   8193

Function Documentation

◆ LOG_MODULE_REGISTER()

LOG_MODULE_REGISTER ( plat_pldm_monitor  )

◆ nic_present_check()

void nic_present_check ( )
Here is the call graph for this function:

◆ plat_pldm_get_state_effecter_state_handler()

uint8_t plat_pldm_get_state_effecter_state_handler ( const uint8_t *  buf,
uint16_t  len,
uint8_t *  resp,
uint16_t *  resp_len,
struct pldm_state_effecter_info info_p 
)
Here is the call graph for this function:

◆ plat_pldm_load_state_effecter_table()

void plat_pldm_load_state_effecter_table ( void  )

◆ plat_pldm_set_state_effecter_state_handler()

uint8_t plat_pldm_set_state_effecter_state_handler ( const uint8_t *  buf,
uint16_t  len,
uint8_t *  resp,
uint16_t *  resp_len,
struct pldm_state_effecter_info info_p 
)
Here is the call graph for this function:

◆ ssd_alert_check()

void ssd_alert_check ( uint8_t  group)

◆ ssd_alert_check_handler()

void ssd_alert_check_handler ( struct k_work *  work)

◆ ssd_alert_check_ina230()

void ssd_alert_check_ina230 ( uint8_t  idx,
uint8_t *  flag 
)
Here is the call graph for this function:

◆ ssd_alert_check_isl28022()

void ssd_alert_check_isl28022 ( uint8_t  idx,
uint8_t *  flag 
)
Here is the call graph for this function:

◆ ssd_present_check()

void ssd_present_check ( )
Here is the call graph for this function:

◆ vr_alert_check()

void vr_alert_check ( )
Here is the call graph for this function:

◆ vr_status_mfr_specific_check_handler()

void vr_status_mfr_specific_check_handler ( struct k_work *  work)

Get PMBUS_STATUS_MFR_SPECIFIC

Clear faults when bit ADCUNLOCK or BBEVENT is high

Here is the call graph for this function:

Variable Documentation

◆ e1s_prsnt_pin

uint8_t e1s_prsnt_pin[4][4]
Initial value:
= {
{ PRSNT_SSD0_R_N, PRSNT_SSD1_R_N, PRSNT_SSD2_R_N, PRSNT_SSD3_R_N },
{ PRSNT_SSD4_R_N, PRSNT_SSD5_R_N, PRSNT_SSD6_R_N, PRSNT_SSD7_R_N },
{ PRSNT_SSD8_R_N, PRSNT_SSD9_R_N, PRSNT_SSD10_R_N, PRSNT_SSD11_R_N },
{ PRSNT_SSD12_R_N, PRSNT_SSD13_R_N, PRSNT_SSD14_R_N, PRSNT_SSD15_R_N },
}

◆ e1s_sensor_table

uint8_t e1s_sensor_table[SSD_MAX_NUMBER]
Initial value:
= {
}
#define SENSOR_NUM_TEMP_E1S_1
Definition: plat_sensor_table.h:43
#define SENSOR_NUM_TEMP_E1S_4
Definition: plat_sensor_table.h:46
#define SENSOR_NUM_TEMP_E1S_3
Definition: plat_sensor_table.h:45
#define SENSOR_NUM_TEMP_E1S_2
Definition: plat_sensor_table.h:44
#define SENSOR_NUM_TEMP_E1S_7
Definition: plat_sensor_table.h:227
#define SENSOR_NUM_TEMP_E1S_12
Definition: plat_sensor_table.h:252
#define SENSOR_NUM_TEMP_E1S_11
Definition: plat_sensor_table.h:247
#define SENSOR_NUM_TEMP_E1S_10
Definition: plat_sensor_table.h:242
#define SENSOR_NUM_TEMP_E1S_14
Definition: plat_sensor_table.h:262
#define SENSOR_NUM_TEMP_E1S_5
Definition: plat_sensor_table.h:217
#define SENSOR_NUM_TEMP_E1S_8
Definition: plat_sensor_table.h:232
#define SENSOR_NUM_TEMP_E1S_13
Definition: plat_sensor_table.h:257
#define SENSOR_NUM_TEMP_E1S_9
Definition: plat_sensor_table.h:237
#define SENSOR_NUM_TEMP_E1S_15
Definition: plat_sensor_table.h:267
#define SENSOR_NUM_TEMP_E1S_0
Definition: plat_sensor_table.h:192
#define SENSOR_NUM_TEMP_E1S_6
Definition: plat_sensor_table.h:222

◆ nic_power_ic_sensor_table

uint8_t nic_power_ic_sensor_table[]
Initial value:
= {
}
#define SENSOR_NUM_VOLT_NIC_4
Definition: plat_sensor_table.h:111
#define SENSOR_NUM_VOLT_NIC_2
Definition: plat_sensor_table.h:101
#define SENSOR_NUM_VOLT_NIC_3
Definition: plat_sensor_table.h:106
#define SENSOR_NUM_VOLT_NIC_6
Definition: plat_sensor_table.h:121
#define SENSOR_NUM_VOLT_NIC_0
Definition: plat_sensor_table.h:91
#define SENSOR_NUM_VOLT_NIC_5
Definition: plat_sensor_table.h:116
#define SENSOR_NUM_VOLT_NIC_1
Definition: plat_sensor_table.h:96
#define SENSOR_NUM_VOLT_NIC_7
Definition: plat_sensor_table.h:126

◆ nic_prsnt_pin

uint8_t nic_prsnt_pin[]
Initial value:
= {
PRSNT_NIC0_R_N, PRSNT_NIC1_R_N, PRSNT_NIC2_R_N, PRSNT_NIC3_R_N,
PRSNT_NIC4_R_N, PRSNT_NIC5_R_N, PRSNT_NIC6_R_N, PRSNT_NIC7_R_N,
}

◆ pex_1v25_power_ic_sensor_table

uint8_t pex_1v25_power_ic_sensor_table[]
Initial value:
= {
}
#define SENSOR_NUM_P1V25_VOLT_PEX_0
Definition: plat_sensor_table.h:149
#define SENSOR_NUM_P1V25_VOLT_PEX_1
Definition: plat_sensor_table.h:157
#define SENSOR_NUM_P1V25_VOLT_PEX_2
Definition: plat_sensor_table.h:165
#define SENSOR_NUM_P1V25_VOLT_PEX_3
Definition: plat_sensor_table.h:173

◆ pex_sensor_num_table

uint8_t pex_sensor_num_table[]
Initial value:
= {
}
#define SENSOR_NUM_TEMP_PEX_0
Definition: plat_sensor_table.h:60
#define SENSOR_NUM_TEMP_PEX_1
Definition: plat_sensor_table.h:61
#define SENSOR_NUM_TEMP_PEX_2
Definition: plat_sensor_table.h:183
#define SENSOR_NUM_TEMP_PEX_3
Definition: plat_sensor_table.h:184

◆ plat_state_effecter_table

struct pldm_state_effecter_info plat_state_effecter_table[]

◆ ssd_power_ic_sensor_table

uint8_t ssd_power_ic_sensor_table[]
Initial value:
= {
}
#define SENSOR_NUM_VOLT_E1S_9
Definition: plat_sensor_table.h:238
#define SENSOR_NUM_VOLT_E1S_4
Definition: plat_sensor_table.h:213
#define SENSOR_NUM_VOLT_E1S_0
Definition: plat_sensor_table.h:193
#define SENSOR_NUM_VOLT_E1S_15
Definition: plat_sensor_table.h:268
#define SENSOR_NUM_VOLT_E1S_1
Definition: plat_sensor_table.h:198
#define SENSOR_NUM_VOLT_E1S_13
Definition: plat_sensor_table.h:258
#define SENSOR_NUM_VOLT_E1S_11
Definition: plat_sensor_table.h:248
#define SENSOR_NUM_VOLT_E1S_8
Definition: plat_sensor_table.h:233
#define SENSOR_NUM_VOLT_E1S_3
Definition: plat_sensor_table.h:208
#define SENSOR_NUM_VOLT_E1S_14
Definition: plat_sensor_table.h:263
#define SENSOR_NUM_VOLT_E1S_12
Definition: plat_sensor_table.h:253
#define SENSOR_NUM_VOLT_E1S_10
Definition: plat_sensor_table.h:243
#define SENSOR_NUM_VOLT_E1S_5
Definition: plat_sensor_table.h:218
#define SENSOR_NUM_VOLT_E1S_6
Definition: plat_sensor_table.h:223
#define SENSOR_NUM_VOLT_E1S_7
Definition: plat_sensor_table.h:228
#define SENSOR_NUM_VOLT_E1S_2
Definition: plat_sensor_table.h:203