OpenBIC
OpenSource Bridge-IC
plat_class.c File Reference
#include <stdio.h>
#include <logging/log.h>
#include "libutil.h"
#include "plat_class.h"
Include dependency graph for plat_class.c:

Functions

 LOG_MODULE_REGISTER (plat_class)
 
bool get_adc_voltage (int channel, float *voltage)
 
uint8_t get_board_revision ()
 
int init_platform_config ()
 

Variables

struct adc_info adc [NUMBER_OF_ADC_CHANNEL]
 
struct board_rev_mappting_table board_rev_table []
 

Function Documentation

◆ get_adc_voltage()

bool get_adc_voltage ( int  channel,
float *  voltage 
)

◆ get_board_revision()

uint8_t get_board_revision ( )

◆ init_platform_config()

int init_platform_config ( )
Here is the call graph for this function:

◆ LOG_MODULE_REGISTER()

LOG_MODULE_REGISTER ( plat_class  )

Variable Documentation

◆ adc

Initial value:
= {
{ 0x10, 0 }, { 0x10, 16 }, { 0x14, 0 }, { 0x14, 16 }, { 0x18, 0 }, { 0x18, 16 },
{ 0x1C, 0 }, { 0x1C, 16 }, { 0x110, 0 }, { 0x110, 16 }, { 0x114, 0 }, { 0x114, 16 },
{ 0x118, 0 }, { 0x118, 16 }, { 0x11C, 0 }, { 0x11C, 16 }
}

◆ board_rev_table

struct board_rev_mappting_table board_rev_table[]
Initial value:
= {
{ 1.25, 0.05, BOARD_POC },
{ 0.75, 0.05, BOARD_POC2 },
{ 1.5, 0.05, BOARD_EVT },
{ 1.0, 0.1, BOARD_DVT },
{ 0.5, 0.05, BOARD_PVT },
{ 0.0, 0.05, BOARD_MP },
}
@ BOARD_PVT
Definition: plat_class.h:37
@ BOARD_EVT
Definition: plat_class.h:35
@ BOARD_MP
Definition: plat_class.h:38
@ BOARD_DVT
Definition: plat_class.h:36
@ BOARD_POC2
Definition: plat_class.h:34
@ BOARD_POC
Definition: plat_class.h:33