OpenBIC
OpenSource Bridge-IC
plat_class.h File Reference
#include <stdbool.h>
#include <stdint.h>
Include dependency graph for plat_class.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  _CARD_STATUS_
 

Macros

#define SYS_CLASS_1   1
 
#define SYS_CLASS_2   2
 
#define CPLD_ADDR   0x21
 
#define CPLD_CLASS_TYPE_REG   0x0D
 
#define CPLD_1OU_VPP_POWER_STATUS   0x11
 
#define CPLD_2OU_EXPANSION_CARD_REG   0x13
 
#define MAX_1OU_M2_COUNT   4
 

Typedefs

typedef struct _CARD_STATUS_ CARD_STATUS
 

Enumerations

enum  _1OU_CARD_TYPE_ {
  TYPE_1OU_SI_TEST_CARD = 0x0 , TYPE_1OU_EXP_WITH_6_M2 , TYPE_1OU_RAINBOW_FALLS , TYPE_1OU_VERNAL_FALLS_WITH_TI ,
  TYPE_1OU_VERNAL_FALLS_WITH_AST , TYPE_1OU_EXP_WITH_NIC = 0x07 , TYPE_1OU_ABSENT = 0xFE , TYPE_1OU_UNKNOWN = 0xFF ,
  TYPE_1OU_SI_TEST_CARD = 0x0 , TYPE_1OU_EXP_WITH_6_M2 , TYPE_1OU_RAINBOW_FALLS , TYPE_1OU_VERNAL_FALLS_WITH_TI ,
  TYPE_1OU_VERNAL_FALLS_WITH_AST , TYPE_1OU_KAHUNA_FALLS , TYPE_1OU_WAIMANO_FALLS , TYPE_1OU_EXP_WITH_NIC ,
  TYPE_1OU_ABSENT = 0xFE , TYPE_1OU_UNKNOWN = 0xFF , TYPE_1OU_SI_TEST_CARD = 0x0 , TYPE_1OU_EXP_WITH_6_M2 ,
  TYPE_1OU_RAINBOW_FALLS , TYPE_1OU_VERNAL_FALLS_WITH_TI , TYPE_1OU_VERNAL_FALLS_WITH_AST , TYPE_1OU_KAHUNA_FALLS ,
  TYPE_1OU_WAIMANO_FALLS , TYPE_1OU_EXP_WITH_NIC , TYPE_1OU_OLMSTED_POINT , TYPE_1OU_NIAGARA_FALLS = 0x09 ,
  TYPE_1OU_EXP_WITH_E1S , TYPE_1OU_ABSENT = 0xFE , TYPE_1OU_UNKNOWN = 0xFF , TYPE_1OU_SI_TEST_CARD = 0x0 ,
  TYPE_1OU_EXP_WITH_6_M2 , TYPE_1OU_RAINBOW_FALLS , TYPE_1OU_VERNAL_FALLS_WITH_TI , TYPE_1OU_VERNAL_FALLS_WITH_AST ,
  TYPE_1OU_KAHUNA_FALLS , TYPE_1OU_WAIMANO_FALLS , TYPE_1OU_EXP_WITH_NIC , TYPE_1OU_EXP_WITH_E1S ,
  TYPE_1OU_ABSENT = 0xFE , TYPE_1OU_UNKNOWN = 0xFF , TYPE_1OU_SI_TEST_CARD = 0x0 , TYPE_1OU_EXP_WITH_6_M2 ,
  TYPE_1OU_RAINBOW_FALLS , TYPE_1OU_VERNAL_FALLS_WITH_TI , TYPE_1OU_VERNAL_FALLS_WITH_AST , TYPE_1OU_KAHUNA_FALLS ,
  TYPE_1OU_WAIMANO_FALLS , TYPE_1OU_EXP_WITH_NIC , TYPE_1OU_EXP_WITH_E1S , TYPE_1OU_ABSENT = 0xFE ,
  TYPE_1OU_UNKNOWN = 0xFF , TYPE_1OU_SI_TEST_CARD = 0x0 , TYPE_1OU_EXP_WITH_6_M2 , TYPE_1OU_RAINBOW_FALLS ,
  TYPE_1OU_VERNAL_FALLS_WITH_TI , TYPE_1OU_VERNAL_FALLS_WITH_AST , TYPE_1OU_KAHUNA_FALLS , TYPE_1OU_WAIMANO_FALLS ,
  TYPE_1OU_EXP_WITH_NIC , TYPE_1OU_ABSENT = 0xFE , TYPE_1OU_UNKNOWN = 0xFF
}
 
enum  _2OU_CARD_TYPE_ {
  TYPE_2OU_EXP = 0x1 , TYPE_2OU_EXP_E1S = 0x2 , TYPE_2OU_HSM = 0x6 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF , TYPE_2OU_DPV2_8 = 0x07 , TYPE_2OU_DPV2_16 = 0x70 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF , TYPE_2OU_DPV2_8 = 0x07 , TYPE_2OU_DPV2_16 = 0x70 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF , TYPE_2OU_DPV2_8 = 0x07 , TYPE_2OU_DPV2_16 = 0x70 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF , TYPE_2OU_DPV2_8 = 0x07 , TYPE_2OU_DPV2_16 = 0x70 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF , TYPE_2OU_DPV2_8 = 0x07 , TYPE_2OU_DPV2_16 = 0x70 , TYPE_2OU_ABSENT = 0xFE ,
  TYPE_2OU_UNKNOWN = 0xFF
}
 
enum  HSC_MODULE {
  HSC_MODULE_ADM1272 , HSC_MODULE_XDP710 , HSC_MODULE_UNKNOWN , HSC_MODULE_ADM1272 ,
  HSC_MODULE_LTC4286 , HSC_MODULE_UNKNOWN = 0xFF , HSC_MODULE_ADM1278 , HSC_MODULE_LTC4282 ,
  HSC_MODULE_MP5990 , HSC_MODULE_ADM1276 , HSC_MODULE_UNKNOWN = 0xFF , HSC_MODULE_ADM1278 ,
  HSC_MODULE_LTC4282 , HSC_MODULE_MP5990 , HSC_MODULE_LTC4286 = 0x04 , HSC_MODULE_UNKNOWN = 0xFF ,
  HSC_MODULE_ADM1278 = 0b00 , HSC_MODULE_MP5990 = 0b01 , HSC_MODULE_UNKNOWN , HSC_MODULE_ADM1278 = 0b00 ,
  HSC_MODULE_LTC4282 = 0b01 , HSC_MODULE_MP5990 = 0b10 , HSC_MODULE_UNKNOWN , HSC_MODULE_ADM1278 = 0b00 ,
  HSC_MODULE_LTC4282 = 0b01 , HSC_MODULE_MP5990 = 0b10 , HSC_MODULE_UNKNOWN , HSC_MODULE_MP5990 ,
  HSC_MODULE_RS31380R , HSC_MODULE_UNKNOWN = 0xFF
}
 
enum  BIC_CARD_PRESENT {
  CARD_UNPRESENT = false , CARD_PRESENT = true , CARD_UNPRESENT = false , CARD_PRESENT = true ,
  CARD_UNPRESENT = false , CARD_PRESENT = true , CARD_UNPRESENT = false , CARD_PRESENT = true ,
  CARD_UNPRESENT = false , CARD_PRESENT = true
}
 

Functions

uint8_t get_system_class ()
 
CARD_STATUS get_1ou_status ()
 
CARD_STATUS get_2ou_status ()
 
uint8_t get_hsc_module ()
 
void init_hsc_module ()
 
void init_platform_config ()
 

Macro Definition Documentation

◆ CPLD_1OU_VPP_POWER_STATUS

#define CPLD_1OU_VPP_POWER_STATUS   0x11

◆ CPLD_2OU_EXPANSION_CARD_REG

#define CPLD_2OU_EXPANSION_CARD_REG   0x13

◆ CPLD_ADDR

#define CPLD_ADDR   0x21

◆ CPLD_CLASS_TYPE_REG

#define CPLD_CLASS_TYPE_REG   0x0D

◆ MAX_1OU_M2_COUNT

#define MAX_1OU_M2_COUNT   4

◆ SYS_CLASS_1

#define SYS_CLASS_1   1

◆ SYS_CLASS_2

#define SYS_CLASS_2   2

Typedef Documentation

◆ CARD_STATUS

typedef struct _CARD_STATUS_ CARD_STATUS

Enumeration Type Documentation

◆ _1OU_CARD_TYPE_

Enumerator
TYPE_1OU_SI_TEST_CARD 
TYPE_1OU_EXP_WITH_6_M2 
TYPE_1OU_RAINBOW_FALLS 
TYPE_1OU_VERNAL_FALLS_WITH_TI 
TYPE_1OU_VERNAL_FALLS_WITH_AST 
TYPE_1OU_EXP_WITH_NIC 
TYPE_1OU_ABSENT 
TYPE_1OU_UNKNOWN 
TYPE_1OU_SI_TEST_CARD 
TYPE_1OU_EXP_WITH_6_M2 
TYPE_1OU_RAINBOW_FALLS 
TYPE_1OU_VERNAL_FALLS_WITH_TI 
TYPE_1OU_VERNAL_FALLS_WITH_AST 
TYPE_1OU_KAHUNA_FALLS 
TYPE_1OU_WAIMANO_FALLS 
TYPE_1OU_EXP_WITH_NIC 
TYPE_1OU_ABSENT 
TYPE_1OU_UNKNOWN 
TYPE_1OU_SI_TEST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_2OU_EXP_E1S 
TYPE_2OU_HSM 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 
TYPE_2OU_DPV2_8 
TYPE_2OU_DPV2_16 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 
TYPE_2OU_DPV2_8 
TYPE_2OU_DPV2_16 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 
TYPE_2OU_DPV2_8 
TYPE_2OU_DPV2_16 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 
TYPE_2OU_DPV2_8 
TYPE_2OU_DPV2_16 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 
TYPE_2OU_DPV2_8 
TYPE_2OU_DPV2_16 
TYPE_2OU_ABSENT 
TYPE_2OU_UNKNOWN 

◆ BIC_CARD_PRESENT

Enumerator
CARD_UNPRESENT 
CARD_PRESENT 
CARD_UNPRESENT 
CARD_PRESENT 
CARD_UNPRESENT 
CARD_PRESENT 
CARD_UNPRESENT 
CARD_PRESENT 
CARD_UNPRESENT 
CARD_PRESENT 

◆ HSC_MODULE

enum HSC_MODULE
Enumerator
HSC_MODULE_ADM1272 
HSC_MODULE_XDP710 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1272 
HSC_MODULE_LTC4286 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1278 
HSC_MODULE_LTC4282 
HSC_MODULE_MP5990 
HSC_MODULE_ADM1276 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1278 
HSC_MODULE_LTC4282 
HSC_MODULE_MP5990 
HSC_MODULE_LTC4286 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1278 
HSC_MODULE_MP5990 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1278 
HSC_MODULE_LTC4282 
HSC_MODULE_MP5990 
HSC_MODULE_UNKNOWN 
HSC_MODULE_ADM1278 
HSC_MODULE_LTC4282 
HSC_MODULE_MP5990 
HSC_MODULE_UNKNOWN 
HSC_MODULE_MP5990 
HSC_MODULE_RS31380R 
HSC_MODULE_UNKNOWN 

Function Documentation

◆ get_1ou_status()

CARD_STATUS get_1ou_status ( )

◆ get_2ou_status()

CARD_STATUS get_2ou_status ( )

◆ get_hsc_module()

uint8_t get_hsc_module ( )

◆ get_system_class()

uint8_t get_system_class ( )

◆ init_hsc_module()

void init_hsc_module ( )

◆ init_platform_config()

void init_platform_config ( )