| ONLP
    Open Network Linux Platform APIs | 
| Data Structures | |
| struct | onlp_psu_info_t | 
| Macros | |
| #define | ONLP_PSU_INFO_CAP_IS_SET(_pinfo, _name) ((_pinfo)->caps & ONLP_PSU_CAPS_##_name) | 
| #define | ONLP_PSU_STATUS_PRESENT(_pi) ( (_pi).status & ONLP_PSU_STATUS_PRESENT ) | 
| #define | ONLP_PSU_STATUS_MISSING(_pi) (!ONLP_PSU_STATUS_PRESENT(_pi)) | 
| #define | ONLP_PSU_STATUS_FAILED(_pi) ( (_pi).status & ONLP_PSU_STATUS_FAILED) | 
| #define | ONLP_PSU_CAPS_VALID(_e) (onlp_psu_caps_valid((_e))) | 
| #define | ONLP_PSU_TYPE_STRINGS | 
| #define | ONLP_PSU_TYPE_VALID(_e) ( (0 <= (_e)) && ((_e) <= ONLP_PSU_TYPE_DC48)) | 
| Typedefs | |
| typedef enum onlp_psu_caps_e | onlp_psu_caps_t | 
| typedef enum onlp_psu_type_e | onlp_psu_type_t | 
| typedef struct onlp_psu_info_t | onlp_psu_info_t | 
| Enumerations | |
| enum | onlp_psu_caps_e { ONLP_PSU_CAPS_GET_TYPE = (1 << 0), ONLP_PSU_CAPS_GET_VIN = (1 << 1), ONLP_PSU_CAPS_GET_VOUT = (1 << 2), ONLP_PSU_CAPS_GET_IIN = (1 << 3), ONLP_PSU_CAPS_GET_IOUT = (1 << 4), ONLP_PSU_CAPS_GET_PIN = (1 << 5), ONLP_PSU_CAPS_GET_POUT = (1 << 6) } | 
| enum | onlp_psu_type_e { ONLP_PSU_TYPE_AC, ONLP_PSU_TYPE_DC12, ONLP_PSU_TYPE_DC48, ONLP_PSU_TYPE_LAST = ONLP_PSU_TYPE_DC48, ONLP_PSU_TYPE_COUNT, ONLP_PSU_TYPE_INVALID = -1 } | 
| Functions | |
| int | onlp_psu_sw_init (void) | 
| Software initialization of the PSU module. | |
| int | onlp_psu_hw_init (uint32_t flags) | 
| Hardware initialization of the PSU module.  More... | |
| int | onlp_psu_sw_denit (void) | 
| Deinitialize the psu software module.  More... | |
| int | onlp_psu_hdr_get (onlp_oid_t oid, onlp_oid_hdr_t *rv) | 
| Get the PSU's oid header.  More... | |
| int | onlp_psu_info_get (onlp_oid_t oid, onlp_psu_info_t *rv) | 
| Get the PSU information.  More... | |
| int | onlp_psu_info_to_user_json (onlp_psu_info_t *info, cJSON **cj, uint32_t flags) | 
| Convert a PSU info structure to user JSON.  More... | |
| int | onlp_psu_info_to_json (onlp_psu_info_t *info, cJSON **cj, uint32_t flags) | 
| Convert a PSU info structure to JSON.  More... | |
| int | onlp_psu_info_from_json (cJSON *cj, onlp_psu_info_t *info) | 
| Convert a JSON object to a PSU info structure.  More... | |
| const char * | onlp_psu_caps_name (onlp_psu_caps_t e) | 
| int | onlp_psu_caps_value (const char *str, onlp_psu_caps_t *e, int substr) | 
| const char * | onlp_psu_caps_desc (onlp_psu_caps_t e) | 
| int | onlp_psu_caps_valid (onlp_psu_caps_t e) | 
| const char * | onlp_psu_type_name (onlp_psu_type_t e) | 
| int | onlp_psu_type_value (const char *str, onlp_psu_type_t *e, int substr) | 
| const char * | onlp_psu_type_desc (onlp_psu_type_t e) | 
| Variables | |
| aim_map_si_t | onlp_psu_caps_map [] | 
| aim_map_si_t | onlp_psu_caps_desc_map [] | 
| aim_map_si_t | onlp_psu_type_map [] | 
| aim_map_si_t | onlp_psu_type_desc_map [] | 
| #define ONLP_PSU_CAPS_VALID | ( | _e | ) | (onlp_psu_caps_valid((_e))) | 
validator
| #define ONLP_PSU_INFO_CAP_IS_SET | ( | _pinfo, | |
| _name | |||
| ) | ((_pinfo)->caps & ONLP_PSU_CAPS_##_name) | 
Determine if a PSU capability is set.
| #define ONLP_PSU_STATUS_FAILED | ( | _pi | ) | ( (_pi).status & ONLP_PSU_STATUS_FAILED) | 
PSU has failed.
| #define ONLP_PSU_STATUS_MISSING | ( | _pi | ) | (!ONLP_PSU_STATUS_PRESENT(_pi)) | 
PSU is missing.
| #define ONLP_PSU_STATUS_PRESENT | ( | _pi | ) | ( (_pi).status & ONLP_PSU_STATUS_PRESENT ) | 
PSU is present.
| #define ONLP_PSU_TYPE_STRINGS | 
Strings macro.
| #define ONLP_PSU_TYPE_VALID | ( | _e | ) | ( (0 <= (_e)) && ((_e) <= ONLP_PSU_TYPE_DC48)) | 
validator
| typedef enum onlp_psu_caps_e onlp_psu_caps_t | 
onlp_psu_caps
| typedef struct onlp_psu_info_t onlp_psu_info_t | 
PSU Information Structure
| typedef enum onlp_psu_type_e onlp_psu_type_t | 
onlp_psu_type
| enum onlp_psu_caps_e | 
onlp_psu_caps
| enum onlp_psu_type_e | 
onlp_psu_type
| const char* onlp_psu_caps_desc | ( | onlp_psu_caps_t | e | ) | 
Enum descriptions.
| const char* onlp_psu_caps_name | ( | onlp_psu_caps_t | e | ) | 
Enum names.
| int onlp_psu_caps_valid | ( | onlp_psu_caps_t | e | ) | 
Enum validator.
| int onlp_psu_caps_value | ( | const char * | str, | 
| onlp_psu_caps_t * | e, | ||
| int | substr | ||
| ) | 
Enum values.
| int onlp_psu_hdr_get | ( | onlp_oid_t | oid, | 
| onlp_oid_hdr_t * | rv | ||
| ) | 
Get the PSU's oid header.
| oid | The PSU OID. | |
| [out] | rv | Receives the header. | 
| int onlp_psu_hw_init | ( | uint32_t | flags | ) | 
Hardware initialization of the PSU module.
| flags | The hardware initialization flags. | 
| int onlp_psu_info_from_json | ( | cJSON * | cj, | 
| onlp_psu_info_t * | info | ||
| ) | 
Convert a JSON object to a PSU info structure.
| cj | The JSON object. | |
| [out] | info | Receives the PSU info structure. | 
| int onlp_psu_info_get | ( | onlp_oid_t | oid, | 
| onlp_psu_info_t * | rv | ||
| ) | 
Get the PSU information.
| oid | The PSU OID. | |
| [out] | rv | Receives the information structure. | 
| int onlp_psu_info_to_json | ( | onlp_psu_info_t * | info, | 
| cJSON ** | cj, | ||
| uint32_t | flags | ||
| ) | 
Convert a PSU info structure to JSON.
| info | The PSU info structure | |
| [out] | cj | Receives the JSON object. | 
| flags | The JSON format flags. | 
| int onlp_psu_info_to_user_json | ( | onlp_psu_info_t * | info, | 
| cJSON ** | cj, | ||
| uint32_t | flags | ||
| ) | 
Convert a PSU info structure to user JSON.
| info | The PSU info structure | |
| [out] | cj | Receives the JSON object. | 
| flags | The JSON format flags. | 
| int onlp_psu_sw_denit | ( | void | ) | 
Deinitialize the psu software module.
| const char* onlp_psu_type_desc | ( | onlp_psu_type_t | e | ) | 
Enum descriptions.
| const char* onlp_psu_type_name | ( | onlp_psu_type_t | e | ) | 
Enum names.
| int onlp_psu_type_value | ( | const char * | str, | 
| onlp_psu_type_t * | e, | ||
| int | substr | ||
| ) | 
Enum values.
| aim_map_si_t onlp_psu_caps_desc_map[] | 
onlp_psu_caps_desc_map table.
| aim_map_si_t onlp_psu_caps_map[] | 
onlp_psu_caps_map table.
| aim_map_si_t onlp_psu_type_desc_map[] | 
onlp_psu_type_desc_map table.
| aim_map_si_t onlp_psu_type_map[] | 
onlp_psu_type_map table.
 1.8.13
 1.8.13