From 2fedc3b2f9eaf3a5e36852446032c1629de3ab77 Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Wed, 28 Mar 2018 17:15:10 +0000 Subject: [PATCH 1/4] Add: fan_per_module parameter to common code. You can define fan_count in module instead of defining by FAN_TYPE_NO_EEPROM/FAN_TYPE_EEPROM before Add: Orange LED support to common code. Add: manage_leds_type3 to support future systems with 12 FAN's in 6 modules and using Orange led instead of Red. FIX: remove unnecessary LED color2 from led_colors_map FIX: change FAN LED description for systems with 2 fans pre module Signed-off-by: Oleksandr Shamray --- .../module/inc/mlnx_common/mlnx_common.h | 7 + .../mlnx_common/module/src/mlnx_common_fani.c | 52 +++---- .../mlnx_common/module/src/mlnx_common_ledi.c | 82 ++++++++-- .../mlnx_common/module/src/mlnx_common_sysi.c | 142 +++++++++++++++++- .../onlp/builds/src/module/src/fani.c | 1 + .../onlp/builds/src/module/src/fani.c | 1 + .../onlp/builds/src/module/src/fani.c | 1 + .../onlp/builds/src/module/src/ledi.c | 8 +- .../onlp/builds/src/module/src/fani.c | 1 + .../onlp/builds/src/module/src/ledi.c | 8 +- .../onlp/builds/src/module/src/fani.c | 1 + 11 files changed, 245 insertions(+), 59 deletions(-) diff --git a/packages/platforms/mellanox/any/src/mlnx_common/module/inc/mlnx_common/mlnx_common.h b/packages/platforms/mellanox/any/src/mlnx_common/module/inc/mlnx_common/mlnx_common.h index f2bd7dbe..a1c191fa 100644 --- a/packages/platforms/mellanox/any/src/mlnx_common/module/inc/mlnx_common/mlnx_common.h +++ b/packages/platforms/mellanox/any/src/mlnx_common/module/inc/mlnx_common/mlnx_common.h @@ -24,6 +24,7 @@ #define LED_TYPE_1 1 #define LED_TYPE_2 2 +#define LED_TYPE_3 3 /* led common id */ #define LED_RESERVED 0 @@ -40,6 +41,11 @@ #define LED_PSU2 4 #define LED_UID 5 +/*led type 3 id */ +#define LED_FAN5 6 +#define LED_FAN6 7 +#define LED_PSU_T3 8 + #define PERCENTAGE_MIN 60.0 #define PERCENTAGE_MAX 100.0 #define RPM_MAGIC_MIN 153.0 @@ -125,6 +131,7 @@ typedef struct mlnx_platform_info_s { onlp_fan_info_t* finfo; fan_path_T* fan_fnames; int fan_type; + int fan_per_module; int first_psu_fan_id; } mlnx_platform_info_t; diff --git a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_fani.c b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_fani.c index caa088ca..8eeea7c4 100644 --- a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_fani.c +++ b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_fani.c @@ -126,43 +126,33 @@ _onlp_fani_info_get_fan(int local_id, onlp_fan_info_t* info) int r_val, ret; float range = 0; float temp = 0; - float fru_index = 0; + int fru_index = 0; const char fan_model[]=FAN_MODEL; mlnx_platform_info_t* mlnx_platform_info = get_platform_info(); if(mlnx_platform_info->fan_type == FAN_TYPE_NO_EEPROM) - strncpy(info->model, fan_model, sizeof(info->model)); + strncpy(info->model, fan_model, sizeof(info->model)); if(!mlnx_platform_info->fan_fixed) { - /* We have 4 FRU with 2 fans(total 8 fans). - Eeprom is per FRU but not per fan. - So, need to convert fan ID to FRU ID.*/ - if (local_id % 2) { - fru_index = local_id / 2 + 1; - } else { - fru_index = local_id / 2; - } - /* get fan status - */ - if(mlnx_platform_info->fan_type == FAN_TYPE_EEPROM) { - ret = onlp_file_read_int(&r_val, "%s%s", PREFIX_MODULE_PATH, mlnx_platform_info->fan_fnames[(int)fru_index].status); - if (ret < 0) { - return ONLP_STATUS_E_INTERNAL; + /* not fixed FAN's can have more than 1 FAN per FRU. + EEPROM is per FRU but not per FAN. + So, need to convert fan ID to FRU ID.*/ + if (mlnx_platform_info->fan_per_module == 0) { + info->status |= ONLP_FAN_STATUS_FAILED; + return ONLP_STATUS_OK; } - if (r_val != FAN_STATUS_OK) { - info->status &= ~ONLP_FAN_STATUS_PRESENT; - return ONLP_STATUS_OK; - } - } - else { - ret = onlp_file_read_int(&r_val, "%s%s", PREFIX_MODULE_PATH, mlnx_platform_info->fan_fnames[local_id].status); + /* get fan status */ + fru_index = (local_id + mlnx_platform_info->fan_per_module -1) / mlnx_platform_info->fan_per_module; + + ret = onlp_file_read_int(&r_val, "%s%s", PREFIX_MODULE_PATH, mlnx_platform_info->fan_fnames[fru_index].status); if (ret < 0) { return ONLP_STATUS_E_INTERNAL; } - if (r_val != FAN_STATUS_OK) { - return ONLP_STATUS_OK; - } - } + if (r_val != FAN_STATUS_OK) { + if(mlnx_platform_info->fan_type == FAN_TYPE_EEPROM) + info->status &= ~ONLP_FAN_STATUS_PRESENT; + return ONLP_STATUS_OK; + } } /* Fixed system FAN is always present */ info->status |= ONLP_FAN_STATUS_PRESENT; @@ -230,9 +220,9 @@ _onlp_fani_info_get_fan_on_psu(int local_id, int psu_id, onlp_fan_info_t* info) } if (r_val != FAN_STATUS_OK) { - if(mlnx_platform_info->fan_type == FAN_TYPE_EEPROM) - info->status &= ~ONLP_FAN_STATUS_PRESENT; - return ONLP_STATUS_OK; + if(mlnx_platform_info->fan_type == FAN_TYPE_EEPROM) + info->status &= ~ONLP_FAN_STATUS_PRESENT; + return ONLP_STATUS_OK; } info->status |= ONLP_FAN_STATUS_PRESENT; @@ -259,7 +249,7 @@ _onlp_fani_info_get_fan_on_psu(int local_id, int psu_id, onlp_fan_info_t* info) info->percentage = (int)temp; if (0 != psu_read_eeprom((local_id-mlnx_platform_info->first_psu_fan_id)+1, NULL, info)) - return ONLP_STATUS_E_INTERNAL; + return ONLP_STATUS_E_INTERNAL; return ONLP_STATUS_OK; } diff --git a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_ledi.c b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_ledi.c index 8669cf52..23feeff1 100644 --- a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_ledi.c +++ b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_ledi.c @@ -37,9 +37,11 @@ #define LED_MODE_OFF "none" #define LED_MODE_GREEN "green" #define LED_MODE_RED "red" +#define LED_MODE_ORANGE "orange" #define LED_MODE_BLUE "blue" #define LED_MODE_GREEN_BLINK "green_blink" #define LED_MODE_RED_BLINK "red_blink" +#define LED_MODE_ORANGE_BLINK "orange_blink" #define LED_MODE_BLUE_BLINK "blue_blink" #define LED_MODE_AUTO "cpld_control" @@ -76,56 +78,90 @@ led_light_mode_map_t led_map[] = { {LED_FAN1, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_FAN1, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_FAN1, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN1, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_FAN1, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN1, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_FAN1, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_FAN1, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_FAN2, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_FAN2, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_FAN2, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN2, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_FAN2, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN2, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_FAN2, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_FAN2, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_FAN3, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_FAN3, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_FAN3, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN3, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_FAN3, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN3, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_FAN3, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_FAN3, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_FAN4, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_FAN4, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_FAN4, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN4, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_FAN4, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN4, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_FAN4, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_FAN4, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, + {LED_FAN5, LED_MODE_OFF, ONLP_LED_MODE_OFF}, + {LED_FAN5, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, + {LED_FAN5, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN5, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, + {LED_FAN5, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN5, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, + {LED_FAN5, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, + {LED_FAN5, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, + + {LED_FAN6, LED_MODE_OFF, ONLP_LED_MODE_OFF}, + {LED_FAN6, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, + {LED_FAN6, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN6, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, + {LED_FAN6, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN6, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, + {LED_FAN6, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, + {LED_FAN6, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, + {LED_PSU, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_PSU, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_PSU, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_PSU, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_PSU, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_PSU, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_PSU, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_PSU, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_FAN, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_FAN, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_FAN, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_FAN, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_FAN, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_FAN, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_FAN, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_FAN, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_PSU1, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_PSU1, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_PSU1, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_PSU1, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_PSU1, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_PSU1, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_PSU1, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_PSU1, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, {LED_PSU2, LED_MODE_OFF, ONLP_LED_MODE_OFF}, {LED_PSU2, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, {LED_PSU2, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_PSU2, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, {LED_PSU2, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_PSU2, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, {LED_PSU2, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, {LED_PSU2, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, @@ -133,25 +169,36 @@ led_light_mode_map_t led_map[] = { {LED_UID, LED_MODE_BLUE, ONLP_LED_MODE_BLUE}, {LED_UID, LED_MODE_BLUE_BLINK, ONLP_LED_MODE_BLUE_BLINKING}, {LED_UID, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, + + {LED_PSU_T3, LED_MODE_OFF, ONLP_LED_MODE_OFF}, + {LED_PSU_T3, LED_MODE_GREEN, ONLP_LED_MODE_GREEN}, + {LED_PSU_T3, LED_MODE_RED, ONLP_LED_MODE_RED}, + {LED_PSU_T3, LED_MODE_ORANGE, ONLP_LED_MODE_ORANGE}, + {LED_PSU_T3, LED_MODE_RED_BLINK, ONLP_LED_MODE_RED_BLINKING}, + {LED_PSU_T3, LED_MODE_ORANGE_BLINK, ONLP_LED_MODE_ORANGE_BLINKING}, + {LED_PSU_T3, LED_MODE_GREEN_BLINK, ONLP_LED_MODE_GREEN_BLINKING}, + {LED_PSU_T3, LED_MODE_AUTO, ONLP_LED_MODE_AUTO}, }; typedef struct led_colors { int id; - const char* color1; - const char* color2; + const char* color; } led_colors_t; static led_colors_t led_colors_map[] = { - {LED_SYSTEM, "green", "red"}, - {LED_FAN1, "green", "red"}, - {LED_FAN2, "green", "red"}, - {LED_FAN3, "green", "red"}, - {LED_FAN4, "green", "red"}, - {LED_PSU, "green", "red"}, - {LED_FAN, "green", "red"}, - {LED_PSU1, "green", "red"}, - {LED_PSU2, "green", "red"}, - {LED_UID, "blue", NULL}, + {LED_SYSTEM, "green"}, + {LED_FAN1, "green"}, + {LED_FAN2, "green"}, + {LED_FAN3, "green"}, + {LED_FAN4, "green"}, + {LED_FAN5, "green"}, + {LED_FAN6, "green"}, + {LED_PSU, "green"}, + {LED_FAN, "green"}, + {LED_PSU1, "green"}, + {LED_PSU2, "green"}, + {LED_UID, "blue"}, + {LED_PSU_T3, "green"}, }; static int driver_to_onlp_led_mode(int id, char* driver_led_mode) @@ -199,6 +246,10 @@ static int led_set_mode(onlp_oid_t id, onlp_led_mode_t mode) strcpy(color, "red"); blinking = 1; break; + case ONLP_LED_MODE_ORANGE_BLINKING: + strcpy(color, "orange"); + blinking = 1; + break; case ONLP_LED_MODE_GREEN_BLINKING: strcpy(color, "green"); blinking = 1; @@ -214,6 +265,9 @@ static int led_set_mode(onlp_oid_t id, onlp_led_mode_t mode) case ONLP_LED_MODE_RED: strcpy(color, "red"); break; + case ONLP_LED_MODE_ORANGE: + strcpy(color, "orange"); + break; case ONLP_LED_MODE_GREEN: strcpy(color, "green"); break; @@ -303,9 +357,9 @@ onlp_ledi_set(onlp_oid_t id, int on_or_off) if (id == led_colors_map[i].id) break; } - if (led_colors_map[i].color1) + if (led_colors_map[i].color) onlp_file_write((uint8_t*)LED_OFF, LED_MODE_LEN, - "%s%s_%s", prefix_path, mlnx_platform_info->led_fnames[id], led_colors_map[i].color1); + "%s%s_%s", prefix_path, mlnx_platform_info->led_fnames[id], led_colors_map[i].color); } } diff --git a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_sysi.c b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_sysi.c index 6fa3a415..64fd6985 100644 --- a/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_sysi.c +++ b/packages/platforms/mellanox/any/src/mlnx_common/module/src/mlnx_common_sysi.c @@ -379,13 +379,143 @@ onlp_sysi_platform_manage_leds_type2(void) return ONLP_STATUS_OK; } +int +onlp_sysi_platform_manage_leds_type3(void) +{ + int fan_number, psu_number; + onlp_led_mode_t mode, system_mode; + int min_fan_speed; + + int fan_led_id[6] = { LED_FAN1, LED_FAN2, LED_FAN3, LED_FAN4, LED_FAN5, LED_FAN6 }; + + int fan_problem = 0; + int psu_problem = 0; + + /* + * FAN Indicators + * + * Green - Fan is operating + * Orange - No power or Fan failure + * Off - No power + * + */ + for (fan_number = 1; fan_number <= mlnx_platform_info.fan_num; fan_number += 2) + { + /* each 2 fans had same led_fan */ + onlp_fan_info_t fi; + /* check fans */ + mode = ONLP_LED_MODE_GREEN; + if (onlp_fani_info_get(ONLP_FAN_ID_CREATE(fan_number), &fi) < 0) + { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } else if ((fi.status & ONLP_FAN_STATUS_PRESENT) == 0) { + if (mlnx_platform_info.fan_fixed == false) + { + /* Not present */ + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } + } else if (fi.status & ONLP_FAN_STATUS_FAILED) { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } else { + min_fan_speed = onlp_fani_get_min_rpm(fan_number); + if (fi.rpm < min_fan_speed) + { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } + } + /* check fan i+1 */ + if (onlp_fani_info_get(ONLP_FAN_ID_CREATE(fan_number + 1), &fi) < 0) + { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } else if ((fi.status & 0x1) == 0) { + if (mlnx_platform_info.fan_fixed == false) + { + /* Not present */ + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } + } else if (fi.status & ONLP_FAN_STATUS_FAILED) + { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } else { + min_fan_speed = onlp_fani_get_min_rpm(fan_number + 1); + if (fi.rpm < min_fan_speed) + { + mode = ONLP_LED_MODE_ORANGE; + fan_problem = 1; + } + } + onlp_ledi_mode_set( ONLP_OID_TYPE_CREATE(ONLP_OID_TYPE_LED, fan_led_id[fan_number / 2]), mode); + } + + for (psu_number = 1; psu_number <= mlnx_platform_info.psu_num; psu_number++) + { + onlp_psu_info_t pi; + if (onlp_psui_info_get(ONLP_PSU_ID_CREATE(psu_number), &pi) < 0) + { + psu_problem = 1; + } else { + if (mlnx_platform_info.psu_fixed) + { + /* Fixed system, PSU always in. Check only cable plugged. */ + if (pi.status & ONLP_PSU_STATUS_UNPLUGGED) + { + mode = ONLP_LED_MODE_ORANGE; + psu_problem = 1; + } + } else { + if ((pi.status & ONLP_PSU_STATUS_PRESENT) == 0) + { + /* Not present */ + psu_problem = 1; + } else if (pi.status & ONLP_PSU_STATUS_UNPLUGGED) { + psu_problem = 1; + } + } + } + } + + if (psu_problem) + mode = ONLP_LED_MODE_ORANGE; + else + mode = ONLP_LED_MODE_GREEN; + onlp_ledi_mode_set(ONLP_OID_TYPE_CREATE(ONLP_OID_TYPE_LED, LED_PSU), mode); + + /* Set System status LED green if no problem in FANs or PSUs */ + if (fan_problem || psu_problem) + system_mode = ONLP_LED_MODE_ORANGE; + else + system_mode = ONLP_LED_MODE_GREEN; + + onlp_ledi_mode_set(ONLP_OID_TYPE_CREATE(ONLP_OID_TYPE_LED, LED_SYSTEM), system_mode); + + return ONLP_STATUS_OK; +} + int onlp_sysi_platform_manage_leds(void) { - int res; - if(mlnx_platform_info.led_type == 1) - res=onlp_sysi_platform_manage_leds_type1(); - else - res=onlp_sysi_platform_manage_leds_type2(); - return res; + int res; + switch (mlnx_platform_info.led_type) { + case LED_TYPE_1: + res=onlp_sysi_platform_manage_leds_type1(); + break; + + case LED_TYPE_2: + res=onlp_sysi_platform_manage_leds_type2(); + break; + + case LED_TYPE_3: + res=onlp_sysi_platform_manage_leds_type3(); + break; + default: + res = ONLP_STATUS_E_INVALID; + } + return res; } diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2010/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2010/onlp/builds/src/module/src/fani.c index a4924279..b978252d 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2010/onlp/builds/src/module/src/fani.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2010/onlp/builds/src/module/src/fani.c @@ -70,6 +70,7 @@ onlp_fani_init(void) mlnx_platform_info->finfo = finfo; mlnx_platform_info->fan_fnames = fan_path; mlnx_platform_info->fan_type = FAN_TYPE_NO_EEPROM; + mlnx_platform_info->fan_per_module = 1; mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; return ONLP_STATUS_OK; } diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2100/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2100/onlp/builds/src/module/src/fani.c index 8f05fe8a..e8d1e656 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2100/onlp/builds/src/module/src/fani.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2100/onlp/builds/src/module/src/fani.c @@ -71,6 +71,7 @@ onlp_fani_init(void) mlnx_platform_info->finfo = finfo; mlnx_platform_info->fan_fnames = fan_path; mlnx_platform_info->fan_type = FAN_TYPE_NO_EEPROM; + mlnx_platform_info->fan_per_module = 1; mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; return ONLP_STATUS_OK; } diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/fani.c index 9a47a312..72b977b1 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/fani.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/fani.c @@ -88,6 +88,7 @@ onlp_fani_init(void) mlnx_platform_info->finfo = finfo; mlnx_platform_info->fan_fnames = fan_path; mlnx_platform_info->fan_type = FAN_TYPE_EEPROM; + mlnx_platform_info->fan_per_module = 2; mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; return ONLP_STATUS_OK; } diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/ledi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/ledi.c index 7fdb1f37..6249d791 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/ledi.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2410/onlp/builds/src/module/src/ledi.c @@ -56,25 +56,25 @@ static onlp_led_info_t linfo[] = ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN1), "Chassis LED 2 (FAN1 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN1), "Chassis LED 2 (FAN1 (1-2) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN2), "Chassis LED 3 (FAN2 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN2), "Chassis LED 3 (FAN2 (3-4)", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN3), "Chassis LED 4 (FAN3 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN3), "Chassis LED 4 (FAN3 (5-6) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN4), "Chassis LED 5 (FAN4 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN4), "Chassis LED 5 (FAN4 (7-8) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/fani.c index 69914db2..f77c3b6d 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/fani.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/fani.c @@ -88,6 +88,7 @@ onlp_fani_init(void) mlnx_platform_info->finfo = finfo; mlnx_platform_info->fan_fnames = fan_path; mlnx_platform_info->fan_type = FAN_TYPE_EEPROM; + mlnx_platform_info->fan_per_module = 2; mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; return ONLP_STATUS_OK; } diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/ledi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/ledi.c index 7fdb1f37..571866a7 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/ledi.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2700/onlp/builds/src/module/src/ledi.c @@ -56,25 +56,25 @@ static onlp_led_info_t linfo[] = ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN1), "Chassis LED 2 (FAN1 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN1), "Chassis LED 2 (FAN1 (1-2) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN2), "Chassis LED 3 (FAN2 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN2), "Chassis LED 3 (FAN2 (3-4) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN3), "Chassis LED 4 (FAN3 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN3), "Chassis LED 4 (FAN3 (4-6) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, }, { - { ONLP_LED_ID_CREATE(LED_FAN4), "Chassis LED 5 (FAN4 LED)", 0 }, + { ONLP_LED_ID_CREATE(LED_FAN4), "Chassis LED 5 (FAN4 (7-8) )", 0 }, ONLP_LED_STATUS_PRESENT, ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | ONLP_LED_CAPS_RED | ONLP_LED_CAPS_RED_BLINKING | ONLP_LED_CAPS_AUTO, diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2740/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2740/onlp/builds/src/module/src/fani.c index 7e57fcb6..05ab232f 100755 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2740/onlp/builds/src/module/src/fani.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-msn2740/onlp/builds/src/module/src/fani.c @@ -76,6 +76,7 @@ onlp_fani_init(void) mlnx_platform_info->finfo = finfo; mlnx_platform_info->fan_fnames = fan_path; mlnx_platform_info->fan_type = FAN_TYPE_NO_EEPROM; + mlnx_platform_info->fan_per_module = 1; mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; return ONLP_STATUS_OK; } From 43e8d1848b2f88a7a616e192f7680d5046602fc7 Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Wed, 4 Apr 2018 11:16:17 +0000 Subject: [PATCH 2/4] Add: QMB700/QMB700ES systems support Signed-off-by: Oleksandr Shamray --- .../x86-64/x86-64-mlnx-qmb700/Makefile | 1 + .../x86-64-mlnx-qmb700/modules/Makefile | 1 + .../x86-64/x86-64-mlnx-qmb700/modules/PKG.yml | 1 + .../x86-64/x86-64-mlnx-qmb700/onlp/Makefile | 1 + .../x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml | 1 + .../x86-64-mlnx-qmb700/onlp/builds/Makefile | 2 + .../onlp/builds/lib/Makefile | 46 ++++++ .../lib/libonlp-x86-64-mlnx-qmb700-r0.mk | 10 ++ .../builds/lib/libonlp-x86-64-mlnx-qmb700.mk | 10 ++ .../onlp/builds/lib/x86_64_mlnx_qmb700.mk | 10 ++ .../onlp/builds/onlpdump/Makefile | 46 ++++++ .../onlp/builds/onlpdump/onlpdump.mk | 10 ++ .../onlp/builds/src/.module | 1 + .../onlp/builds/src/Makefile | 9 ++ .../x86-64-mlnx-qmb700/onlp/builds/src/README | 6 + .../onlp/builds/src/module/auto/make.mk | 9 ++ .../src/module/auto/x86_64_mlnx_qmb700.yml | 50 +++++++ .../x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x | 14 ++ .../x86_64_mlnx_qmb700_config.h | 137 ++++++++++++++++++ .../x86_64_mlnx_qmb700_dox.h | 26 ++++ .../x86_64_mlnx_qmb700_porting.h | 107 ++++++++++++++ .../onlp/builds/src/module/make.mk | 10 ++ .../onlp/builds/src/module/src/Makefile | 9 ++ .../onlp/builds/src/module/src/fani.c | 107 ++++++++++++++ .../onlp/builds/src/module/src/ledi.c | 117 +++++++++++++++ .../onlp/builds/src/module/src/make.mk | 9 ++ .../onlp/builds/src/module/src/platform_lib.h | 39 +++++ .../onlp/builds/src/module/src/sysi.c | 64 ++++++++ .../onlp/builds/src/module/src/thermali.c | 116 +++++++++++++++ .../module/src/x86_64_mlnx_qmb700_config.c | 81 +++++++++++ .../src/module/src/x86_64_mlnx_qmb700_enums.c | 10 ++ .../src/module/src/x86_64_mlnx_qmb700_int.h | 12 ++ .../src/module/src/x86_64_mlnx_qmb700_log.c | 18 +++ .../src/module/src/x86_64_mlnx_qmb700_log.h | 12 ++ .../module/src/x86_64_mlnx_qmb700_module.c | 24 +++ .../src/module/src/x86_64_mlnx_qmb700_ucli.c | 50 +++++++ .../onlp/builds/src/x86_64_mlnx_qmb700.mk | 13 ++ .../platform-config/Makefile | 1 + .../platform-config/r0/Makefile | 1 + .../platform-config/r0/PKG.yml | 1 + .../r0/src/lib/x86-64-mlnx-qmb700-r0.yml | 36 +++++ .../python/x86_64_mlnx_qmb700_r0/__init__.py | 17 +++ 42 files changed, 1245 insertions(+) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile new file mode 100644 index 00000000..dc1e7b86 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile @@ -0,0 +1 @@ +include $(ONL)/make/pkg.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile new file mode 100644 index 00000000..003238cf --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile @@ -0,0 +1 @@ +include $(ONL)/make/pkg.mk \ No newline at end of file diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml new file mode 100644 index 00000000..34f20801 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml @@ -0,0 +1 @@ +!include $ONL_TEMPLATES/no-platform-modules.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-qmb700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile new file mode 100644 index 00000000..003238cf --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile @@ -0,0 +1 @@ +include $(ONL)/make/pkg.mk \ No newline at end of file diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml new file mode 100644 index 00000000..921632bf --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml @@ -0,0 +1 @@ +!include $ONL_TEMPLATES/onlp-platform-any.yml PLATFORM=x86-64-mlnx-qmb700 ARCH=amd64 TOOLCHAIN=x86_64-linux-gnu diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile new file mode 100644 index 00000000..e7437cb2 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile @@ -0,0 +1,2 @@ +FILTER=src +include $(ONL)/make/subdirs.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile new file mode 100644 index 00000000..4bdf74ed --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile @@ -0,0 +1,46 @@ +############################################################ +# +# +# Copyright 2014 BigSwitch Networks, Inc. +# +# Licensed under the Eclipse Public License, Version 1.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.eclipse.org/legal/epl-v10.html +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, +# either express or implied. See the License for the specific +# language governing permissions and limitations under the +# License. +# +# +############################################################ +# +# +############################################################ +include $(ONL)/make/config.amd64.mk + +MODULE := libonlp-x86-64-mlnx-qmb700 +include $(BUILDER)/standardinit.mk + +DEPENDMODULES := AIM IOF mlnx_common x86_64_mlnx_qmb700 onlplib +DEPENDMODULE_HEADERS := sff + +include $(BUILDER)/dependmodules.mk + +SHAREDLIB := libonlp-x86-64-mlnx-qmb700.so +$(SHAREDLIB)_TARGETS := $(ALL_TARGETS) +include $(BUILDER)/so.mk +.DEFAULT_GOAL := $(SHAREDLIB) + +GLOBAL_CFLAGS += -I$(onlp_BASEDIR)/module/inc +GLOBAL_CFLAGS += -I$(mlnx_common_BASEDIR)/module/inc +GLOBAL_CFLAGS += -DAIM_CONFIG_INCLUDE_MODULES_INIT=1 +GLOBAL_CFLAGS += -fPIC +GLOBAL_LINK_LIBS += -lpthread + +include $(BUILDER)/targets.mk + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk new file mode 100644 index 00000000..341d59f7 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk @@ -0,0 +1,10 @@ + +############################################################################### +# +# Inclusive Makefile for the libonlp-x86-64-mlnx-qmb700-r0 module. +# +# Autogenerated 2015-12-23 23:45:22.249911 +# +############################################################################### +libonlp-x86-64-mlnx-qmb700-r0_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk new file mode 100644 index 00000000..f4b9d94f --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk @@ -0,0 +1,10 @@ + +############################################################################### +# +# Inclusive Makefile for the libonlp-x86-64-mlnx-qmb700 module. +# +# Autogenerated 2016-10-13 22:58:39.095824 +# +############################################################################### +libonlp-x86-64-mlnx-qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk new file mode 100644 index 00000000..413c2357 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk @@ -0,0 +1,10 @@ + +############################################################################### +# +# Inclusive Makefile for the x86_64_mlnx_qmb700 module. +# +# Autogenerated 2015-12-23 23:45:22.262891 +# +############################################################################### +x86_64_mlnx_qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile new file mode 100644 index 00000000..8f40a1a7 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile @@ -0,0 +1,46 @@ +############################################################ +# +# +# Copyright 2014 BigSwitch Networks, Inc. +# +# Licensed under the Eclipse Public License, Version 1.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.eclipse.org/legal/epl-v10.html +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, +# either express or implied. See the License for the specific +# language governing permissions and limitations under the +# License. +# +# +############################################################ +# +# +# +############################################################ +include $(ONL)/make/config.amd64.mk + +.DEFAULT_GOAL := onlpdump + +MODULE := onlpdump +include $(BUILDER)/standardinit.mk + +DEPENDMODULES := AIM IOF onlp mlnx_common x86_64_mlnx_qmb700 onlplib onlp_platform_defaults sff cjson cjson_util timer_wheel OS + +include $(BUILDER)/dependmodules.mk + +BINARY := onlpdump +$(BINARY)_LIBRARIES := $(LIBRARY_TARGETS) +include $(BUILDER)/bin.mk + +GLOBAL_CFLAGS += -DAIM_CONFIG_AIM_MAIN_FUNCTION=onlpdump_main +GLOBAL_CFLAGS += -DAIM_CONFIG_INCLUDE_MODULES_INIT=1 +GLOBAL_CFLAGS += -DAIM_CONFIG_INCLUDE_MAIN=1 +GLOBAL_LINK_LIBS += -lpthread -lm + +include $(BUILDER)/targets.mk + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk new file mode 100644 index 00000000..77d7d005 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk @@ -0,0 +1,10 @@ + +############################################################################### +# +# Inclusive Makefile for the onlpdump module. +# +# Autogenerated 2016-10-13 22:58:37.393320 +# +############################################################################### +onlpdump_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module new file mode 100644 index 00000000..7119f1d1 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module @@ -0,0 +1 @@ +name: x86_64_mlnx_qmb700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile new file mode 100644 index 00000000..770ebf0b --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile @@ -0,0 +1,9 @@ +############################################################################### +# +# +# +############################################################################### +include ../../init.mk +MODULE := x86_64_mlnx_qmb700 +AUTOMODULE := x86_64_mlnx_qmb700 +include $(BUILDER)/definemodule.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README new file mode 100644 index 00000000..6af022f0 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README @@ -0,0 +1,6 @@ +############################################################################### +# +# x86_64_mlnx_qmb700 README +# +############################################################################### + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk new file mode 100644 index 00000000..03e275da --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk @@ -0,0 +1,9 @@ +############################################################################### +# +# x86_64_mlnx_qmb700 Autogeneration +# +############################################################################### +x86_64_mlnx_qmb700_AUTO_DEFS := module/auto/x86_64_mlnx_qmb700.yml +x86_64_mlnx_qmb700_AUTO_DIRS := module/inc/x86_64_mlnx_qmb700 module/src +include $(BUILDER)/auto.mk + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml new file mode 100644 index 00000000..b9912cf1 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml @@ -0,0 +1,50 @@ +############################################################################### +# +# x86_64_mlnx_qmb700 Autogeneration Definitions. +# +############################################################################### + +cdefs: &cdefs +- X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING: + doc: "Include or exclude logging." + default: 1 +- X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT: + doc: "Default enabled log options." + default: AIM_LOG_OPTIONS_DEFAULT +- X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT: + doc: "Default enabled log bits." + default: AIM_LOG_BITS_DEFAULT +- X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT: + doc: "Default enabled custom log bits." + default: 0 +- X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB: + doc: "Default all porting macros to use the C standard libraries." + default: 1 +- X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS: + doc: "Include standard library headers for stdlib porting macros." + default: x86_64_mlnx_qmb700_CONFIG_PORTING_STDLIB +- X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI: + doc: "Include generic uCli support." + default: 0 +- X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION: + doc: "Assume chassis fan direction is the same as the PSU fan direction." + default: 0 + + +definitions: + cdefs: + X86_64_MLNX_QMB700_CONFIG_HEADER: + defs: *cdefs + basename: x86_64_mlnx_qmb700_config + + portingmacro: + x86_64_mlnx_qmb700: + macros: + - malloc + - free + - memset + - memcpy + - strncpy + - vsnprintf + - snprintf + - strlen diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x new file mode 100644 index 00000000..2987ccfa --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x @@ -0,0 +1,14 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +/* <--auto.start.xmacro(ALL).define> */ +/* */ + +/* <--auto.start.xenum(ALL).define> */ +/* */ + + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h new file mode 100644 index 00000000..b9823297 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h @@ -0,0 +1,137 @@ +/**************************************************************************//** + * + * @file + * @brief x86_64_mlnx_qmb700 Configuration Header + * + * @addtogroup x86_64_mlnx_qmb700-config + * @{ + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_QMB700_CONFIG_H__ +#define __X86_64_MLNX_QMB700_CONFIG_H__ + +#ifdef GLOBAL_INCLUDE_CUSTOM_CONFIG +#include +#endif +#ifdef X86_64_MLNX_QMB700_INCLUDE_CUSTOM_CONFIG +#include +#endif + +/* */ +#include +/** + * X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING + * + * Include or exclude logging. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING +#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING 1 +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT + * + * Default enabled log options. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT +#define X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT AIM_LOG_OPTIONS_DEFAULT +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT + * + * Default enabled log bits. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT +#define X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT AIM_LOG_BITS_DEFAULT +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + * + * Default enabled custom log bits. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT +#define X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT 0 +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB + * + * Default all porting macros to use the C standard libraries. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB +#define X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB 1 +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS + * + * Include standard library headers for stdlib porting macros. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS +#define X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI + * + * Include generic uCli support. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI +#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI 0 +#endif + +/** + * X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION + * + * Assume chassis fan direction is the same as the PSU fan direction. */ + + +#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION +#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION 0 +#endif + + + +/** + * All compile time options can be queried or displayed + */ + +/** Configuration settings structure. */ +typedef struct x86_64_mlnx_qmb700_config_settings_s { + /** name */ + const char* name; + /** value */ + const char* value; +} x86_64_mlnx_qmb700_config_settings_t; + +/** Configuration settings table. */ +/** x86_64_mlnx_qmb700_config_settings table. */ +extern x86_64_mlnx_qmb700_config_settings_t x86_64_mlnx_qmb700_config_settings[]; + +/** + * @brief Lookup a configuration setting. + * @param setting The name of the configuration option to lookup. + */ +const char* x86_64_mlnx_qmb700_config_lookup(const char* setting); + +/** + * @brief Show the compile-time configuration. + * @param pvs The output stream. + */ +int x86_64_mlnx_qmb700_config_show(struct aim_pvs_s* pvs); + +/* */ + +#include "x86_64_mlnx_qmb700_porting.h" + +#endif /* __X86_64_MLNX_QMB700_CONFIG_H__ */ +/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h new file mode 100644 index 00000000..b647e90d --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h @@ -0,0 +1,26 @@ +/**************************************************************************//** + * + * x86_64_mlnx_qmb700 Doxygen Header + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_QMB700_DOX_H__ +#define __X86_64_MLNX_QMB700_DOX_H__ + +/** + * @defgroup x86_64_mlnx_qmb700 x86_64_mlnx_qmb700 - x86_64_mlnx_qmb700 Description + * + +The documentation overview for this module should go here. + + * + * @{ + * + * @defgroup x86_64_mlnx_qmb700-x86_64_mlnx_qmb700 Public Interface + * @defgroup x86_64_mlnx_qmb700-config Compile Time Configuration + * @defgroup x86_64_mlnx_qmb700-porting Porting Macros + * + * @} + * + */ + +#endif /* __X86_64_MLNX_QMB700_DOX_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h new file mode 100644 index 00000000..a7475fa4 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h @@ -0,0 +1,107 @@ +/**************************************************************************//** + * + * @file + * @brief x86_64_mlnx_qmb700 Porting Macros. + * + * @addtogroup x86_64_mlnx_qmb700-porting + * @{ + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_QMB700_PORTING_H__ +#define __X86_64_MLNX_QMB700_PORTING_H__ + + +/* */ +#if X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS == 1 +#include +#include +#include +#include +#include +#endif + +#ifndef X86_64_MLNX_QMB700_MALLOC + #if defined(GLOBAL_MALLOC) + #define X86_64_MLNX_QMB700_MALLOC GLOBAL_MALLOC + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_MALLOC malloc + #else + #error The macro X86_64_MLNX_QMB700_MALLOC is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_FREE + #if defined(GLOBAL_FREE) + #define X86_64_MLNX_QMB700_FREE GLOBAL_FREE + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_FREE free + #else + #error The macro X86_64_MLNX_QMB700_FREE is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_MEMSET + #if defined(GLOBAL_MEMSET) + #define X86_64_MLNX_QMB700_MEMSET GLOBAL_MEMSET + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_MEMSET memset + #else + #error The macro X86_64_MLNX_QMB700_MEMSET is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_MEMCPY + #if defined(GLOBAL_MEMCPY) + #define X86_64_MLNX_QMB700_MEMCPY GLOBAL_MEMCPY + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_MEMCPY memcpy + #else + #error The macro X86_64_MLNX_QMB700_MEMCPY is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_STRNCPY + #if defined(GLOBAL_STRNCPY) + #define X86_64_MLNX_QMB700_STRNCPY GLOBAL_STRNCPY + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_STRNCPY strncpy + #else + #error The macro X86_64_MLNX_QMB700_STRNCPY is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_VSNPRINTF + #if defined(GLOBAL_VSNPRINTF) + #define X86_64_MLNX_QMB700_VSNPRINTF GLOBAL_VSNPRINTF + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_VSNPRINTF vsnprintf + #else + #error The macro X86_64_MLNX_QMB700_VSNPRINTF is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_SNPRINTF + #if defined(GLOBAL_SNPRINTF) + #define X86_64_MLNX_QMB700_SNPRINTF GLOBAL_SNPRINTF + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_SNPRINTF snprintf + #else + #error The macro X86_64_MLNX_QMB700_SNPRINTF is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_QMB700_STRLEN + #if defined(GLOBAL_STRLEN) + #define X86_64_MLNX_QMB700_STRLEN GLOBAL_STRLEN + #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_QMB700_STRLEN strlen + #else + #error The macro X86_64_MLNX_QMB700_STRLEN is required but cannot be defined. + #endif +#endif + +/* */ + + +#endif /* __X86_64_MLNX_QMB700_PORTING_H__ */ +/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk new file mode 100644 index 00000000..37149254 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk @@ -0,0 +1,10 @@ +############################################################################### +# +# +# +############################################################################### +THIS_DIR := $(dir $(lastword $(MAKEFILE_LIST))) +x86_64_mlnx_qmb700_INCLUDES := -I $(THIS_DIR)inc +x86_64_mlnx_qmb700_INTERNAL_INCLUDES := -I $(THIS_DIR)src +x86_64_mlnx_qmb700_DEPENDMODULE_ENTRIES := init:x86_64_mlnx_qmb700 ucli:x86_64_mlnx_qmb700 + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile new file mode 100644 index 00000000..823b325e --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile @@ -0,0 +1,9 @@ +############################################################################### +# +# Local source generation targets. +# +############################################################################### + +ucli: + @../../../../tools/uclihandlers.py x86_64_mlnx_qmb700_ucli.c + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c new file mode 100644 index 00000000..852142e4 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c @@ -0,0 +1,107 @@ +/************************************************************ + * + * + * Copyright 2014 Big Switch Networks, Inc. + * + * Licensed under the Eclipse Public License, Version 1.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.eclipse.org/legal/epl-v10.html + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific + * language governing permissions and limitations under the + * License. + * + * + ************************************************************ + * + * Fan Platform Implementation Defaults. + * + ***********************************************************/ +#include +#include +#include +#include +#include "platform_lib.h" +#include "mlnx_common/mlnx_common.h" + +#define FAN_RESERVED 0 +#define FAN_1_ON_MAIN_BOARD 1 +#define FAN_2_ON_MAIN_BOARD 2 +#define FAN_3_ON_MAIN_BOARD 3 +#define FAN_4_ON_MAIN_BOARD 4 +#define FAN_5_ON_MAIN_BOARD 5 +#define FAN_6_ON_MAIN_BOARD 6 +#define FAN_7_ON_MAIN_BOARD 7 +#define FAN_8_ON_MAIN_BOARD 8 +#define FAN_9_ON_MAIN_BOARD 9 +#define FAN_10_ON_MAIN_BOARD 10 +#define FAN_11_ON_MAIN_BOARD 11 +#define FAN_12_ON_MAIN_BOARD 12 +#define FAN_1_ON_PSU1 13 +#define FAN_1_ON_PSU2 14 + +#define FIRST_PSU_FAN_ID 13 + +static int min_fan_speed[CHASSIS_FAN_COUNT+1] = {0}; +static int max_fan_speed[CHASSIS_FAN_COUNT+1] = {0}; + +static fan_path_T fan_path[] = /* must map with onlp_fan_id */ +{ + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_RESERVED), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_1_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_2_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_3_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_4_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_5_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_6_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_7_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_8_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_9_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_10_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_11_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_MAIN_BOARD(PROJECT_NAME, FAN_12_ON_MAIN_BOARD), + MAKE_FAN_PATH_ON_PSU(1 ,1), + MAKE_FAN_PATH_ON_PSU(2, 1) +}; + +/* Static fan information */ +onlp_fan_info_t finfo[] = { + { }, /* Not used */ + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(1), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(2), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(3), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(4), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(5), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(6), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(7), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(8), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(9), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(10), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(11), + MAKE_FAN_INFO_NODE_ON_MAIN_BOARD(12), + MAKE_FAN_INFO_NODE_ON_PSU(1,1), + MAKE_FAN_INFO_NODE_ON_PSU(2,1) +}; + +/* + * This function will be called prior to all of onlp_fani_* functions. + */ +int +onlp_fani_init(void) +{ + mlnx_platform_info_t* mlnx_platform_info = get_platform_info(); + mlnx_platform_info->min_fan_speed = min_fan_speed; + mlnx_platform_info->max_fan_speed = max_fan_speed; + mlnx_platform_info->finfo = finfo; + mlnx_platform_info->fan_fnames = fan_path; + mlnx_platform_info->fan_type = FAN_TYPE_NO_EEPROM; + mlnx_platform_info->fan_per_module = 2; + mlnx_platform_info->first_psu_fan_id = FIRST_PSU_FAN_ID; + return ONLP_STATUS_OK; +} + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c new file mode 100644 index 00000000..2e4224dd --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c @@ -0,0 +1,117 @@ +/************************************************************ + * + * + * Copyright 2014 Big Switch Networks, Inc. + * + * Licensed under the Eclipse Public License, Version 1.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.eclipse.org/legal/epl-v10.html + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific + * language governing permissions and limitations under the + * License. + * + * + ************************************************************ + * + * + * + ***********************************************************/ +#include +#include +#include +#include +#include +#include +#include +#include "platform_lib.h" +#include + +static char* file_names[] = /* must map with onlp_led_id */ +{ + "reserved", + "status", + "fan1", + "fan2", + "fan3", + "fan4", + "fan5", + "fan6", + "psu", +}; + +/* + * Get the information for the given LED OID. + */ +static onlp_led_info_t linfo[] = +{ + { }, /* Not used */ + { + { ONLP_LED_ID_CREATE(LED_SYSTEM), "Chassis LED 1 (SYSTEM LED)", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN1), "Chassis LED 2 (FAN1 (1-2) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN2), "Chassis LED 3 (FAN2 (3-4) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN3), "Chassis LED 4 (FAN3 (5-6) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN4), "Chassis LED 5 (FAN5 (7-8) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN5), "Chassis LED 6 (FAN5 (9-10) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_FAN6), "Chassis LED 7 (FAN6 (11-12) )", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, + { + { ONLP_LED_ID_CREATE(LED_PSU_T3), "Chassis LED 8 (PSU LED)", 0 }, + ONLP_LED_STATUS_PRESENT, + ONLP_LED_CAPS_ON_OFF | ONLP_LED_CAPS_GREEN | ONLP_LED_CAPS_GREEN_BLINKING | + ONLP_LED_CAPS_ORANGE | ONLP_LED_CAPS_ORANGE_BLINKING | ONLP_LED_CAPS_AUTO, + }, +}; + +/* + * This function will be called prior to any other onlp_ledi_* functions. + */ +int +onlp_ledi_init(void) +{ + /* + * ONLPD calls it too early before all BSP insfrastructure is set + */ + mlnx_platform_info_t* mlnx_platform_info = get_platform_info(); + mlnx_platform_info->linfo = linfo; + mlnx_platform_info->led_fnames = file_names; + return ONLP_STATUS_OK; +} diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk new file mode 100644 index 00000000..a988f33f --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk @@ -0,0 +1,9 @@ +############################################################################### +# +# +# +############################################################################### + +LIBRARY := x86_64_mlnx_qmb700 +$(LIBRARY)_SUBDIR := $(dir $(lastword $(MAKEFILE_LIST))) +include $(BUILDER)/lib.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h new file mode 100644 index 00000000..29aaeccb --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h @@ -0,0 +1,39 @@ +/************************************************************ + * + * + * Copyright 2014 Big Switch Networks, Inc. + * + * Licensed under the Eclipse Public License, Version 1.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.eclipse.org/legal/epl-v10.html + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific + * language governing permissions and limitations under the + * License. + * + * + ************************************************************ + * + * + * + ***********************************************************/ +#ifndef __PLATFORM_LIB_H__ +#define __PLATFORM_LIB_H__ + +#include "x86_64_mlnx_qmb700_log.h" + +#define CHASSIS_PSU_COUNT 2 +#define CHASSIS_TOTAL_FAN_COUNT 14 +#define CHASSIS_TOTAL_THERMAL_COUNT 8 +#define CHASSIS_FAN_COUNT (CHASSIS_TOTAL_FAN_COUNT - CHASSIS_PSU_COUNT) +#define CHASSIS_THERMAL_COUNT (CHASSIS_TOTAL_THERMAL_COUNT - CHASSIS_PSU_COUNT) +#define CPLD_COUNT 3 +#define SFP_PORT_COUNT 32 +#define CHASSIS_LED_COUNT 8 + +#endif /* __PLATFORM_LIB_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c new file mode 100644 index 00000000..1da67d0d --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c @@ -0,0 +1,64 @@ +/************************************************************ + * + * + * Copyright 2014 Big Switch Networks, Inc. + * + * Licensed under the Eclipse Public License, Version 1.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.eclipse.org/legal/epl-v10.html + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific + * language governing permissions and limitations under the + * License. + * + * + ************************************************************ + * + * + * + ***********************************************************/ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "platform_lib.h" +#include +#include "x86_64_mlnx_qmb700_int.h" +#include "x86_64_mlnx_qmb700_log.h" + +#define ONL_PLATFORM_NAME "x86-64-mlnx-qmb700-r0" + +int mc_get_platform_info(mlnx_platform_info_t* mlnx_platform) +{ + strncpy(mlnx_platform->onl_platform_name, ONL_PLATFORM_NAME, PLATFORM_NAME_MAX_LEN); + mlnx_platform->sfp_num = SFP_PORT_COUNT; + mlnx_platform->led_num = CHASSIS_LED_COUNT; + mlnx_platform->psu_num = CHASSIS_PSU_COUNT; + mlnx_platform->fan_num = CHASSIS_FAN_COUNT; + mlnx_platform->thermal_num = CHASSIS_THERMAL_COUNT; + mlnx_platform->cpld_num = CPLD_COUNT; + mlnx_platform->psu_fixed = false; + mlnx_platform->fan_fixed = false; + mlnx_platform->psu_type = PSU_TYPE_2; + mlnx_platform->led_type = LED_TYPE_3; + + return ONLP_STATUS_OK; +} + +int +onlp_sysi_init(void) +{ + return ONLP_STATUS_OK; +} + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c new file mode 100644 index 00000000..7011410d --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c @@ -0,0 +1,116 @@ +/************************************************************ + * + * + * Copyright 2014 Big Switch Networks, Inc. + * + * Licensed under the Eclipse Public License, Version 1.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.eclipse.org/legal/epl-v10.html + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, + * either express or implied. See the License for the specific + * language governing permissions and limitations under the + * License. + * + * + ************************************************************ + * + * Thermal Sensor Platform Implementation. + * + ***********************************************************/ +#include +#include +#include +#include +#include +#include +#include "platform_lib.h" +#include "mlnx_common/mlnx_common.h" + +enum onlp_thermal_id +{ + THERMAL_RESERVED = 0, + THERMAL_CPU_CORE_0, + THERMAL_CPU_CORE_1, + THERMAL_CPU_CORE_2, + THERMAL_CPU_CORE_3, + THERMAL_ASIC, + THERMAL_BOARD_AMB, + THERMAL_PORT, + THERMAL_ON_PSU1, + THERMAL_ON_PSU2, +}; + +static char* thermal_fnames[] = /* must map with onlp_thermal_id */ +{ + "reserved", + "cpu_core0", + "cpu_core1", + "cpu_core2", + "cpu_core3", + "asic", + "board_amb", + "port_amb", + "psu1", + "psu2" +}; + +/* Static values */ +static onlp_thermal_info_t tinfo[] = { + { }, /* Not used */ + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_0), "CPU Core 0", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS + }, + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_1), "CPU Core 1", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS + }, + + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_0), "CPU Core 2", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS + }, + + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_1), "CPU Core 3", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS + }, + + { { ONLP_THERMAL_ID_CREATE(THERMAL_ASIC), "Asic Thermal Sensor", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_ALL, 0, ASIC_THERMAL_THRESHOLD_INIT_DEFAULTS + }, + { { ONLP_THERMAL_ID_CREATE(THERMAL_BOARD_AMB), "Board AMB Thermal Sensor", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_GET_TEMPERATURE, 0, {0,0,0} + }, + { { ONLP_THERMAL_ID_CREATE(THERMAL_PORT), "Port AMB Thermal Sensor", 0}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_GET_TEMPERATURE, 0, {0,0,0} + }, + { { ONLP_THERMAL_ID_CREATE(THERMAL_ON_PSU1), "PSU-1 Thermal Sensor 1", ONLP_PSU_ID_CREATE(PSU1_ID)}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_GET_TEMPERATURE, 0, {0,0,0} + }, + { { ONLP_THERMAL_ID_CREATE(THERMAL_ON_PSU2), "PSU-2 Thermal Sensor 1", ONLP_PSU_ID_CREATE(PSU2_ID)}, + ONLP_THERMAL_STATUS_PRESENT, + ONLP_THERMAL_CAPS_GET_TEMPERATURE, 0, {0,0,0} + } +}; + +/* + * This will be called to intiialize the thermali subsystem. + */ +int +onlp_thermali_init(void) +{ + mlnx_platform_info_t* mlnx_platform_info = get_platform_info(); + mlnx_platform_info->tinfo=tinfo; + mlnx_platform_info->thermal_fnames=thermal_fnames; + return ONLP_STATUS_OK; +} diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c new file mode 100644 index 00000000..25e8d508 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c @@ -0,0 +1,81 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +/* */ +#define __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(_x) #_x +#define __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(_x) __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(_x) +x86_64_mlnx_qmb700_config_settings_t x86_64_mlnx_qmb700_config_settings[] = +{ +#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION + { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION) }, +#else +{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif + { NULL, NULL } +}; +#undef __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE +#undef __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME + +const char* +x86_64_mlnx_qmb700_config_lookup(const char* setting) +{ + int i; + for(i = 0; x86_64_mlnx_qmb700_config_settings[i].name; i++) { + if(strcmp(x86_64_mlnx_qmb700_config_settings[i].name, setting)) { + return x86_64_mlnx_qmb700_config_settings[i].value; + } + } + return NULL; +} + +int +x86_64_mlnx_qmb700_config_show(struct aim_pvs_s* pvs) +{ + int i; + for(i = 0; x86_64_mlnx_qmb700_config_settings[i].name; i++) { + aim_printf(pvs, "%s = %s\n", x86_64_mlnx_qmb700_config_settings[i].name, x86_64_mlnx_qmb700_config_settings[i].value); + } + return i; +} + +/* */ + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c new file mode 100644 index 00000000..369f4add --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c @@ -0,0 +1,10 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +/* <--auto.start.enum(ALL).source> */ +/* */ + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h new file mode 100644 index 00000000..13144c54 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h @@ -0,0 +1,12 @@ +/**************************************************************************//** + * + * x86_64_mlnx_qmb700 Internal Header + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_QMB700_INT_H__ +#define __X86_64_MLNX_QMB700_INT_H__ + +#include + + +#endif /* __X86_64_MLNX_QMB700_INT_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c new file mode 100644 index 00000000..9c54abb6 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c @@ -0,0 +1,18 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#include "x86_64_mlnx_qmb700_log.h" +/* + * x86_64_mlnx_qmb700 log struct. + */ +AIM_LOG_STRUCT_DEFINE( + X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT, + X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT, + NULL, /* Custom log map */ + X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + ); + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h new file mode 100644 index 00000000..66d6aadb --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h @@ -0,0 +1,12 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_QMB700_LOG_H__ +#define __X86_64_MLNX_QMB700_LOG_H__ + +#define AIM_LOG_MODULE_NAME x86_64_mlnx_qmb700 +#include + +#endif /* __X86_64_MLNX_QMB700_LOG_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c new file mode 100644 index 00000000..b9953c97 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c @@ -0,0 +1,24 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#include "x86_64_mlnx_qmb700_log.h" + +static int +datatypes_init__(void) +{ +#define x86_64_mlnx_qmb700_ENUMERATION_ENTRY(_enum_name, _desc) AIM_DATATYPE_MAP_REGISTER(_enum_name, _enum_name##_map, _desc, AIM_LOG_INTERNAL); +#include + return 0; +} + +void __x86_64_mlnx_qmb700_module_init__(void) +{ + AIM_LOG_STRUCT_REGISTER(); + datatypes_init__(); +} + +int __onlp_platform_version__ = 1; diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c new file mode 100644 index 00000000..db0decf3 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c @@ -0,0 +1,50 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#if x86_64_mlnx_qmb700_CONFIG_INCLUDE_UCLI == 1 + +#include +#include +#include + +static ucli_status_t +x86_64_mlnx_qmb700_ucli_ucli__config__(ucli_context_t* uc) +{ + UCLI_HANDLER_MACRO_MODULE_CONFIG(x86_64_mlnx_qmb700) +} + +/* */ +/* */ + +static ucli_module_t +x86_64_mlnx_qmb700_ucli_module__ = + { + "x86_64_mlnx_qmb700_ucli", + NULL, + x86_64_mlnx_qmb700_ucli_ucli_handlers__, + NULL, + NULL, + }; + +ucli_node_t* +x86_64_mlnx_qmb700_ucli_node_create(void) +{ + ucli_node_t* n; + ucli_module_init(&x86_64_mlnx_qmb700_ucli_module__); + n = ucli_node_create("x86_64_mlnx_qmb700", NULL, &x86_64_mlnx_qmb700_ucli_module__); + ucli_node_subnode_add(n, ucli_module_log_node_create("x86_64_mlnx_qmb700")); + return n; +} + +#else +void* +x86_64_mlnx_qmb700_ucli_node_create(void) +{ + return NULL; +} +#endif + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk new file mode 100644 index 00000000..97ca08d2 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk @@ -0,0 +1,13 @@ + +############################################################################### +# +# Inclusive Makefile for the x86_64_mlnx_qmb700 module. +# +# Autogenerated 2015-12-23 23:45:56.754200 +# +############################################################################### +x86_64_mlnx_qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) +include $(x86_64_mlnx_qmb700_BASEDIR)/module/make.mk +include $(x86_64_mlnx_qmb700_BASEDIR)/module/auto/make.mk +include $(x86_64_mlnx_qmb700_BASEDIR)/module/src/make.mk + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile new file mode 100644 index 00000000..dc1e7b86 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile @@ -0,0 +1 @@ +include $(ONL)/make/pkg.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile new file mode 100644 index 00000000..dc1e7b86 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile @@ -0,0 +1 @@ +include $(ONL)/make/pkg.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml new file mode 100644 index 00000000..2d75d3df --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml @@ -0,0 +1 @@ +!include $ONL_TEMPLATES/platform-config-platform.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-qmb700 REVISION=r0 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml new file mode 100644 index 00000000..10bdf18b --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml @@ -0,0 +1,36 @@ +--- + +###################################################################### +# +# platform-config for Mellanox qmb700 +# +###################################################################### + +x86-64-mlnx-qmb700-r0: + + grub: + + serial: >- + --unit=0 + --speed=115200 + --word=8 + --parity=0 + --stop=1 + + kernel: + <<: *kernel-4-9 + + args: >- + nopat + console=ttyS0,115200n8 + rd_NO_MD + rd_NO_LUKS + acpi_enforce_resources=lax + acpi=noirq + i2c-ismt.enable=0 + + ##network + ## interfaces: + ## ma1: + ## name: ~ + ## syspath: pci0000:00/0000:00:14.0 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py new file mode 100644 index 00000000..8d3f0f00 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py @@ -0,0 +1,17 @@ +from onl.platform.base import * +from onl.platform.mellanox import * + +class OnlPlatform_x86_64_mlnx_qmb700_r0(OnlPlatformMellanox, + OnlPlatformPortConfig_32x100): + PLATFORM='x86-64-mlnx-qmb700-r0' + MODEL="QMB700" + SYS_OBJECT_ID=".700.1" + + def baseconfig(self): + # load modules + import os + # necessary if there are issues with the install + # os.system("/usr/bin/apt-get install") + os.system("/etc/mlnx/mlnx-hw-management start") + self.syseeprom_export(); + return True From acc69bfa906af8ab9beda5f31e4e78d258db695a Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Tue, 31 Jul 2018 11:01:12 +0000 Subject: [PATCH 3/4] Change: System name QMB700 -> MQM8700 Signed-off-by: Oleksandr Shamray --- .../Makefile | 0 .../modules/Makefile | 0 .../modules/PKG.yml | 2 +- .../onlp/Makefile | 0 .../onlp/PKG.yml | 2 +- .../onlp/builds/Makefile | 0 .../onlp/builds/lib/Makefile | 6 +- .../lib/libonlp-x86-64-mlnx-mqm8700-r0.mk} | 4 +- .../lib/libonlp-x86-64-mlnx-mqm8700.mk} | 4 +- .../onlp/builds/lib/x86_64_mlnx_mqm8700.mk} | 4 +- .../onlp/builds/onlpdump/Makefile | 2 +- .../onlp/builds/onlpdump/onlpdump.mk | 0 .../onlp/builds/src/.module | 1 + .../onlp/builds/src/Makefile | 4 +- .../onlp/builds/src/README | 2 +- .../onlp/builds/src/module/auto/make.mk | 6 +- .../src/module/auto/x86_64_mlnx_mqm8700.yml} | 26 ++-- .../x86_64_mlnx_mqm8700.x} | 2 +- .../x86_64_mlnx_mqm8700_config.h | 137 ++++++++++++++++++ .../x86_64_mlnx_mqm8700_dox.h | 26 ++++ .../x86_64_mlnx_mqm8700_porting.h | 107 ++++++++++++++ .../onlp/builds/src/module/make.mk | 6 +- .../onlp/builds/src/module/src/Makefile | 2 +- .../onlp/builds/src/module/src/fani.c | 0 .../onlp/builds/src/module/src/ledi.c | 0 .../onlp/builds/src/module/src/make.mk | 2 +- .../onlp/builds/src/module/src/platform_lib.h | 2 +- .../onlp/builds/src/module/src/sysi.c | 6 +- .../onlp/builds/src/module/src/thermali.c | 0 .../module/src/x86_64_mlnx_mqm8700_config.c | 81 +++++++++++ .../module/src/x86_64_mlnx_mqm8700_enums.c} | 2 +- .../src/module/src/x86_64_mlnx_mqm8700_int.h | 12 ++ .../src/module/src/x86_64_mlnx_mqm8700_log.c | 18 +++ .../src/module/src/x86_64_mlnx_mqm8700_log.h} | 8 +- .../module/src/x86_64_mlnx_mqm8700_module.c | 24 +++ .../src/module/src/x86_64_mlnx_mqm8700_ucli.c | 50 +++++++ .../onlp/builds/src/x86_64_mlnx_mqm8700.mk | 13 ++ .../platform-config/Makefile | 0 .../platform-config/r0/Makefile | 0 .../platform-config/r0/PKG.yml | 2 +- .../r0/src/lib/x86-64-mlnx-mqm8700-r0.yml} | 4 +- .../x86_64_mlnx_mqm8700_r0}/__init__.py | 6 +- .../onlp/builds/src/.module | 1 - .../x86_64_mlnx_qmb700_config.h | 137 ------------------ .../x86_64_mlnx_qmb700_dox.h | 26 ---- .../x86_64_mlnx_qmb700_porting.h | 107 -------------- .../module/src/x86_64_mlnx_qmb700_config.c | 81 ----------- .../src/module/src/x86_64_mlnx_qmb700_int.h | 12 -- .../src/module/src/x86_64_mlnx_qmb700_log.c | 18 --- .../module/src/x86_64_mlnx_qmb700_module.c | 24 --- .../src/module/src/x86_64_mlnx_qmb700_ucli.c | 50 ------- .../onlp/builds/src/x86_64_mlnx_qmb700.mk | 13 -- 52 files changed, 521 insertions(+), 521 deletions(-) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/modules/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/modules/PKG.yml (61%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/PKG.yml (56%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/lib/Makefile (89%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk => x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700-r0.mk} (57%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk => x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700.mk} (58%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk => x86-64-mlnx-mqm8700/onlp/builds/lib/x86_64_mlnx_mqm8700.mk} (60%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/onlpdump/Makefile (91%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/onlpdump/onlpdump.mk (100%) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/.module rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/Makefile (77%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/README (85%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/auto/make.mk (51%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml => x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/x86_64_mlnx_mqm8700.yml} (60%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x => x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700.x} (84%) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_config.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_dox.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_porting.h rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/make.mk (51%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/Makefile (76%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/fani.c (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/ledi.c (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/make.mk (89%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/platform_lib.h (97%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/sysi.c (93%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/onlp/builds/src/module/src/thermali.c (100%) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_config.c rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c => x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_enums.c} (80%) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_int.h create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.c rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h => x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.h} (54%) create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_module.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_ucli.c create mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/x86_64_mlnx_mqm8700.mk rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/platform-config/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/platform-config/r0/Makefile (100%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700 => x86-64-mlnx-mqm8700}/platform-config/r0/PKG.yml (52%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml => x86-64-mlnx-mqm8700/platform-config/r0/src/lib/x86-64-mlnx-mqm8700-r0.yml} (89%) rename packages/platforms/mellanox/x86-64/{x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0 => x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0}/__init__.py (79%) delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c delete mode 100644 packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/modules/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/modules/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/modules/PKG.yml similarity index 61% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/modules/PKG.yml index 34f20801..73373296 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/modules/PKG.yml +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/modules/PKG.yml @@ -1 +1 @@ -!include $ONL_TEMPLATES/no-platform-modules.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-qmb700 +!include $ONL_TEMPLATES/no-platform-modules.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-mqm8700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/PKG.yml similarity index 56% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/PKG.yml index 921632bf..0024bcd2 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/PKG.yml +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/PKG.yml @@ -1 +1 @@ -!include $ONL_TEMPLATES/onlp-platform-any.yml PLATFORM=x86-64-mlnx-qmb700 ARCH=amd64 TOOLCHAIN=x86_64-linux-gnu +!include $ONL_TEMPLATES/onlp-platform-any.yml PLATFORM=x86-64-mlnx-mqm8700 ARCH=amd64 TOOLCHAIN=x86_64-linux-gnu diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/Makefile similarity index 89% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/Makefile index 4bdf74ed..765baa47 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/Makefile +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/Makefile @@ -23,15 +23,15 @@ ############################################################ include $(ONL)/make/config.amd64.mk -MODULE := libonlp-x86-64-mlnx-qmb700 +MODULE := libonlp-x86-64-mlnx-mqm8700 include $(BUILDER)/standardinit.mk -DEPENDMODULES := AIM IOF mlnx_common x86_64_mlnx_qmb700 onlplib +DEPENDMODULES := AIM IOF mlnx_common x86_64_mlnx_mqm8700 onlplib DEPENDMODULE_HEADERS := sff include $(BUILDER)/dependmodules.mk -SHAREDLIB := libonlp-x86-64-mlnx-qmb700.so +SHAREDLIB := libonlp-x86-64-mlnx-mqm8700.so $(SHAREDLIB)_TARGETS := $(ALL_TARGETS) include $(BUILDER)/so.mk .DEFAULT_GOAL := $(SHAREDLIB) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700-r0.mk similarity index 57% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700-r0.mk index 341d59f7..fac6eb51 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700-r0.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700-r0.mk @@ -1,10 +1,10 @@ ############################################################################### # -# Inclusive Makefile for the libonlp-x86-64-mlnx-qmb700-r0 module. +# Inclusive Makefile for the libonlp-x86-64-mlnx-mqm8700-r0 module. # # Autogenerated 2015-12-23 23:45:22.249911 # ############################################################################### -libonlp-x86-64-mlnx-qmb700-r0_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) +libonlp-x86-64-mlnx-mqm8700-r0_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700.mk similarity index 58% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700.mk index f4b9d94f..ad59e890 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/libonlp-x86-64-mlnx-qmb700.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/libonlp-x86-64-mlnx-mqm8700.mk @@ -1,10 +1,10 @@ ############################################################################### # -# Inclusive Makefile for the libonlp-x86-64-mlnx-qmb700 module. +# Inclusive Makefile for the libonlp-x86-64-mlnx-mqm8700 module. # # Autogenerated 2016-10-13 22:58:39.095824 # ############################################################################### -libonlp-x86-64-mlnx-qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) +libonlp-x86-64-mlnx-mqm8700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/x86_64_mlnx_mqm8700.mk similarity index 60% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/x86_64_mlnx_mqm8700.mk index 413c2357..3f2da271 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/lib/x86_64_mlnx_qmb700.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/lib/x86_64_mlnx_mqm8700.mk @@ -1,10 +1,10 @@ ############################################################################### # -# Inclusive Makefile for the x86_64_mlnx_qmb700 module. +# Inclusive Makefile for the x86_64_mlnx_mqm8700 module. # # Autogenerated 2015-12-23 23:45:22.262891 # ############################################################################### -x86_64_mlnx_qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) +x86_64_mlnx_mqm8700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/onlpdump/Makefile similarity index 91% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/onlpdump/Makefile index 8f40a1a7..58b6ac82 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/Makefile +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/onlpdump/Makefile @@ -29,7 +29,7 @@ include $(ONL)/make/config.amd64.mk MODULE := onlpdump include $(BUILDER)/standardinit.mk -DEPENDMODULES := AIM IOF onlp mlnx_common x86_64_mlnx_qmb700 onlplib onlp_platform_defaults sff cjson cjson_util timer_wheel OS +DEPENDMODULES := AIM IOF onlp mlnx_common x86_64_mlnx_mqm8700 onlplib onlp_platform_defaults sff cjson cjson_util timer_wheel OS include $(BUILDER)/dependmodules.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/onlpdump/onlpdump.mk similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/onlpdump/onlpdump.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/onlpdump/onlpdump.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/.module b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/.module new file mode 100644 index 00000000..88444c31 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/.module @@ -0,0 +1 @@ +name: x86_64_mlnx_mqm8700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/Makefile similarity index 77% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/Makefile index 770ebf0b..de4fbe78 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/Makefile +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/Makefile @@ -4,6 +4,6 @@ # ############################################################################### include ../../init.mk -MODULE := x86_64_mlnx_qmb700 -AUTOMODULE := x86_64_mlnx_qmb700 +MODULE := x86_64_mlnx_mqm8700 +AUTOMODULE := x86_64_mlnx_mqm8700 include $(BUILDER)/definemodule.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/README similarity index 85% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/README index 6af022f0..cc54e7d0 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/README +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/README @@ -1,6 +1,6 @@ ############################################################################### # -# x86_64_mlnx_qmb700 README +# x86_64_mlnx_mqm8700 README # ############################################################################### diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/make.mk similarity index 51% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/make.mk index 03e275da..aefe42e8 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/make.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/make.mk @@ -1,9 +1,9 @@ ############################################################################### # -# x86_64_mlnx_qmb700 Autogeneration +# x86_64_mlnx_mqm8700 Autogeneration # ############################################################################### -x86_64_mlnx_qmb700_AUTO_DEFS := module/auto/x86_64_mlnx_qmb700.yml -x86_64_mlnx_qmb700_AUTO_DIRS := module/inc/x86_64_mlnx_qmb700 module/src +x86_64_mlnx_mqm8700_AUTO_DEFS := module/auto/x86_64_mlnx_mqm8700.yml +x86_64_mlnx_mqm8700_AUTO_DIRS := module/inc/x86_64_mlnx_mqm8700 module/src include $(BUILDER)/auto.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/x86_64_mlnx_mqm8700.yml similarity index 60% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/x86_64_mlnx_mqm8700.yml index b9912cf1..c0bf4ddd 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/auto/x86_64_mlnx_qmb700.yml +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/auto/x86_64_mlnx_mqm8700.yml @@ -1,44 +1,44 @@ ############################################################################### # -# x86_64_mlnx_qmb700 Autogeneration Definitions. +# x86_64_mlnx_mqm8700 Autogeneration Definitions. # ############################################################################### cdefs: &cdefs -- X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING: +- X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING: doc: "Include or exclude logging." default: 1 -- X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT: +- X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT: doc: "Default enabled log options." default: AIM_LOG_OPTIONS_DEFAULT -- X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT: +- X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT: doc: "Default enabled log bits." default: AIM_LOG_BITS_DEFAULT -- X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT: +- X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT: doc: "Default enabled custom log bits." default: 0 -- X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB: +- X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB: doc: "Default all porting macros to use the C standard libraries." default: 1 -- X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS: +- X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS: doc: "Include standard library headers for stdlib porting macros." - default: x86_64_mlnx_qmb700_CONFIG_PORTING_STDLIB -- X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI: + default: x86_64_mlnx_mqm8700_CONFIG_PORTING_STDLIB +- X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI: doc: "Include generic uCli support." default: 0 -- X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION: +- X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION: doc: "Assume chassis fan direction is the same as the PSU fan direction." default: 0 definitions: cdefs: - X86_64_MLNX_QMB700_CONFIG_HEADER: + X86_64_MLNX_MQM8700_CONFIG_HEADER: defs: *cdefs - basename: x86_64_mlnx_qmb700_config + basename: x86_64_mlnx_mqm8700_config portingmacro: - x86_64_mlnx_qmb700: + x86_64_mlnx_mqm8700: macros: - malloc - free diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700.x similarity index 84% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700.x index 2987ccfa..7b17366e 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700.x +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700.x @@ -3,7 +3,7 @@ * * *****************************************************************************/ -#include +#include /* <--auto.start.xmacro(ALL).define> */ /* */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_config.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_config.h new file mode 100644 index 00000000..a94542fd --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_config.h @@ -0,0 +1,137 @@ +/**************************************************************************//** + * + * @file + * @brief x86_64_mlnx_mqm8700 Configuration Header + * + * @addtogroup x86_64_mlnx_mqm8700-config + * @{ + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_MQM8700_CONFIG_H__ +#define __X86_64_MLNX_MQM8700_CONFIG_H__ + +#ifdef GLOBAL_INCLUDE_CUSTOM_CONFIG +#include +#endif +#ifdef X86_64_MLNX_MQM8700_INCLUDE_CUSTOM_CONFIG +#include +#endif + +/* */ +#include +/** + * X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING + * + * Include or exclude logging. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING +#define X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING 1 +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT + * + * Default enabled log options. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT +#define X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT AIM_LOG_OPTIONS_DEFAULT +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT + * + * Default enabled log bits. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT +#define X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT AIM_LOG_BITS_DEFAULT +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + * + * Default enabled custom log bits. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT +#define X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT 0 +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB + * + * Default all porting macros to use the C standard libraries. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB +#define X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB 1 +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS + * + * Include standard library headers for stdlib porting macros. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS +#define X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI + * + * Include generic uCli support. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI +#define X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI 0 +#endif + +/** + * X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION + * + * Assume chassis fan direction is the same as the PSU fan direction. */ + + +#ifndef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION +#define X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION 0 +#endif + + + +/** + * All compile time options can be queried or displayed + */ + +/** Configuration settings structure. */ +typedef struct x86_64_mlnx_mqm8700_config_settings_s { + /** name */ + const char* name; + /** value */ + const char* value; +} x86_64_mlnx_mqm8700_config_settings_t; + +/** Configuration settings table. */ +/** x86_64_mlnx_mqm8700_config_settings table. */ +extern x86_64_mlnx_mqm8700_config_settings_t x86_64_mlnx_mqm8700_config_settings[]; + +/** + * @brief Lookup a configuration setting. + * @param setting The name of the configuration option to lookup. + */ +const char* x86_64_mlnx_mqm8700_config_lookup(const char* setting); + +/** + * @brief Show the compile-time configuration. + * @param pvs The output stream. + */ +int x86_64_mlnx_mqm8700_config_show(struct aim_pvs_s* pvs); + +/* */ + +#include "x86_64_mlnx_mqm8700_porting.h" + +#endif /* __X86_64_MLNX_MQM8700_CONFIG_H__ */ +/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_dox.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_dox.h new file mode 100644 index 00000000..454bfb64 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_dox.h @@ -0,0 +1,26 @@ +/**************************************************************************//** + * + * x86_64_mlnx_mqm8700 Doxygen Header + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_MQM8700_DOX_H__ +#define __X86_64_MLNX_MQM8700_DOX_H__ + +/** + * @defgroup x86_64_mlnx_mqm8700 x86_64_mlnx_mqm8700 - x86_64_mlnx_mqm8700 Description + * + +The documentation overview for this module should go here. + + * + * @{ + * + * @defgroup x86_64_mlnx_mqm8700-x86_64_mlnx_mqm8700 Public Interface + * @defgroup x86_64_mlnx_mqm8700-config Compile Time Configuration + * @defgroup x86_64_mlnx_mqm8700-porting Porting Macros + * + * @} + * + */ + +#endif /* __X86_64_MLNX_MQM8700_DOX_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_porting.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_porting.h new file mode 100644 index 00000000..d7e87576 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/inc/x86_64_mlnx_mqm8700/x86_64_mlnx_mqm8700_porting.h @@ -0,0 +1,107 @@ +/**************************************************************************//** + * + * @file + * @brief x86_64_mlnx_mqm8700 Porting Macros. + * + * @addtogroup x86_64_mlnx_mqm8700-porting + * @{ + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_MQM8700_PORTING_H__ +#define __X86_64_MLNX_MQM8700_PORTING_H__ + + +/* */ +#if X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS == 1 +#include +#include +#include +#include +#include +#endif + +#ifndef X86_64_MLNX_MQM8700_MALLOC + #if defined(GLOBAL_MALLOC) + #define X86_64_MLNX_MQM8700_MALLOC GLOBAL_MALLOC + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_MALLOC malloc + #else + #error The macro X86_64_MLNX_MQM8700_MALLOC is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_FREE + #if defined(GLOBAL_FREE) + #define X86_64_MLNX_MQM8700_FREE GLOBAL_FREE + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_FREE free + #else + #error The macro X86_64_MLNX_MQM8700_FREE is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_MEMSET + #if defined(GLOBAL_MEMSET) + #define X86_64_MLNX_MQM8700_MEMSET GLOBAL_MEMSET + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_MEMSET memset + #else + #error The macro X86_64_MLNX_MQM8700_MEMSET is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_MEMCPY + #if defined(GLOBAL_MEMCPY) + #define X86_64_MLNX_MQM8700_MEMCPY GLOBAL_MEMCPY + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_MEMCPY memcpy + #else + #error The macro X86_64_MLNX_MQM8700_MEMCPY is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_STRNCPY + #if defined(GLOBAL_STRNCPY) + #define X86_64_MLNX_MQM8700_STRNCPY GLOBAL_STRNCPY + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_STRNCPY strncpy + #else + #error The macro X86_64_MLNX_MQM8700_STRNCPY is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_VSNPRINTF + #if defined(GLOBAL_VSNPRINTF) + #define X86_64_MLNX_MQM8700_VSNPRINTF GLOBAL_VSNPRINTF + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_VSNPRINTF vsnprintf + #else + #error The macro X86_64_MLNX_MQM8700_VSNPRINTF is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_SNPRINTF + #if defined(GLOBAL_SNPRINTF) + #define X86_64_MLNX_MQM8700_SNPRINTF GLOBAL_SNPRINTF + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_SNPRINTF snprintf + #else + #error The macro X86_64_MLNX_MQM8700_SNPRINTF is required but cannot be defined. + #endif +#endif + +#ifndef X86_64_MLNX_MQM8700_STRLEN + #if defined(GLOBAL_STRLEN) + #define X86_64_MLNX_MQM8700_STRLEN GLOBAL_STRLEN + #elif X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB == 1 + #define X86_64_MLNX_MQM8700_STRLEN strlen + #else + #error The macro X86_64_MLNX_MQM8700_STRLEN is required but cannot be defined. + #endif +#endif + +/* */ + + +#endif /* __X86_64_MLNX_MQM8700_PORTING_H__ */ +/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/make.mk similarity index 51% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/make.mk index 37149254..c85531db 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/make.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/make.mk @@ -4,7 +4,7 @@ # ############################################################################### THIS_DIR := $(dir $(lastword $(MAKEFILE_LIST))) -x86_64_mlnx_qmb700_INCLUDES := -I $(THIS_DIR)inc -x86_64_mlnx_qmb700_INTERNAL_INCLUDES := -I $(THIS_DIR)src -x86_64_mlnx_qmb700_DEPENDMODULE_ENTRIES := init:x86_64_mlnx_qmb700 ucli:x86_64_mlnx_qmb700 +x86_64_mlnx_mqm8700_INCLUDES := -I $(THIS_DIR)inc +x86_64_mlnx_mqm8700_INTERNAL_INCLUDES := -I $(THIS_DIR)src +x86_64_mlnx_mqm8700_DEPENDMODULE_ENTRIES := init:x86_64_mlnx_mqm8700 ucli:x86_64_mlnx_mqm8700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/Makefile similarity index 76% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/Makefile index 823b325e..e4172517 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/Makefile +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/Makefile @@ -5,5 +5,5 @@ ############################################################################### ucli: - @../../../../tools/uclihandlers.py x86_64_mlnx_qmb700_ucli.c + @../../../../tools/uclihandlers.py x86_64_mlnx_mqm8700_ucli.c diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/fani.c similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/fani.c rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/fani.c diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/ledi.c similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/ledi.c rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/ledi.c diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/make.mk similarity index 89% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/make.mk index a988f33f..8dd3e0f9 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/make.mk +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/make.mk @@ -4,6 +4,6 @@ # ############################################################################### -LIBRARY := x86_64_mlnx_qmb700 +LIBRARY := x86_64_mlnx_mqm8700 $(LIBRARY)_SUBDIR := $(dir $(lastword $(MAKEFILE_LIST))) include $(BUILDER)/lib.mk diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/platform_lib.h similarity index 97% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/platform_lib.h index 29aaeccb..fd26ee65 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/platform_lib.h +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/platform_lib.h @@ -25,7 +25,7 @@ #ifndef __PLATFORM_LIB_H__ #define __PLATFORM_LIB_H__ -#include "x86_64_mlnx_qmb700_log.h" +#include "x86_64_mlnx_mqm8700_log.h" #define CHASSIS_PSU_COUNT 2 #define CHASSIS_TOTAL_FAN_COUNT 14 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/sysi.c similarity index 93% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/sysi.c index 1da67d0d..677f64b0 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/sysi.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/sysi.c @@ -34,10 +34,10 @@ #include #include "platform_lib.h" #include -#include "x86_64_mlnx_qmb700_int.h" -#include "x86_64_mlnx_qmb700_log.h" +#include "x86_64_mlnx_mqm8700_int.h" +#include "x86_64_mlnx_mqm8700_log.h" -#define ONL_PLATFORM_NAME "x86-64-mlnx-qmb700-r0" +#define ONL_PLATFORM_NAME "x86-64-mlnx-mqm8700-r0" int mc_get_platform_info(mlnx_platform_info_t* mlnx_platform) { diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/thermali.c rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_config.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_config.c new file mode 100644 index 00000000..033e2e16 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_config.c @@ -0,0 +1,81 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +/* */ +#define __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(_x) #_x +#define __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(_x) __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(_x) +x86_64_mlnx_mqm8700_config_settings_t x86_64_mlnx_mqm8700_config_settings[] = +{ +#ifdef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_INCLUDE_LOGGING(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_PORTING_STDLIB(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_INCLUDE_UCLI(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif +#ifdef X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION + { __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION), __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION) }, +#else +{ X86_64_MLNX_MQM8700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION(__X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME), "__undefined__" }, +#endif + { NULL, NULL } +}; +#undef __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_VALUE +#undef __X86_64_MLNX_MQM8700_CONFIG_STRINGIFY_NAME + +const char* +x86_64_mlnx_mqm8700_config_lookup(const char* setting) +{ + int i; + for(i = 0; x86_64_mlnx_mqm8700_config_settings[i].name; i++) { + if(strcmp(x86_64_mlnx_mqm8700_config_settings[i].name, setting)) { + return x86_64_mlnx_mqm8700_config_settings[i].value; + } + } + return NULL; +} + +int +x86_64_mlnx_mqm8700_config_show(struct aim_pvs_s* pvs) +{ + int i; + for(i = 0; x86_64_mlnx_mqm8700_config_settings[i].name; i++) { + aim_printf(pvs, "%s = %s\n", x86_64_mlnx_mqm8700_config_settings[i].name, x86_64_mlnx_mqm8700_config_settings[i].value); + } + return i; +} + +/* */ + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_enums.c similarity index 80% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_enums.c index 369f4add..195e3b13 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_enums.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_enums.c @@ -3,7 +3,7 @@ * * *****************************************************************************/ -#include +#include /* <--auto.start.enum(ALL).source> */ /* */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_int.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_int.h new file mode 100644 index 00000000..66b0794c --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_int.h @@ -0,0 +1,12 @@ +/**************************************************************************//** + * + * x86_64_mlnx_mqm8700 Internal Header + * + *****************************************************************************/ +#ifndef __X86_64_MLNX_MQM8700_INT_H__ +#define __X86_64_MLNX_MQM8700_INT_H__ + +#include + + +#endif /* __X86_64_MLNX_MQM8700_INT_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.c new file mode 100644 index 00000000..a2b106e6 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.c @@ -0,0 +1,18 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#include "x86_64_mlnx_mqm8700_log.h" +/* + * x86_64_mlnx_mqm8700 log struct. + */ +AIM_LOG_STRUCT_DEFINE( + X86_64_MLNX_MQM8700_CONFIG_LOG_OPTIONS_DEFAULT, + X86_64_MLNX_MQM8700_CONFIG_LOG_BITS_DEFAULT, + NULL, /* Custom log map */ + X86_64_MLNX_MQM8700_CONFIG_LOG_CUSTOM_BITS_DEFAULT + ); + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.h similarity index 54% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.h index 66d6aadb..0b528889 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.h +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_log.h @@ -3,10 +3,10 @@ * * *****************************************************************************/ -#ifndef __X86_64_MLNX_QMB700_LOG_H__ -#define __X86_64_MLNX_QMB700_LOG_H__ +#ifndef __X86_64_MLNX_MQM8700_LOG_H__ +#define __X86_64_MLNX_MQM8700_LOG_H__ -#define AIM_LOG_MODULE_NAME x86_64_mlnx_qmb700 +#define AIM_LOG_MODULE_NAME x86_64_mlnx_mqm8700 #include -#endif /* __X86_64_MLNX_QMB700_LOG_H__ */ +#endif /* __X86_64_MLNX_MQM8700_LOG_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_module.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_module.c new file mode 100644 index 00000000..83b1eae9 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_module.c @@ -0,0 +1,24 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#include "x86_64_mlnx_mqm8700_log.h" + +static int +datatypes_init__(void) +{ +#define x86_64_mlnx_mqm8700_ENUMERATION_ENTRY(_enum_name, _desc) AIM_DATATYPE_MAP_REGISTER(_enum_name, _enum_name##_map, _desc, AIM_LOG_INTERNAL); +#include + return 0; +} + +void __x86_64_mlnx_mqm8700_module_init__(void) +{ + AIM_LOG_STRUCT_REGISTER(); + datatypes_init__(); +} + +int __onlp_platform_version__ = 1; diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_ucli.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_ucli.c new file mode 100644 index 00000000..8909f39a --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/x86_64_mlnx_mqm8700_ucli.c @@ -0,0 +1,50 @@ +/**************************************************************************//** + * + * + * + *****************************************************************************/ +#include + +#if x86_64_mlnx_mqm8700_CONFIG_INCLUDE_UCLI == 1 + +#include +#include +#include + +static ucli_status_t +x86_64_mlnx_mqm8700_ucli_ucli__config__(ucli_context_t* uc) +{ + UCLI_HANDLER_MACRO_MODULE_CONFIG(x86_64_mlnx_mqm8700) +} + +/* */ +/* */ + +static ucli_module_t +x86_64_mlnx_mqm8700_ucli_module__ = + { + "x86_64_mlnx_mqm8700_ucli", + NULL, + x86_64_mlnx_mqm8700_ucli_ucli_handlers__, + NULL, + NULL, + }; + +ucli_node_t* +x86_64_mlnx_mqm8700_ucli_node_create(void) +{ + ucli_node_t* n; + ucli_module_init(&x86_64_mlnx_mqm8700_ucli_module__); + n = ucli_node_create("x86_64_mlnx_mqm8700", NULL, &x86_64_mlnx_mqm8700_ucli_module__); + ucli_node_subnode_add(n, ucli_module_log_node_create("x86_64_mlnx_mqm8700")); + return n; +} + +#else +void* +x86_64_mlnx_mqm8700_ucli_node_create(void) +{ + return NULL; +} +#endif + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/x86_64_mlnx_mqm8700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/x86_64_mlnx_mqm8700.mk new file mode 100644 index 00000000..ec1d2eb6 --- /dev/null +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/x86_64_mlnx_mqm8700.mk @@ -0,0 +1,13 @@ + +############################################################################### +# +# Inclusive Makefile for the x86_64_mlnx_mqm8700 module. +# +# Autogenerated 2015-12-23 23:45:56.754200 +# +############################################################################### +x86_64_mlnx_mqm8700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) +include $(x86_64_mlnx_mqm8700_BASEDIR)/module/make.mk +include $(x86_64_mlnx_mqm8700_BASEDIR)/module/auto/make.mk +include $(x86_64_mlnx_mqm8700_BASEDIR)/module/src/make.mk + diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/Makefile similarity index 100% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/Makefile rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/Makefile diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/PKG.yml similarity index 52% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/PKG.yml index 2d75d3df..6dd5281e 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/PKG.yml +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/PKG.yml @@ -1 +1 @@ -!include $ONL_TEMPLATES/platform-config-platform.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-qmb700 REVISION=r0 +!include $ONL_TEMPLATES/platform-config-platform.yml ARCH=amd64 VENDOR=mellanox BASENAME=x86-64-mlnx-mqm8700 REVISION=r0 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/lib/x86-64-mlnx-mqm8700-r0.yml similarity index 89% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/lib/x86-64-mlnx-mqm8700-r0.yml index 10bdf18b..cedd2d49 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/lib/x86-64-mlnx-qmb700-r0.yml +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/lib/x86-64-mlnx-mqm8700-r0.yml @@ -2,11 +2,11 @@ ###################################################################### # -# platform-config for Mellanox qmb700 +# platform-config for Mellanox mqm8700 # ###################################################################### -x86-64-mlnx-qmb700-r0: +x86-64-mlnx-mqm8700-r0: grub: diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py similarity index 79% rename from packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py rename to packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py index 8d3f0f00..c704cb97 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/platform-config/r0/src/python/x86_64_mlnx_qmb700_r0/__init__.py +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py @@ -1,10 +1,10 @@ from onl.platform.base import * from onl.platform.mellanox import * -class OnlPlatform_x86_64_mlnx_qmb700_r0(OnlPlatformMellanox, +class OnlPlatform_x86_64_mlnx_mqm8700_r0(OnlPlatformMellanox, OnlPlatformPortConfig_32x100): - PLATFORM='x86-64-mlnx-qmb700-r0' - MODEL="QMB700" + PLATFORM='x86-64-mlnx-mqm8700-r0' + MODEL="MQM8700" SYS_OBJECT_ID=".700.1" def baseconfig(self): diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module deleted file mode 100644 index 7119f1d1..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/.module +++ /dev/null @@ -1 +0,0 @@ -name: x86_64_mlnx_qmb700 diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h deleted file mode 100644 index b9823297..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_config.h +++ /dev/null @@ -1,137 +0,0 @@ -/**************************************************************************//** - * - * @file - * @brief x86_64_mlnx_qmb700 Configuration Header - * - * @addtogroup x86_64_mlnx_qmb700-config - * @{ - * - *****************************************************************************/ -#ifndef __X86_64_MLNX_QMB700_CONFIG_H__ -#define __X86_64_MLNX_QMB700_CONFIG_H__ - -#ifdef GLOBAL_INCLUDE_CUSTOM_CONFIG -#include -#endif -#ifdef X86_64_MLNX_QMB700_INCLUDE_CUSTOM_CONFIG -#include -#endif - -/* */ -#include -/** - * X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING - * - * Include or exclude logging. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING -#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING 1 -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT - * - * Default enabled log options. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT -#define X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT AIM_LOG_OPTIONS_DEFAULT -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT - * - * Default enabled log bits. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT -#define X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT AIM_LOG_BITS_DEFAULT -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT - * - * Default enabled custom log bits. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT -#define X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT 0 -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB - * - * Default all porting macros to use the C standard libraries. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB -#define X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB 1 -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS - * - * Include standard library headers for stdlib porting macros. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS -#define X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI - * - * Include generic uCli support. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI -#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI 0 -#endif - -/** - * X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION - * - * Assume chassis fan direction is the same as the PSU fan direction. */ - - -#ifndef X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION -#define X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION 0 -#endif - - - -/** - * All compile time options can be queried or displayed - */ - -/** Configuration settings structure. */ -typedef struct x86_64_mlnx_qmb700_config_settings_s { - /** name */ - const char* name; - /** value */ - const char* value; -} x86_64_mlnx_qmb700_config_settings_t; - -/** Configuration settings table. */ -/** x86_64_mlnx_qmb700_config_settings table. */ -extern x86_64_mlnx_qmb700_config_settings_t x86_64_mlnx_qmb700_config_settings[]; - -/** - * @brief Lookup a configuration setting. - * @param setting The name of the configuration option to lookup. - */ -const char* x86_64_mlnx_qmb700_config_lookup(const char* setting); - -/** - * @brief Show the compile-time configuration. - * @param pvs The output stream. - */ -int x86_64_mlnx_qmb700_config_show(struct aim_pvs_s* pvs); - -/* */ - -#include "x86_64_mlnx_qmb700_porting.h" - -#endif /* __X86_64_MLNX_QMB700_CONFIG_H__ */ -/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h deleted file mode 100644 index b647e90d..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_dox.h +++ /dev/null @@ -1,26 +0,0 @@ -/**************************************************************************//** - * - * x86_64_mlnx_qmb700 Doxygen Header - * - *****************************************************************************/ -#ifndef __X86_64_MLNX_QMB700_DOX_H__ -#define __X86_64_MLNX_QMB700_DOX_H__ - -/** - * @defgroup x86_64_mlnx_qmb700 x86_64_mlnx_qmb700 - x86_64_mlnx_qmb700 Description - * - -The documentation overview for this module should go here. - - * - * @{ - * - * @defgroup x86_64_mlnx_qmb700-x86_64_mlnx_qmb700 Public Interface - * @defgroup x86_64_mlnx_qmb700-config Compile Time Configuration - * @defgroup x86_64_mlnx_qmb700-porting Porting Macros - * - * @} - * - */ - -#endif /* __X86_64_MLNX_QMB700_DOX_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h deleted file mode 100644 index a7475fa4..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/inc/x86_64_mlnx_qmb700/x86_64_mlnx_qmb700_porting.h +++ /dev/null @@ -1,107 +0,0 @@ -/**************************************************************************//** - * - * @file - * @brief x86_64_mlnx_qmb700 Porting Macros. - * - * @addtogroup x86_64_mlnx_qmb700-porting - * @{ - * - *****************************************************************************/ -#ifndef __X86_64_MLNX_QMB700_PORTING_H__ -#define __X86_64_MLNX_QMB700_PORTING_H__ - - -/* */ -#if X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS == 1 -#include -#include -#include -#include -#include -#endif - -#ifndef X86_64_MLNX_QMB700_MALLOC - #if defined(GLOBAL_MALLOC) - #define X86_64_MLNX_QMB700_MALLOC GLOBAL_MALLOC - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_MALLOC malloc - #else - #error The macro X86_64_MLNX_QMB700_MALLOC is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_FREE - #if defined(GLOBAL_FREE) - #define X86_64_MLNX_QMB700_FREE GLOBAL_FREE - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_FREE free - #else - #error The macro X86_64_MLNX_QMB700_FREE is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_MEMSET - #if defined(GLOBAL_MEMSET) - #define X86_64_MLNX_QMB700_MEMSET GLOBAL_MEMSET - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_MEMSET memset - #else - #error The macro X86_64_MLNX_QMB700_MEMSET is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_MEMCPY - #if defined(GLOBAL_MEMCPY) - #define X86_64_MLNX_QMB700_MEMCPY GLOBAL_MEMCPY - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_MEMCPY memcpy - #else - #error The macro X86_64_MLNX_QMB700_MEMCPY is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_STRNCPY - #if defined(GLOBAL_STRNCPY) - #define X86_64_MLNX_QMB700_STRNCPY GLOBAL_STRNCPY - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_STRNCPY strncpy - #else - #error The macro X86_64_MLNX_QMB700_STRNCPY is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_VSNPRINTF - #if defined(GLOBAL_VSNPRINTF) - #define X86_64_MLNX_QMB700_VSNPRINTF GLOBAL_VSNPRINTF - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_VSNPRINTF vsnprintf - #else - #error The macro X86_64_MLNX_QMB700_VSNPRINTF is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_SNPRINTF - #if defined(GLOBAL_SNPRINTF) - #define X86_64_MLNX_QMB700_SNPRINTF GLOBAL_SNPRINTF - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_SNPRINTF snprintf - #else - #error The macro X86_64_MLNX_QMB700_SNPRINTF is required but cannot be defined. - #endif -#endif - -#ifndef X86_64_MLNX_QMB700_STRLEN - #if defined(GLOBAL_STRLEN) - #define X86_64_MLNX_QMB700_STRLEN GLOBAL_STRLEN - #elif X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB == 1 - #define X86_64_MLNX_QMB700_STRLEN strlen - #else - #error The macro X86_64_MLNX_QMB700_STRLEN is required but cannot be defined. - #endif -#endif - -/* */ - - -#endif /* __X86_64_MLNX_QMB700_PORTING_H__ */ -/* @} */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c deleted file mode 100644 index 25e8d508..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_config.c +++ /dev/null @@ -1,81 +0,0 @@ -/**************************************************************************//** - * - * - * - *****************************************************************************/ -#include - -/* */ -#define __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(_x) #_x -#define __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(_x) __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(_x) -x86_64_mlnx_qmb700_config_settings_t x86_64_mlnx_qmb700_config_settings[] = -{ -#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_LOGGING(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_PORTING_STDLIB(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_PORTING_INCLUDE_STDLIB_HEADERS(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_UCLI(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif -#ifdef X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION - { __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME(X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION), __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE(X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION) }, -#else -{ X86_64_MLNX_QMB700_CONFIG_INCLUDE_DEFAULT_FAN_DIRECTION(__X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME), "__undefined__" }, -#endif - { NULL, NULL } -}; -#undef __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_VALUE -#undef __X86_64_MLNX_QMB700_CONFIG_STRINGIFY_NAME - -const char* -x86_64_mlnx_qmb700_config_lookup(const char* setting) -{ - int i; - for(i = 0; x86_64_mlnx_qmb700_config_settings[i].name; i++) { - if(strcmp(x86_64_mlnx_qmb700_config_settings[i].name, setting)) { - return x86_64_mlnx_qmb700_config_settings[i].value; - } - } - return NULL; -} - -int -x86_64_mlnx_qmb700_config_show(struct aim_pvs_s* pvs) -{ - int i; - for(i = 0; x86_64_mlnx_qmb700_config_settings[i].name; i++) { - aim_printf(pvs, "%s = %s\n", x86_64_mlnx_qmb700_config_settings[i].name, x86_64_mlnx_qmb700_config_settings[i].value); - } - return i; -} - -/* */ - diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h deleted file mode 100644 index 13144c54..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_int.h +++ /dev/null @@ -1,12 +0,0 @@ -/**************************************************************************//** - * - * x86_64_mlnx_qmb700 Internal Header - * - *****************************************************************************/ -#ifndef __X86_64_MLNX_QMB700_INT_H__ -#define __X86_64_MLNX_QMB700_INT_H__ - -#include - - -#endif /* __X86_64_MLNX_QMB700_INT_H__ */ diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c deleted file mode 100644 index 9c54abb6..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_log.c +++ /dev/null @@ -1,18 +0,0 @@ -/**************************************************************************//** - * - * - * - *****************************************************************************/ -#include - -#include "x86_64_mlnx_qmb700_log.h" -/* - * x86_64_mlnx_qmb700 log struct. - */ -AIM_LOG_STRUCT_DEFINE( - X86_64_MLNX_QMB700_CONFIG_LOG_OPTIONS_DEFAULT, - X86_64_MLNX_QMB700_CONFIG_LOG_BITS_DEFAULT, - NULL, /* Custom log map */ - X86_64_MLNX_QMB700_CONFIG_LOG_CUSTOM_BITS_DEFAULT - ); - diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c deleted file mode 100644 index b9953c97..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_module.c +++ /dev/null @@ -1,24 +0,0 @@ -/**************************************************************************//** - * - * - * - *****************************************************************************/ -#include - -#include "x86_64_mlnx_qmb700_log.h" - -static int -datatypes_init__(void) -{ -#define x86_64_mlnx_qmb700_ENUMERATION_ENTRY(_enum_name, _desc) AIM_DATATYPE_MAP_REGISTER(_enum_name, _enum_name##_map, _desc, AIM_LOG_INTERNAL); -#include - return 0; -} - -void __x86_64_mlnx_qmb700_module_init__(void) -{ - AIM_LOG_STRUCT_REGISTER(); - datatypes_init__(); -} - -int __onlp_platform_version__ = 1; diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c deleted file mode 100644 index db0decf3..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/module/src/x86_64_mlnx_qmb700_ucli.c +++ /dev/null @@ -1,50 +0,0 @@ -/**************************************************************************//** - * - * - * - *****************************************************************************/ -#include - -#if x86_64_mlnx_qmb700_CONFIG_INCLUDE_UCLI == 1 - -#include -#include -#include - -static ucli_status_t -x86_64_mlnx_qmb700_ucli_ucli__config__(ucli_context_t* uc) -{ - UCLI_HANDLER_MACRO_MODULE_CONFIG(x86_64_mlnx_qmb700) -} - -/* */ -/* */ - -static ucli_module_t -x86_64_mlnx_qmb700_ucli_module__ = - { - "x86_64_mlnx_qmb700_ucli", - NULL, - x86_64_mlnx_qmb700_ucli_ucli_handlers__, - NULL, - NULL, - }; - -ucli_node_t* -x86_64_mlnx_qmb700_ucli_node_create(void) -{ - ucli_node_t* n; - ucli_module_init(&x86_64_mlnx_qmb700_ucli_module__); - n = ucli_node_create("x86_64_mlnx_qmb700", NULL, &x86_64_mlnx_qmb700_ucli_module__); - ucli_node_subnode_add(n, ucli_module_log_node_create("x86_64_mlnx_qmb700")); - return n; -} - -#else -void* -x86_64_mlnx_qmb700_ucli_node_create(void) -{ - return NULL; -} -#endif - diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk b/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk deleted file mode 100644 index 97ca08d2..00000000 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-qmb700/onlp/builds/src/x86_64_mlnx_qmb700.mk +++ /dev/null @@ -1,13 +0,0 @@ - -############################################################################### -# -# Inclusive Makefile for the x86_64_mlnx_qmb700 module. -# -# Autogenerated 2015-12-23 23:45:56.754200 -# -############################################################################### -x86_64_mlnx_qmb700_BASEDIR := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) -include $(x86_64_mlnx_qmb700_BASEDIR)/module/make.mk -include $(x86_64_mlnx_qmb700_BASEDIR)/module/auto/make.mk -include $(x86_64_mlnx_qmb700_BASEDIR)/module/src/make.mk - From 9c649d16e1af2e67a0c437b396fd8e13570d2902 Mon Sep 17 00:00:00 2001 From: Oleksandr Shamray Date: Tue, 31 Jul 2018 18:57:57 +0000 Subject: [PATCH 4/4] Fix: CPU sensors count on MQM8700 system Signed-off-by: Oleksandr Shamray --- .../onlp/builds/src/module/src/thermali.c | 13 +++---------- .../src/python/x86_64_mlnx_mqm8700_r0/__init__.py | 2 +- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c index 7011410d..fedbf1b3 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/onlp/builds/src/module/src/thermali.c @@ -36,8 +36,7 @@ enum onlp_thermal_id THERMAL_RESERVED = 0, THERMAL_CPU_CORE_0, THERMAL_CPU_CORE_1, - THERMAL_CPU_CORE_2, - THERMAL_CPU_CORE_3, + THERMAL_CPU_PACK, THERMAL_ASIC, THERMAL_BOARD_AMB, THERMAL_PORT, @@ -50,8 +49,7 @@ static char* thermal_fnames[] = /* must map with onlp_thermal_id */ "reserved", "cpu_core0", "cpu_core1", - "cpu_core2", - "cpu_core3", + "cpu_pack", "asic", "board_amb", "port_amb", @@ -71,12 +69,7 @@ static onlp_thermal_info_t tinfo[] = { ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS }, - { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_0), "CPU Core 2", 0}, - ONLP_THERMAL_STATUS_PRESENT, - ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS - }, - - { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_CORE_1), "CPU Core 3", 0}, + { { ONLP_THERMAL_ID_CREATE(THERMAL_CPU_PACK), "CPU pack", 0}, ONLP_THERMAL_STATUS_PRESENT, ONLP_THERMAL_CAPS_ALL, 0, CPU_THERMAL_THRESHOLD_INIT_DEFAULTS }, diff --git a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py index c704cb97..99fc6c29 100644 --- a/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py +++ b/packages/platforms/mellanox/x86-64/x86-64-mlnx-mqm8700/platform-config/r0/src/python/x86_64_mlnx_mqm8700_r0/__init__.py @@ -5,7 +5,7 @@ class OnlPlatform_x86_64_mlnx_mqm8700_r0(OnlPlatformMellanox, OnlPlatformPortConfig_32x100): PLATFORM='x86-64-mlnx-mqm8700-r0' MODEL="MQM8700" - SYS_OBJECT_ID=".700.1" + SYS_OBJECT_ID=".8700.1" def baseconfig(self): # load modules