Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
5c28911
[Mellanox] Update SDK/FW/SAI to 4.6.1020/2012.1020/SAIBuild2305.25.0.…
keboliu Aug 15, 2023
b6fba8a
buildimage commit for infra - indep module
noaOrMlnx Sep 20, 2023
64818c3
add independent mode support profile for msn4700 SKU
dbarashinvd Aug 14, 2023
35e1548
temp commit for independent modules code
dbarashinvd Aug 17, 2023
dbd6c9c
update modules mgmt to have new state db table
dbarashinvd Sep 20, 2023
7948b45
Change .gitmodules to represent fork repo
noaOrMlnx Sep 20, 2023
e867751
Add URL to MLNX_FW
noaOrMlnx Sep 21, 2023
7e7c858
Change submodules pointer
noaOrMlnx Sep 21, 2023
9c9834c
Update submodule of sonic-sairedis
Junchao-Mellanox Sep 22, 2023
f29b2ab
[Mellanox] Remove unnecessary file manipulation in the SAI Make file…
keboliu Aug 3, 2023
08f6b53
Fix issues in module static detection
Junchao-Mellanox Sep 25, 2023
76a273c
Update platform wait to not wait for sfp_counter and module_counter
Junchao-Mellanox Sep 25, 2023
c187501
Update submodule for reading/writing EEPROM by page and offset
Junchao-Mellanox Sep 28, 2023
c8e0abf
Update submodule for debug tool
Junchao-Mellanox Sep 28, 2023
649e079
Update swss and sairedis submodules pointers
noaOrMlnx Sep 28, 2023
ad3c1ef
update modules mgmt to have new state db table
dbarashinvd Sep 20, 2023
627410c
Fix issues and separate to static module detection
dbarashinvd Sep 26, 2023
3129f44
Update submodules & add late-create flag to sai.xml
noaOrMlnx Oct 1, 2023
c1cb242
fix issues and change waiting list to Set
dbarashinvd Oct 1, 2023
694db48
Remove skip_cmis_mgr flag for msn4700
noaOrMlnx Oct 4, 2023
690e37a
Adding jsons to conifgure ASIC and modules
tshalvi Oct 8, 2023
4c84d77
platform code changes to ignore EEPROM restirctions when dealing with…
tshalvi Oct 10, 2023
5e1204e
Uncommenting limited_eeprom workaround
tshalvi Oct 10, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
[submodule "sonic-swss-common"]
path = src/sonic-swss-common
url = https://github.com/sonic-net/sonic-swss-common
url = https://github.com/noaOrMlnx/sonic-swss-common
[submodule "sonic-linux-kernel"]
path = src/sonic-linux-kernel
url = https://github.com/sonic-net/sonic-linux-kernel
[submodule "sonic-sairedis"]
path = src/sonic-sairedis
url = https://github.com/sonic-net/sonic-sairedis
url = https://github.com/noaOrMlnx/sonic-sairedis
[submodule "sonic-swss"]
path = src/sonic-swss
url = https://github.com/sonic-net/sonic-swss
url = https://github.com/noaOrMlnx/sonic-swss
[submodule "src/p4c-bm/p4c-bm"]
path = platform/p4/p4c-bm/p4c-bm
url = https://github.com/krambn/p4c-bm
Expand All @@ -30,16 +30,16 @@
url = https://github.com/p4lang/ptf.git
[submodule "src/sonic-utilities"]
path = src/sonic-utilities
url = https://github.com/sonic-net/sonic-utilities
url = https://github.com/noaOrMlnx/sonic-utilities
[submodule "platform/broadcom/sonic-platform-modules-arista"]
path = platform/broadcom/sonic-platform-modules-arista
url = https://github.com/aristanetworks/sonic
[submodule "src/sonic-platform-common"]
path = src/sonic-platform-common
url = https://github.com/sonic-net/sonic-platform-common
url = https://github.com/noaOrMlnx/sonic-platform-common
[submodule "src/sonic-platform-daemons"]
path = src/sonic-platform-daemons
url = https://github.com/sonic-net/sonic-platform-daemons
url = https://github.com/noaOrMlnx/sonic-platform-daemons
[submodule "src/sonic-platform-pde"]
path = src/sonic-platform-pde
url = https://github.com/sonic-net/sonic-platform-pdk-pde
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SAI_INDEPENDENT_MODULE_MODE=1
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
<!-- Number of ports in the following port list -->
<number-of-physical-ports>32</number-of-physical-ports>

<!-- Global port late create -->
<late-create-all-ports>1</late-create-all-ports>

<!-- List of ports in the device -->
<ports-list>
<port-info>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
SAI_INDEPENDENT_MODULE_MODE=1
191 changes: 191 additions & 0 deletions device/mellanox/x86_64-mlnx_msn4700-r0/media_settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,191 @@
{
"GLOBAL_MEDIA_SETTINGS":{
"0-31":{
"QSFP28-40GBASE-CR4-3M":{
"speed:400G-GAUI-4":{
"main":{
"lane0": "0x00000088",
"lane1": "0x00000088",
"lane2": "0x0000008c",
"lane3": "0x00000088",
"lane4": "0x0000008c",
"lane5": "0x0000008c",
"lane6": "0x0000008c",
"lane7": "0x0000008c"
}
},
"speed:400GAUI-8":{
"post1":{
"lane0": "0x00000000",
"lane1": "0x00000000",
"lane2": "0x00000000",
"lane3": "0x00000000",
"lane4": "0x00000000",
"lane5": "0x00000000",
"lane6": "0x00000000",
"lane7": "0x00000000"
}
}
},
"QSFP-DD-*":{
"speed:400GAUI-8":{
"idriver":{
"lane0": "0x0000003c",
"lane1": "0x0000003c",
"lane2": "0x0000003c",
"lane3": "0x0000003c",
"lane4": "0x0000003c",
"lane5": "0x0000003c",
"lane6": "0x0000003c",
"lane7": "0x0000003c"
},
"pre1":{
"lane0": "0x00000002",
"lane1": "0x00000002",
"lane2": "0x00000002",
"lane3": "0x00000002",
"lane4": "0x00000002",
"lane5": "0x00000002",
"lane6": "0x00000002",
"lane7": "0x00000002"
},
"pre2":{
"lane0": "0x00000000",
"lane1": "0x00000000",
"lane2": "0x00000000",
"lane3": "0x00000000",
"lane4": "0x00000000",
"lane5": "0x00000000",
"lane6": "0x00000000",
"lane7": "0x00000000"
},
"pre3":{
"lane0": "0x00000000",
"lane1": "0x00000000",
"lane2": "0x00000000",
"lane3": "0x00000000",
"lane4": "0x00000000",
"lane5": "0x00000000",
"lane6": "0x00000000",
"lane7": "0x00000000"
},
"main":{
"lane0": "0x00000020",
"lane1": "0x00000020",
"lane2": "0x00000020",
"lane3": "0x00000020",
"lane4": "0x00000020",
"lane5": "0x00000020",
"lane6": "0x00000020",
"lane7": "0x00000020"
},
"post1":{
"lane0": "0x00000006",
"lane1": "0x00000006",
"lane2": "0x00000006",
"lane3": "0x00000006",
"lane4": "0x00000006",
"lane5": "0x00000006",
"lane6": "0x00000006",
"lane7": "0x00000006"
},
"ob_m2lp":{
"lane0": "0x0000000e",
"lane1": "0x0000000e",
"lane2": "0x0000000e",
"lane3": "0x0000000e",
"lane4": "0x0000000e",
"lane5": "0x0000000e",
"lane6": "0x0000000e",
"lane7": "0x0000000e"
},
"ob_alev_out":{
"lane0": "0x0000000f",
"lane1": "0x0000000f",
"lane2": "0x0000000f",
"lane3": "0x0000000f",
"lane4": "0x0000000f",
"lane5": "0x0000000f",
"lane6": "0x0000000f",
"lane7": "0x0000000f"
},
"obplev":{
"lane0": "0x00000069",
"lane1": "0x00000069",
"lane2": "0x00000069",
"lane3": "0x00000069",
"lane4": "0x00000069",
"lane5": "0x00000069",
"lane6": "0x00000069",
"lane7": "0x00000069"
},
"obnlev":{
"lane0": "0x0000005f",
"lane1": "0x0000005f",
"lane2": "0x0000005f",
"lane3": "0x0000005f",
"lane4": "0x0000005f",
"lane5": "0x0000005f",
"lane6": "0x0000005f",
"lane7": "0x0000005f"
},
"regn_bfm1p":{
"lane0": "0x0000001e",
"lane1": "0x0000001e",
"lane2": "0x0000001e",
"lane3": "0x0000001e",
"lane4": "0x0000001e",
"lane5": "0x0000001e",
"lane6": "0x0000001e",
"lane7": "0x0000001e"
},
"regn_bfm1p":{
"lane0": "0x000000aa",
"lane1": "0x000000aa",
"lane2": "0x000000aa",
"lane3": "0x000000aa",
"lane4": "0x000000aa",
"lane5": "0x000000aa",
"lane6": "0x000000aa",
"lane7": "0x000000aa"
}
}
},
"AMPHENOL-1234":{
"speed:400GAUI-8":{
"main":{
"lane0": "0x00000004",
"lane1": "0x00000005",
"lane2": "0x00000006",
"lane3": "0x00000007",
"lane4": "0x0000000b",
"lane5": "0x0000000c",
"lane6": "0x0000000d",
"lane7": "0x0000000e"
},
"ob_m2lp":{
"lane0": "0x00000008",
"lane1": "0x00000009",
"lane2": "0x0000000a",
"lane3": "0x0000000b",
"lane4": "0x0000000b",
"lane5": "0x0000000c",
"lane6": "0x0000000d",
"lane7": "0x0000000e"
},
"regn_bfm1p":{
"lane0": "0x0000000c",
"lane1": "0x0000000d",
"lane2": "0x0000000e",
"lane3": "0x0000000f",
"lane4": "0x0000000b",
"lane5": "0x0000000c",
"lane6": "0x0000000d",
"lane7": "0x0000000e"
}
}
}
}
}
}

78 changes: 78 additions & 0 deletions device/mellanox/x86_64-mlnx_msn4700-r0/optics_si_settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"GLOBAL_MEDIA_SETTINGS": {
"11-30": {
"50G_SPEED": {
"Default": {
"OutputAmplitudeTargetRx": {
"OutputAmplitudeTargetRx1": 0,
"OutputAmplitudeTargetRx2": 0,
"OutputAmplitudeTargetRx3": 0,
"OutputAmplitudeTargetRx4": 0,
"OutputAmplitudeTargetRx5": 0,
"OutputAmplitudeTargetRx6": 0,
"OutputAmplitudeTargetRx7": 0,
"OutputAmplitudeTargetRx8": 0
},
"OutputEqPreCursorTargetRx": {
"OutputEqPreCursorTargetRx1": 0,
"OutputEqPreCursorTargetRx2": 0,
"OutputEqPreCursorTargetRx3": 0,
"OutputEqPreCursorTargetRx4": 0,
"OutputEqPreCursorTargetRx5": 0,
"OutputEqPreCursorTargetRx6": 0,
"OutputEqPreCursorTargetRx7": 0,
"OutputEqPreCursorTargetRx8": 0
},
"OutputEqPostCursorTargetRx": {
"OutputEqPostCursorTargetRx1": 0,
"OutputEqPostCursorTargetRx2": 0,
"OutputEqPostCursorTargetRx3": 0,
"OutputEqPostCursorTargetRx4": 0,
"OutputEqPostCursorTargetRx5": 0,
"OutputEqPostCursorTargetRx6": 0,
"OutputEqPostCursorTargetRx7": 0,
"OutputEqPostCursorTargetRx8": 0
}
}
}
},
"1-10,31-40": {
"50G_SPEED": {
"Default": {
"OutputAmplitudeTargetRx": {
"OutputAmplitudeTargetRx1": 0,
"OutputAmplitudeTargetRx2": 0,
"OutputAmplitudeTargetRx3": 0,
"OutputAmplitudeTargetRx4": 0,
"OutputAmplitudeTargetRx5": 0,
"OutputAmplitudeTargetRx6": 0,
"OutputAmplitudeTargetRx7": 0,
"OutputAmplitudeTargetRx8": 0
},
"OutputEqPreCursorTargetRx": {
"OutputEqPreCursorTargetRx1": 0,
"OutputEqPreCursorTargetRx2": 0,
"OutputEqPreCursorTargetRx3": 0,
"OutputEqPreCursorTargetRx4": 0,
"OutputEqPreCursorTargetRx5": 0,
"OutputEqPreCursorTargetRx6": 0,
"OutputEqPreCursorTargetRx7": 0,
"OutputEqPreCursorTargetRx8": 0
},
"OutputEqPostCursorTargetRx": {
"OutputEqPostCursorTargetRx1": 0,
"OutputEqPostCursorTargetRx2": 0,
"OutputEqPostCursorTargetRx3": 0,
"OutputEqPostCursorTargetRx4": 0,
"OutputEqPostCursorTargetRx5": 0,
"OutputEqPostCursorTargetRx6": 0,
"OutputEqPostCursorTargetRx7": 0,
"OutputEqPostCursorTargetRx8": 0
}
}
}
}
}
}


1 change: 0 additions & 1 deletion device/mellanox/x86_64-mlnx_msn4700-r0/platform_wait

This file was deleted.

69 changes: 69 additions & 0 deletions device/mellanox/x86_64-mlnx_msn4700-r0/platform_wait
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#!/bin/bash

declare -r SYSLOG_LOGGER="/usr/bin/logger"
declare -r SYSLOG_IDENTIFIER="platform_wait"
declare -r SYSLOG_ERROR="error"
declare -r SYSLOG_NOTICE="notice"
declare -r SYSLOG_INFO="info"

declare -r HW_MGMT_CONFIG="/var/run/hw-management/config"

declare -r MODULE_COUNTER="${HW_MGMT_CONFIG}/module_counter"
declare -r SFP_COUNTER="${HW_MGMT_CONFIG}/sfp_counter"

declare -r EXIT_SUCCESS="0"
declare -r EXIT_TIMEOUT="1"

function log_error() {
eval "${SYSLOG_LOGGER} -t ${SYSLOG_IDENTIFIER} -p ${SYSLOG_ERROR} $@"
}

function log_notice() {
eval "${SYSLOG_LOGGER} -t ${SYSLOG_IDENTIFIER} -p ${SYSLOG_NOTICE} $@"
}

function log_info() {
eval "${SYSLOG_LOGGER} -t ${SYSLOG_IDENTIFIER} -p ${SYSLOG_INFO} $@"
}

function wait_for_sfp() {
local -r _NUM_MATCH="^[0-9]+$"
local -r _NUM_ZERO="0"

local _MODULE_CNT="0"
local _SFP_CNT="0"

local -i _WDOG_CNT="1"
local -ir _WDOG_MAX="300"

local -r _TIMEOUT="1s"

while [[ "${_WDOG_CNT}" -le "${_WDOG_MAX}" ]]; do
_MODULE_CNT="$(cat ${MODULE_COUNTER} 2>&1)"
_SFP_CNT="$(cat ${SFP_COUNTER} 2>&1)"

if [[ "${_MODULE_CNT}" =~ ${_NUM_MATCH} && "${_SFP_CNT}" =~ ${_NUM_MATCH} ]]; then
if [[ "${_SFP_CNT}" -gt "${_NUM_ZERO}" && "${_MODULE_CNT}" -eq "${_SFP_CNT}" ]]; then
return "${EXIT_SUCCESS}"
fi
fi

let "_WDOG_CNT++"
sleep "${_TIMEOUT}"
done

return "${EXIT_TIMEOUT}"
}

log_info "Wait for SFP interfaces to be ready"

sleep 60
EXIT_CODE="$?"
if [[ "${EXIT_CODE}" != "${EXIT_SUCCESS}" ]]; then
log_error "SFP interfaces are not ready: timeout"
exit "${EXIT_CODE}"
fi

log_info "SFP interfaces are ready"

exit "${EXIT_SUCCESS}"

This file was deleted.

Loading