OpenBIC
OpenSource Bridge-IC
plat_hook.c File Reference
#include <logging/log.h>
#include <drivers/peci.h>
#include "sensor.h"
#include "intel_peci.h"
#include "intel_dimm.h"
#include "power_status.h"
#include "i2c-mux-tca9548.h"
#include "libutil.h"
#include "hal_peci.h"
#include "plat_hook.h"
#include "plat_sensor_table.h"
#include "plat_gpio.h"
#include "plat_isr.h"
#include "pmbus.h"
Include dependency graph for plat_hook.c:

Macros

#define ADJUST_P0V85_VOLTAGE(x)   (x * 1.01)
 

Functions

 LOG_MODULE_REGISTER (plat_hook)
 
bool pre_vr_read (sensor_cfg *cfg, void *args)
 
bool post_vr_read (sensor_cfg *cfg, void *args, int *const reading)
 
bool post_p085v_voltage_read (sensor_cfg *cfg, void *args, int *reading)
 
bool post_adc128d818_read (sensor_cfg *cfg, void *args, int *reading)
 

Variables

adc_asd_init_arg ast_adc_init_args []
 
ina233_init_arg ina233_init_args []
 
rtq6056_init_arg rtq6056_init_args []
 
vr_pre_read_arg vr_pre_read_args []
 
max11617_init_arg max11617_init_args []
 
adc128d818_init_arg adc128d818_init_args []
 
vistara_init_arg vistara_init_args []
 

Macro Definition Documentation

◆ ADJUST_P0V85_VOLTAGE

#define ADJUST_P0V85_VOLTAGE (   x)    (x * 1.01)

Function Documentation

◆ LOG_MODULE_REGISTER()

LOG_MODULE_REGISTER ( plat_hook  )

◆ post_adc128d818_read()

bool post_adc128d818_read ( sensor_cfg cfg,
void *  args,
int *  reading 
)

◆ post_p085v_voltage_read()

bool post_p085v_voltage_read ( sensor_cfg cfg,
void *  args,
int *  reading 
)

◆ post_vr_read()

bool post_vr_read ( sensor_cfg cfg,
void *  args,
int *const  reading 
)
Here is the call graph for this function:

◆ pre_vr_read()

bool pre_vr_read ( sensor_cfg cfg,
void *  args 
)
Here is the call graph for this function:

Variable Documentation

◆ adc128d818_init_args

adc128d818_init_arg adc128d818_init_args[]
Initial value:
= {
[0] = {
.is_init = false,
.external_vref = false,
.scalefactor[0] = 2,
.scalefactor[1] = 2,
.scalefactor[2] = 1,
.scalefactor[3] = 1,
.scalefactor[4] = 1,
.scalefactor[5] = 1,
.scalefactor[6] = 1,
},
}

◆ ast_adc_init_args

adc_asd_init_arg ast_adc_init_args[]
Initial value:
= {
[0] = { .is_init = false,
.deglitch[0] = { .deglitch_en = false,},
.deglitch[1] = { .deglitch_en = false,},
.deglitch[2] = { .deglitch_en = false,},
.deglitch[3] = { .deglitch_en = false,},
.deglitch[4] = { .deglitch_en = false,},
.deglitch[5] = { .deglitch_en = false,},
.deglitch[6] = { .deglitch_en = false,},
.deglitch[7] = { .deglitch_en = false,},
},
[1] = {
.is_init = false,
.deglitch[0] = { .deglitch_en = false,},
.deglitch[1] = { .deglitch_en = false,},
.deglitch[2] = { .deglitch_en = false,},
.deglitch[3] = { .deglitch_en = false,},
}
}

◆ ina233_init_args

ina233_init_arg ina233_init_args[]
Initial value:
= {
[0] = {
.is_init = false,
.current_lsb = 0.001,
.r_shunt = 0.005,
.mfr_config_init = false,
.is_need_mfr_device_config_init = false,
.is_need_set_alert_threshold = false,
},
[1] = {
.is_init = false,
.current_lsb = 0.001,
.r_shunt = 0.005,
.mfr_config_init = false,
.is_need_mfr_device_config_init = false,
.is_need_set_alert_threshold = false,
},
}

◆ max11617_init_args

max11617_init_arg max11617_init_args[]
Initial value:
= {
[0] = {
.is_init = false,
.setup_byte = 0xd2,
.scalefactor[0] = 2,
.scalefactor[1] = 2,
.scalefactor[2] = 1,
.scalefactor[3] = 1,
.scalefactor[4] = 1,
.scalefactor[5] = 1,
.scalefactor[6] = 1,
},
}

◆ rtq6056_init_args

rtq6056_init_arg rtq6056_init_args[]
Initial value:
= {
[0] = {
.is_init = false,
.current_lsb = 0.001,
.r_shunt = 0.005,
},
[1] = {
.is_init = false,
.current_lsb = 0.001,
.r_shunt = 0.005,
},
}

◆ vistara_init_args

vistara_init_arg vistara_init_args[]
Initial value:
= {
[0] = {true,},
}

◆ vr_pre_read_args

vr_pre_read_arg vr_pre_read_args[]
Initial value:
= {
[0] = { 0x0 },
[1] = { 0x1 },
}