diff --git a/.azure-pipelines/azure-pipelines-UpgrateVersion.yml b/.azure-pipelines/azure-pipelines-UpgrateVersion.yml index 33f802b0d56c..1d2a0fbae6dc 100644 --- a/.azure-pipelines/azure-pipelines-UpgrateVersion.yml +++ b/.azure-pipelines/azure-pipelines-UpgrateVersion.yml @@ -42,12 +42,32 @@ parameters: - mellanox stages: +- stage: Prepare + jobs: + - job: Prepare + steps: + - script: | + DEFAULT_MIRROR_URL_PREFIX=http://packages.trafficmanager.net + DEBIAN_TIMESTAMP=$(curl $DEFAULT_MIRROR_URL_PREFIX/snapshot/debian/latest/timestamp) + DEBIAN_SECURITY_TIMESTAMP=$(curl $DEFAULT_MIRROR_URL_PREFIX/snapshot/debian-security/latest/timestamp) + echo "DEBIAN_TIMESTAMP=$DEBIAN_TIMESTAMP, DEBIAN_SECURITY_TIMESTAMP=$DEBIAN_SECURITY_TIMESTAMP" + echo "##vso[task.setvariable variable=DEBIAN_TIMESTAMP;isOutput=true]$DEBIAN_TIMESTAMP" + echo "##vso[task.setvariable variable=DEBIAN_SECURITY_TIMESTAMP;isOutput=true]$DEBIAN_SECURITY_TIMESTAMP" + name: SetVersions + displayName: 'Set snapshot versions' - stage: Build + dependsOn: Prepare variables: - name: CACHE_MODE value: none - name: VERSION_CONTROL_OPTIONS value: 'SONIC_VERSION_CONTROL_COMPONENTS=' + - name: SKIP_CHECKOUT + value: true + - name: DEBIAN_TIMESTAMP + value: $[ stageDependencies.Prepare.Prepare.outputs['SetVersions.DEBIAN_TIMESTAMP'] ] + - name: DEBIAN_SECURITY_TIMESTAMP + value: $[ stageDependencies.Prepare.Prepare.outputs['SetVersions.DEBIAN_SECURITY_TIMESTAMP'] ] - template: .azure-pipelines/template-variables.yml@buildimage jobs: - template: azure-pipelines-build.yml @@ -56,6 +76,21 @@ stages: buildOptions: '${{ variables.VERSION_CONTROL_OPTIONS }} ENABLE_DOCKER_BASE_PULL=n SONIC_BUILD_JOBS=$(nproc) ENABLE_IMAGE_SIGNATURE=y' preSteps: - template: .azure-pipelines/template-clean-sonic-slave.yml@buildimage + - checkout: self + submodules: recursive + fetchDepth: 0 + path: s + displayName: 'Checkout code' + - script: | + echo "DEBIAN_TIMESTAMP=$DEBIAN_TIMESTAMP, DEBIAN_SECURITY_TIMESTAMP=$DEBIAN_SECURITY_TIMESTAMP" + if [ "$MIRROR_SNAPSHOT" == y ]; then + mkdir -p target/versions/default/ + echo "debian==$DEBIAN_TIMESTAMP" > target/versions/default/versions-mirror + echo "debian-security==$DEBIAN_SECURITY_TIMESTAMP" >> target/versions/default/versions-mirror + cat target/versions/default/versions-mirror + fi + displayName: 'Set snapshot versions' + - stage: UpgradeVersions jobs: - job: UpgradeVersions diff --git a/.azure-pipelines/azure-pipelines-build.yml b/.azure-pipelines/azure-pipelines-build.yml index 09a46573fe0f..92897231dab9 100644 --- a/.azure-pipelines/azure-pipelines-build.yml +++ b/.azure-pipelines/azure-pipelines-build.yml @@ -108,7 +108,8 @@ jobs: platform_rpc: nephos buildSteps: - - template: template-skipvstest.yml + - template: .azure-pipelines/template-skipvstest.yml@buildimage + - template: .azure-pipelines/template-daemon.yml@buildimage - bash: | set -ex if [ $(GROUP_NAME) == vs ]; then @@ -168,4 +169,4 @@ jobs: make $BUILD_OPTIONS target/sonic-$(GROUP_NAME).bin fi displayName: "Build sonic image" - - template: check-dirty-version.yml + - template: .azure-pipelines/check-dirty-version.yml@buildimage diff --git a/.azure-pipelines/azure-pipelines-image-template.yml b/.azure-pipelines/azure-pipelines-image-template.yml index 67d75abc6887..d4d2c96e1c61 100644 --- a/.azure-pipelines/azure-pipelines-image-template.yml +++ b/.azure-pipelines/azure-pipelines-image-template.yml @@ -25,7 +25,7 @@ jobs: jobFilters: ${{ parameters.jobFilters }} jobVariables: ${{ parameters.jobVariables }} preSteps: - - template: cleanup.yml + - template: .azure-pipelines/cleanup.yml@buildimage - ${{ parameters.preSteps }} - script: | if [ -n "$(CACHE_MODE)" ] && echo $(PLATFORM_AZP) | grep -E -q "^(vs|broadcom|mellanox|marvell-armhf)$"; then @@ -67,6 +67,6 @@ jobs: artifactName: 'sonic-buildimage.$(GROUP_NAME)$(GROUP_EXTNAME)' publishPrefix: '$(Build.DefinitionName)/$(Build.SourceBranchName)/$(GROUP_NAME)' - ${{ parameters.postSteps }} - - template: cleanup.yml + - template: .azure-pipelines/cleanup.yml@buildimage jobGroups: ${{ parameters.jobGroups }} buildSteps: ${{ parameters.buildSteps }} diff --git a/.azure-pipelines/cleanup.yml b/.azure-pipelines/cleanup.yml index 6569c8ed0bf3..4f74de0f413a 100644 --- a/.azure-pipelines/cleanup.yml +++ b/.azure-pipelines/cleanup.yml @@ -1,5 +1,11 @@ steps: - script: | + set -x + # kill daemon process + ps $(cat /tmp/azp_daemon_kill_docker_pid) + sudo kill $(cat /tmp/azp_daemon_kill_docker_pid) + rm /tmp/azp_daemon_kill_docker_pid + if sudo [ -f /var/run/march/docker.pid ] ; then pid=`sudo cat /var/run/march/docker.pid` ; sudo kill $pid fi @@ -11,4 +17,5 @@ steps: pid=`sudo cat dockerfs/var/run/docker.pid` ; sudo kill $pid fi sudo rm -rf $(ls -A1) + condition: always() displayName: "Clean Workspace" diff --git a/.azure-pipelines/template-daemon.yml b/.azure-pipelines/template-daemon.yml new file mode 100644 index 000000000000..903e10c2d5c6 --- /dev/null +++ b/.azure-pipelines/template-daemon.yml @@ -0,0 +1,24 @@ +steps: +- bash: | + ( + while true + do + sleep 120 + now=$(date +%s) + pids=$(ps -C docker -o pid,etime,args | grep "docker build" | cut -d" " -f2) + for pid in $pids + do + start=$(date --date="$(ls -dl /proc/$pid --time-style full-iso | awk '{print$6,$7}')" +%s) + time_s=$(($now-$start)) + if [[ $time_s -gt $(DOCKER_BUILD_TIMEOUT) ]]; then + echo =========== $(date +%F%T) $time_s &>> target/daemon.log + ps $pid &>> target/daemon.log + sudo kill $pid + fi + done + done + ) & + daemon_pid=$! + ps $daemon_pid + echo $daemon_pid >> /tmp/azp_daemon_kill_docker_pid + displayName: start daemon to kill hang docker diff --git a/.azure-pipelines/template-variables.yml b/.azure-pipelines/template-variables.yml index ce2ec6874315..42d46182d263 100644 --- a/.azure-pipelines/template-variables.yml +++ b/.azure-pipelines/template-variables.yml @@ -5,3 +5,4 @@ variables: SONIC_BUILD_RETRY_COUNT: 3 SONIC_BUILD_RETRY_INTERVAL: 600 DOCKER_BUILDKIT: 0 + DOCKER_BUILD_TIMEOUT: 3600 diff --git a/Makefile.work b/Makefile.work index 0d11c23a7511..8116171a9275 100644 --- a/Makefile.work +++ b/Makefile.work @@ -56,6 +56,10 @@ # * GZ_COMPRESS_PROGRAM: Select pigz to reduce build time # * Default: gzip # * Values: pigz,gzip +# * UNATTENDED: Don't wait for interactive input from terminal, setting this +# * value to anything will enable it +# * Default: unset +# * Value: y # ############################################################################### @@ -495,6 +499,7 @@ SONIC_BUILD_INSTRUCTION := $(MAKE) \ MDEBUG=$(MDEBUG) \ PASSWORD=$(PASSWORD) \ USERNAME=$(USERNAME) \ + CHANGE_DEFAULT_PASSWORD=$(CHANGE_DEFAULT_PASSWORD) \ SONIC_BUILD_JOBS=$(SONIC_BUILD_JOBS) \ SONIC_USE_DOCKER_BUILDKIT=$(SONIC_USE_DOCKER_BUILDKIT) \ VS_PREPARE_MEM=$(VS_PREPARE_MEM) \ @@ -558,6 +563,7 @@ endif export MIRROR_URLS export MIRROR_SECURITY_URLS +export SONIC_VERSION_CONTROL_COMPONENTS %:: | sonic-build-hooks ifneq ($(filter y, $(MULTIARCH_QEMU_ENVIRON) $(CROSS_BUILD_ENVIRON)),) @@ -613,23 +619,28 @@ init : .ONESHELL : reset reset : - $(Q)echo && echo -n "Warning! All local changes will be lost. Proceed? [y/N]: " - $(Q)read ans && ( - if [ $$ans == y ]; then - echo "Resetting local repository. Please wait..."; - sudo rm -rf fsroot*; - if [ "$(MULTIARCH_QEMU_ENVIRON)" == y ] && [[ "$(CONFIGURED_ARCH)" == "armhf" || "$(CONFIGURED_ARCH)" == "arm64" ]]; then - echo "Stopping march $(CONFIGURED_ARCH) docker" - sudo kill -9 `sudo cat /var/run/march/docker.pid` || true - sudo rm -f /var/run/march/docker.pid || true - fi - git clean -xfdf; - git reset --hard; - git submodule foreach --recursive 'git clean -xfdf || true'; - git submodule foreach --recursive 'git reset --hard || true'; - git submodule foreach --recursive 'git remote update || true'; - git submodule update --init --recursive; - echo "Reset complete!"; - else - echo "Reset aborted"; - fi ) + $(Q)echo && ( + if [ -z "$(UNATTENDED)" ]; then + echo -n "Warning! All local changes will be lost. Proceed? [y/N]: " + @read ans + else + ans=y + fi + if [ $$ans == y ]; then + echo "Resetting local repository. Please wait..."; + sudo rm -rf fsroot*; + if [ "$(MULTIARCH_QEMU_ENVIRON)" == y ] && [[ "$(CONFIGURED_ARCH)" == "armhf" || "$(CONFIGURED_ARCH)" == "arm64" ]]; then + echo "Stopping march $(CONFIGURED_ARCH) docker" + sudo kill -9 `sudo cat /var/run/march/docker.pid` || true + sudo rm -f /var/run/march/docker.pid || true + fi + git clean -xfdf; + git reset --hard; + git submodule foreach --recursive 'git clean -xfdf || true'; + git submodule foreach --recursive 'git reset --hard || true'; + git submodule foreach --recursive 'git remote update || true'; + git submodule update --init --recursive; + echo "Reset complete!"; + else + echo "Reset aborted"; + fi ) diff --git a/README.md b/README.md index 0aa24bebfb67..05c9f5102c98 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,3 @@ -*static analysis*: - -[![Total alerts](https://img.shields.io/lgtm/alerts/g/Azure/sonic-buildimage.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/Azure/sonic-buildimage/alerts/) -[![Language grade: Python](https://img.shields.io/lgtm/grade/python/g/Azure/sonic-buildimage.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/Azure/sonic-buildimage/context:python) - *master builds*: [![Barefoot](https://dev.azure.com/mssonic/build/_apis/build/status/barefoot/Azure.sonic-buildimage.official.barefoot?branchName=master&label=Barefoot)](https://dev.azure.com/mssonic/build/_build/latest?definitionId=146&branchName=master) diff --git a/build_debian.sh b/build_debian.sh index abc0e1fa831a..f5c9ccd297db 100755 --- a/build_debian.sh +++ b/build_debian.sh @@ -704,6 +704,16 @@ sudo LANG=C chroot $FILESYSTEM_ROOT umount /proc || true ## Prepare empty directory to trigger mount move in initramfs-tools/mount_loop_root, implemented by patching sudo mkdir $FILESYSTEM_ROOT/host + +if [[ "$CHANGE_DEFAULT_PASSWORD" == "y" ]]; then + ## Expire default password for exitsing users that can do login + default_users=$(cat $FILESYSTEM_ROOT/etc/passwd | grep "/home"| grep ":/bin/bash\|:/bin/sh" | awk -F ":" '{print $1}' 2> /dev/null) + for user in $default_users + do + sudo LANG=C chroot $FILESYSTEM_ROOT passwd -e ${user} + done +fi + ## Compress most file system into squashfs file sudo rm -f $ONIE_INSTALLER_PAYLOAD $FILESYSTEM_SQUASHFS ## Output the file system total size for diag purpose diff --git a/check_install.py b/check_install.py index b8fc3936f751..3a923e91deb6 100755 --- a/check_install.py +++ b/check_install.py @@ -11,6 +11,7 @@ def main(): parser = argparse.ArgumentParser(description='test_login cmdline parser') parser.add_argument('-u', default="admin", help='login user name') parser.add_argument('-P', default="YourPaSsWoRd", help='login password') + parser.add_argument('-N', default="Test@2022", help='new password') parser.add_argument('-p', type=int, default=9000, help='local port') args = parser.parse_args() @@ -20,6 +21,7 @@ def main(): cmd_prompt = "{}@sonic:~\$ $".format(args.u) grub_selection = "The highlighted entry will be executed" firsttime_prompt = 'firsttime_exit' + passwd_change_prompt = ['Current password:', 'New password:', 'Retype new password:'] i = 0 while True: @@ -36,7 +38,6 @@ def main(): # select default SONiC Image p.expect(grub_selection) p.sendline() - # bootup sonic image while True: i = p.expect([login_prompt, passwd_prompt, firsttime_prompt, cmd_prompt]) @@ -46,6 +47,30 @@ def main(): elif i == 1: # send password p.sendline(args.P) + # Check for password change prompt + try: + p.expect('Current password:', timeout=2) + except pexpect.TIMEOUT: + break + else: + # send old password for password prompt + p.sendline(args.P) + p.expect(passwd_change_prompt[1]) + # send new password + p.sendline(args.N) + p.expect(passwd_change_prompt[2]) + # retype new password + p.sendline(args.N) + time.sleep(1) + # Restore default password + p.sendline('passwd {}'.format(args.u)) + p.expect(passwd_change_prompt[0]) + p.sendline(args.N) + p.expect(passwd_change_prompt[1]) + p.sendline(args.P) + p.expect(passwd_change_prompt[2]) + p.sendline(args.P) + break elif i == 2: # fix a login timeout issue, caused by the login_prompt message mixed with the output message of the rc.local time.sleep(1) diff --git a/device/arista/x86_64-arista_7050_qx32s/sensors.conf b/device/arista/x86_64-arista_7050_qx32s/sensors.conf index 6030de90eea5..c130e4191274 100644 --- a/device/arista/x86_64-arista_7050_qx32s/sensors.conf +++ b/device/arista/x86_64-arista_7050_qx32s/sensors.conf @@ -11,6 +11,9 @@ bus "i2c-7" "SCD 0000:02:00.0 SMBus master 0 bus 5" chip "k10temp-pci-00c3" label temp1 "Cpu temp sensor" +chip "fam15h_power-pci-00c4" + ignore power1 + chip "max6658-i2c-2-4c" label temp1 "Board temp sensor" set temp1_max 55 @@ -34,7 +37,13 @@ chip "pmbus-i2c-6-58" label temp2 "Power supply 1 inlet temp sensor" label temp3 "Power supply 1 sensor" + ignore fan2 + ignore fan3 + chip "pmbus-i2c-5-58" label temp1 "Power supply 2 hotspot sensor" label temp2 "Power supply 2 inlet temp sensor" label temp3 "Power supply 2 sensor" + + ignore fan2 + ignore fan3 diff --git a/device/arista/x86_64-arista_7050cx3_32s/sensors.conf b/device/arista/x86_64-arista_7050cx3_32s/sensors.conf index c63a526124d0..24798a802f98 100644 --- a/device/arista/x86_64-arista_7050cx3_32s/sensors.conf +++ b/device/arista/x86_64-arista_7050cx3_32s/sensors.conf @@ -10,6 +10,9 @@ bus "i2c-14" "SCD 0000:02:00.0 SMBus master 1 bus 4" chip "k10temp-pci-00c3" label temp1 "Cpu temp sensor" +chip "fam15h_power-pci-00c4" + ignore power1 + chip "max6658-i2c-2-4c" label temp1 "Cpu board temp sensor" set temp1_max 75 @@ -33,7 +36,13 @@ chip "pmbus-i2c-13-58" label temp2 "Power supply 1 inlet temp sensor" label temp3 "Power supply 1 sensor" + ignore fan2 + ignore fan3 + chip "pmbus-i2c-14-58" label temp1 "Power supply 2 hotspot sensor" label temp2 "Power supply 2 inlet temp sensor" label temp3 "Power supply 2 sensor" + + ignore fan2 + ignore fan3 diff --git a/device/arista/x86_64-arista_7060_cx32s/sensors.conf b/device/arista/x86_64-arista_7060_cx32s/sensors.conf index 57e785881912..73349200ec5c 100644 --- a/device/arista/x86_64-arista_7060_cx32s/sensors.conf +++ b/device/arista/x86_64-arista_7060_cx32s/sensors.conf @@ -11,6 +11,9 @@ bus "i2c-7" "SCD 0000:02:00.0 SMBus master 0 bus 5" chip "k10temp-pci-00c3" label temp1 "Cpu temp sensor" +chip "fam15h_power-pci-00c4" + ignore power1 + chip "max6697-i2c-2-1a" label temp1 "Board sensor" set temp1_max 95 @@ -45,7 +48,13 @@ chip "pmbus-i2c-6-58" label temp2 "Power supply 1 inlet temp sensor" label temp3 "Power supply 1 exhaust temp sensor" + ignore fan2 + ignore fan3 + chip "pmbus-i2c-5-58" label temp1 "Power supply 2 hotspot sensor" label temp2 "Power supply 2 inlet temp sensor" label temp3 "Power supply 2 exhaust temp sensor" + + ignore fan2 + ignore fan3 diff --git a/device/arista/x86_64-arista_7280cr3mk_32p4/Arista-7280CR3-C40/gearbox_config.json b/device/arista/x86_64-arista_7280cr3mk_32p4/Arista-7280CR3-C40/gearbox_config.json index 5a1fd88d49ad..11ba880428ed 100644 --- a/device/arista/x86_64-arista_7280cr3mk_32p4/Arista-7280CR3-C40/gearbox_config.json +++ b/device/arista/x86_64-arista_7280cr3mk_32p4/Arista-7280CR3-C40/gearbox_config.json @@ -119,224 +119,544 @@ "index": 1, "phy_id": 1, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet4", "index": 2, "phy_id": 1, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet8", "index": 3, "phy_id": 1, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet12", "index": 4, "phy_id": 1, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet16", "index": 5, "phy_id": 2, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet20", "index": 6, "phy_id": 2, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet24", "index": 7, "phy_id": 2, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet28", "index": 8, "phy_id": 2, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet32", "index": 9, "phy_id": 3, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet36", "index": 10, "phy_id": 3, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet40", "index": 11, "phy_id": 3, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet44", "index": 12, "phy_id": 3, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet48", "index": 13, "phy_id": 4, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet52", "index": 14, "phy_id": 4, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-5], + "system_tx_fir_main": [11,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet56", "index": 15, "phy_id": 4, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet60", "index": 16, "phy_id": 4, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet64", "index": 17, "phy_id": 5, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet68", "index": 18, "phy_id": 5, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet72", "index": 19, "phy_id": 5, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet76", "index": 20, "phy_id": 5, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-3,-3], + "system_tx_fir_main": [11,11], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet80", "index": 21, "phy_id": 6, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet84", "index": 22, "phy_id": 6, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet88", "index": 23, "phy_id": 6, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet92", "index": 24, "phy_id": 6, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-4,-4], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet96", "index": 25, "phy_id": 7, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet100", "index": 26, "phy_id": 7, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet104", "index": 27, "phy_id": 7, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet108", "index": 28, "phy_id": 7, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet112", "index": 29, "phy_id": 8, "system_lanes": [4,5], - "line_lanes": [20,21,22,23] + "line_lanes": [20,21,22,23], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet116", "index": 30, "phy_id": 8, "system_lanes": [6,7], - "line_lanes": [8,9,10,11] + "line_lanes": [8,9,10,11], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet120", "index": 31, "phy_id": 8, "system_lanes": [0,1], - "line_lanes": [12,13,14,15] + "line_lanes": [12,13,14,15], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] }, { "name": "Ethernet124", "index": 32, "phy_id": 8, "system_lanes": [2,3], - "line_lanes": [16,17,18,19] + "line_lanes": [16,17,18,19], + "system_tx_fir_pre2": [1,1], + "system_tx_fir_pre1": [-5,-5], + "system_tx_fir_main": [14,14], + "system_tx_fir_post1": [0,0], + "system_tx_fir_post2": [0,0], + "line_tx_fir_pre2": [0,0,0,0], + "line_tx_fir_pre1": [-1,-1,-1,-1], + "line_tx_fir_main": [13,13,13,13], + "line_tx_fir_post1": [-5,-5,-5,-5], + "line_tx_fir_post2": [0,0,0,0] } ] } diff --git a/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/jr2-a7280cr3-32d4-40x100G.config.bcm b/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/jr2-a7280cr3-32d4-40x100G.config.bcm index 93c5c8d21560..a10f1f5c6f24 100644 --- a/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/jr2-a7280cr3-32d4-40x100G.config.bcm +++ b/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/jr2-a7280cr3-32d4-40x100G.config.bcm @@ -493,15 +493,16 @@ tm_port_header_type_out_233.BCM8869X=CPU tm_port_header_type_in_240.BCM8869X=INJECTED_2 tm_port_header_type_out_240.BCM8869X=RAW -sai_recycle_port_lane_base=0 -ucode_port_221.BCM8869X=RCY.21:core_0.221 -ucode_port_222.BCM8869X=RCY.22:core_1.222 -tm_port_header_type_out_221.BCM8869X=ETH -tm_port_header_type_in_221.BCM8869X=ETH -tm_port_header_type_out_222.BCM8869X=ETH -tm_port_header_type_in_222.BCM8869X=ETH -port_init_speed_221.BCM8869X=400000 -port_init_speed_222.BCM8869X=400000 +#RCY +sai_recycle_port_lane_base=200 +ucode_port_49.BCM8869X=RCY0:core_0.49 +ucode_port_50.BCM8869X=RCY1:core_1.50 +tm_port_header_type_out_49.BCM8869X=ETH +tm_port_header_type_in_49.BCM8869X=ETH +tm_port_header_type_out_50.BCM8869X=ETH +tm_port_header_type_in_50.BCM8869X=ETH +port_init_speed_49.BCM8869X=400000 +port_init_speed_50.BCM8869X=400000 # fabric port_init_cl72_sfi=1 @@ -788,6 +789,7 @@ dport_map_direct.BCM8869X=1 pmf_sexem3_stage.BCM8869X=IPMF3 rif_id_max=0x6000 +appl_param_nof_ports_per_modid=64 dma_desc_aggregator_chain_length_max.BCM8869X=1000 dma_desc_aggregator_buff_size_kb.BCM8869X=100 dma_desc_aggregator_timeout_usec.BCM8869X=1000 diff --git a/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/port_config.ini b/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/port_config.ini index 34ddd34c2806..ca11e4c0dd6b 100644 --- a/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/port_config.ini +++ b/device/arista/x86_64-arista_7800r3_48cq2_lc/Arista-7800R3-48CQ2-C48/port_config.ini @@ -47,5 +47,5 @@ Ethernet176 54,55 Ethernet45/1 45 Ext 100000 1 Ethernet180 50,51 Ethernet46/1 46 Ext 100000 1 46 8 Ethernet184 52,53 Ethernet47/1 47 Ext 100000 1 47 8 Ethernet188 48,49 Ethernet48/1 48 Ext 100000 1 48 8 -Ethernet-Rec0 221 Recirc0/0 51 Rec 400000 0 221 8 -Ethernet-IB0 222 Recirc0/1 52 Inb 400000 1 222 8 +Ethernet-Rec0 249 Recirc0/0 51 Rec 400000 0 49 8 +Ethernet-IB0 250 Recirc0/1 52 Inb 400000 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/j2p-a7800r3a-36d-36x400G.config.bcm b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/j2p-a7800r3a-36d-36x400G.config.bcm index 8421a2b9ee08..7fc12d0c432f 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/j2p-a7800r3a-36d-36x400G.config.bcm +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/j2p-a7800r3a-36d-36x400G.config.bcm @@ -263,15 +263,15 @@ tm_port_header_type_in_219=INJECTED_2 port_init_speed_sat=400000 ### RCY -sai_recycle_port_lane_base=0 -ucode_port_221=RCY.21:core_0.221 -ucode_port_222=RCY.22:core_1.222 -tm_port_header_type_out_221=ETH -tm_port_header_type_in_221=ETH -tm_port_header_type_out_222=ETH -tm_port_header_type_in_222=ETH -port_init_speed_221=400000 -port_init_speed_222=400000 +sai_recycle_port_lane_base=200 +ucode_port_49=RCY0:core_0.49 +ucode_port_50=RCY1:core_1.50 +tm_port_header_type_out_49=ETH +tm_port_header_type_in_49=ETH +tm_port_header_type_out_50=ETH +tm_port_header_type_in_50=ETH +port_init_speed_49=400000 +port_init_speed_50=400000 #OLP port tm_port_header_type_in_240=INJECTED_2 @@ -981,5 +981,6 @@ serdes_tx_taps_34=nrz:-5:83:-22:0:0:0 serdes_tx_taps_35=nrz:-4:75:-21:0:0:0 serdes_tx_taps_36=nrz:-8:89:-29:0:0:0 +appl_param_nof_ports_per_modid=64 xflow_macsec_secure_chan_to_num_secure_assoc_encrypt=2 xflow_macsec_secure_chan_to_num_secure_assoc_decrypt=2 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/port_config.ini index a72d84f584ea..f8448735b26f 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/0/port_config.ini @@ -17,5 +17,5 @@ Ethernet112 24,25,26,27 Ethernet15/1 15 Ext 100000 Eth1 Ethernet120 16,17,18,19 Ethernet16/1 16 Ext 100000 Eth120-ASIC0 0 16 8 Ethernet128 8,9,10,11 Ethernet17/1 17 Ext 100000 Eth128-ASIC0 0 17 8 Ethernet136 0,1,2,3 Ethernet18/1 18 Ext 100000 Eth136-ASIC0 0 18 8 -Ethernet-Rec0 221 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 221 8 -Ethernet-IB0 222 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 222 8 +Ethernet-Rec0 249 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 49 8 +Ethernet-IB0 250 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/j2p-a7800r3a-36d-36x400G.config.bcm b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/j2p-a7800r3a-36d-36x400G.config.bcm index 34a77903ebdf..c13991ae101f 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/j2p-a7800r3a-36d-36x400G.config.bcm +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/j2p-a7800r3a-36d-36x400G.config.bcm @@ -263,15 +263,15 @@ tm_port_header_type_in_219=INJECTED_2 port_init_speed_sat=400000 ### RCY -sai_recycle_port_lane_base=0 -ucode_port_221=RCY.21:core_0.221 -ucode_port_222=RCY.22:core_1.222 -tm_port_header_type_out_221=ETH -tm_port_header_type_in_221=ETH -tm_port_header_type_out_222=ETH -tm_port_header_type_in_222=ETH -port_init_speed_221=400000 -port_init_speed_222=400000 +sai_recycle_port_lane_base=200 +ucode_port_49=RCY0:core_0.49 +ucode_port_50=RCY1:core_1.50 +tm_port_header_type_out_49=ETH +tm_port_header_type_in_49=ETH +tm_port_header_type_out_50=ETH +tm_port_header_type_in_50=ETH +port_init_speed_49=400000 +port_init_speed_50=400000 #OLP port tm_port_header_type_in_240=INJECTED_2 @@ -981,5 +981,6 @@ serdes_tx_taps_34=nrz:-5:75:-20:0:0:0 serdes_tx_taps_35=nrz:-5:80:-23:0:0:0 serdes_tx_taps_36=nrz:-7:85:-25:0:0:0 +appl_param_nof_ports_per_modid=64 xflow_macsec_secure_chan_to_num_secure_assoc_encrypt=2 xflow_macsec_secure_chan_to_num_secure_assoc_decrypt=2 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/port_config.ini index 81cda90851cb..b15b00ca0953 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/1/port_config.ini @@ -17,5 +17,5 @@ Ethernet256 24,25,26,27 Ethernet33/1 33 Ext 100000 Eth1 Ethernet264 16,17,18,19 Ethernet34/1 34 Ext 100000 Eth120-ASIC1 0 16 8 Ethernet272 8,9,10,11 Ethernet35/1 35 Ext 100000 Eth128-ASIC1 0 17 8 Ethernet280 0,1,2,3 Ethernet36/1 36 Ext 100000 Eth136-ASIC1 0 18 8 -Ethernet-Rec1 221 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 221 8 -Ethernet-IB1 222 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 222 8 +Ethernet-Rec1 249 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 49 8 +Ethernet-IB1 250 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/port_config.ini index 3d1c79a5fe50..268ba635ed44 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-C36/port_config.ini @@ -35,7 +35,7 @@ Ethernet256 24,25,26,27 Ethernet33/1 33 Ext 100000 Eth1 Ethernet264 16,17,18,19 Ethernet34/1 34 Ext 100000 Eth120-ASIC1 0 16 8 Ethernet272 8,9,10,11 Ethernet35/1 35 Ext 100000 Eth128-ASIC1 0 17 8 Ethernet280 0,1,2,3 Ethernet36/1 36 Ext 100000 Eth136-ASIC1 0 18 8 -Ethernet-Rec0 221 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 221 8 -Ethernet-IB0 222 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 222 8 -Ethernet-Rec1 221 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 221 8 -Ethernet-IB1 222 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 222 8 \ No newline at end of file +Ethernet-Rec0 249 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 49 8 +Ethernet-IB0 250 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 50 8 +Ethernet-Rec1 249 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 49 8 +Ethernet-IB1 250 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/j2p-a7800r3a-36d-36x400G.config.bcm b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/j2p-a7800r3a-36d-36x400G.config.bcm index 46dcd675d65c..711800de5c73 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/j2p-a7800r3a-36d-36x400G.config.bcm +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/j2p-a7800r3a-36d-36x400G.config.bcm @@ -263,15 +263,15 @@ tm_port_header_type_in_219=INJECTED_2 port_init_speed_sat=400000 ### RCY -sai_recycle_port_lane_base=0 -ucode_port_221=RCY.21:core_0.221 -ucode_port_222=RCY.22:core_1.222 -tm_port_header_type_out_221=ETH -tm_port_header_type_in_221=ETH -tm_port_header_type_out_222=ETH -tm_port_header_type_in_222=ETH -port_init_speed_221=400000 -port_init_speed_222=400000 +sai_recycle_port_lane_base=200 +ucode_port_49=RCY0:core_0.49 +ucode_port_50=RCY1:core_1.50 +tm_port_header_type_out_49=ETH +tm_port_header_type_in_49=ETH +tm_port_header_type_out_50=ETH +tm_port_header_type_in_50=ETH +port_init_speed_49=400000 +port_init_speed_50=400000 #OLP port tm_port_header_type_in_240=INJECTED_2 @@ -1018,5 +1018,6 @@ serdes_tx_taps_34=pam4:-14:136:-14:2:0:-4 serdes_tx_taps_35=pam4:-16:141:-5:3:-2:-3 serdes_tx_taps_36=pam4:-16:137:-12:2:0:-3 +appl_param_nof_ports_per_modid=64 xflow_macsec_secure_chan_to_num_secure_assoc_encrypt=2 xflow_macsec_secure_chan_to_num_secure_assoc_decrypt=4 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/port_config.ini index a8a0a9603114..de840da3eb9a 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/0/port_config.ini @@ -17,5 +17,5 @@ Ethernet112 24,25,26,27,28,29,30,31 Ethernet15/1 15 Ext Ethernet120 16,17,18,19,20,21,22,23 Ethernet16/1 16 Ext 400000 Eth120-ASIC0 0 16 8 Ethernet128 8,9,10,11,12,13,14,15 Ethernet17/1 17 Ext 400000 Eth128-ASIC0 0 17 8 Ethernet136 0,1,2,3,4,5,6,7 Ethernet18/1 18 Ext 400000 Eth136-ASIC0 0 18 8 -Ethernet-Rec0 221 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 221 8 -Ethernet-IB0 222 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 222 8 +Ethernet-Rec0 249 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 49 8 +Ethernet-IB0 250 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/j2p-a7800r3a-36d-36x400G.config.bcm b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/j2p-a7800r3a-36d-36x400G.config.bcm index 5eb17bc354fb..c5712833d21a 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/j2p-a7800r3a-36d-36x400G.config.bcm +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/j2p-a7800r3a-36d-36x400G.config.bcm @@ -263,15 +263,15 @@ tm_port_header_type_in_219=INJECTED_2 port_init_speed_sat=400000 ### RCY -sai_recycle_port_lane_base=0 -ucode_port_221=RCY.21:core_0.221 -ucode_port_222=RCY.22:core_1.222 -tm_port_header_type_out_221=ETH -tm_port_header_type_in_221=ETH -tm_port_header_type_out_222=ETH -tm_port_header_type_in_222=ETH -port_init_speed_221=400000 -port_init_speed_222=400000 +sai_recycle_port_lane_base=200 +ucode_port_49=RCY0:core_0.49 +ucode_port_50=RCY1:core_1.50 +tm_port_header_type_out_49=ETH +tm_port_header_type_in_49=ETH +tm_port_header_type_out_50=ETH +tm_port_header_type_in_50=ETH +port_init_speed_49=400000 +port_init_speed_50=400000 #OLP port tm_port_header_type_in_240=INJECTED_2 @@ -1018,5 +1018,6 @@ serdes_tx_taps_34=pam4:-14:136:-14:2:0:-4 serdes_tx_taps_35=pam4:-16:141:-5:3:-2:-3 serdes_tx_taps_36=pam4:-16:137:-12:2:0:-3 +appl_param_nof_ports_per_modid=64 xflow_macsec_secure_chan_to_num_secure_assoc_encrypt=2 xflow_macsec_secure_chan_to_num_secure_assoc_decrypt=4 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/port_config.ini index 517251fcf7b6..68db8fb44969 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/1/port_config.ini @@ -17,5 +17,5 @@ Ethernet256 24,25,26,27,28,29,30,31 Ethernet33/1 33 Ext Ethernet264 16,17,18,19,20,21,22,23 Ethernet34/1 34 Ext 400000 Eth120-ASIC1 0 16 8 Ethernet272 8,9,10,11,12,13,14,15 Ethernet35/1 35 Ext 400000 Eth128-ASIC1 0 17 8 Ethernet280 0,1,2,3,4,5,6,7 Ethernet36/1 36 Ext 400000 Eth136-ASIC1 0 18 8 -Ethernet-Rec1 221 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 221 8 -Ethernet-IB1 222 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 222 8 +Ethernet-Rec1 249 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 49 8 +Ethernet-IB1 250 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 50 8 diff --git a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/port_config.ini b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/port_config.ini index 0c057dee3def..37a8915cf32e 100644 --- a/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/port_config.ini +++ b/device/arista/x86_64-arista_7800r3a_36d2_lc/Arista-7800R3A-36D2-D36/port_config.ini @@ -35,7 +35,7 @@ Ethernet256 24,25,26,27,28,29,30,31 Ethernet33/1 33 Ext Ethernet264 16,17,18,19,20,21,22,23 Ethernet34/1 34 Ext 400000 Eth120-ASIC1 0 16 8 Ethernet272 8,9,10,11,12,13,14,15 Ethernet35/1 35 Ext 400000 Eth128-ASIC1 0 17 8 Ethernet280 0,1,2,3,4,5,6,7 Ethernet36/1 36 Ext 400000 Eth136-ASIC1 0 18 8 -Ethernet-Rec0 221 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 221 8 -Ethernet-IB0 222 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 222 8 -Ethernet-Rec1 221 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 221 8 -Ethernet-IB1 222 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 222 8 +Ethernet-Rec0 249 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 0 49 8 +Ethernet-IB0 250 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 1 50 8 +Ethernet-Rec1 249 Recirc0/0 39 Rec 400000 Rcy0-ASIC1 0 49 8 +Ethernet-IB1 250 Recirc0/1 40 Inb 400000 Rcy1-ASIC1 1 50 8 diff --git a/device/celestica/x86_64-cel_seastone-r0/platform.json b/device/celestica/x86_64-cel_seastone-r0/platform.json index a3778ae81aef..e72c00fea5bd 100644 --- a/device/celestica/x86_64-cel_seastone-r0/platform.json +++ b/device/celestica/x86_64-cel_seastone-r0/platform.json @@ -266,6 +266,9 @@ "name": "PSU-1 FAN-1", "speed": { "controllable": false + }, + "status_led": { + "available": false } } ] @@ -281,6 +284,9 @@ "name": "PSU-2 FAN-1", "speed": { "controllable": false + }, + "status_led": { + "available": false } } ] diff --git a/device/celestica/x86_64-cel_silverstone-r0/Silverstone-128x100/th3-128x100G.config.bcm b/device/celestica/x86_64-cel_silverstone-r0/Silverstone-128x100/th3-128x100G.config.bcm index 0b66c8b53814..447de2e85b5a 100644 --- a/device/celestica/x86_64-cel_silverstone-r0/Silverstone-128x100/th3-128x100G.config.bcm +++ b/device/celestica/x86_64-cel_silverstone-r0/Silverstone-128x100/th3-128x100G.config.bcm @@ -11,6 +11,8 @@ pll_bypass=1 init_all_modules=0 +sai_tunnel_global_sip_mask_enable=1 + portmap_20=33:100:2 portmap_21=35:100:2 portmap_22=37:100:2 diff --git a/device/celestica/x86_64-cel_silverstone-r0/Silverstone/th3-32x400G.config.bcm b/device/celestica/x86_64-cel_silverstone-r0/Silverstone/th3-32x400G.config.bcm index 5e5fc82aeace..400fbdcf7573 100644 --- a/device/celestica/x86_64-cel_silverstone-r0/Silverstone/th3-32x400G.config.bcm +++ b/device/celestica/x86_64-cel_silverstone-r0/Silverstone/th3-32x400G.config.bcm @@ -12,6 +12,7 @@ pll_bypass=1 init_all_modules=0 +sai_tunnel_global_sip_mask_enable=1 #portmap_38=257:10 diff --git a/device/mellanox/x86_64-mlnx_msn2010-r0/platform.json b/device/mellanox/x86_64-mlnx_msn2010-r0/platform.json index 1e8fe747f906..d48b4e8e8fc8 100644 --- a/device/mellanox/x86_64-mlnx_msn2010-r0/platform.json +++ b/device/mellanox/x86_64-mlnx_msn2010-r0/platform.json @@ -67,6 +67,9 @@ }, { "name": "CPU Core 3 Temp" + }, + { + "name": "SODIMM 1 Temp" } ], "sfps": [ diff --git a/device/mellanox/x86_64-mlnx_msn2100-r0/platform.json b/device/mellanox/x86_64-mlnx_msn2100-r0/platform.json index 74b4397759c1..485a3614b66b 100644 --- a/device/mellanox/x86_64-mlnx_msn2100-r0/platform.json +++ b/device/mellanox/x86_64-mlnx_msn2100-r0/platform.json @@ -67,6 +67,9 @@ }, { "name": "CPU Core 3 Temp" + }, + { + "name": "SODIMM 1 Temp" } ], "sfps": [ diff --git a/device/mellanox/x86_64-mlnx_msn2410-r0/platform.json b/device/mellanox/x86_64-mlnx_msn2410-r0/platform.json index 6ed5a3a84aa8..98a60a5e898f 100644 --- a/device/mellanox/x86_64-mlnx_msn2410-r0/platform.json +++ b/device/mellanox/x86_64-mlnx_msn2410-r0/platform.json @@ -114,6 +114,9 @@ }, { "name": "CPU Pack Temp" + }, + { + "name": "SODIMM 1 Temp" } ], "sfps": [ diff --git a/device/mellanox/x86_64-mlnx_msn2700-r0/platform.json b/device/mellanox/x86_64-mlnx_msn2700-r0/platform.json index 063a211e785c..22599926e3fa 100644 --- a/device/mellanox/x86_64-mlnx_msn2700-r0/platform.json +++ b/device/mellanox/x86_64-mlnx_msn2700-r0/platform.json @@ -114,6 +114,9 @@ }, { "name": "CPU Pack Temp" + }, + { + "name": "SODIMM 1 Temp" } ], "sfps": [ diff --git a/device/mellanox/x86_64-nvidia_sn2201-r0/platform.json b/device/mellanox/x86_64-nvidia_sn2201-r0/platform.json index 83250c75f74e..b0ab14793910 100644 --- a/device/mellanox/x86_64-nvidia_sn2201-r0/platform.json +++ b/device/mellanox/x86_64-nvidia_sn2201-r0/platform.json @@ -101,6 +101,9 @@ }, { "name": "ASIC" + }, + { + "name": "SODIMM 1 Temp" } ], "sfps": [{ diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_1M.csv b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_1M.csv new file mode 100755 index 000000000000..b9f4e750a8df --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_1M.csv @@ -0,0 +1,342 @@ +VERSION,CABLE TYPE,VENDOR,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +1.2,DAC_1M,GENERIC,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,SPEED,ENCODING,,,,,,,,,SPEED,ENCODING,,,,,,,,,,,,,SPEED,ENCODING,,,,,,,SPEED,ENCODING,,,,,,,SPEED,ENCODING,,,,,,,,,, +,,,50G/400G,PAM4,,,,,,,,,25G/100G,NRZ,,,,,,,,,,,,,10G/40G,NRZ,,,,,,,LT 50G/400G ,PAM4,,,,,,,ANLT 25G/100G ,NRZ,,,,,,,,,, +index,Front Port,lane,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_EQ_COARSE_TUNE_EFFORT_50G,RX_EQ_FINE_TUNE_EFFORT_50G,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_AGC_TARGET,RX_EYE_DISQUALIFY_THRESHOLD_25G,RX_EQ_COARSE_TUNE_EFFORT_25G,RX_EQ_FINE_TUNE_EFFORT_25G,SD_RESET_THRESHOLD,SD_RESET_25G,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_EQ_COARSE_TUNE_EFFORT_50G,RX_EQ_FINE_TUNE_EFFORT_50G,RX_CTLE_LF,RX_CTLE_HF,RX_CTLE_BW,LINK_TRAINING,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_AGC_TARGET,RX_EYE_DISQUALIFY_THRESHOLD_25G,RX_EQ_COARSE_TUNE_EFFORT_25G,RX_EQ_FINE_TUNE_EFFORT_25G,SD_RESET_25G,SD_RESET_THRESHOLD_25G,LINK_TRAINING,AN,AN_ABILITY,FEC +0,0,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +1,0,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +2,0,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +3,0,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +4,0,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +5,0,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +6,0,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +7,0,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +8,1,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +9,1,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +10,1,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +11,1,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +12,1,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +13,1,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +14,1,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +15,1,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +16,2,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +17,2,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +18,2,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +19,2,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +20,2,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +21,2,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +22,2,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +23,2,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +24,3,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +25,3,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +26,3,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +27,3,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +28,3,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +29,3,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +30,3,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +31,3,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +32,4,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +33,4,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +34,4,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +35,4,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +36,4,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +37,4,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +38,4,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +39,4,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +40,5,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +41,5,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +42,5,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +43,5,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +44,5,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +45,5,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +46,5,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +47,5,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +48,6,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +49,6,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +50,6,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +51,6,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +52,6,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +53,6,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +54,6,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +55,6,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +56,7,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +57,7,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +58,7,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +59,7,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +60,7,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +61,7,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +62,7,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +63,7,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +64,8,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +65,8,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +66,8,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +67,8,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +68,8,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +69,8,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +70,8,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +71,8,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +72,9,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +73,9,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +74,9,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +75,9,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +76,9,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +77,9,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +78,9,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +79,9,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +80,10,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +81,10,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +82,10,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +83,10,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +84,10,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +85,10,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +86,10,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +87,10,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +88,11,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +89,11,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +90,11,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +91,11,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +92,11,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +93,11,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +94,11,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +95,11,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +96,12,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +97,12,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +98,12,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +99,12,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +100,12,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +101,12,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +102,12,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +103,12,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +104,13,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +105,13,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +106,13,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +107,13,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +108,13,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +109,13,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +110,13,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +111,13,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +112,14,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +113,14,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +114,14,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +115,14,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +116,14,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +117,14,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +118,14,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +119,14,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +120,15,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +121,15,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +122,15,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +123,15,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +124,15,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +125,15,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +126,15,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +127,15,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +128,16,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +129,16,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +130,16,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +131,16,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +132,16,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +133,16,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +134,16,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +135,16,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +136,17,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +137,17,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +138,17,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +139,17,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +140,17,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +141,17,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +142,17,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +143,17,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +144,18,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +145,18,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +146,18,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +147,18,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +148,18,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +149,18,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +150,18,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +151,18,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +152,19,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +153,19,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +154,19,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +155,19,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +156,19,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +157,19,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +158,19,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +159,19,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +160,20,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +161,20,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +162,20,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +163,20,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +164,20,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +165,20,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +166,20,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +167,20,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +168,21,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +169,21,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +170,21,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +171,21,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +172,21,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +173,21,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +174,21,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +175,21,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +176,22,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +177,22,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +178,22,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +179,22,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +180,22,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +181,22,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +182,22,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +183,22,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +184,23,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +185,23,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +186,23,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +187,23,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +188,23,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +189,23,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +190,23,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +191,23,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +192,24,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +193,24,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +194,24,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +195,24,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +196,24,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +197,24,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +198,24,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +199,24,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +200,25,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +201,25,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +202,25,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +203,25,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +204,25,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +205,25,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +206,25,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +207,25,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +208,26,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +209,26,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +210,26,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +211,26,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +212,26,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +213,26,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +214,26,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +215,26,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +216,27,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +217,27,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +218,27,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +219,27,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +220,27,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +221,27,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +222,27,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +223,27,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +224,28,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +225,28,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +226,28,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +227,28,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +228,28,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +229,28,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +230,28,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +231,28,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +232,29,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +233,29,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +234,29,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +235,29,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +236,29,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +237,29,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +238,29,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +239,29,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +240,30,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +241,30,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +242,30,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +243,30,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +244,30,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +245,30,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +246,30,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +247,30,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +248,31,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +249,31,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +250,31,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +251,31,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +252,31,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +253,31,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +254,31,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +255,31,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,0,1,130,100,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_3M.csv b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_3M.csv new file mode 100755 index 000000000000..b6bbd017e483 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_DAC_3M.csv @@ -0,0 +1,342 @@ +VERSION,CABLE TYPE,VENDOR,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +1.2,DAC_3M,GENERIC,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,SPEED,ENCODING,,,,,,,,,SPEED,ENCODING,,,,,,,,,,,,,SPEED,ENCODING,,,,,,,SPEED,ENCODING,,,,,,,SPEED,ENCODING,,,,,,,,,, +,,,50G/400G,PAM4,,,,,,,,,25G/100G,NRZ,,,,,,,,,,,,,10G/40G,NRZ,,,,,,,LT 50G/400G,PAM4,,,,,,,ANLT 25G/100G,NRZ,,,,,,,,,, +index,Front Port,lane,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_EQ_COARSE_TUNE_EFFORT_50G,RX_EQ_FINE_TUNE_EFFORT_50G,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_AGC_TARGET,RX_EYE_DISQUALIFY_THRESHOLD_25G,RX_EQ_COARSE_TUNE_EFFORT_25G,RX_EQ_FINE_TUNE_EFFORT_25G,SD_RESET_THRESHOLD,SD_RESET_25G,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_EQ_COARSE_TUNE_EFFORT_50G,RX_EQ_FINE_TUNE_EFFORT_50G,RX_CTLE_LF,RX_CTLE_HF,RX_CTLE_BW,LINK_TRAINING,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_AGC_TARGET,RX_EYE_DISQUALIFY_THRESHOLD_25G,RX_EQ_COARSE_TUNE_EFFORT_25G,RX_EQ_FINE_TUNE_EFFORT_25G,SD_RESET_25G,SD_RESET_THRESHOLD_25G,LINK_TRAINING,AN,AN_ABILITY,FEC +0,0,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +1,0,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +2,0,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +3,0,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +4,0,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +5,0,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +6,0,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +7,0,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +8,1,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +9,1,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +10,1,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +11,1,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +12,1,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +13,1,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +14,1,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +15,1,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +16,2,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +17,2,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +18,2,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +19,2,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +20,2,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +21,2,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +22,2,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +23,2,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +24,3,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +25,3,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +26,3,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +27,3,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +28,3,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +29,3,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +30,3,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +31,3,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +32,4,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +33,4,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +34,4,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +35,4,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +36,4,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +37,4,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +38,4,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +39,4,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +40,5,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +41,5,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +42,5,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +43,5,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +44,5,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +45,5,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +46,5,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +47,5,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +48,6,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +49,6,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +50,6,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +51,6,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +52,6,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +53,6,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +54,6,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +55,6,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +56,7,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +57,7,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +58,7,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +59,7,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +60,7,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +61,7,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +62,7,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +63,7,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +64,8,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +65,8,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +66,8,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +67,8,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +68,8,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +69,8,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +70,8,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +71,8,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +72,9,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +73,9,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +74,9,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +75,9,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +76,9,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +77,9,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +78,9,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +79,9,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +80,10,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +81,10,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +82,10,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +83,10,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +84,10,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +85,10,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +86,10,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +87,10,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +88,11,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +89,11,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +90,11,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +91,11,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +92,11,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +93,11,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +94,11,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +95,11,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +96,12,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +97,12,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +98,12,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +99,12,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +100,12,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +101,12,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +102,12,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +103,12,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +104,13,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +105,13,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +106,13,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +107,13,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +108,13,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +109,13,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +110,13,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +111,13,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +112,14,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +113,14,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +114,14,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +115,14,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +116,14,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +117,14,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +118,14,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +119,14,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +120,15,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +121,15,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +122,15,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +123,15,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +124,15,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +125,15,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +126,15,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +127,15,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +128,16,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +129,16,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +130,16,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +131,16,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +132,16,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +133,16,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +134,16,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +135,16,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +136,17,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +137,17,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +138,17,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +139,17,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +140,17,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +141,17,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +142,17,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +143,17,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +144,18,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +145,18,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +146,18,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +147,18,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +148,18,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +149,18,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +150,18,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +151,18,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +152,19,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +153,19,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +154,19,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +155,19,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +156,19,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +157,19,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +158,19,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +159,19,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +160,20,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +161,20,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +162,20,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +163,20,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +164,20,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +165,20,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +166,20,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +167,20,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +168,21,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +169,21,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +170,21,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +171,21,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +172,21,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +173,21,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +174,21,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +175,21,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +176,22,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +177,22,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +178,22,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +179,22,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +180,22,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +181,22,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +182,22,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +183,22,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +184,23,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +185,23,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +186,23,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +187,23,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +188,23,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +189,23,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +190,23,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +191,23,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +192,24,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +193,24,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +194,24,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +195,24,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +196,24,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +197,24,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +198,24,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +199,24,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +200,25,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +201,25,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +202,25,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +203,25,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +204,25,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +205,25,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +206,25,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +207,25,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +208,26,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +209,26,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +210,26,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +211,26,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +212,26,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +213,26,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +214,26,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +215,26,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +216,27,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +217,27,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +218,27,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +219,27,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +220,27,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +221,27,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +222,27,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +223,27,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +224,28,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +225,28,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +226,28,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +227,28,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +228,28,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +229,28,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +230,28,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +231,28,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +232,29,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +233,29,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +234,29,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +235,29,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +236,29,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +237,29,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +238,29,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +239,29,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +240,30,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +241,30,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +242,30,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +243,30,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +244,30,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +245,30,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +246,30,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +247,30,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +248,31,0,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +249,31,1,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +250,31,2,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +251,31,3,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +252,31,4,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +253,31,5,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +254,31,6,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +255,31,7,0,0,0,0,0,Medium,HIGH,0,2,0,0,0,0,0,0,2,2,130,150,Low,Low,5,TRUE,0,3,2,-2,0,4,0,1,0,0,2,Medium,High,0,10,10,1,0,1,130,100,Low,Low,0,NA,1,1,100GBASE-KR4,NONE +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_Optics.csv b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_Optics.csv new file mode 100755 index 000000000000..a652f33e78b9 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/CSV/TL7_Optics.csv @@ -0,0 +1,261 @@ +VERSION,CABLE TYPE,VENDOR,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +1.2,OPTICS,GENERIC,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,SPEED,ENCODING,,,,,,,,,,SPEED,ENCODING,,,,,,,,,,,,,,SPEED,ENCODING,,,,,, +,,,50G/400G,PAM4,,,,,,,,,,25G/100G,NRZ,,,,,,,,,,,,,,10G/40G,NRZ,,,,,, +index,Front Port,lane,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,Optical Module CTLE,RX_EQ_COARSE_TUNE_EFFORT_50G,RX_EQ_FINE_TUNE_EFFORT_50G,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,Optical Module CTLE,RX_GAINSHAPE1,RX_GAINSHAPE2,RX_AGC_TARGET,RX_EYE_DISQUALIFY_THRESHOLD_25G,RX_EQ_COARSE_TUNE_EFFORT_25G,RX_EQ_FINE_TUNE_EFFORT_25G,SD_RESET_THRESHOLD,SD_RESET_25G,LINK_TRAINING,TX_EQ_ATTN,TX_EQ_PRE1,TX_EQ_PRE2,TX_EQ_PRE3,TX_EQ_POST,RX_GAINSHAPE1,RX_GAINSHAPE2,LINK_TRAINING +0,0,0,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +1,0,1,0,4,0,0,8,5,Medium,High,0,2,0,0,2,0,0,8,4,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +2,0,2,0,4,0,0,8,3.5,Medium,High,0,2,0,0,2,0,0,4,5,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +3,0,3,0,4,0,0,6,6.5,Medium,High,0,2,0,0,6,0,0,6,4,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +4,0,4,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +5,0,5,0,2,0,0,10,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +6,0,6,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +7,0,7,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,High,High,NA,FALSE,0,0,0,0,0,0,0,0,0 +8,1,0,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +9,1,1,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +10,1,2,0,4,0,0,6,4.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +11,1,3,0,4,0,0,8,3.5,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +12,1,4,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +13,1,5,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +14,1,6,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +15,1,7,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +16,2,0,0,2,0,0,6,5,Medium,High,0,2,0,0,2,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +17,2,1,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +18,2,2,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,5,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +19,2,3,0,4,0,0,6,5.5,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +20,2,4,0,6,0,0,6,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +21,2,5,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +22,2,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +23,2,7,0,6,0,0,6,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +24,3,0,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +25,3,1,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +26,3,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +27,3,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +28,3,4,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +29,3,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +30,3,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +31,3,7,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +32,4,0,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +33,4,1,0,4,0,0,6,5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +34,4,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +35,4,3,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +36,4,4,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +37,4,5,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +38,4,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +39,4,7,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +40,5,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +41,5,1,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +42,5,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +43,5,3,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +44,5,4,0,4,0,0,6,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +45,5,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +46,5,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +47,5,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +48,6,0,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +49,6,1,0,6,0,0,6,4,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +50,6,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +51,6,3,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +52,6,4,0,6,0,0,6,3.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +53,6,5,0,6,0,0,6,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +54,6,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +55,6,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +56,7,0,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +57,7,1,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +58,7,2,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +59,7,3,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +60,7,4,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +61,7,5,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +62,7,6,0,4,0,0,4,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +63,7,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +64,8,0,0,4,0,0,6,5,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +65,8,1,0,4,0,0,6,6.5,Medium,High,0,2,0,0,4,0,0,8,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +66,8,2,0,4,0,0,6,5.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +67,8,3,0,4,0,0,10,4,Medium,High,0,2,0,0,4,0,0,10,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +68,8,4,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +69,8,5,0,4,0,0,10,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +70,8,6,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +71,8,7,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +72,9,0,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +73,9,1,0,4,0,0,4,7,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +74,9,2,0,4,0,0,8,4.5,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +75,9,3,0,4,0,0,8,5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +76,9,4,0,4,0,0,6,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +77,9,5,0,4,0,0,4,7,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +78,9,6,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +79,9,7,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +80,10,0,0,4,0,0,6,5,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +81,10,1,0,4,0,0,8,5,Medium,High,0,2,0,0,4,0,0,6,5,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +82,10,2,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +83,10,3,0,4,0,0,6,6,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +84,10,4,0,4,0,0,4,7,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +85,10,5,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +86,10,6,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +87,10,7,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +88,11,0,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +89,11,1,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +90,11,2,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +91,11,3,0,6,0,0,6,4.5,Medium,High,0,2,0,0,6,0,0,8,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +92,11,4,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +93,11,5,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +94,11,6,0,4,0,0,4,7.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +95,11,7,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +96,12,0,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +97,12,1,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +98,12,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +99,12,3,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +100,12,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +101,12,5,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +102,12,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +103,12,7,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +104,13,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +105,13,1,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +106,13,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +107,13,3,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +108,13,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +109,13,5,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +110,13,6,0,4,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +111,13,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +112,14,0,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +113,14,1,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +114,14,2,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +115,14,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +116,14,4,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +117,14,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +118,14,6,0,4,0,0,4,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +119,14,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +120,15,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +121,15,1,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +122,15,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +123,15,3,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +124,15,4,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +125,15,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +126,15,6,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +127,15,7,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +128,16,0,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +129,16,1,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +130,16,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +131,16,3,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +132,16,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +133,16,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +134,16,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +135,16,7,0,4,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +136,17,0,0,4,0,0,4,4,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +137,17,1,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +138,17,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +139,17,3,0,6,0,0,6,3.5,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +140,17,4,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +141,17,5,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +142,17,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +143,17,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +144,18,0,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +145,18,1,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +146,18,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +147,18,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +148,18,4,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +149,18,5,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +150,18,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +151,18,7,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +152,19,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +153,19,1,0,6,0,0,6,4,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +154,19,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +155,19,3,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +156,19,4,0,4,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +157,19,5,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +158,19,6,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +159,19,7,0,6,0,0,6,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +160,20,0,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +161,20,1,0,4,0,0,6,5.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +162,20,2,0,4,0,0,6,5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +163,20,3,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +164,20,4,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +165,20,5,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +166,20,6,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +167,20,7,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +168,21,0,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +169,21,1,0,4,0,0,6,5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +170,21,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +171,21,3,0,6,0,0,6,4,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +172,21,4,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +173,21,5,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +174,21,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +175,21,7,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +176,22,0,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +177,22,1,0,4,0,0,8,4.5,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +178,22,2,0,4,0,0,8,4,Medium,High,0,2,0,0,4,0,0,8,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +179,22,3,0,4,0,0,10,3,Medium,High,0,2,0,0,4,0,0,10,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +180,22,4,0,4,0,0,10,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +181,22,5,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +182,22,6,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +183,22,7,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +184,23,0,0,6,0,0,6,4,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +185,23,1,0,4,0,0,4,7,Medium,High,0,2,0,0,4,0,0,8,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +186,23,2,0,4,0,0,6,4.5,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +187,23,3,0,4,0,0,6,5.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +188,23,4,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +189,23,5,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +190,23,6,0,4,0,0,8,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +191,23,7,0,4,0,0,8,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +192,24,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +193,24,1,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +194,24,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +195,24,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +196,24,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +197,24,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +198,24,6,0,4,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +199,24,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +200,25,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +201,25,1,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +202,25,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +203,25,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +204,25,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +205,25,5,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +206,25,6,0,4,0,0,4,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +207,25,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +208,26,0,0,4,0,0,6,3.5,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +209,26,1,0,4,0,0,6,4.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +210,26,2,0,4,0,0,4,5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +211,26,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +212,26,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +213,26,5,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +214,26,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +215,26,7,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +216,27,0,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +217,27,1,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +218,27,2,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +219,27,3,0,6,0,0,6,4.5,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +220,27,4,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +221,27,5,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +222,27,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +223,27,7,0,6,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +224,28,0,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +225,28,1,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +226,28,2,0,4,0,0,4,4.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +227,28,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +228,28,4,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +229,28,5,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +230,28,6,0,4,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +231,28,7,0,4,0,0,6,4.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +232,29,0,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +233,29,1,0,6,0,0,6,4,Medium,High,0,2,0,0,6,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +234,29,2,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +235,29,3,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +236,29,4,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +237,29,5,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +238,29,6,0,4,0,0,4,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +239,29,7,0,6,0,0,4,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +240,30,0,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +241,30,1,0,4,0,0,6,6,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +242,30,2,0,4,0,0,6,4,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +243,30,3,0,4,0,0,4,6,Medium,High,0,2,0,0,4,0,0,6,3,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +244,30,4,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +245,30,5,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +246,30,6,0,4,0,0,8,4,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +247,30,7,0,4,0,0,4,6.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +248,31,0,0,6,-1,0,4,4.5,Medium,High,0,2,0,0,6,0,0,6,2,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +249,31,1,0,4,0,0,6,5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +250,31,2,0,4,0,0,4,5.5,Medium,High,0,2,0,0,4,0,0,4,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +251,31,3,0,4,0,0,4,6.5,Medium,High,0,2,0,0,4,0,0,6,4,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +252,31,4,0,4,0,0,6,6,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +253,31,5,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +254,31,6,0,4,0,0,6,5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 +255,31,7,0,4,0,0,6,5.5,Medium,High,0,2,0,0,0,0,0,0,0,0,0,100,100,LOW,LOW,NA,FALSE,0,0,0,0,0,0,0,0,0 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/installer.conf b/device/wistron/x86_64-wistron_6512_32r-r0/installer.conf index d5f9419d77ff..0bd1a8bae86f 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/installer.conf +++ b/device/wistron/x86_64-wistron_6512_32r-r0/installer.conf @@ -1,4 +1,4 @@ CONSOLE_PORT=0x3f8 CONSOLE_DEV=0 CONSOLE_SPEED=115200 -ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="pcie_aspm=off" +ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="pcie_aspm=off intel_iommu=off" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/pcie.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/pcie.yaml new file mode 100755 index 000000000000..227f7cb249bf --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/pcie.yaml @@ -0,0 +1,495 @@ +- bus: '00' + dev: '00' + fn: '0' + id: 6f00 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DMI2 (rev 05)' +- bus: '00' + dev: '01' + fn: '0' + id: 6f02 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 1 (rev 05)' +- bus: '00' + dev: '01' + fn: '1' + id: 6f03 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 1 (rev 05)' +- bus: '00' + dev: '02' + fn: '0' + id: 6f04 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 2 (rev 05)' +- bus: '00' + dev: '02' + fn: '2' + id: 6f06 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 2 (rev 05)' +- bus: '00' + dev: '02' + fn: '3' + id: 6f07 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 2 (rev 05)' +- bus: '00' + dev: '03' + fn: '0' + id: 6f08 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 05)' +- bus: '00' + dev: '03' + fn: '1' + id: 6f09 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 05)' +- bus: '00' + dev: '03' + fn: '2' + id: 6f0a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 05)' +- bus: '00' + dev: '03' + fn: '3' + id: 6f0b + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 05)' +- bus: '00' + dev: '04' + fn: '0' + id: 6f20 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 0 (rev 05)' +- bus: '00' + dev: '04' + fn: '1' + id: 6f21 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 1 (rev 05)' +- bus: '00' + dev: '04' + fn: '2' + id: 6f22 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 2 (rev 05)' +- bus: '00' + dev: '04' + fn: '3' + id: 6f23 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 3 (rev 05)' +- bus: '00' + dev: '04' + fn: '4' + id: 6f24 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 4 (rev 05)' +- bus: '00' + dev: '04' + fn: '5' + id: 6f25 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 5 (rev 05)' +- bus: '00' + dev: '04' + fn: '6' + id: 6f26 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 6 (rev 05)' +- bus: '00' + dev: '04' + fn: '7' + id: 6f27 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Crystal Beach DMA Channel 7 (rev 05)' +- bus: '00' + dev: '05' + fn: '0' + id: 6f28 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Map/VTd_Misc/System Management (rev 05)' +- bus: '00' + dev: '05' + fn: '1' + id: 6f29 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Hot Plug (rev 05)' +- bus: '00' + dev: '05' + fn: '2' + id: 6f2a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO RAS/Control Status/Global Errors (rev 05)' +- bus: '00' + dev: '05' + fn: '4' + id: 6f2c + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D I/O APIC (rev 05)' +- bus: '00' + dev: '05' + fn: '6' + id: 6f39 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IO Performance Monitoring (rev 05)' +- bus: '00' + dev: '06' + fn: '0' + id: 6f10 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '1' + id: 6f11 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '2' + id: 6f12 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '3' + id: 6f13 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '4' + id: 6f14 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '5' + id: 6f15 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '6' + id: 6f16 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '06' + fn: '7' + id: 6f17 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '07' + fn: '0' + id: 6f18 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '07' + fn: '1' + id: 6f19 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '07' + fn: '2' + id: 6f1a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '07' + fn: '3' + id: 6f1b + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '07' + fn: '4' + id: 6f1c + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Debug (rev 05)' +- bus: '00' + dev: '14' + fn: '0' + id: 8c31 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 05)' +- bus: '00' + dev: '16' + fn: '0' + id: 8c3a + name: 'Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #1 (rev 04)' +- bus: '00' + dev: '16' + fn: '1' + id: 8c3b + name: 'Intel Corporation 8 Series/C220 Series Chipset Family MEI Controller #2 (rev 04)' +- bus: '00' + dev: '1c' + fn: '0' + id: 8c10 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d5)' +- bus: '00' + dev: '1c' + fn: '7' + id: 8c1e + name: 'Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #8 (rev d5)' +- bus: '00' + dev: '1d' + fn: '0' + id: 8c26 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family USB EHCI #1 (rev 05)' +- bus: '00' + dev: '1f' + fn: '0' + id: 8c54 + name: 'Intel Corporation C224 Series Chipset Family Server Standard SKU LPC Controller (rev 05)' +- bus: '00' + dev: '1f' + fn: '2' + id: 8c02 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family 6-port SATA Controller 1 [AHCI mode] (rev 05)' +- bus: '00' + dev: '1f' + fn: '3' + id: 8c22 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 05)' +- bus: '02' + dev: '00' + fn: '0' + id: 1b58 + name: 'Device 1d98:1b58 (rev 10)' +- bus: '04' + dev: '00' + fn: '0' + id: 15a7 + name: 'Intel Corporation Device 15a7' +- bus: '04' + dev: '00' + fn: '1' + id: 15a7 + name: 'Intel Corporation Device 15a7' +- bus: '05' + dev: '00' + fn: '0' + id: 15a7 + name: 'Intel Corporation Device 15a7' +- bus: '05' + dev: '00' + fn: '1' + id: 15a7 + name: 'Intel Corporation Device 15a7' +- bus: '0b' + dev: '00' + fn: '0' + id: 1533 + name: 'Intel Corporation I210 Gigabit Network Connection (rev 03)' +- bus: 'ff' + dev: '0b' + fn: '0' + id: 6f81 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 05)' +- bus: 'ff' + dev: '0b' + fn: '1' + id: 6f36 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 05)' +- bus: 'ff' + dev: '0b' + fn: '2' + id: 6f37 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 05)' +- bus: 'ff' + dev: '0b' + fn: '3' + id: 6f76 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link Debug (rev 05)' +- bus: 'ff' + dev: '0c' + fn: '0' + id: 6fe0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0c' + fn: '1' + id: 6fe1 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0c' + fn: '2' + id: 6fe2 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0c' + fn: '3' + id: 6fe3 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0f' + fn: '0' + id: 6ff8 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0f' + fn: '4' + id: 6ffc + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0f' + fn: '5' + id: 6ffd + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '0f' + fn: '6' + id: 6ffe + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 05)' +- bus: 'ff' + dev: '10' + fn: '0' + id: 6f1d + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R2PCIe Agent (rev 05)' +- bus: 'ff' + dev: '10' + fn: '1' + id: 6f34 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R2PCIe Agent (rev 05)' +- bus: 'ff' + dev: '10' + fn: '5' + id: 6f1e + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 05)' +- bus: 'ff' + dev: '10' + fn: '6' + id: 6f7d + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 05)' +- bus: 'ff' + dev: '10' + fn: '7' + id: 6f1f + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 05)' +- bus: 'ff' + dev: '12' + fn: '0' + id: 6fa0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Home Agent 0 (rev 05)' +- bus: 'ff' + dev: '12' + fn: '1' + id: 6f30 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Home Agent 0 (rev 05)' +- bus: 'ff' + dev: '12' + fn: '2' + id: 6f70 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Home Agent 0 Debug (rev 05)' +- bus: 'ff' + dev: '13' + fn: '0' + id: 6fa8 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Target Address/Thermal/RAS (rev 05)' +- bus: 'ff' + dev: '13' + fn: '1' + id: 6f71 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Target Address/Thermal/RAS (rev 05)' +- bus: 'ff' + dev: '13' + fn: '2' + id: 6faa + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 05)' +- bus: 'ff' + dev: '13' + fn: '3' + id: 6fab + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 05)' +- bus: 'ff' + dev: '13' + fn: '4' + id: 6fac + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 05)' +- bus: 'ff' + dev: '13' + fn: '5' + id: 6fad + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 05)' +- bus: 'ff' + dev: '13' + fn: '6' + id: 6fae + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Broadcast (rev 05)' +- bus: 'ff' + dev: '13' + fn: '7' + id: 6faf + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Global Broadcast (rev 05)' +- bus: 'ff' + dev: '14' + fn: '0' + id: 6fb0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 0 Thermal Control (rev 05)' +- bus: 'ff' + dev: '14' + fn: '1' + id: 6fb1 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 1 Thermal Control (rev 05)' +- bus: 'ff' + dev: '14' + fn: '2' + id: 6fb2 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 0 Error (rev 05)' +- bus: 'ff' + dev: '14' + fn: '3' + id: 6fb3 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 1 Error (rev 05)' +- bus: 'ff' + dev: '14' + fn: '4' + id: 6fbc + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 05)' +- bus: 'ff' + dev: '14' + fn: '5' + id: 6fbd + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 05)' +- bus: 'ff' + dev: '14' + fn: '6' + id: 6fbe + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 05)' +- bus: 'ff' + dev: '14' + fn: '7' + id: 6fbf + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 05)' +- bus: 'ff' + dev: '15' + fn: '0' + id: 6fb4 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 2 Thermal Control (rev 05)' +- bus: 'ff' + dev: '15' + fn: '1' + id: 6fb5 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 3 Thermal Control (rev 05)' +- bus: 'ff' + dev: '15' + fn: '2' + id: 6fb6 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 2 Error (rev 05)' +- bus: 'ff' + dev: '15' + fn: '3' + id: 6fb7 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 3 Error (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '0' + id: 6f98 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '1' + id: 6f99 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '2' + id: 6f9a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '3' + id: 6fc0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '4' + id: 6f9c + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1e' + fn: '7' + id: 6f9f + name: 'Intel Corporation Device 6f9f (rev 05)' +- bus: 'ff' + dev: '1f' + fn: '0' + id: 6f88 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' +- bus: 'ff' + dev: '1f' + fn: '2' + id: 6f8a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 05)' diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/platform.json b/device/wistron/x86_64-wistron_6512_32r-r0/platform.json new file mode 100644 index 000000000000..f978e6190513 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/platform.json @@ -0,0 +1,848 @@ +{ + "chassis": { + "name": "wistron_6512_32r", + "components": [ + { + "name": "BIOS" + }, + { + "name": "CPLD1" + }, + { + "name": "CPLD2" + }, + { + "name": "MB_FPGA" + }, + { + "name": "CPU_FPGA" + }, + { + "name": "BMC" + } + ], + "fans": [ + { + "name": "FAN-1F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-1R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "fan_drawers": [ + { + "name": "FanTray1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-1F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-1R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray2", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-2F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray3", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-3F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray4", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-4F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray5", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-5F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray6", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-6F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray7", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-7F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + } + ], + "psus": [ + { + "name": "PSU-1", + "fans": [ + { + "name": "PSU-1 FAN-1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "status_led": { + "controllable": false + } + }, + { + "name": "PSU-2", + "fans": [ + { + "name": "PSU-2 FAN-1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "status_led": { + "controllable": false + } + } + ], + "thermals": [ + { + "name": "Switch", + "controllable": false + }, + { + "name": "UCPUB", + "controllable": false + }, + { + "name": "UFANB", + "controllable": false + }, + { + "name": "UFRNT1", + "controllable": false + }, + { + "name": "UFRNT2", + "controllable": false + }, + { + "name": "UFRNT3", + "controllable": false + }, + { + "name": "UFRNT4", + "controllable": false + }, + { + "name": "UREAR1", + "controllable": false + } + ], + "sfps": [ + { + "name": "port1" + }, + { + "name": "port2" + }, + { + "name": "port3" + }, + { + "name": "port4" + }, + { + "name": "port5" + }, + { + "name": "port6" + }, + { + "name": "port7" + }, + { + "name": "port8" + }, + { + "name": "port9" + }, + { + "name": "port10" + }, + { + "name": "port11" + }, + { + "name": "port12" + }, + { + "name": "port13" + }, + { + "name": "port14" + }, + { + "name": "port15" + }, + { + "name": "port16" + }, + { + "name": "port17" + }, + { + "name": "port18" + }, + { + "name": "port19" + }, + { + "name": "port20" + }, + { + "name": "port21" + }, + { + "name": "port22" + }, + { + "name": "port23" + }, + { + "name": "port24" + }, + { + "name": "port25" + }, + { + "name": "port26" + }, + { + "name": "port27" + }, + { + "name": "port28" + }, + { + "name": "port29" + }, + { + "name": "port30" + }, + { + "name": "port31" + }, + { + "name": "port32" + } + ] + }, + "interfaces": { + "Ethernet0": { + "index": "0,0,0,0,0,0,0,0", + "lanes": "89,90,91,92,93,94,95,96", + "breakout_modes": { + "1x400G[100G]": ["Eth1"], + "1x100G(4)": ["Eth1"], + "4x25G[10G](4)": ["Eth1-1", "Eth1-2", "Eth1-3", "Eth1-4"], + "4x10G[25G](4)": ["Eth1-1", "Eth1-2", "Eth1-3", "Eth1-4"] + } + }, + "Ethernet8": { + "index": "1,1,1,1,1,1,1,1", + "lanes": "81,82,83,84,85,86,87,88", + "breakout_modes": { + "1x400G[100G]": ["Eth2"], + "1x100G(4)": ["Eth2"], + "4x25G[10G](4)": ["Eth2-1", "Eth2-2", "Eth2-3", "Eth2-4"], + "4x10G[25G](4)": ["Eth2-1", "Eth2-2", "Eth2-3", "Eth2-4"] + } + }, + "Ethernet16": { + "index": "2,2,2,2,2,2,2,2", + "lanes": "73,74,75,76,77,78,79,80", + "breakout_modes": { + "1x400G[100G]": ["Eth3"], + "1x100G(4)": ["Eth3"], + "4x25G[10G](4)": ["Eth3-1", "Eth3-2", "Eth3-3", "Eth3-4"], + "4x10G[25G](4)": ["Eth3-1", "Eth3-2", "Eth3-3", "Eth3-4"] + } + }, + "Ethernet24": { + "index": "3,3,3,3,3,3,3,3", + "lanes": "65,66,67,68,69,70,71,72", + "breakout_modes": { + "1x400G[100G]": ["Eth4"], + "1x100G(4)": ["Eth4"], + "4x25G[10G](4)": ["Eth4-1", "Eth4-2", "Eth4-3", "Eth4-4"], + "4x10G[25G](4)": ["Eth4-1", "Eth4-2", "Eth4-3", "Eth4-4"] + } + }, + "Ethernet32": { + "index": "4,4,4,4,4,4,4,4", + "lanes": "57,58,59,60,61,62,63,64", + "breakout_modes": { + "1x400G[100G]": ["Eth5"], + "1x100G(4)": ["Eth5"], + "4x25G[10G](4)": ["Eth5-1", "Eth5-2", "Eth5-3", "Eth5-4"], + "4x10G[25G](4)": ["Eth5-1", "Eth5-2", "Eth5-3", "Eth5-4"] + } + }, + "Ethernet40": { + "index": "5,5,5,5,5,5,5,5", + "lanes": "49,50,51,52,53,54,55,56", + "breakout_modes": { + "1x400G[100G]": ["Eth6"], + "1x100G(4)": ["Eth6"], + "4x25G[10G](4)": ["Eth6-1", "Eth6-2", "Eth6-3", "Eth6-4"], + "4x10G[25G](4)": ["Eth6-1", "Eth6-2", "Eth6-3", "Eth6-4"] + } + }, + "Ethernet48": { + "index": "6,6,6,6,6,6,6,6", + "lanes": "41,42,43,44,45,46,47,48", + "breakout_modes": { + "1x400G[100G]": ["Eth7"], + "1x100G(4)": ["Eth7"], + "4x25G[10G](4)": ["Eth7-1", "Eth7-2", "Eth7-3", "Eth7-4"], + "4x10G[25G](4)": ["Eth7-1", "Eth7-2", "Eth7-3", "Eth7-4"] + } + }, + "Ethernet56": { + "index": "7,7,7,7,7,7,7,7", + "lanes": "33,34,35,36,37,38,39,40", + "breakout_modes": { + "1x400G[100G]": ["Eth8"], + "1x100G(4)": ["Eth8"], + "4x25G[10G](4)": ["Eth8-1", "Eth8-2", "Eth8-3", "Eth8-4"], + "4x10G[25G](4)": ["Eth8-1", "Eth8-2", "Eth8-3", "Eth8-4"] + } + }, + "Ethernet64": { + "index": "8,8,8,8,8,8,8,8", + "lanes": "153,154,155,156,157,158,159,160", + "breakout_modes": { + "1x400G[100G]": ["Eth9"], + "1x100G(4)": ["Eth9"], + "4x25G[10G](4)": ["Eth9-1", "Eth9-2", "Eth9-3", "Eth9-4"], + "4x10G[25G](4)": ["Eth9-1", "Eth9-2", "Eth9-3", "Eth9-4"] + } + }, + "Ethernet72": { + "index": "9,9,9,9,9,9,9,9", + "lanes": "145,146,147,148,149,150,151,152", + "breakout_modes": { + "1x400G[100G]": ["Eth10"], + "1x100G(4)": ["Eth10"], + "4x25G[10G](4)": ["Eth10-1", "Eth10-2", "Eth10-3", "Eth10-4"], + "4x10G[25G](4)": ["Eth10-1", "Eth10-2", "Eth10-3", "Eth10-4"] + } + }, + "Ethernet80": { + "index": "10,10,10,10,10,10,10,10", + "lanes": "137,138,139,140,141,142,143,144", + "breakout_modes": { + "1x400G[100G]": ["Eth11"], + "1x100G(4)": ["Eth11"], + "4x25G[10G](4)": ["Eth11-1", "Eth11-2", "Eth11-3", "Eth11-4"], + "4x10G[25G](4)": ["Eth11-1", "Eth11-2", "Eth11-3", "Eth11-4"] + } + }, + "Ethernet88": { + "index": "11,11,11,11,11,11,11,11", + "lanes": "129,130,131,132,133,134,135,136", + "breakout_modes": { + "1x400G[100G]": ["Eth12"], + "1x100G(4)": ["Eth12"], + "4x25G[10G](4)": ["Eth12-1", "Eth12-2", "Eth12-3", "Eth12-4"], + "4x10G[25G](4)": ["Eth12-1", "Eth12-2", "Eth12-3", "Eth12-4"] + } + }, + "Ethernet96": { + "index": "12,12,12,12,12,12,12,12", + "lanes": "121,122,123,124,125,126,127,128", + "breakout_modes": { + "1x400G[100G]": ["Eth13"], + "1x100G(4)": ["Eth13"], + "4x25G[10G](4)": ["Eth13-1", "Eth13-2", "Eth13-3", "Eth13-4"], + "4x10G[25G](4)": ["Eth13-1", "Eth13-2", "Eth13-3", "Eth13-4"] + } + }, + "Ethernet104": { + "index": "13,13,13,13,13,13,13,13", + "lanes": "113,114,115,116,117,118,119,120", + "breakout_modes": { + "1x400G[100G]": ["Eth14"], + "1x100G(4)": ["Eth14"], + "4x25G[10G](4)": ["Eth14-1", "Eth14-2", "Eth14-3", "Eth14-4"], + "4x10G[25G](4)": ["Eth14-1", "Eth14-2", "Eth14-3", "Eth14-4"] + } + }, + "Ethernet112": { + "index": "14,14,14,14,14,14,14,14", + "lanes": "105,106,107,108,109,110,111,112", + "breakout_modes": { + "1x400G[100G]": ["Eth15"], + "1x100G(4)": ["Eth15"], + "4x25G[10G](4)": ["Eth15-1", "Eth15-2", "Eth15-3", "Eth15-4"], + "4x10G[25G](4)": ["Eth15-1", "Eth15-2", "Eth15-3", "Eth15-4"] + } + }, + "Ethernet120": { + "index": "15,15,15,15,15,15,15,15", + "lanes": "97,98,99,100,101,102,103,104", + "breakout_modes": { + "1x400G[100G]": ["Eth16"], + "1x100G(4)": ["Eth16"], + "4x25G[10G](4)": ["Eth16-1", "Eth16-2", "Eth16-3", "Eth16-4"], + "4x10G[25G](4)": ["Eth16-1", "Eth16-2", "Eth16-3", "Eth16-4"] + } + }, + "Ethernet128": { + "index": "16,16,16,16,16,16,16,16", + "lanes": "209,210,211,212,213,214,215,216", + "breakout_modes": { + "1x400G[100G]": ["Eth17"], + "1x100G(4)": ["Eth17"], + "4x25G[10G](4)": ["Eth17-1", "Eth17-2", "Eth17-3", "Eth17-4"], + "4x10G[25G](4)": ["Eth17-1", "Eth17-2", "Eth17-3", "Eth17-4"] + } + }, + "Ethernet136": { + "index": "17,17,17,17,17,17,17,17", + "lanes": "217,218,219,220,221,222,223,224", + "breakout_modes": { + "1x400G[100G]": ["Eth18"], + "1x100G(4)": ["Eth18"], + "4x25G[10G](4)": ["Eth18-1", "Eth18-2", "Eth18-3", "Eth18-4"], + "4x10G[25G](4)": ["Eth18-1", "Eth18-2", "Eth18-3", "Eth18-4"] + } + }, + "Ethernet144": { + "index": "18,18,18,18,18,18,18,18", + "lanes": "193,194,195,196,197,198,199,200", + "breakout_modes": { + "1x400G[100G]": ["Eth19"], + "1x100G(4)": ["Eth19"], + "4x25G[10G](4)": ["Eth19-1", "Eth19-2", "Eth19-3", "Eth19-4"], + "4x10G[25G](4)": ["Eth19-1", "Eth19-2", "Eth19-3", "Eth19-4"] + } + }, + "Ethernet152": { + "index": "19,19,19,19,19,19,19,19", + "lanes": "201,202,203,204,205,206,207,208", + "breakout_modes": { + "1x400G[100G]": ["Eth20"], + "1x100G(4)": ["Eth20"], + "4x25G[10G](4)": ["Eth20-1", "Eth20-2", "Eth20-3", "Eth20-4"], + "4x10G[25G](4)": ["Eth20-1", "Eth20-2", "Eth20-3", "Eth20-4"] + } + }, + "Ethernet160": { + "index": "20,20,20,20,20,20,20,20", + "lanes": "177,178,179,180,181,182,183,184", + "breakout_modes": { + "1x400G[100G]": ["Eth21"], + "1x100G(4)": ["Eth21"], + "4x25G[10G](4)": ["Eth21-1", "Eth21-2", "Eth21-3", "Eth21-4"], + "4x10G[25G](4)": ["Eth21-1", "Eth21-2", "Eth21-3", "Eth21-4"] + } + }, + "Ethernet168": { + "index": "21,21,21,21,21,21,21,21", + "lanes": "185,186,187,188,189,190,191,192", + "breakout_modes": { + "1x400G[100G]": ["Eth22"], + "1x100G(4)": ["Eth22"], + "4x25G[10G](4)": ["Eth22-1", "Eth22-2", "Eth22-3", "Eth22-4"], + "4x10G[25G](4)": ["Eth22-1", "Eth22-2", "Eth22-3", "Eth22-4"] + } + }, + "Ethernet176": { + "index": "22,22,22,22,22,22,22,22", + "lanes": "161,162,163,164,165,166,167,168", + "breakout_modes": { + "1x400G[100G]": ["Eth23"], + "1x100G(4)": ["Eth23"], + "4x25G[10G](4)": ["Eth23-1", "Eth23-2", "Eth23-3", "Eth23-4"], + "4x10G[25G](4)": ["Eth23-1", "Eth23-2", "Eth23-3", "Eth23-4"] + } + }, + "Ethernet184": { + "index": "23,23,23,23,23,23,23,23", + "lanes": "169,170,171,172,173,174,175,176", + "breakout_modes": { + "1x400G[100G]": ["Eth24"], + "1x100G(4)": ["Eth24"], + "4x25G[10G](4)": ["Eth24-1", "Eth24-2", "Eth24-3", "Eth24-4"], + "4x10G[25G](4)": ["Eth24-1", "Eth24-2", "Eth24-3", "Eth24-4"] + } + }, + "Ethernet192": { + "index": "24,24,24,24,24,24,24,24", + "lanes": "17,18,19,20,21,22,23,24", + "breakout_modes": { + "1x400G[100G]": ["Eth25"], + "1x100G(4)": ["Eth25"], + "4x25G[10G](4)": ["Eth25-1", "Eth25-2", "Eth25-3", "Eth25-4"], + "4x10G[25G](4)": ["Eth25-1", "Eth25-2", "Eth25-3", "Eth25-4"] + } + }, + "Ethernet200": { + "index": "25,25,25,25,25,25,25,25", + "lanes": "25,26,27,28,29,30,31,32", + "breakout_modes": { + "1x400G[100G]": ["Eth26"], + "1x100G(4)": ["Eth26"], + "4x25G[10G](4)": ["Eth26-1", "Eth26-2", "Eth26-3", "Eth26-4"], + "4x10G[25G](4)": ["Eth26-1", "Eth26-2", "Eth26-3", "Eth26-4"] + } + }, + "Ethernet208": { + "index": "26,26,26,26,26,26,26,26", + "lanes": "1,2,3,4,5,6,7,8", + "breakout_modes": { + "1x400G[100G]": ["Eth27"], + "1x100G(4)": ["Eth27"], + "4x25G[10G](4)": ["Eth27-1", "Eth27-2", "Eth27-3", "Eth27-4"], + "4x10G[25G](4)": ["Eth27-1", "Eth27-2", "Eth27-3", "Eth27-4"] + } + }, + "Ethernet216": { + "index": "27,27,27,27,27,27,27,27", + "lanes": "9,10,11,12,13,14,15,16", + "breakout_modes": { + "1x400G[100G]": ["Eth28"], + "1x100G(4)": ["Eth28"], + "4x25G[10G](4)": ["Eth28-1", "Eth28-2", "Eth28-3", "Eth28-4"], + "4x10G[25G](4)": ["Eth28-1", "Eth28-2", "Eth28-3", "Eth28-4"] + } + }, + "Ethernet224": { + "index": "28,28,28,28,28,28,28,28", + "lanes": "241,242,243,244,245,246,247,248", + "breakout_modes": { + "1x400G[100G]": ["Eth29"], + "1x100G(4)": ["Eth29"], + "4x25G[10G](4)": ["Eth29-1", "Eth29-2", "Eth29-3", "Eth29-4"], + "4x10G[25G](4)": ["Eth29-1", "Eth29-2", "Eth29-3", "Eth29-4"] + } + }, + "Ethernet232": { + "index": "29,29,29,29,29,29,29,29", + "lanes": "249,250,251,252,253,254,255,256", + "breakout_modes": { + "1x400G[100G]": ["Eth30"], + "1x100G(4)": ["Eth30"], + "4x25G[10G](4)": ["Eth30-1", "Eth30-2", "Eth30-3", "Eth30-4"], + "4x10G[25G](4)": ["Eth30-1", "Eth30-2", "Eth30-3", "Eth30-4"] + } + }, + "Ethernet240": { + "index": "30,30,30,30,30,30,30,30", + "lanes": "225,226,227,228,229,230,231,232", + "breakout_modes": { + "1x400G[100G]": ["Eth31"], + "1x100G(4)": ["Eth31"], + "4x25G[10G](4)": ["Eth31-1", "Eth31-2", "Eth31-3", "Eth31-4"], + "4x10G[25G](4)": ["Eth31-1", "Eth31-2", "Eth31-3", "Eth31-4"] + } + }, + "Ethernet248": { + "index": "31,31,31,31,31,31,31,31", + "lanes": "233,234,235,236,237,238,239,240", + "breakout_modes": { + "1x400G[100G]": ["Eth32"], + "1x100G(4)": ["Eth32"], + "4x25G[10G](4)": ["Eth32-1", "Eth32-2", "Eth32-3", "Eth32-4"], + "4x10G[25G](4)": ["Eth32-1", "Eth32-2", "Eth32-3", "Eth32-4"] + } + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/plugins/sfputil.py b/device/wistron/x86_64-wistron_6512_32r-r0/plugins/sfputil.py index 8dbc6ba8519a..c38b792bb9ca 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/plugins/sfputil.py +++ b/device/wistron/x86_64-wistron_6512_32r-r0/plugins/sfputil.py @@ -111,6 +111,7 @@ def get_presence(self, port_num): val_file.close() except IOError as e: print("Error: unable to access file: %s" % str(e)) + val_file.close() return False if content == "1": @@ -134,6 +135,7 @@ def get_low_power_mode(self, port_num): val_file.close() except IOError as e: print("Error: unable to access file: %s" % str(e)) + val_file.close() return False if content == "1": @@ -158,10 +160,35 @@ def set_low_power_mode(self, port_num, lpmode): return True except IOError as e: print("Error: unable to open file: %s" % str(e)) + val_file.close() return False def reset(self, port_num): - raise NotImplementedError + if port_num < self.port_start or port_num > self.port_end: + return False + if not self.get_presence(port_num): + return False # Port is not present, unable to set reset + + if port_num < 16: + reset_path = self.BASE_CPLD1_PATH + "port" + str(port_num+1) + "_reset" + else: + reset_path = self.BASE_CPLD2_PATH + "port" + str(port_num+1) + "_reset" + + self.__port_to_mod_rst = reset_path + + try: + val_file = open(self.__port_to_mod_rst, 'w') + val_file.write('1') + time.sleep(1) + val_file.write('0') + time.sleep(1) + val_file.close() + return True + except IOError as e: + print("Error: unable to open file: %s" % str(e)) + val_file.close() + return False + def _get_sfp_presence(self): port_pres = {} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/fan.py b/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/fan.py deleted file mode 100644 index aec7e23be5c0..000000000000 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/fan.py +++ /dev/null @@ -1,182 +0,0 @@ -#!/usr/bin/env python - -############################################################################# -# -# Module contains an implementation of SONiC Platform Base API and -# provides the fan status which are available in the platform -# -############################################################################# - -import os.path - -try: - from sonic_platform_base.fan_base import FanBase -except ImportError as e: - raise ImportError(str(e) + "- required module not found") - -FAN_PATH = "/sys/bus/i2c/devices/0-0044/" -FANTRAY_NAME_LIST = ["FANTRAY-1", "FANTRAY-2", - "FANTRAY-3", "FANTRAY-4", - "FANTRAY-5", "FANTRAY-6", "FANTRAY-7"] -FAN_NAME_LIST = ["fan1_front","fan2_front","fan3_front","fan4_front","fan5_front","fan6_front", "fan7_front",\ -"fan1_rear","fan2_rear","fan3_rear","fan4_rear", "fan5_rear", "fan6_rear", "fan7_rear",] - -class Fan(FanBase): - """Platform-specific Fan class""" - - def __init__(self, fan_index): - self.fan_tray_index = fan_index - self.fan_presence = "fan{}_present" - self.fan_direction = "fan{}_direction" - self.fan_speed_rpm = "fan{}_input" - FanBase.__init__(self) - - def __read_txt_file(self, file_path): - try: - with open(file_path, 'r') as fd: - data = fd.read() - return data.strip() - except IOError: - pass - return "" - - def __write_txt_file(self, file_path, value): - try: - with open(file_path, 'w') as fd: - fd.write(str(value)) - except BaseException: - return False - return True - - def __search_file_by_name(self, directory, file_name): - for dirpath, dirnames, files in os.walk(directory): - for name in files: - file_path = os.path.join(dirpath, name) - if name in file_name: - return file_path - return None - - def get_direction(self): - """ - Retrieves the direction of fan - Returns: - A string, either FAN_DIRECTION_INTAKE or FAN_DIRECTION_EXHAUST - depending on fan direction - """ - index1=self.fan_tray_index - if self.fan_tray_index>6: - index1=self.fan_tray_index%7 - fan_direction_file = (FAN_PATH + - self.fan_direction.format(index1+1)) - raw = self.__read_txt_file(fan_direction_file).strip('\r\n') - direction = self.FAN_DIRECTION_INTAKE if str( - raw).upper() == "1" else self.FAN_DIRECTION_EXHAUST - - return direction - - def get_speed(self): - """ - Retrieves the speed of fan as a percentage of full speed - Returns: - An integer, the percentage of full fan speed, in the range 0 (off) - to 12000 (full speed) - """ - - speed = 0 - if self.fan_tray_index<=13: - index1=self.fan_tray_index - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1)) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - - return int(speed) - - def get_target_speed(self): - """ - Retrieves the target (expected) speed of the fan - Returns: - An integer, the percentage of full fan speed, in the range 0 (off) - to 100 (full speed) - """ - - speed = 0 - if self.fan_tray_index<=13: - index1=self.fan_tray_index - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1)) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - - return int(speed) - - def get_speed_tolerance(self): - """ - Retrieves the speed tolerance of the fan - Returns: - An integer, the percentage of variance from target speed which is - considered tolerable - """ - return 10 - - def set_speed(self, speed): - """ - Sets the fan speed - Args: - speed: An integer, the percentage of full fan speed to set fan to, - in the range 0 (off) to 100 (full speed) - Returns: - A boolean, True if speed is set successfully, False if not - - Note: - Depends on pwm or target mode is selected: - 1) pwm = speed_pc * 255 <-- Currently use this mode. - 2) target_pwm = speed_pc * 100 / 255 - 2.1) set pwm{}_enable to 3 - - """ - return False - - def set_status_led(self, color): - """ - Sets the state of the fan module status LED - Args: - color: A string representing the color with which to set the - fan module status LED - Returns: - bool: True if status LED state is set successfully, False if not - """ - return False - - def get_name(self): - """ - Retrieves the name of the device - Returns: - string: The name of the device - """ - fan_name = FAN_NAME_LIST[self.fan_tray_index] - - return fan_name - - def get_presence(self): - """ - Retrieves the presence of the PSU - Returns: - bool: True if PSU is present, False if not - """ - index1=self.fan_tray_index - if self.fan_tray_index>6: - index1=self.fan_tray_index%7 - fan_direction_file = (FAN_PATH + - self.fan_presence.format(index1+1)) - present_str = self.__read_txt_file(fan_direction_file) or '1' - - return int(present_str) == 1 - - def get_status(self): - """ - Retrieves the operational status of the device - Returns: - A boolean value, True if device is operating properly, False if not - """ - return self.get_presence() and self.get_speed() > 0 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/psu.py b/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/psu.py deleted file mode 100644 index dc13cc1ed824..000000000000 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/psu.py +++ /dev/null @@ -1,248 +0,0 @@ -#!/usr/bin/env python - -############################################################################# -# psuutil.py -# Platform-specific PSU status interface for SONiC -############################################################################# - -try: - from sonic_platform_base.psu_base import PsuBase -except ImportError as e: - raise ImportError(str(e) + "- required module not found") - -PSU_NAME_LIST = ["PSU-1", "PSU-2"] - -class Psu(PsuBase): - """Platform-specific Psu class""" - - SYSFS_PSU_DIR = ["/sys/bus/i2c/devices/0-005a", - "/sys/bus/i2c/devices/0-0059"] - - def __init__(self, psu_index): - self.index = psu_index - PsuBase.__init__(self) - - - def get_fan(self): - """ - Retrieves object representing the fan module contained in this PSU - Returns: - An object dervied from FanBase representing the fan module - contained in this PSU - """ - # Hardware not supported - return False - - def get_powergood_status(self): - """ - Retrieves the powergood status of PSU - Returns: - A boolean, True if PSU has stablized its output voltages and passed all - its internal self-tests, False if not. - """ - return self.get_status() - - def set_status_led(self, color): - """ - Sets the state of the PSU status LED - Args: - color: A string representing the color with which to set the PSU status LED - Note: Only support green and off - Returns: - bool: True if status LED state is set successfully, False if not - """ - # Hardware not supported - return False - - def get_name(self): - """ - Retrieves the name of the device - Returns: - string: The name of the device - """ - return PSU_NAME_LIST[self.index] - - def get_presence(self): - """ - Retrieves the presence of the PSU - Returns: - bool: True if PSU is present, False if not - """ - attr_file ='present' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - status = 0 - try: - with open(attr_path, 'r') as psu_prs: - status = int(psu_prs.read()) - except IOError: - return False - - return status == 1 - - def get_status(self): - """ - Retrieves the operational status of the device - Returns: - A boolean value, True if device is operating properly, False if not - """ - attr_file = 'power_good' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - status = 0 - try: - with open(attr_path, 'r') as power_status: - status = int(power_status.read()) - except IOError: - return False - - return status == 1 - - def get_model(self): - """ - Retrieves the model number/name of a power supply unit (PSU) defined - by 1-based index - :param idx: An integer, 1-based index of the PSU of which to query model number - :return: String, denoting model number/name - """ - attr_file ='model' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - model = "" - try: - with open(attr_path, 'r') as psu_model: - model = psu_model.read() - except IOError: - return model - - return model - - def get_mfr_id(self): - """ - Retrieves the manufacturing id of a power supply unit (PSU) defined - by 1-based index - :param idx: An integer, 1-based index of the PSU of which to query mfr id - :return: String, denoting manufacturing id - """ - attr_file ='vendor' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - vendor = "" - try: - with open(attr_path, 'r') as psu_vendor: - vendor = psu_vendor.read() - except IOError: - return vendor - - return vendor - - def get_serial(self): - """ - Retrieves the serial number of a power supply unit (PSU) defined - by 1-based index - :param idx: An integer, 1-based index of the PSU of which to query serial number - :return: String, denoting serial number of the PSU unit - """ - attr_file ='sn' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - sn = "" - try: - with open(attr_path, 'r') as psu_sn: - sn = psu_sn.read() - except IOError: - return sn - - return sn - - def get_temperature(self): - """ - Retrieves current temperature reading from PSU - Returns: - A float number of current temperature in Celsius up to nearest thousandth - of one degree Celsius, e.g. 30.125 - """ - attr_file ='temp1_input' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - temp = 0.0 - try: - with open(attr_path, 'r') as psu_temp: - temp = float(psu_temp.read()) / 1000 - except IOError: - return temp - - return temp - - def get_temperature_high_threshold(self): - """ - Retrieves the high threshold temperature of PSU - Returns: - A float number, the high threshold temperature of PSU in Celsius - up to nearest thousandth of one degree Celsius, e.g. 30.125 - """ - return False #Not supported - - def get_voltage_high_threshold(self): - """ - Retrieves the high threshold PSU voltage output - Returns: - A float number, the high threshold output voltage in volts, - e.g. 12.1 - """ - return False #Not supported - - def get_voltage_low_threshold(self): - """ - Retrieves the low threshold PSU voltage output - Returns: - A float number, the low threshold output voltage in volts, - e.g. 12.1 - """ - return False #Not supported - - def get_voltage(self): - """ - Retrieves current PSU voltage output - Returns: - A float number, the output voltage in volts, - e.g. 12.1 - """ - attr_file ='in2_input' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - volt = 0.0 - try: - with open(attr_path, 'r') as psu_volt: - volt = float(psu_volt.read()) / 1000 - except IOError: - return volt - - return volt - - def get_current(self): - """ - Retrieves present electric current supplied by PSU - Returns: - A float number, the electric current in amperes, e.g 15.4 - """ - attr_file ='curr2_input' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - curr = 0.0 - try: - with open(attr_path, 'r') as psu_curr: - curr = float(psu_curr.read()) / 1000 - except IOError: - return curr - - return curr - - def get_power(self): - """ - Retrieves current energy supplied by PSU - Returns: - A float number, the power in watts, e.g. 302.6 - """ - attr_file ='power2_input' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file - power = 0.0 - try: - with open(attr_path, 'r') as psu_power: - power = float(psu_power.read()) / 1000000 - except IOError: - return power - - return power diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/watchdog.py b/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/watchdog.py deleted file mode 100644 index 820dd54f954a..000000000000 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/watchdog.py +++ /dev/null @@ -1,73 +0,0 @@ -#!/usr/bin/env python - -######################################################################## -# -# Abstract base class for implementing a platform-specific class with -# which to interact with a hardware watchdog module in SONiC -# -######################################################################## - -try: - from sonic_platform_base.watchdog_base import WatchdogBase -except ImportError as e: - raise ImportError(str(e) + "- required module not found") - -class Watchdog(WatchdogBase): - """ - Abstract base class for interfacing with a hardware watchdog module - """ - - def __init__(self): - print("INFO: Watchdog __init__") - - def arm(self, seconds): - """ - Arm the hardware watchdog with a timeout of seconds. - If the watchdog is currently armed, calling this function will - simply reset the timer to the provided value. If the underlying - hardware does not support the value provided in , this - method should arm the watchdog with the *next greater* - available value. - Returns: - An integer specifying the *actual* number of seconds the - watchdog was armed with. On failure returns -1. - """ - print("ERROR: Platform did not implement arm()") - raise NotImplementedError - - def disarm(self): - """ - Disarm the hardware watchdog - Returns: - A boolean, True if watchdog is disarmed successfully, False - if not - """ - print("ERROR: Platform did not implement disarm()") - raise NotImplementedError - - def is_armed(self): - """ - Retrieves the armed state of the hardware watchdog. - Returns: - A boolean, True if watchdog is armed, False if not - """ - print("ERROR: Platform did not implement is_armed()") - raise NotImplementedError - - def get_remaining_time(self): - """ - If the watchdog is armed, retrieve the number of seconds - remaining on the watchdog timer - Returns: - An integer specifying the number of seconds remaining on - their watchdog timer. If the watchdog is not armed, returns - -1. - S5232 doesnot have hardware support to show remaining time. - Due to this limitation, this API is implemented in software. - This API would return correct software time difference if it - is called from the process which armed the watchdog timer. - If this API called from any other process, it would return - 0. If the watchdog is not armed, this API would return -1. - """ - print("ERROR: Platform did not implement get_remaining_time()") - raise NotImplementedError diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/system_health_monitoring_config.json b/device/wistron/x86_64-wistron_6512_32r-r0/system_health_monitoring_config.json new file mode 100644 index 000000000000..0e0eec971cac --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/system_health_monitoring_config.json @@ -0,0 +1,11 @@ +{ + "services_to_ignore": [], + "devices_to_ignore": ["asic"], + "user_defined_checkers": [], + "polling_interval": 60, + "led_color": { + "fault": "red", + "normal": "green", + "booting": "green_blinking" + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/6512-32_32x400G.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/6512-32_32x400G.config.yaml index 17ed53abb1d0..cc5bebd7f719 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/6512-32_32x400G.config.yaml +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/6512-32_32x400G.config.yaml @@ -9,16 +9,17 @@ nodes: netdev: - auto_create: "no" multi_interface: "yes" - mac_clk: "1340" - skip_pll_check: "false" - sys_clk: "1720" - mbist_on_init: "true" - ifc_clk: "1200" buffer_management_mode: "api_driven" + wred_cr_ip_proto_list: "17" + cr_assignment_mode: "1" max_lossless_tc: "2" ilpm_enable: "1" forward_profile: "IFCS_FORWARD_PROFILE_ID_PROFILE_E" - ecn_stats_enable: "1" + led_cfg_sck_rate: "0x5" + led_refresh_precliff_timer: "0x18eec2" + led_refresh_cliff_timer: "0x15e" + led_cfg_pic_stream_mode: "1" + led_refresh_tmr_ctl_enable: "1" txring: - txring_id: "0" desc_count: "1024" @@ -41,22 +42,24 @@ nodes: desc_count: "1024" prio: "1" netdev: "true" - queues: "0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44" + queues: "0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 36, 39" - rxring_id: "1" desc_count: "1024" prio: "1" netdev: "true" - queues: "1, 5, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45" + queues: "1, 4, 7, 10, 13, 16, 19, 22, 25, 28, 31, 34, 37, 40" - rxring_id: "2" desc_count: "1024" prio: "1" netdev: "true" - queues: "2, 6, 10, 14, 18, 22, 26, 30, 34, 38, 42, 46" + queues: "2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41, 47" - rxring_id: "3" desc_count: "1024" prio: "1" - netdev: "true" - queues: "3, 7, 11, 15, 19, 23, 27, 31, 35, 39, 43, 47" + queues: "42, 43, 44, 45, 46" + sys_clk: "1720" + ifc_clk: "1200" + mac_clk: "1340" devports: - id: "0" sysport: "1000" @@ -285,20 +288,6 @@ nodes: speed: "400G" sysport: "233" type: "eth" - - id: "257" - fec: "NONE" - lanes: "0:1" - serdes_group: "32" - speed: "10G" - sysport: "257" - type: "mgmt 0" - - id: "258" - fec: "NONE" - lanes: "1:1" - serdes_group: "32" - speed: "10G" - sysport: "258" - type: "mgmt 1" isg: - id: "11" lane_swap: "27163504" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers.json.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers.json.j2 index 1a31812c26b1..b9265c62eb8f 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configuration available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "51691264", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"135520", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"10243072" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_def_lossy.j2 index 1a31812c26b1..79dbf9b2864b 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_def_lossy.j2 @@ -7,7 +7,7 @@ { "BUFFER_POOL": { "lossy_pool": { - "size": "56985600", + "size": "61458432", "type": "egress", "mode": "dynamic", "xoff": "0" @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_t1.j2 index 93dac6b1992a..b9265c62eb8f 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/buffers_defaults_t1.j2 @@ -1,4 +1,4 @@ -{# Default values which will be used if no actual configura available #} +{# Default values which will be used if no actual configuration available #} {% set default_cable = '40m' %} {# Port configuration to cable length look-up table #} @@ -76,7 +76,7 @@ }, "BUFFER_POOL": { "ingress_lossless_pool": { - "size": "47218432", + "size": "51691264", "type": "ingress", "mode": "dynamic", "xoff": "17708800" @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", - "xoff":"38816", + "pool":"ingress_lossless_pool", + "xoff":"135520", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/hwsku.json b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/hwsku.json new file mode 100644 index 000000000000..7157f361663e --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet248": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_A b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_A +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_B b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_B +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.config.yaml index cf505b299dd8..e3db67a5ccc5 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.config.yaml @@ -3,6 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.datapath.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.datapath.config.yaml index 891b0b3e2834..a539d6c70040 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.datapath.config.yaml +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/ivm.sai.datapath.config.yaml @@ -1,9 +1,9 @@ -ISAI_PARAM_P0_0_LS : "4608 4608 4608 4608 2880 2880" -ISAI_PARAM_P0_1_LS : "2226 1946 1946 1890 1218 1218" +ISAI_PARAM_P0_0_LS : "864 864 720 720 720 720" +ISAI_PARAM_P0_1_LS : "770 490 434 378 378 378" ISAI_PARAM_P0_1_ALS : "434 154 154 98 98 98" -ISAI_PARAM_P1_0_LS : "1536 1536 1536 1536 960 960" -ISAI_PARAM_P1_0_LL : "3072 3072 3072 3072 1920 1920" -ISAI_PARAM_P1_1_LS : "1778 1498 1498 1442 938 938" -ISAI_PARAM_P1_1_LL : "2478 2478 2478 2478 2478 2478" +ISAI_PARAM_P1_0_LS : "288 288 240 240 240 240" +ISAI_PARAM_P1_0_LL : "576 576 480 480 480 480" +ISAI_PARAM_P1_1_LS : "686 406 364 308 308 308" +ISAI_PARAM_P1_1_LL : "574 574 574 574 574 574" ISAI_PARAM_P1_1_ALS : "434 154 154 98 98 98" ISAI_PARAM_P1_1_ALL : "126 126 126 126 126 126" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos.json.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos.json.j2 index 104d2d78de87..b03078465730 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos.json.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos.json.j2 @@ -32,87 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } - }, - "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, - "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_def_lossy.j2 index 104d2d78de87..c1170619bc6c 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_t1.j2 index 4b9748c7b594..b03078465730 100644 --- a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/6512-32_32x100G.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/6512-32_32x100G.config.yaml new file mode 100644 index 000000000000..f22016d7be80 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/6512-32_32x100G.config.yaml @@ -0,0 +1,419 @@ +ifcs: + options: + log_level: "info" +nodes: +- node_id: "0" + options: + sd_low_power_mode_global_default: "true" + sku: "configs/sku/innovium.77700_A" + netdev: + - auto_create: "no" + multi_interface: "yes" + buffer_management_mode: "api_driven" + wred_cr_ip_proto_list: "17" + cr_assignment_mode: "1" + max_lossless_tc: "2" + ilpm_enable: "1" + forward_profile: "IFCS_FORWARD_PROFILE_ID_PROFILE_E" + led_cfg_sck_rate: "0x5" + led_refresh_precliff_timer: "0x18eec2" + led_refresh_cliff_timer: "0x15e" + led_cfg_pic_stream_mode: "1" + led_refresh_tmr_ctl_enable: "1" + txring: + - txring_id: "0" + desc_count: "1024" + prio: "1" + netdev: "true" + - txring_id: "1" + desc_count: "1024" + prio: "1" + netdev: "true" + - txring_id: "2" + desc_count: "1024" + prio: "1" + netdev: "true" + - txring_id: "3" + desc_count: "1024" + prio: "1" + netdev: "true" + rxring: + - rxring_id: "0" + desc_count: "1024" + prio: "1" + netdev: "true" + queues: "0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 30, 33, 36, 39" + - rxring_id: "1" + desc_count: "1024" + prio: "1" + netdev: "true" + queues: "1, 4, 7, 10, 13, 16, 19, 22, 25, 28, 31, 34, 37, 40" + - rxring_id: "2" + desc_count: "1024" + prio: "1" + netdev: "true" + queues: "2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35, 38, 41, 47" + - rxring_id: "3" + desc_count: "1024" + prio: "1" + queues: "42, 43, 44, 45, 46" + sys_clk: "1720" + ifc_clk: "1200" + mac_clk: "1340" + devports: + - id: "0" + sysport: "1000" + type: "cpu" + - id: "89" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "11" + speed: "100G" + sysport: "89" + type: "eth" + - id: "81" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "10" + speed: "100G" + sysport: "81" + type: "eth" + - id: "73" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "9" + speed: "100G" + sysport: "73" + type: "eth" + - id: "65" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "8" + speed: "100G" + sysport: "65" + type: "eth" + - id: "57" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "7" + speed: "100G" + sysport: "57" + type: "eth" + - id: "49" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "6" + speed: "100G" + sysport: "49" + type: "eth" + - id: "41" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "5" + speed: "100G" + sysport: "41" + type: "eth" + - id: "33" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "4" + speed: "100G" + sysport: "33" + type: "eth" + - id: "153" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "19" + speed: "100G" + sysport: "153" + type: "eth" + - id: "145" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "18" + speed: "100G" + sysport: "145" + type: "eth" + - id: "137" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "17" + speed: "100G" + sysport: "137" + type: "eth" + - id: "129" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "16" + speed: "100G" + sysport: "129" + type: "eth" + - id: "121" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "15" + speed: "100G" + sysport: "121" + type: "eth" + - id: "113" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "14" + speed: "100G" + sysport: "113" + type: "eth" + - id: "105" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "13" + speed: "100G" + sysport: "105" + type: "eth" + - id: "97" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "12" + speed: "100G" + sysport: "97" + type: "eth" + - id: "209" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "26" + speed: "100G" + sysport: "209" + type: "eth" + - id: "217" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "27" + speed: "100G" + sysport: "217" + type: "eth" + - id: "193" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "24" + speed: "100G" + sysport: "193" + type: "eth" + - id: "201" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "25" + speed: "100G" + sysport: "201" + type: "eth" + - id: "177" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "22" + speed: "100G" + sysport: "177" + type: "eth" + - id: "185" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "23" + speed: "100G" + sysport: "185" + type: "eth" + - id: "161" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "20" + speed: "100G" + sysport: "161" + type: "eth" + - id: "169" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "21" + speed: "100G" + sysport: "169" + type: "eth" + - id: "17" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "2" + speed: "100G" + sysport: "17" + type: "eth" + - id: "25" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "3" + speed: "100G" + sysport: "25" + type: "eth" + - id: "1" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "0" + speed: "100G" + sysport: "1" + type: "eth" + - id: "9" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "1" + speed: "100G" + sysport: "9" + type: "eth" + - id: "241" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "30" + speed: "100G" + sysport: "241" + type: "eth" + - id: "249" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "31" + speed: "100G" + sysport: "249" + type: "eth" + - id: "225" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "28" + speed: "100G" + sysport: "225" + type: "eth" + - id: "233" + fec: "KRFEC" + lanes: "0:4" + serdes_group: "29" + speed: "100G" + sysport: "233" + type: "eth" + isg: + - id: "11" + lane_swap: "27163504" + rx_polarity: "01010000" + tx_polarity: "01100000" + - id: "10" + lane_swap: "51604372" + rx_polarity: "11001000" + tx_polarity: "11110000" + - id: "9" + lane_swap: "17032546" + rx_polarity: "10001000" + tx_polarity: "00000100" + - id: "8" + lane_swap: "70435162" + rx_polarity: "11000100" + tx_polarity: "00100101" + - id: "7" + lane_swap: "27053416" + rx_polarity: "00011001" + tx_polarity: "10001000" + - id: "6" + lane_swap: "70635142" + rx_polarity: "10001000" + tx_polarity: "01100001" + - id: "5" + lane_swap: "27053416" + rx_polarity: "00001001" + tx_polarity: "00001000" + - id: "4" + lane_swap: "62405173" + rx_polarity: "11000101" + tx_polarity: "10110000" + - id: "19" + lane_swap: "06152347" + rx_polarity: "11010110" + tx_polarity: "10001110" + - id: "18" + lane_swap: "73614052" + rx_polarity: "11001100" + tx_polarity: "11100001" + - id: "17" + lane_swap: "17053426" + rx_polarity: "10001001" + tx_polarity: "00001000" + - id: "16" + lane_swap: "54216073" + rx_polarity: "10000011" + tx_polarity: "01001010" + - id: "15" + lane_swap: "36072514" + rx_polarity: "10100000" + tx_polarity: "10100001" + - id: "14" + lane_swap: "50763241" + rx_polarity: "00010001" + tx_polarity: "01110001" + - id: "13" + lane_swap: "26071435" + rx_polarity: "00000011" + tx_polarity: "00101001" + - id: "12" + lane_swap: "43510627" + rx_polarity: "11100100" + tx_polarity: "00011101" + - id: "26" + lane_swap: "31427506" + rx_polarity: "10011000" + tx_polarity: "11110001" + - id: "27" + lane_swap: "21735406" + rx_polarity: "01011110" + tx_polarity: "10011100" + - id: "24" + lane_swap: "07162435" + rx_polarity: "10010000" + tx_polarity: "10001010" + - id: "25" + lane_swap: "64501372" + rx_polarity: "11010001" + tx_polarity: "10001010" + - id: "22" + lane_swap: "35071624" + rx_polarity: "00100011" + tx_polarity: "11001011" + - id: "23" + lane_swap: "64705132" + rx_polarity: "11010100" + tx_polarity: "11101000" + - id: "20" + lane_swap: "16270453" + rx_polarity: "00101100" + tx_polarity: "00001001" + - id: "21" + lane_swap: "71356204" + rx_polarity: "01100010" + tx_polarity: "00001011" + - id: "2" + lane_swap: "37260145" + rx_polarity: "10011010" + tx_polarity: "11000000" + - id: "3" + lane_swap: "47512630" + rx_polarity: "10010100" + tx_polarity: "10101101" + - id: "0" + lane_swap: "05462713" + rx_polarity: "01000000" + tx_polarity: "10010010" + - id: "1" + lane_swap: "71605432" + rx_polarity: "00000000" + tx_polarity: "11000101" + - id: "30" + lane_swap: "37251604" + rx_polarity: "11000010" + tx_polarity: "11001000" + - id: "31" + lane_swap: "42736051" + rx_polarity: "10000110" + tx_polarity: "01000010" + - id: "28" + lane_swap: "01245736" + rx_polarity: "10110101" + tx_polarity: "10000001" + - id: "29" + lane_swap: "52706134" + rx_polarity: "00010010" + tx_polarity: "10101010" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers.json.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers.json.j2 new file mode 100644 index 000000000000..020656fdb8f5 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers.json.j2 @@ -0,0 +1,162 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + +{ + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, + "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "51691264", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, + "lossy_pool": { + "size": "18874368", + "type": "egress", + "mode": "dynamic", + "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" + } + }, + "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"10243072" + }, + "ingress_lossy_profile": { + "pool":"lossy_pool", + "size":"0", + "static_th":"10243072" + }, + "egress_lossy_profile": { + "pool":"lossy_pool", + "size":"1518", + "dynamic_th":"2" + } + }, + "BUFFER_PG": { +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + + "BUFFER_QUEUE": { +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_def_lossy.j2 new file mode 100644 index 000000000000..79dbf9b2864b --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_def_lossy.j2 @@ -0,0 +1,42 @@ +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + +{ + "BUFFER_POOL": { + "lossy_pool": { + "size": "61458432", + "type": "egress", + "mode": "dynamic", + "xoff": "0" + } + }, + "BUFFER_PROFILE": { + "ingress_lossy_profile": { + "pool":"lossy_pool", + "size":"0", + "static_th":"10243072" + }, + "egress_lossy_profile": { + "pool":"lossy_pool", + "size":"1518", + "dynamic_th":"2" + } + }, + "BUFFER_PG": { +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} + }, + "BUFFER_QUEUE": { +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_t1.j2 new file mode 100644 index 000000000000..020656fdb8f5 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/buffers_defaults_t1.j2 @@ -0,0 +1,162 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + +{ + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, + "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "51691264", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, + "lossy_pool": { + "size": "18874368", + "type": "egress", + "mode": "dynamic", + "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" + } + }, + "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"10243072" + }, + "ingress_lossy_profile": { + "pool":"lossy_pool", + "size":"0", + "static_th":"10243072" + }, + "egress_lossy_profile": { + "pool":"lossy_pool", + "size":"1518", + "dynamic_th":"2" + } + }, + "BUFFER_PG": { +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + + "BUFFER_QUEUE": { +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/hwsku.json b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/hwsku.json new file mode 100644 index 000000000000..4116ae2ba5f1 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet248": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_A b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_A new file mode 100644 index 000000000000..ec13307805e1 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_A @@ -0,0 +1,60 @@ +sku: innovium.77700_A + +device_id: 0x1b58 + +# Hardware constraint information +hardware: + num_ibs: 6 + ib_active: 0,1,2,3,4,5 + + ports_per_ib: 32, 32, 32, 32, 20, 20 + recirc_port_num: 32, 32, 32, 32, 32, 32 + cpu_port_num: 33 + cpu_port_ib: 0 + mgmt_port_num: 33 + mgmt_port_ibs: 1,2 + + pics_per_ib: 6, 7, 6, 5, 5, 5 + pic_ports_per_pic: 8 + max_serdes_speed: 50 + + num_shared_pics: 2 + + isg [0-4]: + ib: 0 + pic_id: [0-4] + + isg [5-9]: + ib: 5 + pic_id: [0-4] + + isg [10-14]: + ib: 1 + pic_id: [0-4] + + isg [16-20]: + ib: 3 + pic_id: [0-4] + + isg [21-25]: + ib: 4 + pic_id: [0-4] + + isg [26-30]: + ib: 2 + pic_id: [0-4] + + isg 15: + mode: 8:0 + ib: 1 + pic_id: 5 + + isg 31: + mode: 8:0 + ib: 0 + pic_id: 5 + + isg 32: + mode: 1:1 + ib: 1, 2 + pic_id: 6 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_B b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_B new file mode 100644 index 000000000000..57ba52cbc3bc --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/innovium.77700_B @@ -0,0 +1,60 @@ +sku: innovium.77700_B + +device_id: 0x1b58 + +# Hardware constraint information +hardware: + num_ibs: 6 + ib_active: 0,1,2,3,4,5 + + ports_per_ib: 32, 32, 32, 32, 20, 20 + recirc_port_num: 32, 32, 32, 32, 32, 32 + cpu_port_num: 33 + cpu_port_ib: 0 + mgmt_port_num: 33 + mgmt_port_ibs: 1,2 + + pics_per_ib: 6, 7, 7, 6, 5, 5 + pic_ports_per_pic: 8 + max_serdes_speed: 50 + + num_shared_pics: 2 + + isg [0-4]: + ib: 0 + pic_id: [0-4] + + isg [5-9]: + ib: 5 + pic_id: [0-4] + + isg [10-14]: + ib: 1 + pic_id: [0-4] + + isg [16-20]: + ib: 3 + pic_id: [0-4] + + isg [21-25]: + ib: 4 + pic_id: [0-4] + + isg [26-30]: + ib: 2 + pic_id: [0-4] + + isg 15: + mode: 4:4 + ib: 1, 3 + pic_id: 5 + + isg 31: + mode: 4:4 + ib: 0, 2 + pic_id: 5 + + isg 32: + mode: 1:1 + ib: 1, 2 + pic_id: 6 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.config.yaml new file mode 100644 index 000000000000..1f90f4de88dd --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.config.yaml @@ -0,0 +1,9 @@ +IFCS_INIT_FILE : "/usr/share/sonic/hwsku/6512-32_32x100G.config.yaml" +IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" +IFCS_INNO_CLI_PORT : "9999" +IFCS_TARGET : "device" +INNOVIUM_DIR : "/innovium" +PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" +IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" +IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.datapath.config.yaml b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.datapath.config.yaml new file mode 100644 index 000000000000..891b0b3e2834 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/ivm.sai.datapath.config.yaml @@ -0,0 +1,9 @@ +ISAI_PARAM_P0_0_LS : "4608 4608 4608 4608 2880 2880" +ISAI_PARAM_P0_1_LS : "2226 1946 1946 1890 1218 1218" +ISAI_PARAM_P0_1_ALS : "434 154 154 98 98 98" +ISAI_PARAM_P1_0_LS : "1536 1536 1536 1536 960 960" +ISAI_PARAM_P1_0_LL : "3072 3072 3072 3072 1920 1920" +ISAI_PARAM_P1_1_LS : "1778 1498 1498 1442 938 938" +ISAI_PARAM_P1_1_LL : "2478 2478 2478 2478 2478 2478" +ISAI_PARAM_P1_1_ALS : "434 154 154 98 98 98" +ISAI_PARAM_P1_1_ALL : "126 126 126 126 126 126" diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/pg_profile_lookup.ini new file mode 100644 index 000000000000..0d881737cfa1 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/pg_profile_lookup.ini @@ -0,0 +1,22 @@ +# PG lossless profiles. +# speed cable size xon xoff threshold xon_offset + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/port_config.ini b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/port_config.ini new file mode 100644 index 000000000000..9507616bd5c2 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/port_config.ini @@ -0,0 +1,33 @@ +# name lanes alias speed index mtu fec +Ethernet0 89,90,91,92 Eth1 100000 0 9126 rs +Ethernet8 81,82,83,84 Eth2 100000 1 9126 rs +Ethernet16 73,74,75,76 Eth3 100000 2 9126 rs +Ethernet24 65,66,67,68 Eth4 100000 3 9126 rs +Ethernet32 57,58,59,60 Eth5 100000 4 9126 rs +Ethernet40 49,50,51,52 Eth6 100000 5 9126 rs +Ethernet48 41,42,43,44 Eth7 100000 6 9126 rs +Ethernet56 33,34,35,36 Eth8 100000 7 9126 rs +Ethernet64 153,154,155,156 Eth9 100000 8 9126 rs +Ethernet72 145,146,147,148 Eth10 100000 9 9126 rs +Ethernet80 137,138,139,140 Eth11 100000 10 9126 rs +Ethernet88 129,130,131,132 Eth12 100000 11 9126 rs +Ethernet96 121,122,123,124 Eth13 100000 12 9126 rs +Ethernet104 113,114,115,116 Eth14 100000 13 9126 rs +Ethernet112 105,106,107,108 Eth15 100000 14 9126 rs +Ethernet120 97,98,99,100 Eth16 100000 15 9126 rs +Ethernet128 209,210,211,212 Eth17 100000 16 9126 rs +Ethernet136 217,218,219,220 Eth18 100000 17 9126 rs +Ethernet144 193,194,195,196 Eth19 100000 18 9126 rs +Ethernet152 201,202,203,204 Eth20 100000 19 9126 rs +Ethernet160 177,178,179,180 Eth21 100000 20 9126 rs +Ethernet168 185,186,187,188 Eth22 100000 21 9126 rs +Ethernet176 161,162,163,164 Eth23 100000 22 9126 rs +Ethernet184 169,170,171,172 Eth24 100000 23 9126 rs +Ethernet192 17,18,19,20 Eth25 100000 24 9126 rs +Ethernet200 25,26,27,28 Eth26 100000 25 9126 rs +Ethernet208 1,2,3,4 Eth27 100000 26 9126 rs +Ethernet216 9,10,11,12 Eth28 100000 27 9126 rs +Ethernet224 241,242,243,244 Eth29 100000 28 9126 rs +Ethernet232 249,250,251,252 Eth30 100000 29 9126 rs +Ethernet240 225,226,227,228 Eth31 100000 30 9126 rs +Ethernet248 233,234,235,236 Eth32 100000 31 9126 rs diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos.json.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos.json.j2 new file mode 100644 index 000000000000..b03078465730 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos.json.j2 @@ -0,0 +1,129 @@ +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + + +{ + "TC_TO_QUEUE_MAP":{ + "AZURE":{ + "0":"0", + "1":"1", + "2":"2", + "3":"3", + "4":"4", + "5":"5", + "6":"6", + "7":"7" + } + }, + "TC_TO_PRIORITY_GROUP_MAP": { + "AZURE": { + "0": "0", + "1": "0", + "2": "0", + "3": "3", + "4": "4", + "5": "0", + "6": "0", + "7": "0" + } + }, + "DSCP_TO_TC_MAP": { + "AZURE": { + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" + } + }, + "PORT_QOS_MAP": { +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_def_lossy.j2 new file mode 100644 index 000000000000..c1170619bc6c --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_def_lossy.j2 @@ -0,0 +1,121 @@ +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + + +{ + "TC_TO_QUEUE_MAP":{ + "AZURE":{ + "0":"0", + "1":"1", + "2":"2", + "3":"3", + "4":"4", + "5":"5", + "6":"6", + "7":"7" + } + }, + "TC_TO_PRIORITY_GROUP_MAP": { + "AZURE": { + "0": "0", + "1": "0", + "2": "0", + "3": "1", + "4": "2", + "5": "0", + "6": "0", + "7": "0" + } + }, + "DSCP_TO_TC_MAP": { + "AZURE": { + "0":"0", + "1":"0", + "2":"0", + "3":"0", + "4":"0", + "5":"0", + "6":"0", + "7":"0", + "8":"0", + "9":"0", + "10":"0", + "11":"0", + "12":"0", + "13":"0", + "14":"0", + "15":"0", + "16":"0", + "17":"0", + "18":"0", + "19":"0", + "20":"0", + "21":"0", + "22":"0", + "23":"0", + "24":"0", + "25":"0", + "26":"0", + "27":"0", + "28":"0", + "29":"0", + "30":"0", + "31":"0", + "32":"0", + "33":"0", + "34":"0", + "35":"0", + "36":"0", + "37":"0", + "38":"0", + "39":"0", + "40":"0", + "41":"0", + "42":"0", + "43":"0", + "44":"0", + "45":"0", + "46":"0", + "47":"0", + "48":"0", + "49":"0", + "50":"0", + "51":"0", + "52":"0", + "53":"0", + "54":"0", + "55":"0", + "56":"0", + "57":"0", + "58":"0", + "59":"0", + "60":"0", + "61":"0", + "62":"0", + "63":"0" + } + }, + "PORT_QOS_MAP": { +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + "SCHEDULER": { + "scheduler.7": { + "type": "STRICT" + } + }, + "QUEUE": { + "{{ port_names }}|7": { + "scheduler": "[SCHEDULER|scheduler.7]" + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_t1.j2 new file mode 100644 index 000000000000..b03078465730 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/qos_defaults_t1.j2 @@ -0,0 +1,129 @@ +{% set port_names_list = [] %} +{% for port in PORT %} + {%- if port_names_list.append(port) %}{% endif %} +{% endfor %} +{% set port_names = port_names_list | join(',') -%} + + +{ + "TC_TO_QUEUE_MAP":{ + "AZURE":{ + "0":"0", + "1":"1", + "2":"2", + "3":"3", + "4":"4", + "5":"5", + "6":"6", + "7":"7" + } + }, + "TC_TO_PRIORITY_GROUP_MAP": { + "AZURE": { + "0": "0", + "1": "0", + "2": "0", + "3": "3", + "4": "4", + "5": "0", + "6": "0", + "7": "0" + } + }, + "DSCP_TO_TC_MAP": { + "AZURE": { + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" + } + }, + "PORT_QOS_MAP": { +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" + } + } +} diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/sai.profile b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/sai.profile new file mode 100644 index 000000000000..aba4fc81fb17 --- /dev/null +++ b/device/wistron/x86_64-wistron_6512_32r-r0/wistron_6512_32r_32x100/sai.profile @@ -0,0 +1 @@ +SAI_INIT_CONFIG_FILE=/usr/share/sonic/hwsku/ivm.sai.config.yaml diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers.json.j2 index 1a31812c26b1..b9265c62eb8f 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configuration available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "51691264", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"135520", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"10243072" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_def_lossy.j2 index 1a31812c26b1..79dbf9b2864b 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_def_lossy.j2 @@ -7,7 +7,7 @@ { "BUFFER_POOL": { "lossy_pool": { - "size": "56985600", + "size": "61458432", "type": "egress", "mode": "dynamic", "xoff": "0" @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_t1.j2 index 93dac6b1992a..b9265c62eb8f 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/buffers_defaults_t1.j2 @@ -1,4 +1,4 @@ -{# Default values which will be used if no actual configura available #} +{# Default values which will be used if no actual configuration available #} {% set default_cable = '40m' %} {# Port configuration to cable length look-up table #} @@ -76,7 +76,7 @@ }, "BUFFER_POOL": { "ingress_lossless_pool": { - "size": "47218432", + "size": "51691264", "type": "ingress", "mode": "dynamic", "xoff": "17708800" @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", - "xoff":"38816", + "pool":"ingress_lossless_pool", + "xoff":"135520", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/config_32x400G_wistron_sw_to3200k.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/config_32x400G_wistron_sw_to3200k.yaml index 23445c6dede5..b96146517adb 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/config_32x400G_wistron_sw_to3200k.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/config_32x400G_wistron_sw_to3200k.yaml @@ -10,13 +10,11 @@ nodes: - auto_create: "no" multi_interface: "yes" buffer_management_mode: "api_driven" + wred_cr_ip_proto_list: "17" + cr_assignment_mode: "1" max_lossless_tc: "2" ilpm_enable: "1" forward_profile: "IFCS_FORWARD_PROFILE_ID_PROFILE_E" - ecn_stats_enable: "1" - pcie_attn: "10, 0, 0, 0" - pcie_post: "10, 18, 18, 18" - pcie_pre1: "0, 0, 0, 0" led_cfg_sck_rate: "0x5" led_refresh_precliff_timer: "0x18eec2" led_refresh_cliff_timer: "0x15e" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/hwsku.json new file mode 100644 index 000000000000..7157f361663e --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet248": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_A b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_A +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.config.yaml old mode 100644 new mode 100755 index 0c1644ab7d72..ed98d89bfac6 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.datapath.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.datapath.config.yaml index 891b0b3e2834..a539d6c70040 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.datapath.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/ivm.sai.datapath.config.yaml @@ -1,9 +1,9 @@ -ISAI_PARAM_P0_0_LS : "4608 4608 4608 4608 2880 2880" -ISAI_PARAM_P0_1_LS : "2226 1946 1946 1890 1218 1218" +ISAI_PARAM_P0_0_LS : "864 864 720 720 720 720" +ISAI_PARAM_P0_1_LS : "770 490 434 378 378 378" ISAI_PARAM_P0_1_ALS : "434 154 154 98 98 98" -ISAI_PARAM_P1_0_LS : "1536 1536 1536 1536 960 960" -ISAI_PARAM_P1_0_LL : "3072 3072 3072 3072 1920 1920" -ISAI_PARAM_P1_1_LS : "1778 1498 1498 1442 938 938" -ISAI_PARAM_P1_1_LL : "2478 2478 2478 2478 2478 2478" +ISAI_PARAM_P1_0_LS : "288 288 240 240 240 240" +ISAI_PARAM_P1_0_LL : "576 576 480 480 480 480" +ISAI_PARAM_P1_1_LS : "686 406 364 308 308 308" +ISAI_PARAM_P1_1_LL : "574 574 574 574 574 574" ISAI_PARAM_P1_1_ALS : "434 154 154 98 98 98" ISAI_PARAM_P1_1_ALL : "126 126 126 126 126 126" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos.json.j2 old mode 100644 new mode 100755 index 104d2d78de87..0f1ecd1106d0 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos.json.j2 @@ -18,6 +18,18 @@ "7":"7" } }, + "MAP_PFC_PRIORITY_TO_QUEUE": { + "AZURE": { + "0": "0", + "1": "1", + "2": "2", + "3": "3", + "4": "4", + "5": "5", + "6": "6", + "7": "7" + } + }, "TC_TO_PRIORITY_GROUP_MAP": { "AZURE": { "0": "0", @@ -32,87 +44,149 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" - } - }, - "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" + "scheduler.0": { + "type" : "DWRR", + "weight": "1" + }, + "scheduler.1": { + "type" : "DWRR", + "weight": "1" } }, "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" +{% for port in port_names_list %} + "{{ port }}|3": { + "scheduler" : "scheduler.1", + "wred_profile" : "AZURE_LOSSLESS" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|4": { + "scheduler" : "scheduler.1", + "wred_profile" : "AZURE_LOSSLESS" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|2": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|6": { + "scheduler": "scheduler.0" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + "PORT_QOS_MAP": { +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_to_queue_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..0f1ecd1106d0 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k/qos_defaults_t1.j2 @@ -18,6 +18,18 @@ "7":"7" } }, + "MAP_PFC_PRIORITY_TO_QUEUE": { + "AZURE": { + "0": "0", + "1": "1", + "2": "2", + "3": "3", + "4": "4", + "5": "5", + "6": "6", + "7": "7" + } + }, "TC_TO_PRIORITY_GROUP_MAP": { "AZURE": { "0": "0", @@ -32,83 +44,149 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" + } + }, + "SCHEDULER": { + "scheduler.0": { + "type" : "DWRR", + "weight": "1" + }, + "scheduler.1": { + "type" : "DWRR", + "weight": "1" } }, + "QUEUE": { +{% for port in port_names_list %} + "{{ port }}|3": { + "scheduler" : "scheduler.1", + "wred_profile" : "AZURE_LOSSLESS" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|4": { + "scheduler" : "scheduler.1", + "wred_profile" : "AZURE_LOSSLESS" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|2": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5": { + "scheduler": "scheduler.0" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|6": { + "scheduler": "scheduler.0" + }{% if not loop.last %},{% endif %} + +{% endfor %} + }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_to_queue_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers.json.j2 index 1a31812c26b1..794b5c854689 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "47218432", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"9497600" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_def_lossy.j2 index 1a31812c26b1..abb756c7d4ef 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_def_lossy.j2 @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_t1.j2 index 93dac6b1992a..17b85f08443a 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/buffers_defaults_t1.j2 @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", "static_th":"9497600" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/hwsku.json new file mode 100644 index 000000000000..c874d4d0b9ba --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet152": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet160": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet168": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet176": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet184": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet192": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet200": { + "default_brkout_mode": "4x10G[25G](4)", + "fec": "none" + }, + "Ethernet208": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet232": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet240": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet248": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_A b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_A +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/ivm.sai.config.yaml old mode 100644 new mode 100755 index 5e5d2fe66861..b9f2cc4061d1 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_B" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos.json.j2 old mode 100644 new mode 100755 index 104d2d78de87..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos.json.j2 @@ -32,87 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } - }, - "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, - "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_104x1025_6x100/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers.json.j2 index 1a31812c26b1..794b5c854689 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "47218432", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"9497600" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_def_lossy.j2 index 1a31812c26b1..abb756c7d4ef 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_def_lossy.j2 @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_t1.j2 index 93dac6b1992a..1479f78fed9e 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/buffers_defaults_t1.j2 @@ -86,52 +86,76 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "type": "egress" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", "static_th":"9497600" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/hwsku.json new file mode 100644 index 000000000000..c597c7248c87 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet200": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet208": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet216": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet224": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet232": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet240": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet248": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_A b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_A +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/ivm.sai.config.yaml old mode 100644 new mode 100755 index 8014caa1da4d..3a18ade8f2b2 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos.json.j2 old mode 100644 new mode 100755 index 104d2d78de87..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos.json.j2 @@ -32,87 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } - }, - "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, - "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_24x400_8x100/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers.json.j2 index 1a31812c26b1..794b5c854689 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "47218432", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"9497600" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_def_lossy.j2 index 1a31812c26b1..abb756c7d4ef 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_def_lossy.j2 @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_t1.j2 index 93dac6b1992a..17b85f08443a 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/buffers_defaults_t1.j2 @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", "static_th":"9497600" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/hwsku.json new file mode 100644 index 000000000000..ac524d6920ce --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet40": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet88": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet152": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x100G(4)", + "fec": "none" + }, + "Ethernet248": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_A b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_A +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/ivm.sai.config.yaml old mode 100644 new mode 100755 index e17792d88daa..36fd34a546c4 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos.json.j2 old mode 100644 new mode 100755 index 104d2d78de87..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos.json.j2 @@ -32,87 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } - }, - "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, - "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_28x400_4x100/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers.json.j2 index 93dac6b1992a..020656fdb8f5 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers.json.j2 @@ -76,7 +76,7 @@ }, "BUFFER_POOL": { "ingress_lossless_pool": { - "size": "47218432", + "size": "51691264", "type": "ingress", "mode": "dynamic", "xoff": "17708800" @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_def_lossy.j2 index 1a31812c26b1..79dbf9b2864b 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_def_lossy.j2 @@ -7,7 +7,7 @@ { "BUFFER_POOL": { "lossy_pool": { - "size": "56985600", + "size": "61458432", "type": "egress", "mode": "dynamic", "xoff": "0" @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_t1.j2 index 93dac6b1992a..020656fdb8f5 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/buffers_defaults_t1.j2 @@ -76,7 +76,7 @@ }, "BUFFER_POOL": { "ingress_lossless_pool": { - "size": "47218432", + "size": "51691264", "type": "ingress", "mode": "dynamic", "xoff": "17708800" @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "70565632", + "type": "egress", + "mode": "static" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", - "static_th":"9497600" + "static_th":"10243072" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/config_32x100G_wistron_sw_to3200k.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/config_32x100G_wistron_sw_to3200k.yaml index a6f5d00d8b34..a0faac84625e 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/config_32x100G_wistron_sw_to3200k.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/config_32x100G_wistron_sw_to3200k.yaml @@ -10,12 +10,11 @@ nodes: - auto_create: "no" multi_interface: "yes" buffer_management_mode: "api_driven" + wred_cr_ip_proto_list: "17" + cr_assignment_mode: "1" max_lossless_tc: "2" ilpm_enable: "1" forward_profile: "IFCS_FORWARD_PROFILE_ID_PROFILE_E" - pcie_attn: "10, 0, 0, 0" - pcie_post: "10, 18, 18, 18" - pcie_pre1: "0, 0, 0, 0" led_cfg_sck_rate: "0x5" led_refresh_precliff_timer: "0x18eec2" led_refresh_cliff_timer: "0x15e" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/hwsku.json new file mode 100644 index 000000000000..4116ae2ba5f1 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet248": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/ivm.sai.config.yaml old mode 100644 new mode 100755 index 8ae2b9683d49..7bc06c952692 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_B" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos.json.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos.json.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_32x100/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers.json.j2 index 1a31812c26b1..794b5c854689 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers.json.j2 @@ -1,3 +1,63 @@ +{# Default values which will be used if no actual configura available #} +{% set default_cable = '40m' %} + +{# Port configuration to cable length look-up table #} +{# Each record describes mapping of DUT (DUT port) role and neighbor role to cable length #} +{# Roles described in the minigraph #} +{% set ports2cable = { + 'torrouter_server' : '5m', + 'leafrouter_torrouter' : '40m', + 'spinerouter_leafrouter' : '300m' + } +%} + +{%- macro cable_length(port_name) %} + {%- set cable_len = [] %} + {%- for local_port in DEVICE_NEIGHBOR %} + {%- if local_port == port_name %} + {%- if DEVICE_NEIGHBOR_METADATA is defined and DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor = DEVICE_NEIGHBOR_METADATA[DEVICE_NEIGHBOR[local_port].name] %} + {%- set neighbor_role = neighbor.type %} + {%- set roles1 = switch_role + '_' + neighbor_role %} + {%- set roles2 = neighbor_role + '_' + switch_role %} + {%- set roles1 = roles1 | lower %} + {%- set roles2 = roles2 | lower %} + {%- if roles1 in ports2cable %} + {%- if cable_len.append(ports2cable[roles1]) %}{% endif %} + {%- elif roles2 in ports2cable %} + {%- if cable_len.append(ports2cable[roles2]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else %} + {%- if switch_role.lower() == 'torrouter' %} + {%- for local_port in VLAN_MEMBER %} + {%- if local_port[1] == port_name %} + {%- set roles3 = switch_role + '_' + 'server' %} + {%- set roles3 = roles3 | lower %} + {%- if roles3 in ports2cable %} + {%- if cable_len.append(ports2cable[roles3]) %}{% endif %} + {%- endif %} + {%- endif %} + {%- endfor %} + {%- if cable_len -%} + {{ cable_len.0 }} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- else -%} + {{ default_cable }} + {%- endif %} + {%- endif %} +{%- endmacro %} + +{%- if DEVICE_METADATA is defined %} +{%- set switch_role = DEVICE_METADATA['localhost']['type'] %} +{%- endif -%} + {% set port_names_list = [] %} {% for port in PORT %} {%- if port_names_list.append(port) %}{% endif %} @@ -5,34 +65,98 @@ {% set port_names = port_names_list | join(',') -%} { + "CABLE_LENGTH": { + "AZURE": { + {% for port in PORT %} + {% set cable = cable_length(port) -%} + "{{ port }}": "{{ cable }}"{%- if not loop.last -%},{% endif %} + + {% endfor %} + } + }, "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "47218432", + "type": "ingress", + "mode": "dynamic", + "xoff": "17708800" + }, "lossy_pool": { - "size": "56985600", + "size": "18874368", "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { + "ingress_lossless_profile": { + "pool":"ingress_lossless_pool", + "xoff":"38816", + "size":"1518", + "dynamic_th":"1", + "xon_offset":"9408" + }, + "egress_lossless_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "static_th":"9497600" + }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_def_lossy.j2 index 1a31812c26b1..abb756c7d4ef 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_def_lossy.j2 @@ -15,24 +15,28 @@ }, "BUFFER_PROFILE": { "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} }, "BUFFER_QUEUE": { - "{{ port_names }}|0-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|0-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_t1.j2 index 93dac6b1992a..17b85f08443a 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/buffers_defaults_t1.j2 @@ -86,52 +86,77 @@ "type": "egress", "mode": "dynamic", "xoff": "0" + }, + "egress_lossless_pool": { + "size": "66092800", + "mode": "static", + "type": "egress" } }, "BUFFER_PROFILE": { "ingress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "xoff":"38816", "size":"1518", "dynamic_th":"1", - "xon_offset":"13440" + "xon_offset":"9408" }, "egress_lossless_profile": { - "pool":"[BUFFER_POOL|ingress_lossless_pool]", + "pool":"ingress_lossless_pool", "size":"0", "static_th":"9497600" }, "ingress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"0", "static_th":"9497600" }, "egress_lossy_profile": { - "pool":"[BUFFER_POOL|lossy_pool]", + "pool":"lossy_pool", "size":"1518", "dynamic_th":"2" } }, "BUFFER_PG": { - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - }, - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|ingress_lossless_profile]" - }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|ingress_lossy_profile]" - } +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "ingress_lossless_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|1-2": { + "profile" : "ingress_lossy_profile" + }, +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "ingress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, + "BUFFER_QUEUE": { - "{{ port_names }}|3-4": { - "profile" : "[BUFFER_PROFILE|egress_lossless_profile]" +{% for port in port_names_list %} + "{{ port }}|3-4": { + "profile" : "egress_lossless_profile" }, - "{{ port_names }}|0-2": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|0-2": { + "profile" : "egress_lossy_profile" }, - "{{ port_names }}|5-7": { - "profile" : "[BUFFER_PROFILE|egress_lossy_profile]" - } +{% endfor %} +{% for port in port_names_list %} + "{{ port }}|5-7": { + "profile" : "egress_lossy_profile" + }{% if not loop.last %},{% endif %} + +{% endfor %} } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/hwsku.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/hwsku.json new file mode 100644 index 000000000000..6472483dc248 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/hwsku.json @@ -0,0 +1,132 @@ +{ + "interfaces": { + "Ethernet0": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet8": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet16": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet24": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet32": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet40": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet48": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet56": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet64": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet72": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet80": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet88": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet96": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet104": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet112": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet120": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet128": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet136": { + "default_brkout_mode": "4x25G[10G](4)", + "fec": "rs" + }, + "Ethernet144": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet152": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet160": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet168": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet176": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet184": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet192": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet200": { + "default_brkout_mode": "1x100G(4)", + "fec": "rs" + }, + "Ethernet208": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet216": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet224": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet232": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet240": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + }, + "Ethernet248": { + "default_brkout_mode": "1x400G[100G]", + "fec": "rs" + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_A b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_A index 84aa41983606..ec13307805e1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_A +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_A @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_B b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_B index 27297b313959..57ba52cbc3bc 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_B +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/innovium.77700_B @@ -5,6 +5,7 @@ device_id: 0x1b58 # Hardware constraint information hardware: num_ibs: 6 + ib_active: 0,1,2,3,4,5 ports_per_ib: 32, 32, 32, 32, 20, 20 recirc_port_num: 32, 32, 32, 32, 32, 32 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/ivm.sai.config.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/ivm.sai.config.yaml old mode 100644 new mode 100755 index 01fe64ec7bc9..36da27953d49 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/ivm.sai.config.yaml +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/ivm.sai.config.yaml @@ -3,7 +3,7 @@ IFCS_SKU_FILE : "/usr/share/sonic/hwsku/innovium.77700_A" IFCS_INNO_CLI_PORT : "9999" IFCS_TARGET : "device" INNOVIUM_DIR : "/innovium" -PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes" +PYTHONPATH : "$INNOVIUM_DIR:$INNOVIUM_DIR/cmds:$INNOVIUM_DIR/scripts:$INNOVIUM_DIR/test/:$INNOVIUM_DIR/test/utils:$INNOVIUM_DIR/utils:$INNOVIUM_DIR/pyctypes:$INNOVIUM_DIR/ifcs_cmds:$INNOVIUM_DIR/testutil" PLATFORM_LIBRARY: "/usr/share/sonic/platform/lib_ivm_serdes_pltfm.so" IVM_SAI_DATAPATH_CONFIG_FILE: "/usr/share/sonic/hwsku/ivm.sai.datapath.config.yaml" IVM_SAI_PARAM_A0008: "32" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/pg_profile_lookup.ini b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/pg_profile_lookup.ini index adcb52ab2a29..0d881737cfa1 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/pg_profile_lookup.ini +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/pg_profile_lookup.ini @@ -1,18 +1,22 @@ # PG lossless profiles. # speed cable size xon xoff threshold xon_offset - 25000 5m 1518 0 15680 1 13440 - 50000 5m 1518 0 21248 1 13440 - 100000 5m 1518 0 34624 1 13440 - 400000 5m 1518 0 117536 1 13440 - 25000 40m 1518 0 16928 1 13440 - 50000 40m 1518 0 23392 1 13440 - 100000 40m 1518 0 38816 1 13440 - 400000 40m 1518 0 135520 1 13440 - 25000 100m 1518 0 18848 1 13440 - 50000 100m 1518 0 27264 1 13440 - 100000 100m 1518 0 46496 1 13440 - 400000 100m 1518 0 166688 1 13440 - 25000 300m 1518 0 25184 1 13440 - 50000 300m 1518 0 40128 1 13440 - 100000 300m 1518 0 72384 1 13440 - 400000 300m 1518 0 268640 1 13440 + 25000 5m 1518 0 15680 1 9408 + 50000 5m 1518 0 21248 1 9408 + 100000 5m 1518 0 34624 1 9408 + 200000 5m 1518 0 62368 1 9408 + 400000 5m 1518 0 117536 1 9408 + 25000 40m 1518 0 16928 1 9408 + 50000 40m 1518 0 23392 1 9408 + 100000 40m 1518 0 38816 1 9408 + 200000 40m 1518 0 71904 1 9408 + 400000 40m 1518 0 135520 1 9408 + 25000 100m 1518 0 18848 1 9408 + 50000 100m 1518 0 27264 1 9408 + 100000 100m 1518 0 46496 1 9408 + 200000 100m 1518 0 87168 1 9408 + 400000 100m 1518 0 166688 1 9408 + 25000 300m 1518 0 25184 1 9408 + 50000 300m 1518 0 40128 1 9408 + 100000 300m 1518 0 72384 1 9408 + 200000 300m 1518 0 138112 1 9408 + 400000 300m 1518 0 268640 1 9408 diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos.json.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos.json.j2 old mode 100644 new mode 100755 index 104d2d78de87..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos.json.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos.json.j2 @@ -32,87 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"0", - "4":"0", - "5":"0", - "6":"0", - "7":"0", - "8":"0", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } - }, - "SCHEDULER": { - "scheduler.7": { - "type": "STRICT" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", + "pfc_enable": "3,4" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, - "QUEUE": { - "{{ port_names }}|7": { - "scheduler": "[SCHEDULER|scheduler.7]" + "WRED_PROFILE": { + "AZURE_LOSSLESS" : { + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_def_lossy.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_def_lossy.j2 old mode 100644 new mode 100755 index 104d2d78de87..c1170619bc6c --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_def_lossy.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_def_lossy.j2 @@ -23,8 +23,8 @@ "0": "0", "1": "0", "2": "0", - "3": "3", - "4": "4", + "3": "1", + "4": "2", "5": "0", "6": "0", "7": "0" @@ -99,11 +99,14 @@ } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]" - } +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE" + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "SCHEDULER": { "scheduler.7": { diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_t1.j2 b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_t1.j2 old mode 100644 new mode 100755 index 4b9748c7b594..b03078465730 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_t1.j2 +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/Wistron_sw_to3200k_72x25_6x400/qos_defaults_t1.j2 @@ -32,83 +32,98 @@ }, "DSCP_TO_TC_MAP": { "AZURE": { - "0":"0", - "1":"0", - "2":"0", - "3":"3", - "4":"4", - "5":"0", - "6":"0", - "7":"0", - "8":"1", - "9":"0", - "10":"0", - "11":"0", - "12":"0", - "13":"0", - "14":"0", - "15":"0", - "16":"0", - "17":"0", - "18":"0", - "19":"0", - "20":"0", - "21":"0", - "22":"0", - "23":"0", - "24":"0", - "25":"0", - "26":"0", - "27":"0", - "28":"0", - "29":"0", - "30":"0", - "31":"0", - "32":"0", - "33":"0", - "34":"0", - "35":"0", - "36":"0", - "37":"0", - "38":"0", - "39":"0", - "40":"0", - "41":"0", - "42":"0", - "43":"0", - "44":"0", - "45":"0", - "46":"0", - "47":"0", - "48":"0", - "49":"0", - "50":"0", - "51":"0", - "52":"0", - "53":"0", - "54":"0", - "55":"0", - "56":"0", - "57":"0", - "58":"0", - "59":"0", - "60":"0", - "61":"0", - "62":"0", - "63":"0" + "0" : "1", + "1" : "1", + "2" : "1", + "3" : "3", + "4" : "4", + "5" : "2", + "6" : "1", + "7" : "1", + "8" : "0", + "9" : "1", + "10": "1", + "11": "1", + "12": "1", + "13": "1", + "14": "1", + "15": "1", + "16": "1", + "17": "1", + "18": "1", + "19": "1", + "20": "1", + "21": "1", + "22": "1", + "23": "1", + "24": "1", + "25": "1", + "26": "1", + "27": "1", + "28": "1", + "29": "1", + "30": "1", + "31": "1", + "32": "1", + "33": "1", + "34": "1", + "35": "1", + "36": "1", + "37": "1", + "38": "1", + "39": "1", + "40": "1", + "41": "1", + "42": "1", + "43": "1", + "44": "1", + "45": "1", + "46": "5", + "47": "1", + "48": "6", + "49": "1", + "50": "1", + "51": "1", + "52": "1", + "53": "1", + "54": "1", + "55": "1", + "56": "1", + "57": "1", + "58": "1", + "59": "1", + "60": "1", + "61": "1", + "62": "1", + "63": "1" } }, "PORT_QOS_MAP": { - "{{ port_names }}": { - "tc_to_pg_map": "[TC_TO_PRIORITY_GROUP_MAP|AZURE]", - "tc_to_queue_map": "[TC_TO_QUEUE_MAP|AZURE]", - "dscp_to_tc_map": "[DSCP_TO_TC_MAP|AZURE]", +{% for port in port_names_list %} + "{{ port }}": { + "tc_to_pg_map": "AZURE", + "tc_to_queue_map": "AZURE", + "dscp_to_tc_map": "AZURE", "pfc_enable": "3,4" - } + }{% if not loop.last %},{% endif %} + +{% endfor %} }, "WRED_PROFILE": { "AZURE_LOSSLESS" : { - "red_min_threshold":"50000" + "wred_green_enable" : "true", + "wred_yellow_enable" : "true", + "wred_red_enable" : "true", + "ecn" : "ecn_all", + "green_max_threshold" : "2097152", + "green_min_threshold" : "1048576", + "yellow_max_threshold" : "2097152", + "yellow_min_threshold" : "1048576", + "red_max_threshold" : "2097152", + "red_min_threshold" : "1048576", + "green_drop_probability" : "5", + "yellow_drop_probability": "5", + "red_drop_probability" : "5" } } } diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/installer.conf b/device/wistron/x86_64-wistron_sw_to3200k-r0/installer.conf index 6af5fa8d979b..d7d410dae704 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/installer.conf +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/installer.conf @@ -1,4 +1,4 @@ CONSOLE_PORT=0x3f8 CONSOLE_DEV=4 CONSOLE_SPEED=115200 -ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="pcie_aspm=off" +ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="pcie_aspm=off intel_iommu=off" diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/libplatform.so b/device/wistron/x86_64-wistron_sw_to3200k-r0/libplatform.so new file mode 100644 index 000000000000..1ca41771ff2d Binary files /dev/null and b/device/wistron/x86_64-wistron_sw_to3200k-r0/libplatform.so differ diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/pcie.yaml b/device/wistron/x86_64-wistron_sw_to3200k-r0/pcie.yaml new file mode 100755 index 000000000000..ef4b521c66d3 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/pcie.yaml @@ -0,0 +1,375 @@ +- bus: '00' + dev: '00' + fn: '0' + id: 6f00 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DMI2 (rev 03)' +- bus: '00' + dev: '01' + fn: '0' + id: 6f02 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 1 (rev 03)' +- bus: '00' + dev: '01' + fn: '1' + id: 6f03 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 1 (rev 03)' +- bus: '00' + dev: '02' + fn: '0' + id: 6f04 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 2 (rev 03)' +- bus: '00' + dev: '02' + fn: '2' + id: 6f06 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 2 (rev 03)' +- bus: '00' + dev: '03' + fn: '0' + id: 6f08 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 03)' +- bus: '00' + dev: '03' + fn: '1' + id: 6f09 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 03)' +- bus: '00' + dev: '03' + fn: '2' + id: 6f0a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 03)' +- bus: '00' + dev: '03' + fn: '3' + id: 6f0b + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D PCI Express Root Port 3 (rev 03)' +- bus: '00' + dev: '05' + fn: '0' + id: 6f28 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Map/VTd_Misc/System Management (rev 03)' +- bus: '00' + dev: '05' + fn: '1' + id: 6f29 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO Hot Plug (rev 03)' +- bus: '00' + dev: '05' + fn: '2' + id: 6f2a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D IIO RAS/Control Status/Global Errors (rev 03)' +- bus: '00' + dev: '05' + fn: '4' + id: 6f2c + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D I/O APIC (rev 03)' +- bus: '00' + dev: '14' + fn: '0' + id: 8c31 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family USB xHCI (rev 05)' +- bus: '00' + dev: '1c' + fn: '0' + id: 8c10 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #1 (rev d5)' +- bus: '00' + dev: '1c' + fn: '6' + id: 8c1c + name: 'Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #7 (rev d5)' +- bus: '00' + dev: '1c' + fn: '7' + id: 8c1e + name: 'Intel Corporation 8 Series/C220 Series Chipset Family PCI Express Root Port #8 (rev d5)' +- bus: '00' + dev: '1f' + fn: '0' + id: 8c54 + name: 'Intel Corporation C224 Series Chipset Family Server Standard SKU LPC Controller (rev 05)' +- bus: '00' + dev: '1f' + fn: '3' + id: 8c22 + name: 'Intel Corporation 8 Series/C220 Series Chipset Family SMBus Controller (rev 05)' +- bus: '03' + dev: '00' + fn: '0' + id: 6f50 + name: 'Intel Corporation Xeon Processor D Family QuickData Technology Register DMA Channel 0' +- bus: '03' + dev: '00' + fn: '1' + id: 6f51 + name: 'Intel Corporation Xeon Processor D Family QuickData Technology Register DMA Channel 1' +- bus: '03' + dev: '00' + fn: '2' + id: 6f52 + name: 'Intel Corporation Xeon Processor D Family QuickData Technology Register DMA Channel 2' +- bus: '03' + dev: '00' + fn: '3' + id: 6f53 + name: 'Intel Corporation Xeon Processor D Family QuickData Technology Register DMA Channel 3' +- bus: '04' + dev: '00' + fn: '0' + id: 15ac + name: 'Intel Corporation Ethernet Connection X552 10 GbE SFP+' +- bus: '04' + dev: '00' + fn: '1' + id: 15ac + name: 'Intel Corporation Ethernet Connection X552 10 GbE SFP+' +- bus: '06' + dev: '00' + fn: '0' + id: 1b58 + name: 'Device 1d98:1b58 (rev 10)' +- bus: '07' + dev: '00' + fn: '0' + id: 9100 + name: 'Solid State Storage Technology Corporation Device 9100 (rev 03)' +- bus: '0b' + dev: '00' + fn: '0' + id: e001 + name: 'Altera Corporation Device e001 (rev 09)' +- bus: '0c' + dev: '00' + fn: '0' + id: 1533 + name: 'Intel Corporation I210 Gigabit Network Connection (rev 03)' +- bus: 'ff' + dev: '0b' + fn: '0' + id: 6f81 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 03)' +- bus: 'ff' + dev: '0b' + fn: '1' + id: 6f36 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 03)' +- bus: 'ff' + dev: '0b' + fn: '2' + id: 6f37 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link 0/1 (rev 03)' +- bus: 'ff' + dev: '0b' + fn: '3' + id: 6f76 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R3 QPI Link Debug (rev 03)' +- bus: 'ff' + dev: '0c' + fn: '0' + id: 6fe0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0c' + fn: '1' + id: 6fe1 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0c' + fn: '2' + id: 6fe2 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0c' + fn: '3' + id: 6fe3 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0f' + fn: '0' + id: 6ff8 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0f' + fn: '4' + id: 6ffc + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0f' + fn: '5' + id: 6ffd + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '0f' + fn: '6' + id: 6ffe + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Caching Agent (rev 03)' +- bus: 'ff' + dev: '10' + fn: '0' + id: 6f1d + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R2PCIe Agent (rev 03)' +- bus: 'ff' + dev: '10' + fn: '1' + id: 6f34 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D R2PCIe Agent (rev 03)' +- bus: 'ff' + dev: '10' + fn: '5' + id: 6f1e + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 03)' +- bus: 'ff' + dev: '10' + fn: '6' + id: 6f7d + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 03)' +- bus: 'ff' + dev: '10' + fn: '7' + id: 6f1f + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Ubox (rev 03)' +- bus: 'ff' + dev: '12' + fn: '0' + id: 6fa0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Home Agent 0 (rev 03)' +- bus: 'ff' + dev: '12' + fn: '1' + id: 6f30 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Home Agent 0 (rev 03)' +- bus: 'ff' + dev: '13' + fn: '0' + id: 6fa8 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Target Address/Thermal/RAS (rev 03)' +- bus: 'ff' + dev: '13' + fn: '1' + id: 6f71 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Target Address/Thermal/RAS (rev 03)' +- bus: 'ff' + dev: '13' + fn: '2' + id: 6faa + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 03)' +- bus: 'ff' + dev: '13' + fn: '3' + id: 6fab + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 03)' +- bus: 'ff' + dev: '13' + fn: '4' + id: 6fac + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 03)' +- bus: 'ff' + dev: '13' + fn: '5' + id: 6fad + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel Target Address Decoder (rev 03)' +- bus: 'ff' + dev: '13' + fn: '6' + id: 6fae + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Broadcast (rev 03)' +- bus: 'ff' + dev: '13' + fn: '7' + id: 6faf + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Global Broadcast (rev 03)' +- bus: 'ff' + dev: '14' + fn: '0' + id: 6fb0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 0 Thermal Control (rev 03)' +- bus: 'ff' + dev: '14' + fn: '1' + id: 6fb1 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 1 Thermal Control (rev 03)' +- bus: 'ff' + dev: '14' + fn: '2' + id: 6fb2 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 0 Error (rev 03)' +- bus: 'ff' + dev: '14' + fn: '3' + id: 6fb3 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 1 Error (rev 03)' +- bus: 'ff' + dev: '14' + fn: '4' + id: 6fbc + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 03)' +- bus: 'ff' + dev: '14' + fn: '5' + id: 6fbd + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 03)' +- bus: 'ff' + dev: '14' + fn: '6' + id: 6fbe + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 03)' +- bus: 'ff' + dev: '14' + fn: '7' + id: 6fbf + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D DDRIO Channel 0/1 Interface (rev 03)' +- bus: 'ff' + dev: '15' + fn: '0' + id: 6fb4 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 2 Thermal Control (rev 03)' +- bus: 'ff' + dev: '15' + fn: '1' + id: 6fb5 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 3 Thermal Control (rev 03)' +- bus: 'ff' + dev: '15' + fn: '2' + id: 6fb6 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 2 Error (rev 03)' +- bus: 'ff' + dev: '15' + fn: '3' + id: 6fb7 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Memory Controller 0 - Channel 3 Error (rev 03)' +- bus: 'ff' + dev: '1e' + fn: '0' + id: 6f98 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1e' + fn: '1' + id: 6f99 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1e' + fn: '2' + id: 6f9a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1e' + fn: '3' + id: 6fc0 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1e' + fn: '4' + id: 6f9c + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1f' + fn: '0' + id: 6f88 + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' +- bus: 'ff' + dev: '1f' + fn: '2' + id: 6f8a + name: 'Intel Corporation Xeon E7 v4/Xeon E5 v4/Xeon E3 v4/Xeon D Power Control Unit (rev 03)' \ No newline at end of file diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/platform.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/platform.json new file mode 100644 index 000000000000..18dcca800329 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/platform.json @@ -0,0 +1,844 @@ +{ + "chassis": { + "name": "Wistron_sw_to3200k", + "components": [ + { + "name": "BIOS" + }, + { + "name": "CPLD1" + }, + { + "name": "CPLD2" + }, + { + "name": "MB_FPGA" + }, + { + "name": "FAN_CPLD" + }, + { + "name": "BMC" + } + ], + "fans": [ + { + "name": "FAN-1F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-1R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "fan_drawers": [ + { + "name": "FanTray1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-1F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-1R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray2", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-2F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-2R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray3", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-3F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-3R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray4", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-4F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-4R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray5", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-5F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-5R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray6", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-6F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-6R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + }, + { + "name": "FanTray7", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + }, + "fans": [ + { + "name": "FAN-7F", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + }, + { + "name": "FAN-7R", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ] + } + ], + "psus": [ + { + "name": "PSU-1", + "fans": [ + { + "name": "PSU-1 FAN-1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "status_led": { + "controllable": false + } + }, + { + "name": "PSU-2", + "fans": [ + { + "name": "PSU-2 FAN-1", + "speed": { + "controllable": false + }, + "status_led": { + "controllable": false + } + } + ], + "status_led": { + "controllable": false + } + } + ], + "thermals": [ + { + "name": "Bottom-Front", + "controllable": false + }, + { + "name": "Bottom-Rear", + "controllable": false + }, + { + "name": "Left-Front", + "controllable": false + }, + { + "name": "Right-Front", + "controllable": false + }, + { + "name": "Top-Center", + "controllable": false + }, + { + "name": "Top-Front", + "controllable": false + }, + { + "name": "Top-Rear", + "controllable": false + } + ], + "sfps": [ + { + "name": "port1" + }, + { + "name": "port2" + }, + { + "name": "port3" + }, + { + "name": "port4" + }, + { + "name": "port5" + }, + { + "name": "port6" + }, + { + "name": "port7" + }, + { + "name": "port8" + }, + { + "name": "port9" + }, + { + "name": "port10" + }, + { + "name": "port11" + }, + { + "name": "port12" + }, + { + "name": "port13" + }, + { + "name": "port14" + }, + { + "name": "port15" + }, + { + "name": "port16" + }, + { + "name": "port17" + }, + { + "name": "port18" + }, + { + "name": "port19" + }, + { + "name": "port20" + }, + { + "name": "port21" + }, + { + "name": "port22" + }, + { + "name": "port23" + }, + { + "name": "port24" + }, + { + "name": "port25" + }, + { + "name": "port26" + }, + { + "name": "port27" + }, + { + "name": "port28" + }, + { + "name": "port29" + }, + { + "name": "port30" + }, + { + "name": "port31" + }, + { + "name": "port32" + } + ] + }, + "interfaces": { + "Ethernet0": { + "index": "0,0,0,0,0,0,0,0", + "lanes": "89,90,91,92,93,94,95,96", + "breakout_modes": { + "1x400G[100G]": ["Eth1"], + "1x100G(4)": ["Eth1"], + "4x25G[10G](4)": ["Eth1-1", "Eth1-2", "Eth1-3", "Eth1-4"], + "4x10G[25G](4)": ["Eth1-1", "Eth1-2", "Eth1-3", "Eth1-4"] + } + }, + "Ethernet8": { + "index": "1,1,1,1,1,1,1,1", + "lanes": "81,82,83,84,85,86,87,88", + "breakout_modes": { + "1x400G[100G]": ["Eth2"], + "1x100G(4)": ["Eth2"], + "4x25G[10G](4)": ["Eth2-1", "Eth2-2", "Eth2-3", "Eth2-4"], + "4x10G[25G](4)": ["Eth2-1", "Eth2-2", "Eth2-3", "Eth2-4"] + } + }, + "Ethernet16": { + "index": "2,2,2,2,2,2,2,2", + "lanes": "73,74,75,76,77,78,79,80", + "breakout_modes": { + "1x400G[100G]": ["Eth3"], + "1x100G(4)": ["Eth3"], + "4x25G[10G](4)": ["Eth3-1", "Eth3-2", "Eth3-3", "Eth3-4"], + "4x10G[25G](4)": ["Eth3-1", "Eth3-2", "Eth3-3", "Eth3-4"] + } + }, + "Ethernet24": { + "index": "3,3,3,3,3,3,3,3", + "lanes": "65,66,67,68,69,70,71,72", + "breakout_modes": { + "1x400G[100G]": ["Eth4"], + "1x100G(4)": ["Eth4"], + "4x25G[10G](4)": ["Eth4-1", "Eth4-2", "Eth4-3", "Eth4-4"], + "4x10G[25G](4)": ["Eth4-1", "Eth4-2", "Eth4-3", "Eth4-4"] + } + }, + "Ethernet32": { + "index": "4,4,4,4,4,4,4,4", + "lanes": "57,58,59,60,61,62,63,64", + "breakout_modes": { + "1x400G[100G]": ["Eth5"], + "1x100G(4)": ["Eth5"], + "4x25G[10G](4)": ["Eth5-1", "Eth5-2", "Eth5-3", "Eth5-4"], + "4x10G[25G](4)": ["Eth5-1", "Eth5-2", "Eth5-3", "Eth5-4"] + } + }, + "Ethernet40": { + "index": "5,5,5,5,5,5,5,5", + "lanes": "49,50,51,52,53,54,55,56", + "breakout_modes": { + "1x400G[100G]": ["Eth6"], + "1x100G(4)": ["Eth6"], + "4x25G[10G](4)": ["Eth6-1", "Eth6-2", "Eth6-3", "Eth6-4"], + "4x10G[25G](4)": ["Eth6-1", "Eth6-2", "Eth6-3", "Eth6-4"] + } + }, + "Ethernet48": { + "index": "6,6,6,6,6,6,6,6", + "lanes": "41,42,43,44,45,46,47,48", + "breakout_modes": { + "1x400G[100G]": ["Eth7"], + "1x100G(4)": ["Eth7"], + "4x25G[10G](4)": ["Eth7-1", "Eth7-2", "Eth7-3", "Eth7-4"], + "4x10G[25G](4)": ["Eth7-1", "Eth7-2", "Eth7-3", "Eth7-4"] + } + }, + "Ethernet56": { + "index": "7,7,7,7,7,7,7,7", + "lanes": "33,34,35,36,37,38,39,40", + "breakout_modes": { + "1x400G[100G]": ["Eth8"], + "1x100G(4)": ["Eth8"], + "4x25G[10G](4)": ["Eth8-1", "Eth8-2", "Eth8-3", "Eth8-4"], + "4x10G[25G](4)": ["Eth8-1", "Eth8-2", "Eth8-3", "Eth8-4"] + } + }, + "Ethernet64": { + "index": "8,8,8,8,8,8,8,8", + "lanes": "153,154,155,156,157,158,159,160", + "breakout_modes": { + "1x400G[100G]": ["Eth9"], + "1x100G(4)": ["Eth9"], + "4x25G[10G](4)": ["Eth9-1", "Eth9-2", "Eth9-3", "Eth9-4"], + "4x10G[25G](4)": ["Eth9-1", "Eth9-2", "Eth9-3", "Eth9-4"] + } + }, + "Ethernet72": { + "index": "9,9,9,9,9,9,9,9", + "lanes": "145,146,147,148,149,150,151,152", + "breakout_modes": { + "1x400G[100G]": ["Eth10"], + "1x100G(4)": ["Eth10"], + "4x25G[10G](4)": ["Eth10-1", "Eth10-2", "Eth10-3", "Eth10-4"], + "4x10G[25G](4)": ["Eth10-1", "Eth10-2", "Eth10-3", "Eth10-4"] + } + }, + "Ethernet80": { + "index": "10,10,10,10,10,10,10,10", + "lanes": "137,138,139,140,141,142,143,144", + "breakout_modes": { + "1x400G[100G]": ["Eth11"], + "1x100G(4)": ["Eth11"], + "4x25G[10G](4)": ["Eth11-1", "Eth11-2", "Eth11-3", "Eth11-4"], + "4x10G[25G](4)": ["Eth11-1", "Eth11-2", "Eth11-3", "Eth11-4"] + } + }, + "Ethernet88": { + "index": "11,11,11,11,11,11,11,11", + "lanes": "129,130,131,132,133,134,135,136", + "breakout_modes": { + "1x400G[100G]": ["Eth12"], + "1x100G(4)": ["Eth12"], + "4x25G[10G](4)": ["Eth12-1", "Eth12-2", "Eth12-3", "Eth12-4"], + "4x10G[25G](4)": ["Eth12-1", "Eth12-2", "Eth12-3", "Eth12-4"] + } + }, + "Ethernet96": { + "index": "12,12,12,12,12,12,12,12", + "lanes": "121,122,123,124,125,126,127,128", + "breakout_modes": { + "1x400G[100G]": ["Eth13"], + "1x100G(4)": ["Eth13"], + "4x25G[10G](4)": ["Eth13-1", "Eth13-2", "Eth13-3", "Eth13-4"], + "4x10G[25G](4)": ["Eth13-1", "Eth13-2", "Eth13-3", "Eth13-4"] + } + }, + "Ethernet104": { + "index": "13,13,13,13,13,13,13,13", + "lanes": "113,114,115,116,117,118,119,120", + "breakout_modes": { + "1x400G[100G]": ["Eth14"], + "1x100G(4)": ["Eth14"], + "4x25G[10G](4)": ["Eth14-1", "Eth14-2", "Eth14-3", "Eth14-4"], + "4x10G[25G](4)": ["Eth14-1", "Eth14-2", "Eth14-3", "Eth14-4"] + } + }, + "Ethernet112": { + "index": "14,14,14,14,14,14,14,14", + "lanes": "105,106,107,108,109,110,111,112", + "breakout_modes": { + "1x400G[100G]": ["Eth15"], + "1x100G(4)": ["Eth15"], + "4x25G[10G](4)": ["Eth15-1", "Eth15-2", "Eth15-3", "Eth15-4"], + "4x10G[25G](4)": ["Eth15-1", "Eth15-2", "Eth15-3", "Eth15-4"] + } + }, + "Ethernet120": { + "index": "15,15,15,15,15,15,15,15", + "lanes": "97,98,99,100,101,102,103,104", + "breakout_modes": { + "1x400G[100G]": ["Eth16"], + "1x100G(4)": ["Eth16"], + "4x25G[10G](4)": ["Eth16-1", "Eth16-2", "Eth16-3", "Eth16-4"], + "4x10G[25G](4)": ["Eth16-1", "Eth16-2", "Eth16-3", "Eth16-4"] + } + }, + "Ethernet128": { + "index": "16,16,16,16,16,16,16,16", + "lanes": "209,210,211,212,213,214,215,216", + "breakout_modes": { + "1x400G[100G]": ["Eth17"], + "1x100G(4)": ["Eth17"], + "4x25G[10G](4)": ["Eth17-1", "Eth17-2", "Eth17-3", "Eth17-4"], + "4x10G[25G](4)": ["Eth17-1", "Eth17-2", "Eth17-3", "Eth17-4"] + } + }, + "Ethernet136": { + "index": "17,17,17,17,17,17,17,17", + "lanes": "217,218,219,220,221,222,223,224", + "breakout_modes": { + "1x400G[100G]": ["Eth18"], + "1x100G(4)": ["Eth18"], + "4x25G[10G](4)": ["Eth18-1", "Eth18-2", "Eth18-3", "Eth18-4"], + "4x10G[25G](4)": ["Eth18-1", "Eth18-2", "Eth18-3", "Eth18-4"] + } + }, + "Ethernet144": { + "index": "18,18,18,18,18,18,18,18", + "lanes": "193,194,195,196,197,198,199,200", + "breakout_modes": { + "1x400G[100G]": ["Eth19"], + "1x100G(4)": ["Eth19"], + "4x25G[10G](4)": ["Eth19-1", "Eth19-2", "Eth19-3", "Eth19-4"], + "4x10G[25G](4)": ["Eth19-1", "Eth19-2", "Eth19-3", "Eth19-4"] + } + }, + "Ethernet152": { + "index": "19,19,19,19,19,19,19,19", + "lanes": "201,202,203,204,205,206,207,208", + "breakout_modes": { + "1x400G[100G]": ["Eth20"], + "1x100G(4)": ["Eth20"], + "4x25G[10G](4)": ["Eth20-1", "Eth20-2", "Eth20-3", "Eth20-4"], + "4x10G[25G](4)": ["Eth20-1", "Eth20-2", "Eth20-3", "Eth20-4"] + } + }, + "Ethernet160": { + "index": "20,20,20,20,20,20,20,20", + "lanes": "177,178,179,180,181,182,183,184", + "breakout_modes": { + "1x400G[100G]": ["Eth21"], + "1x100G(4)": ["Eth21"], + "4x25G[10G](4)": ["Eth21-1", "Eth21-2", "Eth21-3", "Eth21-4"], + "4x10G[25G](4)": ["Eth21-1", "Eth21-2", "Eth21-3", "Eth21-4"] + } + }, + "Ethernet168": { + "index": "21,21,21,21,21,21,21,21", + "lanes": "185,186,187,188,189,190,191,192", + "breakout_modes": { + "1x400G[100G]": ["Eth22"], + "1x100G(4)": ["Eth22"], + "4x25G[10G](4)": ["Eth22-1", "Eth22-2", "Eth22-3", "Eth22-4"], + "4x10G[25G](4)": ["Eth22-1", "Eth22-2", "Eth22-3", "Eth22-4"] + } + }, + "Ethernet176": { + "index": "22,22,22,22,22,22,22,22", + "lanes": "161,162,163,164,165,166,167,168", + "breakout_modes": { + "1x400G[100G]": ["Eth23"], + "1x100G(4)": ["Eth23"], + "4x25G[10G](4)": ["Eth23-1", "Eth23-2", "Eth23-3", "Eth23-4"], + "4x10G[25G](4)": ["Eth23-1", "Eth23-2", "Eth23-3", "Eth23-4"] + } + }, + "Ethernet184": { + "index": "23,23,23,23,23,23,23,23", + "lanes": "169,170,171,172,173,174,175,176", + "breakout_modes": { + "1x400G[100G]": ["Eth24"], + "1x100G(4)": ["Eth24"], + "4x25G[10G](4)": ["Eth24-1", "Eth24-2", "Eth24-3", "Eth24-4"], + "4x10G[25G](4)": ["Eth24-1", "Eth24-2", "Eth24-3", "Eth24-4"] + } + }, + "Ethernet192": { + "index": "24,24,24,24,24,24,24,24", + "lanes": "17,18,19,20,21,22,23,24", + "breakout_modes": { + "1x400G[100G]": ["Eth25"], + "1x100G(4)": ["Eth25"], + "4x25G[10G](4)": ["Eth25-1", "Eth25-2", "Eth25-3", "Eth25-4"], + "4x10G[25G](4)": ["Eth25-1", "Eth25-2", "Eth25-3", "Eth25-4"] + } + }, + "Ethernet200": { + "index": "25,25,25,25,25,25,25,25", + "lanes": "25,26,27,28,29,30,31,32", + "breakout_modes": { + "1x400G[100G]": ["Eth26"], + "1x100G(4)": ["Eth26"], + "4x25G[10G](4)": ["Eth26-1", "Eth26-2", "Eth26-3", "Eth26-4"], + "4x10G[25G](4)": ["Eth26-1", "Eth26-2", "Eth26-3", "Eth26-4"] + } + }, + "Ethernet208": { + "index": "26,26,26,26,26,26,26,26", + "lanes": "1,2,3,4,5,6,7,8", + "breakout_modes": { + "1x400G[100G]": ["Eth27"], + "1x100G(4)": ["Eth27"], + "4x25G[10G](4)": ["Eth27-1", "Eth27-2", "Eth27-3", "Eth27-4"], + "4x10G[25G](4)": ["Eth27-1", "Eth27-2", "Eth27-3", "Eth27-4"] + } + }, + "Ethernet216": { + "index": "27,27,27,27,27,27,27,27", + "lanes": "9,10,11,12,13,14,15,16", + "breakout_modes": { + "1x400G[100G]": ["Eth28"], + "1x100G(4)": ["Eth28"], + "4x25G[10G](4)": ["Eth28-1", "Eth28-2", "Eth28-3", "Eth28-4"], + "4x10G[25G](4)": ["Eth28-1", "Eth28-2", "Eth28-3", "Eth28-4"] + } + }, + "Ethernet224": { + "index": "28,28,28,28,28,28,28,28", + "lanes": "241,242,243,244,245,246,247,248", + "breakout_modes": { + "1x400G[100G]": ["Eth29"], + "1x100G(4)": ["Eth29"], + "4x25G[10G](4)": ["Eth29-1", "Eth29-2", "Eth29-3", "Eth29-4"], + "4x10G[25G](4)": ["Eth29-1", "Eth29-2", "Eth29-3", "Eth29-4"] + } + }, + "Ethernet232": { + "index": "29,29,29,29,29,29,29,29", + "lanes": "249,250,251,252,253,254,255,256", + "breakout_modes": { + "1x400G[100G]": ["Eth30"], + "1x100G(4)": ["Eth30"], + "4x25G[10G](4)": ["Eth30-1", "Eth30-2", "Eth30-3", "Eth30-4"], + "4x10G[25G](4)": ["Eth30-1", "Eth30-2", "Eth30-3", "Eth30-4"] + } + }, + "Ethernet240": { + "index": "30,30,30,30,30,30,30,30", + "lanes": "225,226,227,228,229,230,231,232", + "breakout_modes": { + "1x400G[100G]": ["Eth31"], + "1x100G(4)": ["Eth31"], + "4x25G[10G](4)": ["Eth31-1", "Eth31-2", "Eth31-3", "Eth31-4"], + "4x10G[25G](4)": ["Eth31-1", "Eth31-2", "Eth31-3", "Eth31-4"] + } + }, + "Ethernet248": { + "index": "31,31,31,31,31,31,31,31", + "lanes": "233,234,235,236,237,238,239,240", + "breakout_modes": { + "1x400G[100G]": ["Eth32"], + "1x100G(4)": ["Eth32"], + "4x25G[10G](4)": ["Eth32-1", "Eth32-2", "Eth32-3", "Eth32-4"], + "4x10G[25G](4)": ["Eth32-1", "Eth32-2", "Eth32-3", "Eth32-4"] + } + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/platform_components.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/platform_components.json new file mode 100644 index 000000000000..304fbcb52557 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/platform_components.json @@ -0,0 +1,14 @@ +{ + "chassis": { + "Wistron_sw_to3200k": { + "component": { + "BIOS": { }, + "CPLD1": { }, + "CPLD2": { }, + "MB_FPGA": { }, + "FAN_CPLD": { }, + "BMC": { } + } + } + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/eeprom.py b/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/eeprom.py index 9f59510eac28..b7724886eea4 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/eeprom.py +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/eeprom.py @@ -3,16 +3,16 @@ try: import os from sonic_eeprom import eeprom_tlvinfo -except ImportError, e: +except ImportError as e: raise ImportError (str(e) + "- required module not found") def eeprom_check(): - filepath="/sys/bus/i2c/devices/0-0056/eeprom" + filepath="/sys/bus/i2c/devices/0-0056/eeprom" if os.path.isfile(filepath): return 1 #now board, 0x56 else: return 0 #now board, 0x57 - + class board(eeprom_tlvinfo.TlvInfoDecoder): _TLV_INFO_MAX_LEN = 256 def __init__(self, name, path, cpld_root, ro): diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/sfputil.py b/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/sfputil.py index fe59dc7d8ce5..8983579016b4 100644 --- a/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/sfputil.py +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/plugins/sfputil.py @@ -111,7 +111,7 @@ def get_presence(self, port_num): content = val_file.readline().rstrip() val_file.close() except IOError as e: - print "Error: unable to access file: %s" % str(e) + print("Error: unable to access file: %s" % str(e)) return False if content == "1": @@ -145,13 +145,13 @@ def get_transceiver_change_event(self, timeout=0): elif timeout > 0: timeout = timeout / float(1000) # Convert to secs else: - print "get_transceiver_change_event:Invalid timeout value", timeout + print("get_transceiver_change_event:Invalid timeout value", timeout) return False, {} end_time = start_time + timeout if start_time > end_time: - print 'get_transceiver_change_event:' \ - 'time wrap / invalid timeout value', timeout + print('get_transceiver_change_event:' \ + 'time wrap / invalid timeout value', timeout) return False, {} # Time wrap or possibly incorrect timeout @@ -182,5 +182,5 @@ def get_transceiver_change_event(self, timeout=0): if timeout > 0: time.sleep(timeout) return True, {} - print "get_evt_change_event: Should not reach here." + print("get_evt_change_event: Should not reach here.") return False, {} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/smartd.conf b/device/wistron/x86_64-wistron_sw_to3200k-r0/smartd.conf new file mode 100644 index 000000000000..c3877d93ee28 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/smartd.conf @@ -0,0 +1,150 @@ +# Sample configuration file for smartd. See man smartd.conf. + +# Home page is: http://www.smartmontools.org + +# smartd will re-read the configuration file if it receives a HUP +# signal + +# The file gives a list of devices to monitor using smartd, with one +# device per line. Text after a hash (#) is ignored, and you may use +# spaces and tabs for white space. You may use '\' to continue lines. + +# You can usually identify which hard disks are on your system by +# looking in /proc/ide and in /proc/scsi. + +# The word DEVICESCAN will cause any remaining lines in this +# configuration file to be ignored: it tells smartd to scan for all +# ATA and SCSI devices. DEVICESCAN may be followed by any of the +# Directives listed below, which will be applied to all devices that +# are found. Most users should comment out DEVICESCAN and explicitly +# list the devices that they wish to monitor. +#DEVICESCAN -d removable -n standby -m root -M exec /usr/share/smartmontools/smartd-runner + +# Alternative setting to ignore temperature and power-on hours reports +# in syslog. +#DEVICESCAN -I 194 -I 231 -I 9 + +# Alternative setting to report more useful raw temperature in syslog. +#DEVICESCAN -R 194 -R 231 -I 9 + +# Alternative setting to report raw temperature changes >= 5 Celsius +# and min/max temperatures. +#DEVICESCAN -I 194 -I 231 -I 9 -W 5 + +# First ATA/SATA or SCSI/SAS disk. Monitor all attributes, enable +# automatic online data collection, automatic Attribute autosave, and +# start a short self-test every day between 2-3am, and a long self test +# Saturdays between 3-4am. +#/dev/sda -a -o on -S on -s (S/../.././02|L/../../6/03) + +# Monitor SMART status, ATA Error Log, Self-test log, and track +# changes in all attributes except for attribute 194 +#/dev/sdb -H -l error -l selftest -t -I 194 + +# Monitor all attributes except normalized Temperature (usually 194), +# but track Temperature changes >= 4 Celsius, report Temperatures +# >= 45 Celsius and changes in Raw value of Reallocated_Sector_Ct (5). +# Send mail on SMART failures or when Temperature is >= 55 Celsius. +#/dev/sdc -a -I 194 -W 4,45,55 -R 5 -m admin@example.com + +# An ATA disk may appear as a SCSI device to the OS. If a SCSI to +# ATA Translation (SAT) layer is between the OS and the device then +# this can be flagged with the '-d sat' option. This situation may +# become common with SATA disks in SAS and FC environments. +# /dev/sda -a -d sat + +# A very silent check. Only report SMART health status if it fails +# But send an email in this case +#/dev/sdc -H -C 0 -U 0 -m admin@example.com + +# First two SCSI disks. This will monitor everything that smartd can +# monitor. Start extended self-tests Wednesdays between 6-7pm and +# Sundays between 1-2 am +#/dev/sda -d scsi -s L/../../3/18 +#/dev/sdb -d scsi -s L/../../7/01 + +# Monitor 4 ATA disks connected to a 3ware 6/7/8000 controller which uses +# the 3w-xxxx driver. Start long self-tests Sundays between 1-2, 2-3, 3-4, +# and 4-5 am. +# NOTE: starting with the Linux 2.6 kernel series, the /dev/sdX interface +# is DEPRECATED. Use the /dev/tweN character device interface instead. +# For example /dev/twe0, /dev/twe1, and so on. +#/dev/sdc -d 3ware,0 -a -s L/../../7/01 +#/dev/sdc -d 3ware,1 -a -s L/../../7/02 +#/dev/sdc -d 3ware,2 -a -s L/../../7/03 +#/dev/sdc -d 3ware,3 -a -s L/../../7/04 + +# Monitor 2 ATA disks connected to a 3ware 9000 controller which +# uses the 3w-9xxx driver (Linux, FreeBSD). Start long self-tests Tuesdays +# between 1-2 and 3-4 am. +#/dev/twa0 -d 3ware,0 -a -s L/../../2/01 +#/dev/twa0 -d 3ware,1 -a -s L/../../2/03 + +# Monitor 2 SATA (not SAS) disks connected to a 3ware 9000 controller which +# uses the 3w-sas driver (Linux). Start long self-tests Tuesdays +# between 1-2 and 3-4 am. +# On FreeBSD /dev/tws0 should be used instead +#/dev/twl0 -d 3ware,0 -a -s L/../../2/01 +#/dev/twl0 -d 3ware,1 -a -s L/../../2/03 + +# Same as above for Windows. Option '-d 3ware,N' is not necessary, +# disk (port) number is specified in device name. +# NOTE: On Windows, DEVICESCAN works also for 3ware controllers. +#/dev/hdc,0 -a -s L/../../2/01 +#/dev/hdc,1 -a -s L/../../2/03 +# +# Monitor 2 disks connected to the first HP SmartArray controller which +# uses the cciss driver. Start long tests on Sunday nights and short +# self-tests every night and send errors to root +#/dev/cciss/c0d0 -d cciss,0 -a -s (L/../../7/02|S/../.././02) -m root +#/dev/cciss/c0d0 -d cciss,1 -a -s (L/../../7/03|S/../.././03) -m root + +# Monitor 3 ATA disks directly connected to a HighPoint RocketRAID. Start long +# self-tests Sundays between 1-2, 2-3, and 3-4 am. +#/dev/sdd -d hpt,1/1 -a -s L/../../7/01 +#/dev/sdd -d hpt,1/2 -a -s L/../../7/02 +#/dev/sdd -d hpt,1/3 -a -s L/../../7/03 + +# Monitor 2 ATA disks connected to the same PMPort which connected to the +# HighPoint RocketRAID. Start long self-tests Tuesdays between 1-2 and 3-4 am +#/dev/sdd -d hpt,1/4/1 -a -s L/../../2/01 +#/dev/sdd -d hpt,1/4/2 -a -s L/../../2/03 + +# HERE IS A LIST OF DIRECTIVES FOR THIS CONFIGURATION FILE. +# PLEASE SEE THE smartd.conf MAN PAGE FOR DETAILS +# +# -d TYPE Set the device type: ata, scsi, marvell, removable, 3ware,N, hpt,L/M/N +# -T TYPE set the tolerance to one of: normal, permissive +# -o VAL Enable/disable automatic offline tests (on/off) +# -S VAL Enable/disable attribute autosave (on/off) +# -n MODE No check. MODE is one of: never, sleep, standby, idle +# -H Monitor SMART Health Status, report if failed +# -l TYPE Monitor SMART log. Type is one of: error, selftest +# -f Monitor for failure of any 'Usage' Attributes +# -m ADD Send warning email to ADD for -H, -l error, -l selftest, and -f +# -M TYPE Modify email warning behavior (see man page) +# -s REGE Start self-test when type/date matches regular expression (see man page) +# -p Report changes in 'Prefailure' Normalized Attributes +# -u Report changes in 'Usage' Normalized Attributes +# -t Equivalent to -p and -u Directives +# -r ID Also report Raw values of Attribute ID with -p, -u or -t +# -R ID Track changes in Attribute ID Raw value with -p, -u or -t +# -i ID Ignore Attribute ID for -f Directive +# -I ID Ignore Attribute ID for -p, -u or -t Directive +# -C ID Report if Current Pending Sector count non-zero +# -U ID Report if Offline Uncorrectable count non-zero +# -W D,I,C Monitor Temperature D)ifference, I)nformal limit, C)ritical limit +# -v N,ST Modifies labeling of Attribute N (see man page) +# -a Default: equivalent to -H -f -t -l error -l selftest -C 197 -U 198 +# -F TYPE Use firmware bug workaround. Type is one of: none, samsung +# -P TYPE Drive-specific presets: use, ignore, show, showall +# # Comment: text after a hash sign is ignored +# \ Line continuation character +# Attribute ID is a decimal integer 1 <= ID <= 255 +# except for -C and -U, where ID = 0 turns them off. +# All but -d, -m and -M Directives are only implemented for ATA devices +# +# If the test string DEVICESCAN is the first uncommented text +# then smartd will scan for devices. +# DEVICESCAN may be followed by any desired Directives. +/dev/nvme0n1 -a diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/system_health_monitoring_config.json b/device/wistron/x86_64-wistron_sw_to3200k-r0/system_health_monitoring_config.json new file mode 100644 index 000000000000..0e0eec971cac --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/system_health_monitoring_config.json @@ -0,0 +1,11 @@ +{ + "services_to_ignore": [], + "devices_to_ignore": ["asic"], + "user_defined_checkers": [], + "polling_interval": 60, + "led_color": { + "fault": "red", + "normal": "green", + "booting": "green_blinking" + } +} diff --git a/device/wistron/x86_64-wistron_sw_to3200k-r0/watchdog-control.service b/device/wistron/x86_64-wistron_sw_to3200k-r0/watchdog-control.service new file mode 100644 index 000000000000..02ffe8ce9189 --- /dev/null +++ b/device/wistron/x86_64-wistron_sw_to3200k-r0/watchdog-control.service @@ -0,0 +1,10 @@ +[Unit] +Description=watchdog control service +After=swss.service + +[Service] +Type=simple +ExecStart=/usr/local/bin/sw_to3200k_watchdog.sh + +[Install] +WantedBy=multi-user.target diff --git a/dockers/docker-dhcp-relay/cli-plugin-tests/conftest.py b/dockers/docker-dhcp-relay/cli-plugin-tests/conftest.py index 37aec0b8b251..5f0b981ccaee 100644 --- a/dockers/docker-dhcp-relay/cli-plugin-tests/conftest.py +++ b/dockers/docker-dhcp-relay/cli-plugin-tests/conftest.py @@ -19,14 +19,23 @@ def mock_cfgdb(): } def get_entry(table, key): + if table not in CONFIG or key not in CONFIG[table]: + return {} return CONFIG[table][key] def set_entry(table, key, data): CONFIG[table].setdefault(key, {}) - CONFIG[table][key] = data + + if data is None: + CONFIG[table].pop(key) + else: + CONFIG[table][key] = data + + def get_keys(table): + return CONFIG[table].keys() cfgdb.get_entry = mock.Mock(side_effect=get_entry) cfgdb.set_entry = mock.Mock(side_effect=set_entry) + cfgdb.get_keys = mock.Mock(side_effect=get_keys) yield cfgdb - diff --git a/dockers/docker-dhcp-relay/cli-plugin-tests/test_config_dhcp_relay.py b/dockers/docker-dhcp-relay/cli-plugin-tests/test_config_dhcp_relay.py index 2c9a5c19a93b..a42d5cce7a8a 100644 --- a/dockers/docker-dhcp-relay/cli-plugin-tests/test_config_dhcp_relay.py +++ b/dockers/docker-dhcp-relay/cli-plugin-tests/test_config_dhcp_relay.py @@ -111,9 +111,25 @@ def test_plugin_registration(self): cli = mock.MagicMock() dhcp_relay.register(cli) - def test_config_dhcp_relay_add_del_with_nonexist_vlanid(self, ip_version, op): + def test_config_dhcp_relay_add_del_with_nonexist_vlanid_ipv4(self, op): runner = CliRunner() + ip_version = "ipv4" + with mock.patch("utilities_common.cli.run_command") as mock_run_command: + result = runner.invoke(dhcp_relay.dhcp_relay.commands[ip_version] + .commands[IP_VER_TEST_PARAM_MAP[ip_version]["command"]] + .commands[op], ["1001", IP_VER_TEST_PARAM_MAP[ip_version]["ips"][0]]) + print(result.exit_code) + print(result.stdout) + assert result.exit_code != 0 + assert "Error: Vlan1001 doesn't exist" in result.output + assert mock_run_command.call_count == 0 + + def test_config_dhcp_relay_del_with_nonexist_vlanid_ipv6(self): + runner = CliRunner() + + op = "del" + ip_version = "ipv6" with mock.patch("utilities_common.cli.run_command") as mock_run_command: result = runner.invoke(dhcp_relay.dhcp_relay.commands[ip_version] .commands[IP_VER_TEST_PARAM_MAP[ip_version]["command"]] @@ -262,3 +278,25 @@ def test_config_add_del_duplicate_dhcp_relay(self, mock_cfgdb, ip_version, op): assert result.exit_code != 0 assert "Error: Find duplicate DHCP relay ip {} in {} list".format(test_ip, op) in result.output assert mock_run_command.call_count == 0 + + def test_config_add_dhcp_relay_ipv6_with_non_entry(self, mock_cfgdb): + op = "add" + ip_version = "ipv6" + test_ip = IP_VER_TEST_PARAM_MAP[ip_version]["ips"][0] + runner = CliRunner() + db = Db() + db.cfgdb = mock_cfgdb + table = IP_VER_TEST_PARAM_MAP[ip_version]["table"] + db.cfgdb.set_entry(table, "Vlan1000", None) + assert db.cfgdb.get_entry(table, "Vlan1000") == {} + assert len(db.cfgdb.get_keys(table)) == 0 + + with mock.patch("utilities_common.cli.run_command") as mock_run_command: + result = runner.invoke(dhcp_relay.dhcp_relay.commands[ip_version] + .commands[IP_VER_TEST_PARAM_MAP[ip_version]["command"]] + .commands[op], ["1000", test_ip], obj=db) + print(result.exit_code) + print(result.output) + assert result.exit_code == 0 + assert db.cfgdb.get_entry(table, "Vlan1000") == {"dhcpv6_servers": [test_ip]} + assert mock_run_command.call_count == 3 diff --git a/dockers/docker-dhcp-relay/cli/config/plugins/dhcp_relay.py b/dockers/docker-dhcp-relay/cli/config/plugins/dhcp_relay.py index 57848161f653..aea8e491f05b 100644 --- a/dockers/docker-dhcp-relay/cli/config/plugins/dhcp_relay.py +++ b/dockers/docker-dhcp-relay/cli/config/plugins/dhcp_relay.py @@ -22,11 +22,13 @@ def validate_ips(ctx, ips, ip_version): ctx.fail("{} is not IPv{} address".format(ip, ip_version)) -def get_dhcp_servers(db, vlan_name, ctx, table_name, dhcp_servers_str): - table = db.cfgdb.get_entry(table_name, vlan_name) - if len(table.keys()) == 0: - ctx.fail("{} doesn't exist".format(vlan_name)) +def get_dhcp_servers(db, vlan_name, ctx, table_name, dhcp_servers_str, check_is_exist=True): + if check_is_exist: + keys = db.cfgdb.get_keys(table_name) + if vlan_name not in keys: + ctx.fail("{} doesn't exist".format(vlan_name)) + table = db.cfgdb.get_entry(table_name, vlan_name) dhcp_servers = table.get(dhcp_servers_str, []) return dhcp_servers, table @@ -49,7 +51,10 @@ def add_dhcp_relay(vid, dhcp_relay_ips, db, ip_version): ctx = click.get_current_context() # Verify ip addresses are valid validate_ips(ctx, dhcp_relay_ips, ip_version) - dhcp_servers, table = get_dhcp_servers(db, vlan_name, ctx, table_name, dhcp_servers_str) + + # It's unnecessary for DHCPv6 Relay to verify entry exist + check_config_exist = True if ip_version == 4 else False + dhcp_servers, table = get_dhcp_servers(db, vlan_name, ctx, table_name, dhcp_servers_str, check_config_exist) added_ips = [] for dhcp_relay_ip in dhcp_relay_ips: @@ -100,6 +105,9 @@ def del_dhcp_relay(vid, dhcp_relay_ips, db, ip_version): else: table[dhcp_servers_str] = dhcp_servers + if ip_version == 6 and len(table.keys()) == 0: + table = None + db.cfgdb.set_entry(table_name, vlan_name, table) click.echo("Removed DHCP relay address [{}] from {}".format(",".join(dhcp_relay_ips), vlan_name)) try: diff --git a/files/Aboot/boot0.j2 b/files/Aboot/boot0.j2 index de7bfc3d662f..460fdd88fc18 100644 --- a/files/Aboot/boot0.j2 +++ b/files/Aboot/boot0.j2 @@ -524,6 +524,8 @@ write_platform_specific_cmdline() { fi if [ "$sid" = "Lodoga" ]; then aboot_machine=arista_7050cx3_32s + cmdline_add logs_inram=on + cmdline_add libata.force=2.00:noncq fi if [ "$sid" = "Marysville" ]; then aboot_machine=arista_7050sx3_48yc8 @@ -621,6 +623,10 @@ write_platform_specific_cmdline() { cmdline_add intel_idle.max_cstate=0 read_system_eeprom fi + if in_array "$platform" "rook"; then + # Currently applies to Alhambra, Blackhawk, Gardena and Mineral + cmdline_add libata.force=1.00:noncq + fi if in_array "$platform" "crow" "magpie"; then cmdline_add amd_iommu=off cmdline_add modprobe.blacklist=snd_hda_intel,hdaudio diff --git a/files/build_templates/buffers_config.j2 b/files/build_templates/buffers_config.j2 index c8d0aa933204..11e35a7b4dd6 100644 --- a/files/build_templates/buffers_config.j2 +++ b/files/build_templates/buffers_config.j2 @@ -38,6 +38,7 @@ def {%- set ports2cable = defs.ports2cable %} {%- else %} {%- set ports2cable = { + 'internal' : '5m', 'torrouter_server' : '5m', 'leafrouter_torrouter' : '40m', 'spinerouter_leafrouter' : '300m' @@ -93,7 +94,14 @@ def {{ default_cable }} {%- endif %} {%- else -%} - {{ default_cable }} + {%- if port_name.startswith('Ethernet-BP') %} + {%- if 'internal' not in ports2cable %} + {%- set _ = ports2cable.update({'internal': '5m'}) %} + {%- endif -%} + {{ ports2cable['internal'] }} + {%- else -%} + {{ default_cable }} + {%- endif %} {%- endif %} {%- endif %} {%- endmacro %} diff --git a/files/build_templates/docker_image_ctl.j2 b/files/build_templates/docker_image_ctl.j2 index ec94fd420303..cb48e6b5f924 100644 --- a/files/build_templates/docker_image_ctl.j2 +++ b/files/build_templates/docker_image_ctl.j2 @@ -155,11 +155,13 @@ function waitForAllInstanceDatabaseConfigJsonFilesReady() fi done done - fi + fi + # Delay a second to allow all instance database_config.json files to be completely generated and fully accessible. + # This delay is needed to make sure that the database_config.json files are correctly rendered from j2 template + # files ( renderning takes some time ) + sleep 1 fi } -# delay a second to allow the file to be fully accessible -sleep 1 {%- endif %} function postStartAction() @@ -225,6 +227,10 @@ function postStartAction() # then we catch python exception of file not valid # that comes to syslog which is unwanted so wait till database # config is ready and then ping + # sonic-db-cli try to initialize the global database. If in multiasic platform, inital global + # database will try to access to all other instance database-config.json. If other instance + # database-config.json files are not ready yet, it will generate the sonic-db-cli core files. + waitForAllInstanceDatabaseConfigJsonFilesReady until [[ ($(docker exec -i database$DEV pgrep -x -c supervisord) -gt 0) && ($($SONIC_DB_CLI PING | grep -c PONG) -gt 0) && ($(docker exec -i database$DEV sonic-db-cli PING | grep -c PONG) -gt 0) ]]; do sleep 1; @@ -234,11 +240,7 @@ function postStartAction() mv $WARM_DIR/dump.rdb $WARM_DIR/dump.rdb.old else # If there is a config_db.json dump file, load it. - if [ -r /etc/sonic/config_db$DEV.json ]; then - - # For multi-asic, all /var/run/redis$DEV/sonic-db/database_config.json need to ready - # for loading config with --write-to-db - waitForAllInstanceDatabaseConfigJsonFilesReady + if [ -r /etc/sonic/config_db$DEV.json ]; then if [ -r /etc/sonic/init_cfg.json ]; then $SONIC_CFGGEN -j /etc/sonic/init_cfg.json -j /etc/sonic/config_db$DEV.json --write-to-db @@ -678,4 +680,4 @@ case "$1" in echo "Usage: $0 {start namespace(optional)|wait namespace(optional)|stop namespace(optional)}" exit 1 ;; -esac \ No newline at end of file +esac diff --git a/files/build_templates/init_cfg.json.j2 b/files/build_templates/init_cfg.json.j2 index ada8bc1a96c2..72e74a1d92d9 100644 --- a/files/build_templates/init_cfg.json.j2 +++ b/files/build_templates/init_cfg.json.j2 @@ -136,5 +136,16 @@ "digits_class": "true", "special_class": "true" } + }, + "SYSTEM_DEFAULTS" : { +{%- if include_mux == "y" %} + "mux_tunnel_egress_acl": { +{%- if sonic_asic_platform == "mellanox" %} + "status": "enabled" +{% else %} + "status": "disabled" +{% endif %} + } +{% endif %} } } diff --git a/files/build_templates/sonic_debian_extension.j2 b/files/build_templates/sonic_debian_extension.j2 index 086f7aed56f3..592ac64dd324 100644 --- a/files/build_templates/sonic_debian_extension.j2 +++ b/files/build_templates/sonic_debian_extension.j2 @@ -938,7 +938,6 @@ sudo mkdir -p $FILESYSTEM_ROOT/etc/mlnx/ sudo cp $files_path/$MLNX_SPC_FW_FILE $FILESYSTEM_ROOT/etc/mlnx/fw-SPC.mfa sudo cp $files_path/$MLNX_SPC2_FW_FILE $FILESYSTEM_ROOT/etc/mlnx/fw-SPC2.mfa sudo cp $files_path/$MLNX_SPC3_FW_FILE $FILESYSTEM_ROOT/etc/mlnx/fw-SPC3.mfa -sudo cp $files_path/$MLNX_SPC4_FW_FILE $FILESYSTEM_ROOT/etc/mlnx/fw-SPC4.mfa sudo cp $files_path/$ISSU_VERSION_FILE $FILESYSTEM_ROOT/etc/mlnx/issu-version sudo cp $files_path/$MLNX_FFB_SCRIPT $FILESYSTEM_ROOT/usr/bin/mlnx-ffb.sh sudo cp $files_path/$MLNX_ONIE_FW_UPDATE $FILESYSTEM_ROOT/usr/bin/$MLNX_ONIE_FW_UPDATE diff --git a/files/docker/docker.service.conf b/files/docker/docker.service.conf index 7debd85a50ac..73d953ecfdd5 100644 --- a/files/docker/docker.service.conf +++ b/files/docker/docker.service.conf @@ -1,3 +1,4 @@ [Service] +Environment=GODEBUG=netdns=cgo ExecStart= ExecStart=/usr/bin/dockerd -H unix:// --storage-driver=overlay2 --bip=240.127.1.1/24 --iptables=false --ipv6=true --fixed-cidr-v6=fd00::/80 diff --git a/platform/barefoot/sonic-platform-modules-arista b/platform/barefoot/sonic-platform-modules-arista index 4851b192fb3a..7deff3f0256a 160000 --- a/platform/barefoot/sonic-platform-modules-arista +++ b/platform/barefoot/sonic-platform-modules-arista @@ -1 +1 @@ -Subproject commit 4851b192fb3a4a498d33fb648cb5223cf565ef08 +Subproject commit 7deff3f0256a5d0c905d8fde1df0b466a4065104 diff --git a/platform/broadcom/sonic-platform-modules-arista b/platform/broadcom/sonic-platform-modules-arista index 4851b192fb3a..7deff3f0256a 160000 --- a/platform/broadcom/sonic-platform-modules-arista +++ b/platform/broadcom/sonic-platform-modules-arista @@ -1 +1 @@ -Subproject commit 4851b192fb3a4a498d33fb648cb5223cf565ef08 +Subproject commit 7deff3f0256a5d0c905d8fde1df0b466a4065104 diff --git a/platform/broadcom/sonic-platform-modules-nokia b/platform/broadcom/sonic-platform-modules-nokia index 81a9c77a22bd..d768d199bdd0 160000 --- a/platform/broadcom/sonic-platform-modules-nokia +++ b/platform/broadcom/sonic-platform-modules-nokia @@ -1 +1 @@ -Subproject commit 81a9c77a22bd4147e4041a7359e211d7f51b60a8 +Subproject commit d768d199bdd0247135f2135214a92d81953d4795 diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/Makefile b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/Makefile index 86a67f55089b..4e7a7e8191b7 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/Makefile +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/Makefile @@ -1,7 +1,7 @@ ifneq ($(KERNELRELEASE),) obj-m:= wistron_6512_32r_cpld.o wistron_6512_32r_fan.o \ wistron_6512_32r_oom.o wistron_6512_32r_psu.o \ - wistron_6512_32r_thermal.o \ + wistron_6512_32r_thermal.o i2c-imc.o \ wistron_6512_32r_leds.o wistron_6512_32r_syseeprom.o else ifeq (,$(KERNEL_SRC)) diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/i2c-imc.c b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/i2c-imc.c new file mode 100644 index 000000000000..a650f3cf1923 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/i2c-imc.c @@ -0,0 +1,515 @@ +// SPDX-License-Identifier: GPL-2.0 + +/* + * Intel Memory Controller iMC SMBus Driver to DIMMs. + * + * Copyright (c) 2013-2016 Andrew Lutomirski + * Copyright (c) 2020 Stefan Schaeckeler , Cisco Systems + */ + +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + +#include +#include +#include +#include +#include + +/* iMC Main, PCI dev 0x13, fn 0, 8086.6fa8 */ +#define PCI_DEVICE_ID_INTEL_BROADWELL_IMC_TA 0x6fa8 + +/* Register offsets for channel pairs 0+1 and 2+3 */ +#define SMBSTAT(i) (0x180 + 0x10*(i)) +#define SMBCMD(i) (0x184 + 0x10*(i)) +#define SMBCNTL(i) (0x188 + 0x10*(i)) + +/* SMBSTAT fields */ +#define SMBSTAT_RDO (1U << 31) /* Read Data Valid */ +#define SMBSTAT_WOD (1U << 30) /* Write Operation Done */ +#define SMBSTAT_SBE (1U << 29) /* SMBus Error */ +#define SMBSTAT_SMB_BUSY (1U << 28) /* SMBus Busy State */ +#define SMBSTAT_RDATA_MASK 0xffff /* Result of a read */ + +/* SMBCMD fields */ +#define SMBCMD_TRIGGER (1U << 31) /* CMD Trigger */ +#define SMBCMD_WORD_ACCESS (1U << 29) /* Word (vs byte) access */ +#define SMBCMD_TYPE_READ (0U << 27) /* Read */ +#define SMBCMD_TYPE_WRITE (1U << 27) /* Write */ +#define SMBCMD_SA_SHIFT 24 +#define SMBCMD_BA_SHIFT 16 + +/* SMBCNTL fields */ +#define SMBCNTL_DTI_MASK 0xf0000000 /* Slave Address low bits */ +#define SMBCNTL_DTI_SHIFT 28 /* Slave Address low bits */ +#define SMBCNTL_DIS_WRT (1U << 26) /* Disable Write */ +#define SMBCNTL_TSOD_PRES_MASK 0xff /* DIMM Present mask */ + +/* For sanity check: bits that might randomly change if we race with firmware */ +#define SMBCMD_OUR_BITS (~(u32)SMBCMD_TRIGGER) +#define SMBCNTL_OUR_BITS (SMBCNTL_DTI_MASK) + + +/* System Address Decoder, PCI dev 0xf fn 5, 8086.6ffd */ +#define PCI_DEVICE_ID_INTEL_BROADWELL_IMC_SAD 0x6ffd + +/* Register offsets */ +#define SADCNTL 0xf4 + +/* SADCNTL fields */ +#define SADCNTL_LOCAL_NODEID_MASK 0xf /* Local NodeID of socket */ + + +/* Power Control Unit, PCI dev 0x1e fn 1, 8086.6f99 */ +#define PCI_DEVICE_ID_INTEL_BROADWELL_IMC_PCU 0x6f99 + +/* Register offsets */ +#define TSODCNTL 0xe0 + +/* TSODCNTL fields */ + + +/* DIMMs hold jc42 thermal sensors starting at i2c address 0x18 */ +#define DIMM_SENSOR_DRV "jc42" +#define DIMM_SENSOR_BASE_ADR 0x18 + + +#define sanitycheck 1 + +struct imc_channelpair { + struct i2c_adapter adapter; + bool can_write, cltt; +}; + +struct imc_pcu { + struct pci_dev *pci_dev; + u32 tsod_polling_interval; + struct mutex mutex; /* see imc_channelpair_claim() */ +}; + +struct imc_priv { + struct pci_dev *pci_dev; + struct imc_channelpair channelpair[2]; + struct imc_pcu pcu; + bool suspended; +}; + +static int imc_channelpair_claim(struct imc_priv *priv, int i) +{ + if (priv->suspended) + return -EIO; + + /* + * i2c controllers need exclusive access to a psu register and wait + * then for 10ms before starting their transaction. + * + * Possible optimization: Once an i2c controller modified the psu + * register and waits, the other controller does not need to wait for + * the whole 10ms, but then only this other controller has to clean up + * the psu register. + */ + mutex_lock(&priv->pcu.mutex); + + if (priv->channelpair[i].cltt) { + pci_write_config_dword(priv->pcu.pci_dev, TSODCNTL, 0); + usleep_range(10000, 10500); + } + return 0; +} + +static void imc_channelpair_release(struct imc_priv *priv, int i) +{ + if (priv->channelpair[i].cltt) { + /* set tosd_control.tsod_polling_interval to previous value */ + pci_write_config_dword(priv->pcu.pci_dev, TSODCNTL, + priv->pcu.tsod_polling_interval); + } + mutex_unlock(&priv->pcu.mutex); +} + +static bool imc_wait_for_transaction(struct imc_priv *priv, int i, u32 *stat) +{ + int j; + static int busywaits = 1; + + /* + * Distribution of transaction time from 10000 collected samples: + * + * 70us: 1, 80us: 12, 90us: 34, 100us: 132, 110us: 424, 120us: 1138, + * 130us: 5224, 140us: 3035. + * + */ + usleep_range(131, 140); + + /* Don't give up, yet */ + for (j = 0; j < 20; j++) { + pci_read_config_dword(priv->pci_dev, SMBSTAT(i), stat); + if (!(*stat & SMBSTAT_SMB_BUSY)) { + if (j > busywaits) { + busywaits = j; + dev_warn(&priv->pci_dev->dev, + "Discovered surprisingly long transaction time (%d)\n", + busywaits); + } + return true; + } + udelay(9); + } + return false; +} + +/* + * The iMC supports five access types. The terminology is rather inconsistent. + * These are the types: + * + * "Write to pointer register SMBus": I2C_SMBUS_WRITE, I2C_SMBUS_BYTE + * + * Read byte/word: I2C_SMBUS_READ, I2C_SMBUS_{BYTE|WORD}_DATA + * + * Write byte/word: I2C_SMBUS_WRITE, I2C_SMBUS_{BYTE|WORD}_DATA + */ + +static u32 imc_func(struct i2c_adapter *adapter) +{ + int i; + struct imc_channelpair *cp; + struct imc_priv *priv = i2c_get_adapdata(adapter); + + i = (adapter == &priv->channelpair[0].adapter ? 0 : 1); + cp = &priv->channelpair[i]; + + if (cp->can_write) + return I2C_FUNC_SMBUS_BYTE_DATA | I2C_FUNC_SMBUS_WORD_DATA; + else + return I2C_FUNC_SMBUS_READ_BYTE_DATA | + I2C_FUNC_SMBUS_READ_WORD_DATA; +} + +static s32 imc_smbus_xfer(struct i2c_adapter *adap, u16 addr, + unsigned short flags, char read_write, u8 command, + int size, union i2c_smbus_data *data) +{ + int ret, i; + u32 cmd = 0, cntl, stat; +#ifdef sanitycheck + u32 final_cmd, final_cntl; +#endif + struct imc_channelpair *cp; + struct imc_priv *priv = i2c_get_adapdata(adap); + + i = (adap == &priv->channelpair[0].adapter ? 0 : 1); + cp = &priv->channelpair[i]; + + /* Encode CMD part of addresses and access size */ + cmd |= ((u32)addr & 0x7) << SMBCMD_SA_SHIFT; + cmd |= ((u32)command) << SMBCMD_BA_SHIFT; + if (size == I2C_SMBUS_WORD_DATA) + cmd |= SMBCMD_WORD_ACCESS; + + /* Encode read/write and data to write */ + if (read_write == I2C_SMBUS_READ) { + cmd |= SMBCMD_TYPE_READ; + } else { + cmd |= SMBCMD_TYPE_WRITE; + cmd |= (size == I2C_SMBUS_WORD_DATA + ? swab16(data->word) + : data->byte); + } + + ret = imc_channelpair_claim(priv, i); + if (ret) + return ret; + + pci_read_config_dword(priv->pci_dev, SMBCNTL(i), &cntl); + cntl &= ~SMBCNTL_DTI_MASK; + cntl |= ((u32)addr >> 3) << SMBCNTL_DTI_SHIFT; + pci_write_config_dword(priv->pci_dev, SMBCNTL(i), cntl); + + cmd |= SMBCMD_TRIGGER; + pci_write_config_dword(priv->pci_dev, SMBCMD(i), cmd); + + if (!imc_wait_for_transaction(priv, i, &stat)) { + dev_warn(&priv->pci_dev->dev, "smbus transaction did not complete.\n"); + ret = -ETIMEDOUT; + goto xfer_out_release; + } + +#ifdef sanitycheck /* This is a young driver. Keep the checks for now */ + pci_read_config_dword(priv->pci_dev, SMBCMD(i), &final_cmd); + pci_read_config_dword(priv->pci_dev, SMBCNTL(i), &final_cntl); + if (((cmd ^ final_cmd) & SMBCMD_OUR_BITS) || + ((cntl ^ final_cntl) & SMBCNTL_OUR_BITS)) { + dev_err(&priv->pci_dev->dev, + "Access to channel pair %d-%d raced with hardware: cmd 0x%08X->0x%08X, cntl 0x%08X->0x%08X\n", + 2*i, 2*i+1, cmd, final_cmd, cntl, final_cntl); + ret = -EIO; + goto xfer_out_release; + } +#endif + + if (stat & SMBSTAT_SBE) { + /* + * While SBE is set hardware TSOD polling is disabled. This is + * very bad as this bit is RO-V and will only be cleared after + * a further software initiated transaction finishes + * successfully. + */ + dev_err(&priv->pci_dev->dev, + "smbus error: sbe is set 0x%x\n", stat); + ret = -ENXIO; + goto xfer_out_release; + } + + if (read_write == I2C_SMBUS_READ) { + if (!(stat & SMBSTAT_RDO)) { + dev_warn(&priv->pci_dev->dev, + "Unexpected read status 0x%08X\n", stat); + ret = -EIO; + goto xfer_out_release; + } + /* + * The iMC SMBus controller thinks of SMBus words as being + * big-endian (MSB first). Linux treats them as little-endian, + * so we need to swap them. + */ + if (size == I2C_SMBUS_WORD_DATA) + data->word = swab16(stat & SMBSTAT_RDATA_MASK); + else + data->byte = stat & 0xFF; + } else { + if (!(stat & SMBSTAT_WOD)) { + dev_warn(&priv->pci_dev->dev, + "Unexpected write status 0x%08X\n", stat); + ret = -EIO; + } + } + +xfer_out_release: + imc_channelpair_release(priv, i); + + return ret; +} + +static const struct i2c_algorithm imc_smbus_algorithm = { + .smbus_xfer = imc_smbus_xfer, + .functionality = imc_func, +}; + +static void imc_instantiate_sensors(struct i2c_adapter *adapter, u8 presence) +{ + struct i2c_board_info info = {}; + + strcpy(info.type, DIMM_SENSOR_DRV); + info.addr = DIMM_SENSOR_BASE_ADR; + + /* + * Presence is a bit vector. Bits from right to left map into i2c slave + * addresses starting 0x18. + */ + while (presence) { + if (presence & 0x1) + i2c_new_client_device(adapter, &info); + info.addr++; + presence >>= 1; + } +} + +static int imc_init_channelpair(struct imc_priv *priv, int i, int socket) +{ + int err; + u32 val; + struct imc_channelpair *cp = &priv->channelpair[i]; + + i2c_set_adapdata(&cp->adapter, priv); + cp->adapter.owner = THIS_MODULE; + cp->adapter.algo = &imc_smbus_algorithm; + cp->adapter.dev.parent = &priv->pci_dev->dev; + + pci_read_config_dword(priv->pci_dev, SMBCNTL(i), &val); + cp->can_write = !(val & SMBCNTL_DIS_WRT); + + /* + * A TSOD polling interval of > 0 tells us if CLTT mode is enabled on + * some channel pair. + * + * Is there a better way to check for CLTT mode? In particular, is + * there a way to distingush the mode on a channel pair basis? + */ + cp->cltt = (priv->pcu.tsod_polling_interval > 0); + + snprintf(cp->adapter.name, sizeof(cp->adapter.name), + "iMC socket %d for channel pair %d-%d", socket, 2*i, 2*i+1); + err = i2c_add_adapter(&cp->adapter); + if (err) + return err; + + /* For reasons unknown, TSOD_PRES_MASK is only set in CLTT mode. */ + if (cp->cltt) { + dev_info(&priv->pci_dev->dev, + "CLTT is enabled on channel pair %d-%d. Thermal sensors will be automatically enabled\n", + 2*i, 2*i+1); + } else { + dev_info(&priv->pci_dev->dev, + "CLTT is disabled on channel pair %d-%d. Thermal sensors need to be manually enabled\n", + 2*i, 2*i+1); + } + + imc_instantiate_sensors(&cp->adapter, val & SMBCNTL_TSOD_PRES_MASK); + + return 0; +} + +static void imc_free_channelpair(struct imc_priv *priv, int i) +{ + struct imc_channelpair *cp = &priv->channelpair[i]; + + i2c_del_adapter(&cp->adapter); +} + +static struct pci_dev *imc_get_related_device(struct pci_bus *bus, + unsigned int devfn, u16 devid) +{ + struct pci_dev *dev = pci_get_slot(bus, devfn); + + if (!dev) + return NULL; + + if (dev->vendor != PCI_VENDOR_ID_INTEL || dev->device != devid) { + pci_dev_put(dev); + return NULL; + } + return dev; +} + +static int imc_probe(struct pci_dev *dev, const struct pci_device_id *id) +{ + int i, j, err; + struct imc_priv *priv; + struct pci_dev *sad; /* System Address Decoder */ + u32 sadcntl; + + /* Sanity check. This device is always at 0x13.0 */ + if (dev->devfn != PCI_DEVFN(0x13, 0)) + return -ENODEV; + + priv = devm_kzalloc(&dev->dev, sizeof(*priv), GFP_KERNEL); + if (!priv) + return -ENOMEM; + priv->pci_dev = dev; + pci_set_drvdata(dev, priv); + + /* + * From sad, we learn the local node id of the socket. + * + * The socket will not change at runtime and so we throw away sad. + */ + sad = imc_get_related_device(dev->bus, PCI_DEVFN(0x0f, 5), + PCI_DEVICE_ID_INTEL_BROADWELL_IMC_SAD); + if (!sad) { + err = -ENODEV; + goto probe_out_free; + } + pci_read_config_dword(sad, SADCNTL, &sadcntl); + pci_dev_put(sad); + + /* + * From pcu, we access the CLTT polling interval. + * + * The polling interval is set by BIOS. We assume it will not change at + * runtime and cache the initial value. + */ + priv->pcu.pci_dev = imc_get_related_device(dev->bus, PCI_DEVFN(0x1e, 1), + PCI_DEVICE_ID_INTEL_BROADWELL_IMC_PCU); + if (!priv->pcu.pci_dev) { + err = -ENODEV; + goto probe_out_free; + } + pci_read_config_dword(priv->pcu.pci_dev, TSODCNTL, + &priv->pcu.tsod_polling_interval); + + mutex_init(&priv->pcu.mutex); + + for (i = 0; i < 2; i++) { + err = imc_init_channelpair(priv, i, + sadcntl & SADCNTL_LOCAL_NODEID_MASK); + if (err) + goto probe_out_free_channelpair; + } + + return 0; + +probe_out_free_channelpair: + for (j = 0; j < i; j++) + imc_free_channelpair(priv, j); + + mutex_destroy(&priv->pcu.mutex); + +probe_out_free: + kfree(priv); + return err; +} + +static void imc_remove(struct pci_dev *dev) +{ + int i; + struct imc_priv *priv = pci_get_drvdata(dev); + + for (i = 0; i < 2; i++) + imc_free_channelpair(priv, i); + + /* set tosd_control.tsod_polling_interval to initial value */ + pci_write_config_dword(priv->pcu.pci_dev, TSODCNTL, + priv->pcu.tsod_polling_interval); + + mutex_destroy(&priv->pcu.mutex); +} + +static int imc_suspend(struct pci_dev *dev, pm_message_t mesg) +{ + struct imc_priv *priv = pci_get_drvdata(dev); + + /* BIOS is in charge. We should finish any pending transaction */ + priv->suspended = true; + + return 0; +} + +static int imc_resume(struct pci_dev *dev) +{ + struct imc_priv *priv = pci_get_drvdata(dev); + + priv->suspended = false; + + return 0; +} + +static const struct pci_device_id imc_ids[] = { + { PCI_DEVICE(PCI_VENDOR_ID_INTEL, + PCI_DEVICE_ID_INTEL_BROADWELL_IMC_TA) }, + { 0, } +}; +MODULE_DEVICE_TABLE(pci, imc_ids); + +static struct pci_driver imc_pci_driver = { + .name = "imc_smbus", + .id_table = imc_ids, + .probe = imc_probe, + .remove = imc_remove, + .suspend = imc_suspend, + .resume = imc_resume, +}; + +static int __init i2c_imc_init(void) +{ + return pci_register_driver(&imc_pci_driver); +} +module_init(i2c_imc_init); + +static void __exit i2c_imc_exit(void) +{ + pci_unregister_driver(&imc_pci_driver); +} +module_exit(i2c_imc_exit); + +MODULE_AUTHOR("Stefan Schaeckeler "); +MODULE_DESCRIPTION("iMC SMBus driver"); +MODULE_LICENSE("GPL v2"); diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_cpld.c b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_cpld.c index a6c21966d1cf..e66d95a52290 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_cpld.c +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_cpld.c @@ -37,6 +37,7 @@ struct wistron_cpld_data { int reset[PORT_NUM]; int lpmod[PORT_NUM]; int modsel[PORT_NUM]; + int data_rdy[PORT_NUM]; }; static const struct i2c_device_id wistron_cpld_id[] = { @@ -51,6 +52,7 @@ MODULE_DEVICE_TABLE(i2c, wistron_cpld_id); #define TRANSCEIVER_RESET_ATTR_ID(index) MODULE_RESET_##index #define TRANSCEIVER_LPMOD_ATTR_ID(index) MODULE_LPMOD_##index #define TRANSCEIVER_MODSEL_ATTR_ID(index) MODULE_MODSEL_##index +#define TRANSCEIVER_DATA_RDY_ATTR_ID(index) MODULE_DATA_RDY_##index enum wistron_cpld_sysfs_attributes { /* chip version */ @@ -189,6 +191,38 @@ enum wistron_cpld_sysfs_attributes { TRANSCEIVER_MODSEL_ATTR_ID(30), TRANSCEIVER_MODSEL_ATTR_ID(31), TRANSCEIVER_MODSEL_ATTR_ID(32), + TRANSCEIVER_DATA_RDY_ATTR_ID(1), + TRANSCEIVER_DATA_RDY_ATTR_ID(2), + TRANSCEIVER_DATA_RDY_ATTR_ID(3), + TRANSCEIVER_DATA_RDY_ATTR_ID(4), + TRANSCEIVER_DATA_RDY_ATTR_ID(5), + TRANSCEIVER_DATA_RDY_ATTR_ID(6), + TRANSCEIVER_DATA_RDY_ATTR_ID(7), + TRANSCEIVER_DATA_RDY_ATTR_ID(8), + TRANSCEIVER_DATA_RDY_ATTR_ID(9), + TRANSCEIVER_DATA_RDY_ATTR_ID(10), + TRANSCEIVER_DATA_RDY_ATTR_ID(11), + TRANSCEIVER_DATA_RDY_ATTR_ID(12), + TRANSCEIVER_DATA_RDY_ATTR_ID(13), + TRANSCEIVER_DATA_RDY_ATTR_ID(14), + TRANSCEIVER_DATA_RDY_ATTR_ID(15), + TRANSCEIVER_DATA_RDY_ATTR_ID(16), + TRANSCEIVER_DATA_RDY_ATTR_ID(17), + TRANSCEIVER_DATA_RDY_ATTR_ID(18), + TRANSCEIVER_DATA_RDY_ATTR_ID(19), + TRANSCEIVER_DATA_RDY_ATTR_ID(20), + TRANSCEIVER_DATA_RDY_ATTR_ID(21), + TRANSCEIVER_DATA_RDY_ATTR_ID(22), + TRANSCEIVER_DATA_RDY_ATTR_ID(23), + TRANSCEIVER_DATA_RDY_ATTR_ID(24), + TRANSCEIVER_DATA_RDY_ATTR_ID(25), + TRANSCEIVER_DATA_RDY_ATTR_ID(26), + TRANSCEIVER_DATA_RDY_ATTR_ID(27), + TRANSCEIVER_DATA_RDY_ATTR_ID(28), + TRANSCEIVER_DATA_RDY_ATTR_ID(29), + TRANSCEIVER_DATA_RDY_ATTR_ID(30), + TRANSCEIVER_DATA_RDY_ATTR_ID(31), + TRANSCEIVER_DATA_RDY_ATTR_ID(32), }; /* sysfs attributes for hwmon */ @@ -204,6 +238,8 @@ static ssize_t get_mode_lpmod(struct device *dev, struct device_attribute *da, c static ssize_t set_mode_lpmod(struct device *dev, struct device_attribute *da, const char *buf, size_t count); static ssize_t get_mode_modsel(struct device *dev, struct device_attribute *da, char *buf); static ssize_t set_mode_modsel(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_mode_data_rdy(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_mode_data_rdy(struct device *dev, struct device_attribute *da, const char *buf, size_t count); /* version */ static SENSOR_DEVICE_ATTR(version, S_IWUSR | S_IRUGO, get_version, set_version, CPLD_VERSION); @@ -234,6 +270,10 @@ static SENSOR_DEVICE_ATTR(psu_led, S_IWUSR | S_IRUGO, get_led_status, set_led_s static SENSOR_DEVICE_ATTR(port##index##_modsel, S_IWUSR | S_IRUGO, get_mode_modsel, set_mode_modsel, MODULE_MODSEL_##index) #define DECLARE_TRANSCEIVER_MODSEL_ATTR(index) &sensor_dev_attr_port##index##_modsel.dev_attr.attr +#define DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(index) \ + static SENSOR_DEVICE_ATTR(port##index##_data_rdy, S_IWUSR | S_IRUGO, get_mode_data_rdy, set_mode_data_rdy, MODULE_DATA_RDY_##index) +#define DECLARE_TRANSCEIVER_DATA_RDY_ATTR(index) &sensor_dev_attr_port##index##_data_rdy.dev_attr.attr + /* transceiver attributes */ DECLARE_TRANSCEIVER_PRESENT_SENSOR_DEVICE_ATTR(1); DECLARE_TRANSCEIVER_PRESENT_SENSOR_DEVICE_ATTR(2); @@ -363,6 +403,38 @@ DECLARE_TRANSCEIVER_SENSOR_DEVICE_MODSEL_ATTR(29); DECLARE_TRANSCEIVER_SENSOR_DEVICE_MODSEL_ATTR(30); DECLARE_TRANSCEIVER_SENSOR_DEVICE_MODSEL_ATTR(31); DECLARE_TRANSCEIVER_SENSOR_DEVICE_MODSEL_ATTR(32); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(1); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(2); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(3); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(4); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(5); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(6); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(7); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(8); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(9); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(10); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(11); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(12); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(13); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(14); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(15); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(16); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(17); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(18); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(19); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(20); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(21); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(22); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(23); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(24); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(25); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(26); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(27); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(28); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(29); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(30); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(31); +DECLARE_TRANSCEIVER_SENSOR_DEVICE_DATA_RDY_ATTR(32); static struct attribute *wistron_fpga_attributes[] = { &sensor_dev_attr_version.dev_attr.attr, @@ -443,6 +515,22 @@ static struct attribute *wistron_cpld1_attributes[] = { DECLARE_TRANSCEIVER_MODSEL_ATTR(14), DECLARE_TRANSCEIVER_MODSEL_ATTR(15), DECLARE_TRANSCEIVER_MODSEL_ATTR(16), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(1), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(2), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(3), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(4), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(5), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(6), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(7), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(8), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(9), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(10), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(11), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(12), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(13), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(14), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(15), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(16), NULL }; @@ -516,6 +604,22 @@ static struct attribute *wistron_cpld2_attributes[] = { DECLARE_TRANSCEIVER_MODSEL_ATTR(30), DECLARE_TRANSCEIVER_MODSEL_ATTR(31), DECLARE_TRANSCEIVER_MODSEL_ATTR(32), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(17), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(18), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(19), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(20), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(21), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(22), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(23), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(24), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(25), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(26), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(27), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(28), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(29), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(30), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(31), + DECLARE_TRANSCEIVER_DATA_RDY_ATTR(32), NULL }; @@ -758,6 +862,43 @@ static ssize_t set_mode_modsel(struct device *dev, struct device_attribute *da, return count; } +static ssize_t get_mode_data_rdy(struct device *dev, struct device_attribute *da, char *buf) +{ + struct sensor_device_attribute *attr = to_sensor_dev_attr(da); + struct i2c_client *client = to_i2c_client(dev); + struct wistron_cpld_data *data = i2c_get_clientdata(client); + int update_idx, data_rdy = 0; + + update_idx = attr->index - MODULE_DATA_RDY_1; + + mutex_lock(&data->lock); + data_rdy = data->data_rdy[update_idx]; + mutex_unlock(&data->lock); + + return sprintf(buf, "%d", data_rdy); +} + +static ssize_t set_mode_data_rdy(struct device *dev, struct device_attribute *da, const char *buf, size_t count) +{ + struct sensor_device_attribute *attr = to_sensor_dev_attr(da); + struct i2c_client *client = to_i2c_client(dev); + struct wistron_cpld_data *data = i2c_get_clientdata(client); + int error, data_rdy; + int update_idx; + + error = kstrtoint(buf, 10, &data_rdy); + if (error) + return error; + + update_idx = attr->index - MODULE_DATA_RDY_1; + + mutex_lock(&data->lock); + data->data_rdy[update_idx] = data_rdy; + mutex_unlock(&data->lock); + + return count; +} + static void wistron_cpld_add_client(struct i2c_client *client) { struct cpld_client_node *node = kzalloc(sizeof(struct cpld_client_node), GFP_KERNEL); diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_oom.c b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_oom.c index 4236373499b2..0ad2e2ca1ae0 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_oom.c +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_oom.c @@ -10,19 +10,56 @@ #include #include -/* QSFP-DD: page0 (low page + high page (128+128 byte)), page 2 (high page (128 byte)), page11 (high page (128 byte))*/ +#define QSFP28_TYPE 0x11 +#define QSFP_DD_TYPE 0x18 + +#define LOWER_PAGE_OFFSET 0x0 +#define PAGE0_OFFSET 0x80 +#define PAGE1_OFFSET 0x0 +#define PAGE2_OFFSET 0x80 +#define PAGE3_OFFSET 0x0 +#define PAGE10_OFFSET 0x80 +#define PAGE11_OFFSET 0x100 + +#define QSFP_DD_CHAN_MON_OFFSET 0x1a +#define QSFP_DD_TEMP_OFFSET 0xe +#define QSFP_DD_VOLT_OFFSET 0x10 +#define QSFP_DD_RX_LOS_OFFSET 0x13 +#define QSFP_DD_TX_FAULT_OFFSET 0x7 +#define QSFP_DD_DISABLE_OFFSET 0x2 + +#define QSFP28_DOM_BULK_DATA_OFFSET 0x16 +#define QSFP28_RX_LOS_OFFSET 0x3 +#define QSFP28_TX_FAULT_OFFSET 0x4 +#define QSFP28_DISABLE_OFFSET 0x56 + + +/* QSFP-DD: page0 (low page + high page (128+128 byte)), page 1/2/3/10/11 (high page (128 byte))*/ #define EEPROM_DATA_SIZE 256 +#define EEPROM3_DATA_SIZE 384 /* Addresses scanned */ static const unsigned short normal_i2c[] = { I2C_CLIENT_END }; #define MAX_PORT_NAME_LEN 20 +#define TEMP_DATA_SIZE 2 +#define VOLT_DATA_SIZE 2 +#define QSFP_DD_CHAN_MON_DATA_SIZE 0x30 +#define QSFP_DOM_BULK_DATA_SIZE 0x24 -enum sysfs_fan_attributes { +enum sysfs_oom_attributes { OOM_LP_MODE, OOM_TEMP, OOM_EEPROM1, OOM_EEPROM2, + OOM_EEPROM3, OOM_PORT_NAME, + OOM_TEMP_E, + OOM_VOLT_E, + OOM_QSFPDD_CHAN_MON, + OOM_QSFP_DOM_BULK, + OOM_CHAN_RX_LOS, + OOM_CHAN_TX_FAULT, + OOM_CHAN_DISABLE, OOM_ATTR_MAX }; @@ -35,7 +72,16 @@ struct wistron_oom_data { int temp; unsigned char eeprom1[EEPROM_DATA_SIZE]; unsigned char eeprom2[EEPROM_DATA_SIZE]; + unsigned char eeprom3[EEPROM3_DATA_SIZE]; char port_name[MAX_PORT_NAME_LEN]; + + unsigned char qsfp_dd_chan_mon[QSFP_DD_CHAN_MON_DATA_SIZE]; + unsigned char qsfp_dom_bulk[QSFP_DOM_BULK_DATA_SIZE]; + unsigned char tempe[TEMP_DATA_SIZE]; + unsigned char volte[VOLT_DATA_SIZE]; + int rx_los; + int tx_fault; + int disable; }; /* sysfs attributes for hwmon */ @@ -45,20 +91,46 @@ static ssize_t get_oom_info1(struct device *dev, struct device_attribute *da, ch static ssize_t set_oom_info1(struct device *dev, struct device_attribute *da, const char *buf, size_t count); static ssize_t get_oom_info2(struct device *dev, struct device_attribute *da, char *buf); static ssize_t set_oom_info2(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_oom_info3(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_oom_info3(struct device *dev, struct device_attribute *da, const char *buf, size_t count); static ssize_t get_port_name(struct device *dev, struct device_attribute *da, char *buf); static ssize_t set_port_name(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_t_v_e(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_t_v_e(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_qsfp_dd_chan_mon(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_qsfp_dd_chan_mon(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_qsfp_dom_bulk(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_qsfp_dom_bulk(struct device *dev, struct device_attribute *da, const char *buf, size_t count); + + static SENSOR_DEVICE_ATTR(lp_mode, S_IWUSR | S_IRUGO, get_oom_value, set_oom_value, OOM_LP_MODE); static SENSOR_DEVICE_ATTR(temp, S_IWUSR | S_IRUGO, get_oom_value, set_oom_value, OOM_TEMP); static SENSOR_DEVICE_ATTR(eeprom1, S_IWUSR | S_IRUGO, get_oom_info1, set_oom_info1, OOM_EEPROM1); static SENSOR_DEVICE_ATTR(eeprom2, S_IWUSR | S_IRUGO, get_oom_info2, set_oom_info2, OOM_EEPROM2); +static SENSOR_DEVICE_ATTR(eeprom3, S_IWUSR | S_IRUGO, get_oom_info3, set_oom_info3, OOM_EEPROM3); static SENSOR_DEVICE_ATTR(port_name, S_IRUGO | S_IWUSR, get_port_name, set_port_name, OOM_PORT_NAME); +static SENSOR_DEVICE_ATTR(qsfp_dd_chan_mon, S_IWUSR | S_IRUGO, get_qsfp_dd_chan_mon, set_qsfp_dd_chan_mon, OOM_QSFPDD_CHAN_MON); +static SENSOR_DEVICE_ATTR(qsfp_dom_bulk, S_IWUSR | S_IRUGO, get_qsfp_dom_bulk, set_qsfp_dom_bulk, OOM_QSFP_DOM_BULK); +static SENSOR_DEVICE_ATTR(tempe, S_IWUSR | S_IRUGO, get_t_v_e, set_t_v_e, OOM_TEMP_E); +static SENSOR_DEVICE_ATTR(volte, S_IWUSR | S_IRUGO, get_t_v_e, set_t_v_e, OOM_VOLT_E); +static SENSOR_DEVICE_ATTR(rx_los, S_IWUSR | S_IRUGO, get_oom_value, set_oom_value, OOM_CHAN_RX_LOS); +static SENSOR_DEVICE_ATTR(tx_fault, S_IWUSR | S_IRUGO, get_oom_value, set_oom_value, OOM_CHAN_TX_FAULT); +static SENSOR_DEVICE_ATTR(disable, S_IWUSR | S_IRUGO, get_oom_value, set_oom_value, OOM_CHAN_DISABLE); static struct attribute *wistron_oom_attributes[] = { &sensor_dev_attr_lp_mode.dev_attr.attr, &sensor_dev_attr_temp.dev_attr.attr, &sensor_dev_attr_eeprom1.dev_attr.attr, &sensor_dev_attr_eeprom2.dev_attr.attr, + &sensor_dev_attr_eeprom3.dev_attr.attr, &sensor_dev_attr_port_name.dev_attr.attr, + &sensor_dev_attr_qsfp_dd_chan_mon.dev_attr.attr, + &sensor_dev_attr_qsfp_dom_bulk.dev_attr.attr, + &sensor_dev_attr_tempe.dev_attr.attr, + &sensor_dev_attr_volte.dev_attr.attr, + &sensor_dev_attr_rx_los.dev_attr.attr, + &sensor_dev_attr_tx_fault.dev_attr.attr, + &sensor_dev_attr_disable.dev_attr.attr, NULL }; @@ -70,10 +142,27 @@ static ssize_t get_oom_value(struct device *dev, struct device_attribute *da, ch int value = 0; mutex_lock(&data->lock); - if (attr->index == OOM_LP_MODE) - value = data->lp_mode; - else - value = data->temp; + switch (attr->index) { + case OOM_LP_MODE: + value = data->lp_mode; + break; + case OOM_TEMP: + value = data->temp; + break; + case OOM_CHAN_RX_LOS: + value = data->rx_los; + break; + case OOM_CHAN_TX_FAULT: + value = data->tx_fault; + break; + case OOM_CHAN_DISABLE: + value = data->disable; + break; + default: + value = data->temp; + break; + + } mutex_unlock(&data->lock); return sprintf(buf, "%d", value); @@ -93,10 +182,38 @@ static ssize_t set_oom_value(struct device *dev, struct device_attribute *da, co } mutex_lock(&data->lock); - if (attr->index == OOM_LP_MODE) - data->lp_mode = value; - else - data->temp = value; + switch (attr->index) { + case OOM_LP_MODE: + data->lp_mode = value; + break; + case OOM_TEMP: + data->temp = value; + break; + case OOM_CHAN_RX_LOS: + data->rx_los = value; + if (data->eeprom1[0] == QSFP_DD_TYPE) + data->eeprom3[PAGE11_OFFSET + QSFP_DD_RX_LOS_OFFSET] = value; + if (data->eeprom1[0] == QSFP28_TYPE) + data->eeprom1[LOWER_PAGE_OFFSET + QSFP28_RX_LOS_OFFSET] = value; + break; + case OOM_CHAN_TX_FAULT: + data->tx_fault = value; + if (data->eeprom1[0] == QSFP_DD_TYPE) + data->eeprom3[PAGE11_OFFSET + QSFP_DD_TX_FAULT_OFFSET] = value; + if (data->eeprom1[0] == QSFP28_TYPE) + data->eeprom1[LOWER_PAGE_OFFSET + QSFP28_TX_FAULT_OFFSET] = value; + break; + case OOM_CHAN_DISABLE: + data->disable = value; + if (data->eeprom1[0] == QSFP_DD_TYPE) + data->eeprom3[PAGE10_OFFSET + QSFP_DD_DISABLE_OFFSET] = value; + if (data->eeprom1[0] == QSFP28_TYPE) + data->eeprom1[LOWER_PAGE_OFFSET + QSFP28_DISABLE_OFFSET] = value; + break; + default: + data->temp = value; + break; + } mutex_unlock(&data->lock); return count; @@ -123,8 +240,8 @@ static ssize_t set_oom_info1(struct device *dev, struct device_attribute *da, co unsigned int val; mutex_lock(&data->lock); - memset(data->eeprom1, 0xFF, EEPROM_DATA_SIZE); - memset(str, 0x0, 3); + memzero_explicit(data->eeprom1, EEPROM_DATA_SIZE); + memzero_explicit(str, sizeof(str)); if (strlen(buf) >= EEPROM_DATA_SIZE) { for (i=0; i < strlen(buf) ; i++) { @@ -170,8 +287,8 @@ static ssize_t set_oom_info2(struct device *dev, struct device_attribute *da, co unsigned int val; mutex_lock(&data->lock); - memset(data->eeprom2, 0xFF, EEPROM_DATA_SIZE); - memset(str, 0x0, 3); + memzero_explicit(data->eeprom2, EEPROM_DATA_SIZE); + memzero_explicit(str, sizeof(str)); if (strlen(buf) >= EEPROM_DATA_SIZE) { for (i = 0; i < strlen(buf) ; i++) { @@ -195,6 +312,52 @@ static ssize_t set_oom_info2(struct device *dev, struct device_attribute *da, co return size; } +static ssize_t get_oom_info3(struct device *dev, struct device_attribute *da, char *buf) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + + mutex_lock(&data->lock); + memcpy(buf, data->eeprom3, EEPROM3_DATA_SIZE); + mutex_unlock(&data->lock); + + return EEPROM3_DATA_SIZE; +} + +static ssize_t set_oom_info3(struct device *dev, struct device_attribute *da, const char *buf, size_t size) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + int i = 0, j = 0, k = 0; + unsigned char str[3]; + unsigned int val; + + mutex_lock(&data->lock); + memzero_explicit(data->eeprom3, EEPROM3_DATA_SIZE); + memzero_explicit(str, sizeof(str)); + + if (strlen(buf) >= EEPROM3_DATA_SIZE) { + for (i = 0; i < strlen(buf) ; i++) { + for (j = 0; j < 2; j++) { + str[j] = buf[i + j]; + } + + sscanf(str, "%x", &val); + + i = j + i - 1; + if (k >= EEPROM3_DATA_SIZE) + break; + + data->eeprom3[k]=(unsigned char)val; + k++; + } + } + + mutex_unlock(&data->lock); + + return size; +} + static ssize_t get_port_name(struct device *dev, struct device_attribute *da, char *buf) { struct i2c_client *client = to_i2c_client(dev); @@ -224,6 +387,191 @@ static ssize_t set_port_name(struct device *dev, struct device_attribute *da, co return count; } +static ssize_t get_t_v_e(struct device *dev, struct device_attribute *da, char *buf) +{ + struct sensor_device_attribute *attr = to_sensor_dev_attr(da); + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + + mutex_lock(&data->lock); + if (attr->index == OOM_TEMP_E) + memcpy(buf, data->tempe, TEMP_DATA_SIZE); + else + memcpy(buf, data->volte, VOLT_DATA_SIZE); + mutex_unlock(&data->lock); + + return (attr->index == OOM_TEMP_E) ? TEMP_DATA_SIZE : VOLT_DATA_SIZE; +} + +static ssize_t set_t_v_e(struct device *dev, struct device_attribute *da, const char *buf, size_t size) +{ + struct sensor_device_attribute *attr = to_sensor_dev_attr(da); + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + int i = 0, j = 0, k = 0; + unsigned char str[3]; + unsigned int val; + + mutex_lock(&data->lock); + if (attr->index == OOM_TEMP_E) { + memzero_explicit(data->tempe, TEMP_DATA_SIZE); + memzero_explicit(str, sizeof(str)); + + if (strlen(buf) >= TEMP_DATA_SIZE) { + for (i = 0; i < strlen(buf) ; i++) { + for (j = 0; j < 2; j++) { + str[j] = buf[i + j]; + } + + sscanf(str, "%x", &val); + + i = j + i - 1; + if (k >= TEMP_DATA_SIZE) + break; + + data->tempe[k]=(unsigned char)val; + + if (k == 0) + data->temp = data->tempe[k]; + k++; + } + } + + if (data->eeprom1[0] == QSFP_DD_TYPE) + memcpy(&data->eeprom1[LOWER_PAGE_OFFSET + QSFP_DD_TEMP_OFFSET], data->tempe, TEMP_DATA_SIZE); + } + else { + memzero_explicit(data->volte, VOLT_DATA_SIZE); + memzero_explicit(str, sizeof(str)); + + if (strlen(buf) >= VOLT_DATA_SIZE) { + for (i = 0; i < strlen(buf) ; i++) { + for (j = 0; j < 2; j++) { + str[j] = buf[i + j]; + } + + sscanf(str, "%x", &val); + + i = j + i - 1; + if (k >= VOLT_DATA_SIZE) + break; + + data->volte[k]=(unsigned char)val; + k++; + } + } + + if (data->eeprom1[0] == QSFP_DD_TYPE) + memcpy(&data->eeprom1[LOWER_PAGE_OFFSET + QSFP_DD_VOLT_OFFSET], data->volte, VOLT_DATA_SIZE); + } + + mutex_unlock(&data->lock); + + return size; +} + +static ssize_t get_qsfp_dd_chan_mon(struct device *dev, struct device_attribute *da, char *buf) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + + mutex_lock(&data->lock); + memcpy(buf, data->qsfp_dd_chan_mon, QSFP_DD_CHAN_MON_DATA_SIZE); + mutex_unlock(&data->lock); + + return QSFP_DD_CHAN_MON_DATA_SIZE; +} + +static ssize_t set_qsfp_dd_chan_mon(struct device *dev, struct device_attribute *da, const char *buf, size_t size) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + int i = 0, j = 0, k = 0; + unsigned char str[3]; + unsigned int val; + + mutex_lock(&data->lock); + memzero_explicit(data->qsfp_dd_chan_mon, QSFP_DD_CHAN_MON_DATA_SIZE); + memzero_explicit(str, sizeof(str)); + + if (strlen(buf) >= QSFP_DD_CHAN_MON_DATA_SIZE) { + for (i=0; i < strlen(buf) ; i++) { + for (j = 0; j < 2; j++) { + str[j] = buf[i + j]; + } + + sscanf(str, "%x", &val); + + i = j + i - 1; + + if (k >= QSFP_DD_CHAN_MON_DATA_SIZE) + break; + + data->qsfp_dd_chan_mon[k] = (unsigned char)val; + k++; + } + } + + if (data->eeprom1[0] == QSFP_DD_TYPE) + memcpy(&data->eeprom3[PAGE11_OFFSET + QSFP_DD_CHAN_MON_OFFSET], data->qsfp_dd_chan_mon, QSFP_DD_CHAN_MON_DATA_SIZE); + + mutex_unlock(&data->lock); + + return size; +} + +static ssize_t get_qsfp_dom_bulk(struct device *dev, struct device_attribute *da, char *buf) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + + mutex_lock(&data->lock); + memcpy(buf, data->qsfp_dom_bulk, QSFP_DOM_BULK_DATA_SIZE); + mutex_unlock(&data->lock); + + return QSFP_DOM_BULK_DATA_SIZE; +} + +static ssize_t set_qsfp_dom_bulk(struct device *dev, struct device_attribute *da, const char *buf, size_t size) +{ + struct i2c_client *client = to_i2c_client(dev); + struct wistron_oom_data *data = i2c_get_clientdata(client); + int i = 0, j = 0, k = 0; + unsigned char str[3]; + unsigned int val; + + mutex_lock(&data->lock); + memzero_explicit(data->qsfp_dom_bulk, QSFP_DOM_BULK_DATA_SIZE); + memzero_explicit(str, sizeof(str)); + + if (strlen(buf) >= QSFP_DOM_BULK_DATA_SIZE) { + for (i=0; i < strlen(buf) ; i++) { + for (j = 0; j < 2; j++) { + str[j] = buf[i + j]; + } + + sscanf(str, "%x", &val); + + i = j + i - 1; + + if (k >= QSFP_DOM_BULK_DATA_SIZE) + break; + + data->qsfp_dom_bulk[k] = (unsigned char)val; + k++; + } + } + + if (data->eeprom1[0] == QSFP28_TYPE) { + memcpy(&data->eeprom1[LOWER_PAGE_OFFSET + QSFP28_DOM_BULK_DATA_OFFSET], data->qsfp_dom_bulk, QSFP_DOM_BULK_DATA_SIZE); + data->temp = data->qsfp_dom_bulk[0]; + } + + mutex_unlock(&data->lock); + + return size; +} + static const struct attribute_group wistron_oom_group = { .attrs = wistron_oom_attributes, }; diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_psu.c b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_psu.c index 1ea7764dd430..fa48e9ce5d41 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_psu.c +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_psu.c @@ -21,6 +21,7 @@ static const unsigned short normal_i2c[] = { I2C_CLIENT_END }; #define MFR_VENDOR_NAME_LENGTH 16 #define MFR_MODEL_NAME_LENGTH 16 #define MFR_SERIAL_NUM_LENGTH 32 +#define MFR_REV_LENGTH 10 /* Each client has this additional data */ struct wistron_psu_data { @@ -33,13 +34,15 @@ struct wistron_psu_data { int v_out; int i_in; int i_out; - int p_in; - int p_out; + long p_in; + long p_out; int temp_input; + int pwm; int fault; u8 mfr_id[MFR_VENDOR_NAME_LENGTH]; u8 mfr_model[MFR_MODEL_NAME_LENGTH]; u8 mfr_serial[MFR_SERIAL_NUM_LENGTH]; + u8 mfr_rev[MFR_REV_LENGTH]; }; enum psu_index { @@ -57,10 +60,12 @@ enum wistron_psu_sysfs_attributes { PSU_P_IN, PSU_P_OUT, PSU_TEMP1_INPUT, + PSU_PWM, PSU_FAULT, PSU_MFR_ID, PSU_MFR_MODEL, PSU_MFR_SERIAL, + PSU_MFR_REV, }; /* sysfs attributes for hwmon */ @@ -73,10 +78,12 @@ static SENSOR_DEVICE_ATTR(curr2_input, S_IWUSR | S_IRUGO, get_value, set_valu static SENSOR_DEVICE_ATTR(power1_input, S_IWUSR | S_IRUGO, get_value, set_value, PSU_P_IN); static SENSOR_DEVICE_ATTR(power2_input, S_IWUSR | S_IRUGO, get_value, set_value, PSU_P_OUT); static SENSOR_DEVICE_ATTR(temp1_input, S_IWUSR | S_IRUGO, get_value, set_value, PSU_TEMP1_INPUT); +static SENSOR_DEVICE_ATTR(pwm, S_IWUSR | S_IRUGO, get_value, set_value, PSU_PWM); static SENSOR_DEVICE_ATTR(fault, S_IWUSR | S_IRUGO, get_value, set_value, PSU_FAULT); static SENSOR_DEVICE_ATTR(vendor, S_IWUSR | S_IRUGO, get_value, set_value, PSU_MFR_ID); static SENSOR_DEVICE_ATTR(model, S_IWUSR | S_IRUGO, get_value, set_value, PSU_MFR_MODEL); static SENSOR_DEVICE_ATTR(sn, S_IWUSR | S_IRUGO, get_value, set_value, PSU_MFR_SERIAL); +static SENSOR_DEVICE_ATTR(rev, S_IWUSR | S_IRUGO, get_value, set_value, PSU_MFR_REV); static struct attribute *wistron_psu_attributes[] = { @@ -89,10 +96,12 @@ static struct attribute *wistron_psu_attributes[] = { &sensor_dev_attr_power1_input.dev_attr.attr, &sensor_dev_attr_power2_input.dev_attr.attr, &sensor_dev_attr_temp1_input.dev_attr.attr, + &sensor_dev_attr_pwm.dev_attr.attr, &sensor_dev_attr_fault.dev_attr.attr, &sensor_dev_attr_vendor.dev_attr.attr, &sensor_dev_attr_model.dev_attr.attr, &sensor_dev_attr_sn.dev_attr.attr, + &sensor_dev_attr_rev.dev_attr.attr, NULL }; @@ -162,14 +171,17 @@ static ssize_t get_value(struct device *dev, struct device_attribute *da, char * ret_count = sprintf(buf, "%d", data->i_out); break; case PSU_P_IN: - ret_count = sprintf(buf, "%d", data->p_in); + ret_count = sprintf(buf, "%ld", data->p_in); break; case PSU_P_OUT: - ret_count = sprintf(buf, "%d", data->p_out); + ret_count = sprintf(buf, "%ld", data->p_out); break; case PSU_TEMP1_INPUT: ret_count = sprintf(buf, "%d", data->temp_input); break; + case PSU_PWM: + ret_count = sprintf(buf, "%d", data->pwm); + break; case PSU_FAULT: ret_count = sprintf(buf, "%d", data->fault); break; @@ -182,6 +194,9 @@ static ssize_t get_value(struct device *dev, struct device_attribute *da, char * case PSU_MFR_SERIAL: ret_count = sprintf(buf, "%s", data->mfr_serial); break; + case PSU_MFR_REV: + ret_count = sprintf(buf, "%s", data->mfr_rev); + break; default: break; } @@ -222,12 +237,12 @@ static ssize_t set_value(struct device *dev, struct device_attribute *da, const goto exit_err; break; case PSU_P_IN: - error = kstrtoint(buf, 10, &data->p_in); + error = kstrtol(buf, 10, &data->p_in); if (error) goto exit_err; break; case PSU_P_OUT: - error = kstrtoint(buf, 10, &data->p_out); + error = kstrtol(buf, 10, &data->p_out); if (error) goto exit_err; break; @@ -236,23 +251,32 @@ static ssize_t set_value(struct device *dev, struct device_attribute *da, const if (error) goto exit_err; break; + case PSU_PWM: + error = kstrtoint(buf, 10, &data->pwm); + if (error) + goto exit_err; + break; case PSU_FAULT: error = kstrtoint(buf, 10, &data->fault); if (error) goto exit_err; break; case PSU_MFR_ID: - memset(&data->mfr_id, 0x0, sizeof(data->mfr_id)); + memzero_explicit(&data->mfr_id, sizeof(data->mfr_id)); strncpy(data->mfr_id, buf, sizeof(data->mfr_id) - 1); break; case PSU_MFR_MODEL: - memset(&data->mfr_model, 0x0, sizeof(data->mfr_model)); + memzero_explicit(&data->mfr_model, sizeof(data->mfr_model)); strncpy(data->mfr_model, buf, sizeof(data->mfr_model) - 1); break; case PSU_MFR_SERIAL: - memset(&data->mfr_serial, 0x0, sizeof(data->mfr_serial)); + memzero_explicit(&data->mfr_serial, sizeof(data->mfr_serial)); strncpy(data->mfr_serial, buf, sizeof(data->mfr_serial) - 1); break; + case PSU_MFR_REV: + memzero_explicit(&data->mfr_rev, sizeof(data->mfr_rev)); + strncpy(data->mfr_rev, buf, sizeof(data->mfr_rev) - 1); + break; default: break; } diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_syseeprom.c b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_syseeprom.c index a281df719677..578aa3c1d5ef 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_syseeprom.c +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/modules/wistron_6512_32r_syseeprom.c @@ -43,8 +43,8 @@ static ssize_t set_syseeprom(struct device *dev, struct device_attribute *da, co unsigned int val; mutex_lock(&data->lock); - memset(data->eeprom, 0xFF, EEPROM_DATA_SIZE); - memset(str, 0x0, 3); + memzero_explicit(data->eeprom, EEPROM_DATA_SIZE); + memzero_explicit(str, sizeof(str)); if (strlen(buf) >= EEPROM_DATA_SIZE) { for (i = 0; i < strlen(buf) ; i++) { diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-firmware_ver.service b/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-firmware_ver.service new file mode 100644 index 000000000000..42a4d4e50f61 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-firmware_ver.service @@ -0,0 +1,12 @@ +[Unit] +Description=Wistron 6512-32R Platform firmware version service +After=platform-modules-6512-32r.service +DefaultDependencies=no + +[Service] +Type=oneshot +ExecStart=/usr/local/bin/platform_firmware_version +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-platform.service b/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-platform.service index 1842d036cda4..ab8effcc4096 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-platform.service +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/service/6512-32r-platform.service @@ -1,7 +1,6 @@ [Unit] Description=Wistron 6512-32R Platform Monitoring service -Before=pmon.service -After=sysinit.target +After=platform-modules-6512-32r.service DefaultDependencies=no [Service] diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/setup.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/setup.py index 3c2888412e90..3b92de8c129c 100644 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/setup.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/setup.py @@ -1,7 +1,5 @@ from setuptools import setup -DEVICE_NAME = 'wistron' -HW_SKU = 'x86_64-wistron_6512_32r-r0' setup( name='sonic-platform', @@ -16,9 +14,8 @@ packages=[ 'sonic_platform', ], - package_dir={ - 'sonic_platform': '../../../../device/{}/{}/sonic_platform'.format(DEVICE_NAME, HW_SKU)}, - classifiers=[ + package_dir={'sonic_platform': 'sonic_platform'}, + classifiers=[ 'Development Status :: 3 - Alpha', 'Environment :: Plugins', 'Intended Audience :: Developers', diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/__init__.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/__init__.py old mode 100644 new mode 100755 similarity index 70% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/__init__.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/__init__.py index 29dfc92139ef..cc568450a400 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/__init__.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/__init__.py @@ -1,2 +1,2 @@ -__all__ = ['chassis', 'eeprom', 'platform', 'psu', 'sfp', 'thermal', 'fan', 'watchdog'] +__all__ = ['chassis', 'eeprom', 'platform', 'psu', 'sfp', 'thermal', 'fan', 'component', 'watchdog'] from . import platform diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/chassis.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/chassis.py old mode 100644 new mode 100755 similarity index 55% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/chassis.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/chassis.py index 232ca0ca5fe3..d27b26b98f62 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/chassis.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/chassis.py @@ -8,7 +8,6 @@ ############################################################################# try: import sys - import os import time import subprocess from sonic_platform_base.chassis_base import ChassisBase @@ -16,16 +15,19 @@ raise ImportError(str(e) + "- required module not found") NUM_FAN = 14 +NUM_FANTRAY = 7 NUM_PSU = 2 NUM_THERMAL = 8 NUM_SFP = 32 +NUM_COMPONENT = 6 HOST_REBOOT_CAUSE_PATH = "/host/reboot-cause/" PMON_REBOOT_CAUSE_PATH = "/usr/share/sonic/platform/api_files/reboot-cause/" REBOOT_CAUSE_FILE = "reboot-cause.txt" PREV_REBOOT_CAUSE_FILE = "previous-reboot-cause.txt" -HOST_CHK_CMD = "docker > /dev/null 2>&1" -GET_HWSKU_CMD = "sonic-cfggen -d -v DEVICE_METADATA.localhost.hwsku" -GET_PLATFORM_CMD = "sonic-cfggen -d -v DEVICE_METADATA.localhost.platform" +HOST_CHK_CMD = ["docker"] +GET_HWSKU_CMD = ["sonic-cfggen", "-d", "-v", "DEVICE_METADATA.localhost.hwsku"] +GET_PLATFORM_CMD = ["sonic-cfggen", "-d", "-v", "DEVICE_METADATA.localhost.platform"] +EEPROM_BOOT_TIME_INIT_DONE='/tmp/eeprom_init_done' class Chassis(ChassisBase): """Platform-specific Chassis class""" @@ -43,6 +45,7 @@ def __init__(self): self.__initialize_fan() self.__initialize_psu() self.__initialize_thermals() + self.__initialize_components() self.__initialize_sfp() self.__initialize_eeprom() @@ -54,10 +57,11 @@ def __initialize_sfp(self): def __initialize_fan(self): - from sonic_platform.fan import Fan - for fan_index in range(0, NUM_FAN): - fan = Fan(fan_index) - self._fan_list.append(fan) + from sonic_platform.fan_drawer import FanDrawer + for fan_index in range(0, NUM_FANTRAY): + fandrawer = FanDrawer(fan_index) + self._fan_drawer_list.append(fandrawer) + self._fan_list.extend(fandrawer._fan_list) def __initialize_psu(self): from sonic_platform.psu import Psu @@ -75,8 +79,14 @@ def __initialize_eeprom(self): from sonic_platform.eeprom import Tlv self._eeprom = Tlv() + def __initialize_components(self): + from sonic_platform.component import Component + for index in range(0, NUM_COMPONENT): + component = Component(index) + self._component_list.append(component) + def __is_host(self): - return os.system(HOST_CHK_CMD) == 0 + return subprocess.call(HOST_CHK_CMD) == 0 def __read_txt_file(self, file_path): try: @@ -96,7 +106,7 @@ def get_base_mac(self): """ return self._eeprom.get_mac() - def get_serial_number(self): + def get_serial(self): """ Retrieves the hardware serial number for the chassis Returns: @@ -141,15 +151,28 @@ def get_reboot_cause(self): return (reboot_cause, description) def _get_sku_name(self): - p = subprocess.Popen(GET_HWSKU_CMD, shell=True, stdout=subprocess.PIPE) + p = subprocess.Popen(GET_HWSKU_CMD, stdout=subprocess.PIPE) out, err = p.communicate() return out.decode().rstrip('\n') def _get_platform_name(self): - p = subprocess.Popen(GET_PLATFORM_CMD, shell=True, stdout=subprocess.PIPE) + p = subprocess.Popen(GET_PLATFORM_CMD, stdout=subprocess.PIPE) out, err = p.communicate() return out.decode().rstrip('\n') + def get_watchdog(self): + """ + Retreives hardware watchdog device on this chassis + Returns: + An object derived from WatchdogBase representing the hardware + watchdog device + """ + if self._watchdog is None: + from sonic_platform.watchdog import Watchdog + self._watchdog = Watchdog() + + return self._watchdog + def get_name(self): """ Retrieves the name of the device @@ -171,10 +194,22 @@ def _get_sfp_presence(self): port_pres = {} for port in range(0, NUM_SFP): sfp = self._sfp_list[port] - port_pres[port] = sfp.get_presence() + port_pres[port] = 1 if sfp.get_presence() else 0 return port_pres + def _read_sfp_eeprom_to_buffer(self, port): + sfp = self._sfp_list[port] + #if os.path.exists(EEPROM_BOOT_TIME_INIT_DONE): + # return sfp.read_eeprom_buffer() + c = sfp._read_eeprom_specific_bytes(0,1) + return c != ['ff'] and c != ['00'] + + def _clear_sfp_eeprom_buffer(self, port): + sfp = self._sfp_list[port] + return sfp.clear_eeprom_buffer() + + def get_change_event(self, timeout=0): port_dict = {} ret_dict = {'sfp': port_dict} @@ -201,12 +236,19 @@ def get_change_event(self, timeout=0): if cur_presence[port] != self._transceiver_presence[port]: change_event = True if cur_presence[port] == 1: - port_dict[port] = '1' + if self._read_sfp_eeprom_to_buffer(port): + port_dict[port] = '1' + self._transceiver_presence[port] = 1 + else: + cur_presence[port] = 0 + self._transceiver_presence[port] = 0 else: port_dict[port] = '0' + self._clear_sfp_eeprom_buffer(port) + self._transceiver_presence[port] = 0 - self._transceiver_presence = cur_presence - if change_event == True: + #self._transceiver_presence = cur_presence + if change_event is True: break if not forever: @@ -220,3 +262,96 @@ def get_change_event(self, timeout=0): sfp.reinit() return True, ret_dict + + def is_modular_chassis(self): + """ + Retrieves whether the sonic instance is part of modular chassis + Returns: + A bool value, should return False by default or for fixed-platforms. + Should return True for supervisor-cards, line-cards etc running as part + of modular-chassis. + """ + return False + + def initizalize_system_led(self): + self.system_led = "" + return True + + def set_status_led(self, color): + """ + Sets the state of the system LED + + Args: + color: A string representing the color with which to set the + system LED + + Returns: + bool: True if system LED state is set successfully, False if not + """ + self.system_led = color + return True + + def get_status_led(self): + """ + Gets the state of the system LED + + Returns: + A string, one of the valid LED color strings which could be vendor + specified. + """ + return self.system_led + + + def get_presence(self): + """ + Retrieves the presence of the Chassis + Returns: + bool: True if Chassis is present, False if not + """ + return True + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return self._eeprom.get_model() + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return True + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. If the agent cannot determine the parent-relative position + for some reason, or if the associated value of entPhysicalContainedIn is '0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device or -1 if cannot determine the position + """ + return -1 + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return False + + def get_revision(self): + """ + Retrieves the hardware revision of the device + + Returns: + string: Revision value of device + """ + + return '0' + + def get_thermal_manager(self): + raise NotImplementedError diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/component.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/component.py new file mode 100755 index 000000000000..40a0ba551be2 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/component.py @@ -0,0 +1,269 @@ +#!/usr/bin/env python + +import subprocess +from shlex import split +from collections import namedtuple +from functools import reduce + + +try: + from sonic_platform_base.component_base import ComponentBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +CPLD_ADDR_MAPPING = { + "CPLD1": "0-0006", + "CPLD2": "0-0007", +} + +FPGA_ADDR_MAPPING = { + "MB_FPGA": "0-0030", +} + +proc_output = namedtuple('proc_output', 'stdout stderr') +GET_CPU_FPGA_VER_CMD = ["i2cget", "-f", "-y", "0", "0x10", "0x0"] +#GET_BMC_VER_CMD= "ipmitool mc info | grep 'Firmware Revision' | awk '{printf $4}'" +SYSFS_PATH = "/sys/bus/i2c/devices/" +BIOS_VERSION_PATH = "/sys/class/dmi/id/bios_version" +COMPONENT_LIST= [ + ("BIOS", "Basic Input/Output System"), + ("CPLD1", "CPLD 1"), + ("CPLD2", "CPLD 2"), + ("MB_FPGA", "MB FPGA"), + ("CPU_FPGA", "CPU FPGA"), + ("BMC", "baseboard management controller") +] + +class Component(ComponentBase): + """Platform-specific Component class""" + + DEVICE_TYPE = "component" + + def __init__(self, component_index=0): + ComponentBase.__init__(self) + self.index = component_index + self.name = self.get_name() + + def pipeline(self, starter_command, *commands): + if not commands: + try: + starter_command, *commands = starter_command.split('|') + except AttributeError: + pass + starter_command = self._parse(starter_command) + starter = subprocess.Popen(starter_command, stdout=subprocess.PIPE) + last_proc = reduce(self._create_pipe, map(self._parse, commands), starter) + return proc_output(*last_proc.communicate()) + + def _create_pipe(self, previous, command): + proc = subprocess.Popen(command, stdin=previous.stdout, stdout=subprocess.PIPE) + previous.stdout.close() + return proc + + def _parse(self, cmd): + try: + return split(cmd) + except Exception: + return cmd + + def __read_txt_file(self, file_path): + try: + with open(file_path, 'r') as fd: + data = fd.read() + return data.strip() + except IOError: + pass + return "" + + def __get_bios_version(self): + # Retrieves the BIOS firmware version + try: + with open(BIOS_VERSION_PATH, 'r') as fd: + bios_version = fd.read() + return bios_version.strip() + except Exception as e: + return None + + def __get_cpld_version(self): + # Retrieves the CPLD firmware version + cpld_version = dict() + for cpld_name in CPLD_ADDR_MAPPING: + try: + cpld_path = "{}{}{}".format(SYSFS_PATH, CPLD_ADDR_MAPPING[cpld_name], '/version') + cpld_version_raw= int(self.__read_txt_file(cpld_path), 10) + cpld_version[cpld_name] = "{} {}".format("MP" if (cpld_version_raw & 0x10) else "Proto", cpld_version_raw & 0xf) + except Exception as e: + print('Get exception when read cpld') + cpld_version[cpld_name] = 'None' + + return cpld_version + + def __get_cpu_fpga_ver(self): + try: + p = subprocess.Popen(GET_CPU_FPGA_VER_CMD, stdout=subprocess.PIPE) + out, err = p.communicate() + return out.decode().rstrip('\n') + except Exception as e: + print('Get exception when read cpu fpga') + return 'None' + + def __get_bmc_version(self): + try: + #GET_BMC_VER_CMD + out, err = self.pipeline("ipmitool mc info", "grep 'Firmware Revision'", "awk '{printf $4}'") + return out.decode().rstrip('\n') + except Exception as e: + print('Get exception when read bmc') + return 'None' + + def __get_fpga_version(self): + # Retrieves the fpga firmware version + fpga_version = dict() + try: + fpga_path = "{}{}{}".format(SYSFS_PATH, FPGA_ADDR_MAPPING['MB_FPGA'], '/version') + fpga_version_raw= int(self.__read_txt_file(fpga_path), 10) + fpga_version["MB_FPGA"] = "{} {}.{}".format("Formal" if (fpga_version_raw & 0x80) else "Test", ((fpga_version_raw & 0x70) >> 4), fpga_version_raw & 0xf) + except Exception as e: + print('Get exception when read fpga') + fpga_version["MB_FPGA"] = 'None' + + fpga_version_raw= int(self.__get_cpu_fpga_ver(), 16) + fpga_version["CPU_FPGA"] = "{} {}.{}".format("Formal" if (fpga_version_raw & 0x80) else "Test", ((fpga_version_raw & 0x70) >> 4), fpga_version_raw & 0xf) + + return fpga_version + + def get_name(self): + """ + Retrieves the name of the component + Returns: + A string containing the name of the component + """ + return COMPONENT_LIST[self.index][0] + + def get_description(self): + """ + Retrieves the description of the component + Returns: + A string containing the description of the component + """ + return COMPONENT_LIST[self.index][1] + + + def get_firmware_version(self): + """ + Retrieves the firmware version of module + Returns: + string: The firmware versions of the module + """ + fw_version = None + + if self.name == "BIOS": + fw_version = self.__get_bios_version() + elif "CPLD" in self.name: + cpld_version = self.__get_cpld_version() + fw_version = cpld_version.get(self.name) + elif "FPGA" in self.name: + fpga_version = self.__get_fpga_version() + fw_version = fpga_version.get(self.name) + elif "BMC" in self.name: + fw_version = self.__get_bmc_version() + + return fw_version + + def install_firmware(self, image_path): + """ + Install firmware to module + Args: + image_path: A string, path to firmware image + Returns: + A boolean, True if install successfully, False if not + """ + raise NotImplementedError + + def get_presence(self): + """ + Retrieves the presence of the FAN + Returns: + bool: True if FAN is present, False if not + """ + return True + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return 'N/A' + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return 'N/A' + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return True + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return -1 + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return False + + def get_available_firmware_version(self, image_path): + """ + Retrieves the available firmware version of the component + Note: the firmware version will be read from image + Args: + image_path: A string, path to firmware image + Returns: + A string containing the available firmware version of the component + """ + return "N/A" + + def get_firmware_update_notification(self, image_path): + """ + Retrieves a notification on what should be done in order to complete + the component firmware update + Args: + image_path: A string, path to firmware image + Returns: + A string containing the component firmware update notification if required. + By default 'None' value will be used, which indicates that no actions are required + """ + return "None" + + def update_firmware(self, image_path): + """ + Updates firmware of the component + This API performs firmware update: it assumes firmware installation and loading in a single call. + In case platform component requires some extra steps (apart from calling Low Level Utility) + to load the installed firmware (e.g, reboot, power cycle, etc.) - this will be done automatically by API + Args: + image_path: A string, path to firmware image + Raises: + RuntimeError: update failed + """ + return False diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/eeprom.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/eeprom.py old mode 100644 new mode 100755 similarity index 81% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/eeprom.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/eeprom.py index 9d01b1f866b8..7db38ead60a5 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/eeprom.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/eeprom.py @@ -41,12 +41,19 @@ def __parse_output(self, decode_output): for line in lines: try: match = re.search( - '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+)', line) - if match is not None: + '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+[\s]+[\S]+)', line) + if match is not None and match.group(1) == '0x25': idx = match.group(1) value = match.group(3).rstrip('\0') + _eeprom_info_dict[idx] = value + else: + match = re.search( + '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+)', line) + if match is not None: + idx = match.group(1) + value = match.group(3).rstrip('\0') + _eeprom_info_dict[idx] = value - _eeprom_info_dict[idx] = value except BaseException: pass return _eeprom_info_dict @@ -70,7 +77,7 @@ def _load_eeprom(self): if not os.path.exists(CACHE_ROOT): try: os.makedirs(CACHE_ROOT) - except OSError: + except Exception: pass # @@ -79,7 +86,7 @@ def _load_eeprom(self): # try: self.set_cache_name(os.path.join(CACHE_ROOT, CACHE_FILE)) - except OSError: + except Exception: pass e = self.read_eeprom() @@ -90,6 +97,7 @@ def _load_eeprom(self): self.update_cache(e) except Exception: pass + self.decode_eeprom(e) decode_output = sys.stdout.getvalue() sys.stdout = original_stdout @@ -108,3 +116,6 @@ def get_serial(self): def get_mac(self): return self._eeprom.get('0x24', "Undefined.") + + def get_model(self): + return self._eeprom.get('0x21', "Undefined.") diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan.py new file mode 100755 index 000000000000..e6e2ff599524 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan.py @@ -0,0 +1,263 @@ +############################################################################# +# +# Module contains an implementation of SONiC Platform Base API and +# provides the fan status which are available in the platform +# +############################################################################# + + +import os.path + +try: + from sonic_platform_base.fan_base import FanBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +SPEED_TOLERANCE = 15 +SYSFS_PATH = "/sys/bus/i2c/devices/0-0044" +SYSFS_PSU_DIR = ["/sys/bus/i2c/devices/0-005a", + "/sys/bus/i2c/devices/0-0059"] + +FAN_NAME_LIST = ["FAN-1F", "FAN-1R", "FAN-2F", "FAN-2R", + "FAN-3F", "FAN-3R", "FAN-4F", "FAN-4R", + "FAN-5F", "FAN-5R", "FAN-6F", "FAN-6R", + "FAN-7F", "FAN-7R"] + +class Fan(FanBase): + """Platform-specific Fan class""" + + def __init__(self, fan_tray_index, fan_index=0, is_psu_fan=False, psu_index=0): + self.fan_index = fan_index + self.fan_tray_index = fan_tray_index + self.is_psu_fan = is_psu_fan + + if self.is_psu_fan: + self.psu_index = psu_index + + FanBase.__init__(self) + + def __search_hwmon_dir_name(self, directory): + try: + dirs = os.listdir(directory) + for file in dirs: + if file.startswith("hwmon"): + return file + except IOError: + pass + return '' + + def __read_txt_file(self, file_path): + try: + with open(file_path, 'r') as fd: + data = fd.read() + return data.strip() + except IOError: + pass + return None + + def __write_txt_file(self, file_path, data): + try: + with open(file_path, 'w') as fd: + fd.write(data) + except IOError: + pass + return None + + def get_direction(self): + """ + Retrieves the direction of fan + Returns: + A string, either FAN_DIRECTION_INTAKE or FAN_DIRECTION_EXHAUST + depending on fan direction + """ + direction = 0 + if self.is_psu_fan: + # psu fan direction should be the same as fan tray + path= "{}/fan1_direction".format(SYSFS_PATH) + direction=self.__read_txt_file(path) + if direction is None: + return self.FAN_DIRECTION_EXHAUST + elif self.get_presence(): + path= "{}/fan{}_direction".format(SYSFS_PATH, self.fan_tray_index + 1) + direction=self.__read_txt_file(path) + if direction is None: + return self.FAN_DIRECTION_EXHAUST + + return self.FAN_DIRECTION_EXHAUST if int(direction) == 0 else self.FAN_DIRECTION_INTAKE + + + def get_speed(self): + """ + Retrieves the speed of fan as a percentage of full speed + Returns: + An integer, the percentage of full fan speed, in the range 0 (off) + to 100 (full speed) + + """ + speed = 0 + if self.is_psu_fan: + fan_path="{}/pwm".format(SYSFS_PSU_DIR[self.psu_index]) + speed = self.__read_txt_file(fan_path) + if speed is not None: + return int(speed) + else: + return 0 + elif self.get_presence(): + path= "{}/pwm".format(SYSFS_PATH) + speed=self.__read_txt_file(path) + if speed is None: + return 0 + + return int(speed) + + def get_target_speed(self): + """ + Retrieves the target (expected) speed of the fan + Returns: + An integer, the percentage of full fan speed, in the range 0 (off) + to 100 (full speed) + + Note: + speed_pc = pwm_target/255*100 + + 0 : when PWM mode is use + pwm : when pwm mode is not use + """ + return self.get_speed() + + def get_speed_tolerance(self): + """ + Retrieves the speed tolerance of the fan + Returns: + An integer, the percentage of variance from target speed which is + considered tolerable + """ + return SPEED_TOLERANCE + + def set_speed(self, speed): + """ + Sets the fan speed + Args: + speed: An integer, the percentage of full fan speed to set fan to, + in the range 0 (off) to 100 (full speed) + Returns: + A boolean, True if speed is set successfully, False if not + + """ + + return False + + def set_status_led(self, color): + """ + Sets the state of the fan module status LED + Args: + color: A string representing the color with which to set the + fan module status LED + Returns: + bool: True if status LED state is set successfully, False if not + """ + return False #Not supported + + def get_status_led(self): + """ + Gets the state of the fan status LED + Returns: + A string, one of the predefined STATUS_LED_COLOR_* strings above + """ + status=self.get_presence() + if status is None: + return self.STATUS_LED_COLOR_OFF + + return { + 1: self.STATUS_LED_COLOR_GREEN, + 0: self.STATUS_LED_COLOR_RED + }.get(status, self.STATUS_LED_COLOR_OFF) + + def get_name(self): + """ + Retrieves the name of the device + Returns: + string: The name of the device + """ + + fan_name = FAN_NAME_LIST[self.fan_tray_index*2 + self.fan_index] \ + if not self.is_psu_fan \ + else "PSU-{} FAN-{}".format(self.psu_index+1, self.fan_index+1) + + return fan_name + + def get_presence(self): + """ + Retrieves the presence of the FAN + Returns: + bool: True if FAN is present, False if not + """ + + if self.is_psu_fan: + present_path="{}/present".format(SYSFS_PSU_DIR[self.psu_index]) + else: + present_path="{}/fan{}_present".format(SYSFS_PATH, self.fan_tray_index + 1) + + val=self.__read_txt_file(present_path) + if val is not None: + return int(val, 10)==1 + else: + return False + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + if self.is_psu_fan: + status_path = "{}/power_good".format(SYSFS_PSU_DIR[self.psu_index]) + val=self.__read_txt_file(status_path) + if val is not None: + return int(val, 10)==1 + else: + return False + else: + status=self.get_presence() + if status is None: + return False + return status + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + + return "N/A" + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return "N/A" + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return (self.fan_tray_index * 2 + self.fan_index + 1) \ + if not self.is_psu_fan else (self.psu_index + 1) + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return True if not self.is_psu_fan else False + diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan_drawer.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan_drawer.py new file mode 100644 index 000000000000..78d54f5dec25 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/fan_drawer.py @@ -0,0 +1,120 @@ +######################################################################## +# +# Module contains an implementation of SONiC Platform Base API and +# provides the Fan-Drawers' information available in the platform. +# +######################################################################## + +try: + from sonic_platform_base.fan_drawer_base import FanDrawerBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +FANS_PER_FANTRAY = 2 +MAX_FAN_WATT = 40.32 + + +class FanDrawer(FanDrawerBase): + """Platform-specific Fan class""" + + def __init__(self, fantray_index): + + FanDrawerBase.__init__(self) + # FanTray is 0-based in platforms + self.fantrayindex = fantray_index + self.__initialize_fan_drawer() + + + def __initialize_fan_drawer(self): + from sonic_platform.fan import Fan + for i in range(FANS_PER_FANTRAY): + self._fan_list.append(Fan(self.fantrayindex, i)) + + def get_name(self): + """ + Retrieves the fan drawer name + Returns: + string: The name of the device + """ + return "FanTray{}".format(self.fantrayindex+1) + + def get_presence(self): + """ + Retrieves the presence of the device + Returns: + bool: True if device is present, False if not + """ + return self._fan_list[0].get_presence() + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return self._fan_list[0].get_model() + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return self._fan_list[0].get_serial() + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return self._fan_list[0].get_status() + + def set_status_led(self, color): + """ + Sets the state of the fan drawer status LED + Args: + color: A string representing the color with which to set the + fan drawer status LED + Returns: + bool: True if status LED state is set successfully, False if not + """ + return self._fan_list[0].set_status_led(color) + def get_status_led(self): + """ + Gets the state of the fan drawer LED + + Returns: + A string, one of the predefined STATUS_LED_COLOR_* strings above + """ + return self._fan_list[0].get_status_led() + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return (self.fantrayindex+1) + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return True + + def get_maximum_consumed_power(self): + """ + Retrives the maximum power drawn by Fan Drawer + Returns: + A float, with value of the maximum consumable power of the + component. + """ + return MAX_FAN_WATT + diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/platform.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/platform.py old mode 100644 new mode 100755 similarity index 100% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/platform.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/platform.py diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/psu.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/psu.py new file mode 100755 index 000000000000..2ec59298a4d0 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/psu.py @@ -0,0 +1,324 @@ +#!/usr/bin/env python + +############################################################################# +# psuutil.py +# Platform-specific PSU status interface for SONiC +############################################################################# + +try: + from sonic_platform_base.psu_base import PsuBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +PSU_NAME_LIST = ["PSU-1", "PSU-2"] + +class Psu(PsuBase): + """Platform-specific Psu class""" + + SYSFS_PSU_DIR = ["/sys/bus/i2c/devices/0-005a", + "/sys/bus/i2c/devices/0-0059"] + + def __init__(self, psu_index): + self._fan_list = [] + self.PSU_TEMP_MAX = 85 * 1000 + self.PSU_OUTPUT_POWER_MAX = 1300 * 1000 + self.PSU_OUTPUT_VOLTAGE_MIN = 11400 + self.PSU_OUTPUT_VOLTAGE_MAX = 12600 + self.index = psu_index + PsuBase.__init__(self) + self.__initialize_fan() + + def __initialize_fan(self): + from sonic_platform.fan import Fan + for fan_index in range(0, 1): + fan = Fan(fan_index, 0, is_psu_fan=True, psu_index=self.index) + self._fan_list.append(fan) + + def __read_txt_file(self, file_path): + try: + with open(file_path, 'r') as fd: + data = fd.read() + return data.strip() + except IOError: + pass + return "" + + + def get_fan(self, index): + """ + Retrieves object representing the fan module contained in this PSU + Returns: + An object dervied from FanBase representing the fan module + contained in this PSU + """ + return self._fan_list[index] + + def get_powergood_status(self): + """ + Retrieves the powergood status of PSU + Returns: + A boolean, True if PSU has stablized its output voltages and passed all + its internal self-tests, False if not. + """ + return self.get_status() + + def set_status_led(self, color): + """ + Sets the state of the PSU status LED + Args: + color: A string representing the color with which to set the PSU status LED + Note: Only support green and off + Returns: + bool: True if status LED state is set successfully, False if not + """ + # Hardware not supported + return False + + def get_name(self): + """ + Retrieves the name of the device + Returns: + string: The name of the device + """ + return PSU_NAME_LIST[self.index] + + def get_presence(self): + """ + Retrieves the presence of the PSU + Returns: + bool: True if PSU is present, False if not + """ + attr_file ='present' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + status = 0 + try: + with open(attr_path, 'r') as psu_prs: + status = int(psu_prs.read()) + except IOError: + return False + + return status == 1 + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + attr_file = 'power_good' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + status = 0 + try: + with open(attr_path, 'r') as power_status: + status = int(power_status.read()) + except IOError: + return False + + return status == 1 + + def get_model(self): + """ + Retrieves the model number/name of a power supply unit (PSU) defined + by 1-based index + :param idx: An integer, 1-based index of the PSU of which to query model number + :return: String, denoting model number/name + """ + try: + if self.get_presence(): + attr_file = 'model' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return str(val) + except Exception as e: + return None + + def get_mfr_id(self): + """ + Retrieves the manufacturing id of a power supply unit (PSU) defined + by 1-based index + :param idx: An integer, 1-based index of the PSU of which to query mfr id + :return: String, denoting manufacturing id + """ + try: + if self.get_presence(): + attr_file = 'vendor' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return str(val) + except Exception as e: + return None + + def get_serial(self): + """ + Retrieves the serial number of a power supply unit (PSU) defined + by 1-based index + :param idx: An integer, 1-based index of the PSU of which to query serial number + :return: String, denoting serial number of the PSU unit + """ + try: + if self.get_presence(): + attr_file = 'sn' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return str(val) + except Exception as e: + return None + + def get_voltage(self): + """ + Retrieves current PSU voltage output + Returns: + A int number, the output voltage in volts. + """ + try: + if self.get_presence(): + attr_file = 'in2_input' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return float(val) / 1000.0 + except Exception as e: + return None + + def get_current(self): + """ + Retrieves present electric current supplied by PSU + Returns: + A int number, electric current in amperes + """ + try: + if self.get_presence(): + attr_file = 'curr2_input' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return float(val) / 1000.0 + except Exception as e: + return None + + def get_power(self): + """ + Retrieves current energy supplied by PSU + Returns: + A int number, the power in watts. + """ + try: + if self.get_presence(): + attr_file = 'power2_input' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return float(val) / 1000000.0 + except Exception as e: + return None + + def get_status_led(self): + """ + Gets the state of the PSU status LED + Returns: + A string, one of the predefined STATUS_LED_COLOR_* strings. + """ + # TODO + if self.get_presence(): + if self.get_powergood_status(): + return self.STATUS_LED_COLOR_GREEN + else: + return self.STATUS_LED_COLOR_RED + else: + return None + + def get_temperature(self): + """ + Retrieves current temperature reading from PSU + Returns: + A float number of current temperature in Celsius up to nearest thousandth + of one degree Celsius, e.g. 30.125 + """ + try: + if self.get_presence(): + attr_file = 'temp1_input' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + val = self.__read_txt_file(attr_path) + return float(val) / 1000.0 + except Exception as e: + return None + + def get_temperature_high_threshold(self): + """ + Retrieves the high threshold temperature of PSU + Returns: + A float number, the high threshold temperature of PSU in Celsius + up to nearest thousandth of one degree Celsius, e.g. 30.125 + """ + return float(self.PSU_TEMP_MAX/1000) + + def get_voltage_high_threshold(self): + """ + Retrieves the high threshold PSU voltage output + Returns: + A float number, the high threshold output voltage in volts, + e.g. 12.1 + """ + return float(self.PSU_OUTPUT_VOLTAGE_MAX/1000) + + def get_voltage_low_threshold(self): + """ + Retrieves the low threshold PSU voltage output + Returns: + A float number, the low threshold output voltage in volts, + e.g. 12.1 + """ + return float(self.PSU_OUTPUT_VOLTAGE_MIN/1000) + + def get_maximum_supplied_power(self): + """ + Retrieves the maximum supplied power by PSU + Returns: + A float number, the maximum power output in Watts. + e.g. 1200.1 + """ + return float(self.PSU_OUTPUT_POWER_MAX/1000) + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. If the agent cannot determine the parent-relative position + for some reason, or if the associated value of entPhysicalContainedIn is '0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device or -1 if cannot determine the position + """ + return self.index + 1 + + def is_replaceable(self): + return True + + def get_revision(self): + """ + Retrieves the hardware revision of the device + Returns: + string: Revision value of device + """ + try: + if self.get_presence(): + attr_file = 'rev' + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file + with open(attr_path, 'r') as revision: + val = revision.read() + return val.strip() + except IOError: + return None + + def get_num_fans(self): + """ + Retrieves the number of fan modules available on this PSU + + Returns: + An integer, the number of fan modules available on this PSU + """ + return len(self._fan_list) + + def get_all_fans(self): + """ + Retrieves all fan modules available on this PSU + + Returns: + A list of objects derived from FanBase representing all fan + modules available on this PSU + """ + return self._fan_list diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/sfp.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/sfp.py old mode 100644 new mode 100755 similarity index 72% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/sfp.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/sfp.py index 7664999e56b8..53ca1e970500 --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/sfp.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/sfp.py @@ -10,8 +10,14 @@ from sonic_platform_base.sonic_sfp.sff8436 import sff8436Dom from sonic_platform_base.sonic_sfp.qsfp_dd import qsfp_dd_InterfaceId from sonic_platform_base.sonic_sfp.qsfp_dd import qsfp_dd_Dom + from sonic_platform_base.sonic_sfp.sffbase import sffbase + from sonic_platform_base.sonic_sfp.sff8024 import type_abbrv_name + from sonic_platform_base.sonic_sfp.sff8024 import type_of_media_interface from sonic_py_common.logger import Logger import sys + import time + import subprocess + import os except ImportError as e: raise ImportError(str(e) + "- required module not found") @@ -133,9 +139,9 @@ QSFP_OPTION_VALUE_WIDTH = 4 QSFP_MODULE_UPPER_PAGE3_START = 384 -QSFP_MODULE_THRESHOLD_OFFSET = 128 +QSFP_MODULE_THRESHOLD_OFFSET = 0 QSFP_MODULE_THRESHOLD_WIDTH = 24 -QSFP_CHANNL_THRESHOLD_OFFSET = 176 +QSFP_CHANNL_THRESHOLD_OFFSET = 48 QSFP_CHANNL_THRESHOLD_WIDTH = 24 #definitions of the offset and width for values in DOM info eeprom @@ -149,9 +155,13 @@ QSFP_DD_RX_POWER_WIDTH = 16 QSFP_DD_TX_POWER_OFFSET = 26 QSFP_DD_TX_POWER_WIDTH = 16 +QSFP_DD_CHANNL_FLAGS_SUPPORT_OFFSET = 29 +QSFP_DD_CHANNL_FLAGS_SUPPORT_WIDTH = 2 +QSFP_DD_CHANNL_MON_SUPPORT_OFFSET = 31 +QSFP_DD_CHANNL_MON_SUPPORT_WIDTH = 2 QSFP_DD_CHANNL_MON_OFFSET = 154 QSFP_DD_CHANNL_MON_WIDTH = 48 -QSFP_DD_CHANNL_DISABLE_STATUS_OFFSET = 86 +QSFP_DD_CHANNL_DISABLE_STATUS_OFFSET = 2 QSFP_DD_CHANNL_DISABLE_STATUS_WIDTH = 1 QSFP_DD_CHANNL_RX_LOS_STATUS_OFFSET = 19 QSFP_DD_CHANNL_RX_LOS_STATUS_WIDTH = 1 @@ -193,8 +203,52 @@ QSFP_TYPE = "QSFP" QSFP_DD_TYPE = "QSFP_DD" +PAUSE_EEPROM_SERVICE_STAMP='/tmp/pause_eeprom_polling' + # Global logger class instance logger = Logger() +class ext_qsfp_dd(sffbase): + version = '1.0' + + qsfp_dd_mon_capability = { + 'Tx_bias_support': + {'offset': 1, + 'bit': 0, + 'type': 'bitvalue'}, + 'Tx_power_support': + {'offset': 1, + 'bit': 1, + 'type': 'bitvalue'}, + 'Rx_power_support': + {'offset': 1, + 'bit': 2, + 'type': 'bitvalue'}, + 'Voltage_support': + {'offset': 0, + 'bit': 1, + 'type': 'bitvalue'}, + 'Temp_support': + {'offset': 0, + 'bit': 0, + 'type': 'bitvalue'} + } + + qsfp_dd_flags_capability = { + 'tx_fault': + {'offset': 0, + 'bit': 0, + 'type': 'bitvalue'}, + 'rx_los': + {'offset': 1, + 'bit': 1, + 'type': 'bitvalue'} + } + + def parse_mon_capability(self, sn_raw_data, start_pos): + return sffbase.parse(self, self.qsfp_dd_mon_capability, sn_raw_data, start_pos) + + def parse_flags_capability(self, sn_raw_data, start_pos): + return sffbase.parse(self, self.qsfp_dd_flags_capability, sn_raw_data, start_pos) class Sfp(SfpBase): """Platform-specific Sfp class""" @@ -243,19 +297,24 @@ class Sfp(SfpBase): RESET_17_32_PATH = "/sys/bus/i2c/devices/0-0007/port{}_reset" PRS_1_16_PATH = "/sys/bus/i2c/devices/0-0006/port{}_present" PRS_17_32_PATH = "/sys/bus/i2c/devices/0-0007/port{}_present" + LPMODE_1_16_PATH = "/sys/bus/i2c/devices/0-0006/port{}_lpmode" + LPMODE_17_32_PATH = "/sys/bus/i2c/devices/0-0007/port{}_lpmode" def __init__(self, sfp_index, sfp_type): # Init index self.index = sfp_index self.port_num = self.index + 1 + self.abbrv = None # Init eeprom path eeprom_path_prefix = '/sys/bus/i2c/devices/0-00' self.port_to_eeprom1_mapping = {} self.port_to_eeprom2_mapping = {} + self.port_to_eeprom3_mapping = {} for x in range(self.PORT_START, self.PORT_END + 1): self.port_to_eeprom1_mapping[x] = eeprom_path_prefix + self.port_to_i2c_mapping[x] + '/eeprom1' self.port_to_eeprom2_mapping[x] = eeprom_path_prefix + self.port_to_i2c_mapping[x] + '/eeprom2' + self.port_to_eeprom3_mapping[x] = eeprom_path_prefix + self.port_to_i2c_mapping[x] + '/eeprom3' self._detect_sfp_type(sfp_type) self._dom_capability_detect() @@ -282,7 +341,153 @@ def get_presence(self): except IOError: return False logger.log_info("debug:port_ %s sfp presence is %s" % (str(self.index), str(presence))) - return presence + return presence == 1 + + def _get_eeprom_by_bmc(self): + eeprom_path_prefix = '/sys/bus/i2c/devices/0-00' + mux = int((0x70 + self.index / 8) * 2) + chan = 1 << (self.index % 8) + sel_ch_cmd = 'ipmitool raw 0x30 0x25 0x1 {} 0x0 {} 2>/dev/null'.format(mux, chan) + desel_ch_cmd = 'ipmitool raw 0x30 0x25 0x1 {} 0x0 0x0 2>/dev/null'.format(mux) + desel_all_ch_cmd = 'ipmitool raw 0x30 0x25 0x1 0xe0 0x0 0x0 2>/dev/null; ipmitool raw 0x30 0x25 0x1 0xe2 0x0 0x0 2>/dev/null; ipmitool raw 0x30 0x25 0x1 0xe4 0x0 0x0 2>/dev/null; ipmitool raw 0x30 0x25 0x1 0xe6 0x0 0x0 2>/dev/null' + sel_page_cmd = 'ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f {} 2>/dev/null' + read_lower_cmd = 'ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x0 2>/dev/null' + read_upper_cmd = 'ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>/dev/null' + + try: + subprocess.Popen(sel_ch_cmd, stdout=subprocess.PIPE) + subprocess.Popen(sel_page_cmd.format(0), stdout=subprocess.PIPE) + time.sleep(0.05) + p = subprocess.Popen(read_lower_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + # retry if error occurred + i = 0 + while out == b'' and i < 3: + subprocess.Popen(desel_all_ch_cmd, stdout=subprocess.PIPE) + time.sleep(0.05) + subprocess.Popen(sel_ch_cmd, stdout=subprocess.PIPE) + subprocess.Popen(sel_page_cmd.format(0), stdout=subprocess.PIPE) + time.sleep(0.05) + p = subprocess.Popen(read_lower_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + i = i + 1 + if out == b'': + return False + + data_lower = out.decode().strip().replace("\n", "") + + i = 0 + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + while out == b'' and i < 3: + time.sleep(0.05) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + i = i + 1 + if out == b'': + return False + + data_upper_page_0 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0x1), stdout=subprocess.PIPE) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + data_upper_page_1 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0x2), stdout=subprocess.PIPE) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + data_upper_page_2 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0x3), stdout=subprocess.PIPE) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + data_upper_page_3 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0x10), stdout=subprocess.PIPE) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + data_upper_page_10 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0x11), stdout=subprocess.PIPE) + p = subprocess.Popen(read_upper_cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + data_upper_page_11 = out.decode().strip().replace("\n", "") + + subprocess.Popen(sel_page_cmd.format(0), stdout=subprocess.PIPE) + subprocess.Popen(desel_ch_cmd, stdout=subprocess.PIPE) + + eeprom1 = data_lower + " " + data_upper_page_0 + eeprom2 = data_upper_page_1 + " " + data_upper_page_2 + eeprom3 = data_upper_page_3 + " " + data_upper_page_10 + " " + data_upper_page_11 + + os.remove(PAUSE_EEPROM_SERVICE_STAMP) + + eeprom_raw_lower = [int(x, 16) for x in data_lower.split()] + if eeprom_raw_lower[0] in QSFP_TYPE_CODE_LIST: + temp = eeprom_raw_lower[22] + if temp > 128: + return False + elif eeprom_raw_lower[0] in QSFP_DD_TYPE_CODE_LIST: + temp = eeprom_raw_lower[14] + if temp > 128: + return False + + eeprom1 = eeprom1.replace(" ","") + eeprom2 = eeprom2.replace(" ","") + eeprom3 = eeprom3.replace(" ","") + + for i in range(0, 3): + sysfs_sfp_i2c_client_temp_path = eeprom_path_prefix + self.port_to_i2c_mapping[self.index] + '/temp' + if i == 0: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom1_mapping[self.index] + eeprom = eeprom1 + elif i == 1: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom2_mapping[self.index] + eeprom = eeprom2 + else: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom3_mapping[self.index] + eeprom = eeprom3 + + try: + with open(sysfs_sfp_i2c_client_eeprom_path, 'w') as fd: + fd.write(eeprom) + fd.close() + if i == 0: + with open(sysfs_sfp_i2c_client_temp_path, 'w') as fd: + fd.write(temp) + fd.close() + except IOError: + fd.close() + return True + except Exception: + return False + + def read_eeprom_buffer(self): + with open(PAUSE_EEPROM_SERVICE_STAMP, 'w') as f: + f.write("") + f.close() + + time.sleep(0.2) + rc = self._get_eeprom_by_bmc() + + + return rc + + def clear_eeprom_buffer(self): + for i in range(0, 3): + if i == 0: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom1_mapping[self.index] + elif i == 1: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom2_mapping[self.index] + else: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom3_mapping[self.index] + try: + with open(sysfs_sfp_i2c_client_eeprom_path, 'w') as fd: + fd.write(" ") + fd.close() + except IOError: + fd.close() def _read_eeprom_specific_bytes(self, offset, num_bytes): sysfsfile_eeprom = None @@ -292,9 +497,12 @@ def _read_eeprom_specific_bytes(self, offset, num_bytes): if offset < 256: sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom1_mapping[self.index] - else: + elif offset < 512: sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom2_mapping[self.index] offset = offset - 256 + else: + sysfs_sfp_i2c_client_eeprom_path = self.port_to_eeprom3_mapping[self.index] + offset = offset - 512 try: sysfsfile_eeprom = open(sysfs_sfp_i2c_client_eeprom_path, mode="rb", buffering=0) @@ -321,8 +529,10 @@ def _detect_sfp_type(self, sfp_type): if eeprom_raw: if eeprom_raw[0] in QSFP_TYPE_CODE_LIST: self.sfp_type = QSFP_TYPE + self.abbrv = type_abbrv_name[eeprom_raw[0]] elif eeprom_raw[0] in QSFP_DD_TYPE_CODE_LIST: self.sfp_type = QSFP_DD_TYPE + self.abbrv = type_abbrv_name[eeprom_raw[0]] else: # we don't regonize this identifier value, treat the xSFP module as the default type self.sfp_type = sfp_type @@ -333,6 +543,7 @@ def _detect_sfp_type(self, sfp_type): # eeprom_raw being None indicates the module is not present. # in this case we treat it as the default type according to the SKU self.sfp_type = sfp_type + self.abbrv = type_abbrv_name['18'] def _dom_capability_detect(self): if not self.get_presence(): @@ -342,17 +553,23 @@ def _dom_capability_detect(self): self.dom_rx_power_supported = False self.dom_tx_bias_power_supported = False self.dom_tx_power_supported = False - self.dom_channel_monitor_supported = False self.dom_module_monitor_supported = False - self.dom_channel_treshold_supported = False - self.dom_module_treshold_supported =False self.calibration = 0 return - self.dom_channel_monitor_supported = False + self.dom_channel_monitor_supported = True self.dom_module_monitor_supported = True - self.dom_channel_treshold_supported = False - self.dom_module_treshold_supported =False + self.dom_channel_threshold_supported = True + self.dom_module_threshold_supported = True + + + self.dom_supported = False + self.dom_temp_supported = False + self.dom_volt_supported = False + self.dom_rx_power_supported = False + self.dom_tx_bias_supported = False + self.dom_tx_power_supported = False + self.dom_thresholds_supported = False if self.sfp_type == QSFP_TYPE: self.calibration = 1 @@ -369,7 +586,7 @@ def _dom_capability_detect(self): if qsfp_dom_capability_raw is not None: qsfp_version_compliance_raw = self._read_eeprom_specific_bytes(QSFP_VERSION_COMPLIANCE_OFFSET, QSFP_VERSION_COMPLIANCE_WIDTH) qsfp_version_compliance = int(qsfp_version_compliance_raw[0], 16) - dom_capability = sfpi_obj.parse_qsfp_dom_capability(qsfp_dom_capability_raw, 0) + dom_capability = sfpi_obj.parse_dom_capability(qsfp_dom_capability_raw, 0) if qsfp_version_compliance >= 0x08: self.dom_temp_supported = dom_capability['data']['Temp_support']['value'] == 'On' self.dom_volt_supported = dom_capability['data']['Voltage_support']['value'] == 'On' @@ -405,33 +622,36 @@ def _dom_capability_detect(self): if sfpi_obj is None: self.dom_supported = False - offset = 0 + self.dom_temp_supported = True + self.dom_volt_supported = True + self.dom_tx_fault_supported = False + self.dom_rx_los_supported = False + + offset = 0; + # two types of QSFP-DD cable types supported: Copper and Optical. qsfp_dom_capability_raw = self._read_eeprom_specific_bytes((offset + XCVR_DOM_CAPABILITY_OFFSET_QSFP_DD), XCVR_DOM_CAPABILITY_WIDTH_QSFP_DD) + if qsfp_dom_capability_raw is not None: - self.dom_temp_supported = True - self.dom_volt_supported = True dom_capability = sfpi_obj.parse_dom_capability(qsfp_dom_capability_raw, 0) if dom_capability['data']['Flat_MEM']['value'] == 'Off': - self.dom_supported = False - self.dom_rx_power_supported = False - self.dom_tx_power_supported = False - self.dom_tx_bias_power_supported = False - self.dom_thresholds_supported = False - else: - self.dom_supported = False - self.dom_rx_power_supported = False - self.dom_tx_power_supported = False - self.dom_tx_bias_power_supported = False - self.dom_thresholds_supported = False - else: - self.dom_supported = False - self.dom_temp_supported = False - self.dom_volt_supported = False - self.dom_rx_power_supported = False - self.dom_tx_power_supported = False - self.dom_tx_bias_power_supported = False - self.dom_thresholds_supported = False + + ext_dd = ext_qsfp_dd() + offset = 256 + mon_sup_raw = self._read_eeprom_specific_bytes(offset + QSFP_DD_CHANNL_MON_SUPPORT_OFFSET, QSFP_DD_CHANNL_MON_SUPPORT_WIDTH) + mon_sup_data = ext_dd.parse_mon_capability(mon_sup_raw, 0) + + self.dom_thresholds_supported = mon_sup_data['data']['Tx_power_support']['value'] == 'On' + self.dom_rx_power_supported = mon_sup_data['data']['Tx_power_support']['value'] == 'On' + self.dom_tx_power_supported = mon_sup_data['data']['Rx_power_support']['value'] == 'On' + self.dom_tx_bias_supported = mon_sup_data['data']['Tx_bias_support']['value'] == 'On' + self.dom_supported = True + + flags_sup_raw = self._read_eeprom_specific_bytes(offset + QSFP_DD_CHANNL_FLAGS_SUPPORT_OFFSET, QSFP_DD_CHANNL_FLAGS_SUPPORT_WIDTH) + flags_sup_data = ext_dd.parse_flags_capability(flags_sup_raw, 0) + + self.dom_tx_fault_supported = flags_sup_data['data']['tx_fault']['value'] == 'On' + self.dom_rx_los_supported = flags_sup_data['data']['rx_los']['value'] == 'On' else: self.dom_supported = False @@ -486,8 +706,19 @@ def get_transceiver_info(self): application_advertisement |1*255VCHAR |supported applications advertisement ================================================================================ """ + self.reinit() + info_dict_keys = [ + 'type', 'hardware_rev', 'serial', 'manufacturer', + 'model', 'connector', 'encoding', 'ext_identifier', + 'ext_rateselect_compliance', 'cable_type', 'cable_length', + 'nominal_bit_rate', 'specification_compliance', 'vendor_date', + 'vendor_oui', 'application_advertisement', 'type_abbrv_name'] + transceiver_info_dict = {} compliance_code_dict = {} + transceiver_info_dict = dict.fromkeys(info_dict_keys, "NA") + transceiver_info_dict["specification_compliance"] = '{}' + transceiver_info_dict['type_abbrv_name'] = self.abbrv #QSFP if self.sfp_type == QSFP_TYPE: @@ -636,6 +867,7 @@ def get_transceiver_info(self): if sfp_media_type_dict is None: return None + transceiver_info_dict['specification_compliance'] = type_of_media_interface[sfp_media_type_raw[0]] host_media_list = "" sfp_application_type_first_list = self._read_eeprom_specific_bytes((XCVR_FIRST_APPLICATION_LIST_OFFSET_QSFP_DD), XCVR_FIRST_APPLICATION_LIST_WIDTH_QSFP_DD) possible_application_count = 8 @@ -663,7 +895,6 @@ def get_transceiver_info(self): transceiver_info_dict['encoding'] = "Not supported for CMIS cables" transceiver_info_dict['ext_identifier'] = str(sfp_ext_identifier_data['data']['Extended Identifier']['value']) transceiver_info_dict['ext_rateselect_compliance'] = "Not supported for CMIS cables" - transceiver_info_dict['specification_compliance'] = "Not supported for CMIS cables" transceiver_info_dict['cable_type'] = "Length Cable Assembly(m)" transceiver_info_dict['cable_length'] = str(sfp_cable_len_data['data']['Length Cable Assembly(m)']['value']) transceiver_info_dict['nominal_bit_rate'] = "Not supported for CMIS cables" @@ -700,6 +931,7 @@ def get_transceiver_bulk_status(self): TX power |INT |TX output power in mW ======================================================================== """ + self.reinit() transceiver_dom_info_dict = {} dom_info_dict_keys = ['temperature', 'voltage', @@ -754,6 +986,10 @@ def get_transceiver_bulk_status(self): dom_channel_monitor_data = sfpd_obj.parse_channel_monitor_params_with_tx_power(dom_data_raw[start : end], 0) if self.dom_tx_power_supported: + transceiver_dom_info_dict['tx1bias'] = dom_channel_monitor_data['data']['TX1Bias']['value'] + transceiver_dom_info_dict['tx2bias'] = dom_channel_monitor_data['data']['TX2Bias']['value'] + transceiver_dom_info_dict['tx3bias'] = dom_channel_monitor_data['data']['TX3Bias']['value'] + transceiver_dom_info_dict['tx4bias'] = dom_channel_monitor_data['data']['TX4Bias']['value'] transceiver_dom_info_dict['tx1power'] = self._convert_string_to_num(dom_channel_monitor_data['data']['TX1Power']['value']) transceiver_dom_info_dict['tx2power'] = self._convert_string_to_num(dom_channel_monitor_data['data']['TX2Power']['value']) transceiver_dom_info_dict['tx3power'] = self._convert_string_to_num(dom_channel_monitor_data['data']['TX3Power']['value']) @@ -765,38 +1001,64 @@ def get_transceiver_bulk_status(self): transceiver_dom_info_dict['rx3power'] = self._convert_string_to_num(dom_channel_monitor_data['data']['RX3Power']['value']) transceiver_dom_info_dict['rx4power'] = self._convert_string_to_num(dom_channel_monitor_data['data']['RX4Power']['value']) - transceiver_dom_info_dict['tx1bias'] = dom_channel_monitor_data['data']['TX1Bias']['value'] - transceiver_dom_info_dict['tx2bias'] = dom_channel_monitor_data['data']['TX2Bias']['value'] - transceiver_dom_info_dict['tx3bias'] = dom_channel_monitor_data['data']['TX3Bias']['value'] - transceiver_dom_info_dict['tx4bias'] = dom_channel_monitor_data['data']['TX4Bias']['value'] #QSFP-DD else: - offset = 0 sfpd_obj = qsfp_dd_Dom() if sfpd_obj is None: return transceiver_dom_info_dict - dom_data_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_DOM_BULK_DATA_START), QSFP_DD_DOM_BULK_DATA_SIZE) - if dom_data_raw is None: - return transceiver_dom_info_dict - if self.dom_module_monitor_supported: + if self.dom_temp_supported: - start = QSFP_DD_TEMPE_OFFSET - QSFP_DD_DOM_BULK_DATA_START - end = start + QSFP_DD_TEMPE_WIDTH - dom_temperature_data = sfpd_obj.parse_temperature(dom_data_raw[start : end], 0) + offset = 0 + dom_data_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_TEMPE_OFFSET), QSFP_DD_TEMPE_WIDTH) + dom_temperature_data = sfpd_obj.parse_temperature(dom_data_raw, 0) temp = self._convert_string_to_num(dom_temperature_data['data']['Temperature']['value']) if temp is not None: transceiver_dom_info_dict['temperature'] = temp if self.dom_volt_supported: - start = QSFP_DD_VOLT_OFFSET - QSFP_DD_DOM_BULK_DATA_START - end = start + QSFP_DD_VOLT_WIDTH - dom_voltage_data = sfpd_obj.parse_voltage(dom_data_raw[start : end], 0) + offset = 0 + dom_data_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_VOLT_OFFSET), QSFP_DD_VOLT_WIDTH) + dom_voltage_data = sfpd_obj.parse_voltage(dom_data_raw, 0) volt = self._convert_string_to_num(dom_voltage_data['data']['Vcc']['value']) if volt is not None: transceiver_dom_info_dict['voltage'] = volt + if self.dom_channel_monitor_supported: + + offset = 768 + dom_data_raw = self._read_eeprom_specific_bytes(offset + (QSFP_DD_CHANNL_MON_OFFSET - 128), QSFP_DD_CHANNL_MON_WIDTH) + dom_channel_monitor_data = sfpd_obj.parse_channel_monitor_params(dom_data_raw, 0) + if self.dom_tx_power_supported: + transceiver_dom_info_dict['tx1power'] = dom_channel_monitor_data['data']['TX1Power']['value'] + transceiver_dom_info_dict['tx2power'] = dom_channel_monitor_data['data']['TX2Power']['value'] + transceiver_dom_info_dict['tx3power'] = dom_channel_monitor_data['data']['TX3Power']['value'] + transceiver_dom_info_dict['tx4power'] = dom_channel_monitor_data['data']['TX4Power']['value'] + transceiver_dom_info_dict['tx5power'] = dom_channel_monitor_data['data']['TX5Power']['value'] + transceiver_dom_info_dict['tx6power'] = dom_channel_monitor_data['data']['TX6Power']['value'] + transceiver_dom_info_dict['tx7power'] = dom_channel_monitor_data['data']['TX7Power']['value'] + transceiver_dom_info_dict['tx8power'] = dom_channel_monitor_data['data']['TX8Power']['value'] + + if self.dom_rx_power_supported: + transceiver_dom_info_dict['rx1power'] = dom_channel_monitor_data['data']['RX1Power']['value'] + transceiver_dom_info_dict['rx2power'] = dom_channel_monitor_data['data']['RX2Power']['value'] + transceiver_dom_info_dict['rx3power'] = dom_channel_monitor_data['data']['RX3Power']['value'] + transceiver_dom_info_dict['rx4power'] = dom_channel_monitor_data['data']['RX4Power']['value'] + transceiver_dom_info_dict['rx5power'] = dom_channel_monitor_data['data']['RX5Power']['value'] + transceiver_dom_info_dict['rx6power'] = dom_channel_monitor_data['data']['RX6Power']['value'] + transceiver_dom_info_dict['rx7power'] = dom_channel_monitor_data['data']['RX7Power']['value'] + transceiver_dom_info_dict['rx8power'] = dom_channel_monitor_data['data']['RX8Power']['value'] + + if self.dom_tx_bias_supported: + transceiver_dom_info_dict['tx1bias'] = dom_channel_monitor_data['data']['TX1Bias']['value'] + transceiver_dom_info_dict['tx2bias'] = dom_channel_monitor_data['data']['TX2Bias']['value'] + transceiver_dom_info_dict['tx3bias'] = dom_channel_monitor_data['data']['TX3Bias']['value'] + transceiver_dom_info_dict['tx4bias'] = dom_channel_monitor_data['data']['TX4Bias']['value'] + transceiver_dom_info_dict['tx5bias'] = dom_channel_monitor_data['data']['TX5Bias']['value'] + transceiver_dom_info_dict['tx6bias'] = dom_channel_monitor_data['data']['TX6Bias']['value'] + transceiver_dom_info_dict['tx7bias'] = dom_channel_monitor_data['data']['TX7Bias']['value'] + transceiver_dom_info_dict['tx8bias'] = dom_channel_monitor_data['data']['TX8Bias']['value'] return transceiver_dom_info_dict @@ -831,6 +1093,7 @@ def get_transceiver_threshold_info(self): txbiaslowwarning |FLOAT |Low Warning Threshold value of tx Bias Current in mA. ======================================================================== """ + self.reinit() transceiver_dom_threshold_info_dict = {} dom_info_dict_keys = ['temphighalarm', 'temphighwarning', @@ -851,9 +1114,7 @@ def get_transceiver_threshold_info(self): if not self.dom_supported or not self.qsfp_page3_available: return transceiver_dom_threshold_info_dict - # Dom Threshold data starts from offset 384 - # Revert offset back to 0 once data is retrieved - offset = QSFP_MODULE_UPPER_PAGE3_START + offset = 512 sfpd_obj = sff8436Dom() if sfpd_obj is None: return transceiver_dom_threshold_info_dict @@ -871,7 +1132,7 @@ def get_transceiver_threshold_info(self): dom_channel_threshold_data = sfpd_obj.parse_channel_threshold_values(dom_channel_threshold_raw, 0) # Threshold Data - if self.dom_module_treshold_supported: + if self.dom_module_threshold_supported: transceiver_dom_threshold_info_dict['temphighalarm'] = dom_module_threshold_data['data']['TempHighAlarm']['value'] transceiver_dom_threshold_info_dict['temphighwarning'] = dom_module_threshold_data['data']['TempHighWarning']['value'] transceiver_dom_threshold_info_dict['templowalarm'] = dom_module_threshold_data['data']['TempLowAlarm']['value'] @@ -880,7 +1141,7 @@ def get_transceiver_threshold_info(self): transceiver_dom_threshold_info_dict['vcchighwarning'] = dom_module_threshold_data['data']['VccHighWarning']['value'] transceiver_dom_threshold_info_dict['vcclowalarm'] = dom_module_threshold_data['data']['VccLowAlarm']['value'] transceiver_dom_threshold_info_dict['vcclowwarning'] = dom_module_threshold_data['data']['VccLowWarning']['value'] - if self.dom_channel_treshold_supported: + if self.dom_channel_threshold_supported: transceiver_dom_threshold_info_dict['rxpowerhighalarm'] = dom_channel_threshold_data['data']['RxPowerHighAlarm']['value'] transceiver_dom_threshold_info_dict['rxpowerhighwarning'] = dom_channel_threshold_data['data']['RxPowerHighWarning']['value'] transceiver_dom_threshold_info_dict['rxpowerlowalarm'] = dom_channel_threshold_data['data']['RxPowerLowAlarm']['value'] @@ -906,8 +1167,8 @@ def get_transceiver_threshold_info(self): if sfpd_obj is None: return transceiver_dom_threshold_info_dict - # page 02 (we put page 2 to byte 256~384) - offset = 256 + # page 02 (we put page 2 to byte 384~511) + offset = 384 dom_module_threshold_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_MODULE_THRESHOLD_OFFSET), QSFP_DD_MODULE_THRESHOLD_WIDTH) if dom_module_threshold_raw is None: return transceiver_dom_threshold_info_dict @@ -915,7 +1176,7 @@ def get_transceiver_threshold_info(self): dom_module_threshold_data = sfpd_obj.parse_module_threshold_values(dom_module_threshold_raw, 0) # Threshold Data - if self.dom_module_treshold_supported: + if self.dom_module_threshold_supported: transceiver_dom_threshold_info_dict['temphighalarm'] = dom_module_threshold_data['data']['TempHighAlarm']['value'] transceiver_dom_threshold_info_dict['temphighwarning'] = dom_module_threshold_data['data']['TempHighWarning']['value'] transceiver_dom_threshold_info_dict['templowalarm'] = dom_module_threshold_data['data']['TempLowAlarm']['value'] @@ -924,7 +1185,7 @@ def get_transceiver_threshold_info(self): transceiver_dom_threshold_info_dict['vcchighwarning'] = dom_module_threshold_data['data']['VccHighWarning']['value'] transceiver_dom_threshold_info_dict['vcclowalarm'] = dom_module_threshold_data['data']['VccLowAlarm']['value'] transceiver_dom_threshold_info_dict['vcclowwarning'] = dom_module_threshold_data['data']['VccLowWarning']['value'] - if self.dom_channel_treshold_supported: + if self.dom_channel_threshold_supported: transceiver_dom_threshold_info_dict['rxpowerhighalarm'] = dom_module_threshold_data['data']['RxPowerHighAlarm']['value'] transceiver_dom_threshold_info_dict['rxpowerhighwarning'] = dom_module_threshold_data['data']['RxPowerHighWarning']['value'] transceiver_dom_threshold_info_dict['rxpowerlowalarm'] = dom_module_threshold_data['data']['RxPowerLowAlarm']['value'] @@ -974,12 +1235,12 @@ def get_rx_los(self): #QSFP-DD else: - # page 11h (we put page 2 to byte 384~512) - if self.dom_rx_tx_power_bias_supported: - offset = 384 + # page 11h (we put page 11 to byte 768~895) + if self.dom_rx_los_supported: + offset = 768 dom_channel_monitor_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_CHANNL_RX_LOS_STATUS_OFFSET), QSFP_DD_CHANNL_RX_LOS_STATUS_WIDTH) if dom_channel_monitor_raw is not None: - rx_los_data = int(dom_channel_monitor_raw[0], 8) + rx_los_data = int(dom_channel_monitor_raw[0], 16) rx_los_list.append(rx_los_data & 0x01 != 0) rx_los_list.append(rx_los_data & 0x02 != 0) rx_los_list.append(rx_los_data & 0x04 != 0) @@ -999,6 +1260,7 @@ def get_tx_fault(self): A Boolean, True if SFP has TX fault, False if not Note : TX fault status is lached until a call to get_tx_fault or a reset. """ + self.reinit() if not self.dom_supported: return None @@ -1016,7 +1278,20 @@ def get_tx_fault(self): #QSFP-DD else: - return None + # page 11h (we put page 11 to byte 768~895) + if self.dom_tx_fault_supported: + offset = 768 + dom_channel_monitor_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_CHANNL_TX_FAULT_STATUS_OFFSET), QSFP_DD_CHANNL_TX_FAULT_STATUS_WIDTH) + if dom_channel_monitor_raw is not None: + tx_fault_data = int(dom_channel_monitor_raw[0], 16) + tx_fault_list.append(tx_fault_data & 0x01 != 0) + tx_fault_list.append(tx_fault_data & 0x02 != 0) + tx_fault_list.append(tx_fault_data & 0x04 != 0) + tx_fault_list.append(tx_fault_data & 0x08 != 0) + tx_fault_list.append(tx_fault_data & 0x10 != 0) + tx_fault_list.append(tx_fault_data & 0x20 != 0) + tx_fault_list.append(tx_fault_data & 0x40 != 0) + tx_fault_list.append(tx_fault_data & 0x80 != 0) return tx_fault_list @@ -1031,6 +1306,7 @@ def get_tx_disable(self): for SFP, the TX Disable State and Soft TX Disable Select is ORed as the tx_disable status returned These two bits are bit 7 & 6 in byte 110 page a2 respectively """ + self.reinit() if not self.dom_supported: return None @@ -1048,20 +1324,19 @@ def get_tx_disable(self): #QSFP-DD else: - if self.dom_rx_tx_power_bias_supported: - # page 11h (we put page 1 to byte 384~512) - offset = 384 - dom_channel_monitor_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_CHANNL_DISABLE_STATUS_OFFSET), QSFP_DD_CHANNL_DISABLE_STATUS_WIDTH) - if dom_channel_monitor_raw is not None: - tx_disable_data = int(dom_channel_monitor_raw[0], 16) - tx_disable_list.append(tx_disable_data & 0x01 != 0) - tx_disable_list.append(tx_disable_data & 0x02 != 0) - tx_disable_list.append(tx_disable_data & 0x04 != 0) - tx_disable_list.append(tx_disable_data & 0x08 != 0) - tx_disable_list.append(tx_disable_data & 0x10 != 0) - tx_disable_list.append(tx_disable_data & 0x20 != 0) - tx_disable_list.append(tx_disable_data & 0x40 != 0) - tx_disable_list.append(tx_disable_data & 0x80 != 0) + # page 10h (we put page 10 to byte 640~767) + offset = 640 + dom_channel_monitor_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_CHANNL_DISABLE_STATUS_OFFSET), QSFP_DD_CHANNL_DISABLE_STATUS_WIDTH) + if dom_channel_monitor_raw is not None: + tx_disable_data = int(dom_channel_monitor_raw[0], 16) + tx_disable_list.append(tx_disable_data & 0x01 != 0) + tx_disable_list.append(tx_disable_data & 0x02 != 0) + tx_disable_list.append(tx_disable_data & 0x04 != 0) + tx_disable_list.append(tx_disable_data & 0x08 != 0) + tx_disable_list.append(tx_disable_data & 0x10 != 0) + tx_disable_list.append(tx_disable_data & 0x20 != 0) + tx_disable_list.append(tx_disable_data & 0x40 != 0) + tx_disable_list.append(tx_disable_data & 0x80 != 0) return tx_disable_list @@ -1083,8 +1358,17 @@ def get_lpmode(self): Returns: A Boolean, True if lpmode is enabled, False if disabled """ - # SFP doesn't support this feature - return False + lpmode = False + try: + if self.index < 16: + lpmode_path=self.LPMODE_1_16_PATH.format(self.port_num) + else: + lpmode_path=self.LPMODE_17_32_PATH.format(self.port_num) + with open(lpmode_path, 'r') as sfp_lpmode: + lpmode = int(sfp_lpmode.read(), 16) + except IOError: + return False + return lpmode == 1 def get_power_override(self): """ @@ -1102,6 +1386,7 @@ def get_temperature(self): Returns: An integer number of current temperature in Celsius """ + self.reinit() if not self.dom_supported: return None #QSFP @@ -1146,6 +1431,7 @@ def get_voltage(self): Returns: An integer number of supply voltage in mV """ + self.reinit() if not self.dom_supported: return None @@ -1192,6 +1478,7 @@ def get_tx_bias(self): for channel 0 to channel 4. Ex. ['110.09', '111.12', '108.21', '112.09'] """ + self.reinit() tx_bias_list = [] #QSFP @@ -1212,25 +1499,24 @@ def get_tx_bias(self): #QSFP-DD else: - # page 11h (we put page 1 to byte 384~512) - if self.dom_rx_tx_power_bias_supported: - offset = 384 + # page 11h (we put page 1 to byte 768~895) + if dom_tx_bias_power_supported: + offset = 768 sfpd_obj = qsfp_dd_Dom() if sfpd_obj is None: return None - if dom_tx_bias_power_supported: - dom_tx_bias_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_TX_BIAS_OFFSET), QSFP_DD_TX_BIAS_WIDTH) - if dom_tx_bias_raw is not None: - dom_tx_bias_data = sfpd_obj.parse_dom_tx_bias(dom_tx_bias_raw, 0) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX1Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX2Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX3Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX4Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX5Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX6Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX7Bias']['value'])) - tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX8Bias']['value'])) + dom_tx_bias_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_TX_BIAS_OFFSET), QSFP_DD_TX_BIAS_WIDTH) + if dom_tx_bias_raw is not None: + dom_tx_bias_data = sfpd_obj.parse_dom_tx_bias(dom_tx_bias_raw, 0) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX1Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX2Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX3Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX4Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX5Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX6Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX7Bias']['value'])) + tx_bias_list.append(self._convert_string_to_num(dom_tx_bias_data['data']['TX8Bias']['value'])) return tx_bias_list @@ -1243,6 +1529,7 @@ def get_rx_power(self): power in mW for channel 0 to channel 4. Ex. ['1.77', '1.71', '1.68', '1.70'] """ + self.reinit() rx_power_list = [] #QSFP @@ -1268,25 +1555,24 @@ def get_rx_power(self): #QSFP-DD elif self.sfp_type == QSFP_DD_TYPE: - # page 11h (we put page 1 to byte 384~512) - if self.dom_rx_tx_power_bias_supported: - offset = 384 + # page 11h (we put page 11 to byte 768~895) + if self.dom_rx_power_supported: + offset = 768 sfpd_obj = qsfp_dd_Dom() if sfpd_obj is None: return None - if self.dom_rx_power_supported: - dom_rx_power_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_RX_POWER_OFFSET), QSFP_DD_RX_POWER_WIDTH) - if dom_rx_power_raw is not None: - dom_rx_power_data = sfpd_obj.parse_dom_rx_power(dom_rx_power_raw, 0) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX1Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX2Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX3Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX4Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX5Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX6Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX7Power']['value'])) - rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX8Power']['value'])) + dom_rx_power_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_RX_POWER_OFFSET), QSFP_DD_RX_POWER_WIDTH) + if dom_rx_power_raw is not None: + dom_rx_power_data = sfpd_obj.parse_dom_rx_power(dom_rx_power_raw, 0) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX1Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX2Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX3Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX4Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX5Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX6Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX7Power']['value'])) + rx_power_list.append(self._convert_string_to_num(dom_rx_power_data['data']['RX8Power']['value'])) return rx_power_list @@ -1299,6 +1585,7 @@ def get_tx_power(self): for channel 0 to channel 4. Ex. ['1.86', '1.86', '1.86', '1.86'] """ + self.reinit() tx_power_list = [] #QSFP @@ -1324,25 +1611,24 @@ def get_tx_power(self): #QSFP-DD else: - # page 11h (we put page 1 to byte 384~512) - if self.dom_rx_tx_power_bias_supported: - offset = 384 + # page 11h (we put page 11 to byte 768~895) + if self.dom_tx_power_supported: + offset = 768 sfpd_obj = qsfp_dd_Dom() if sfpd_obj is None: return None - if self.dom_tx_power_supported: - dom_tx_power_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_TX_POWER_OFFSET), QSFP_DD_TX_POWER_WIDTH) - if dom_tx_power_raw is not None: - dom_tx_power_data = sfpd_obj.parse_dom_tx_power(dom_tx_power_raw, 0) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX1Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX2Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX3Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX4Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX5Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX6Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX7Power']['value'])) - tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX8Power']['value'])) + dom_tx_power_raw = self._read_eeprom_specific_bytes((offset + QSFP_DD_TX_POWER_OFFSET), QSFP_DD_TX_POWER_WIDTH) + if dom_tx_power_raw is not None: + dom_tx_power_data = sfpd_obj.parse_dom_tx_power(dom_tx_power_raw, 0) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX1Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX2Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX3Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX4Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX5Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX6Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX7Power']['value'])) + tx_power_list.append(self._convert_string_to_num(dom_tx_power_data['data']['TX8Power']['value'])) return tx_power_list @@ -1352,8 +1638,22 @@ def reset(self): Returns: A boolean, True if successful, False if not """ - # SFP doesn't support this feature - return False + try: + if self.index < 16: + file_path=self.RESET_1_16_PATH.format(self.port_num) + else: + file_path=self.RESET_17_32_PATH.format(self.port_num) + + with open(file_path, 'w') as fd: + fd.write(str(1)) + time.sleep(1) + fd.write(str(0)) + time.sleep(1) + + except IOError: + return False + + return True def tx_disable(self, tx_disable): """ @@ -1390,8 +1690,18 @@ def set_lpmode(self, lpmode): Returns: A boolean, True if lpmode is set successfully, False if not """ - # SFP doesn't support this feature - return False + try: + if self.index < 16: + lpmode_path=self.LPMODE_1_16_PATH.format(self.port_num) + else: + lpmode_path=self.LPMODE_17_32_PATH.format(self.port_num) + val_file = open(lpmode_path, 'w') + val_file.write('1' if lpmode else '0') + val_file.close() + return True + except IOError: + val_file.close() + return False def set_power_override(self, power_override, power_set): """ @@ -1420,7 +1730,7 @@ def get_name(self): string: The name of the device """ - name='port'+str(self.index) + name='port'+str(self.index + 1) return name def get_model(self): @@ -1441,3 +1751,40 @@ def get_serial(self): transceiver_dom_info_dict = self.get_transceiver_info() return transceiver_dom_info_dict.get("serial", "N/A") + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return self.get_presence() and not self.get_reset_status() + + def get_position_in_parent(self): + """ + Returns: + Temp return 0 + """ + return 0 + + def is_replaceable(self): + """ + Retrieves if replaceable + Returns: + A boolean value, True if replaceable + """ + return True + + def get_error_description(self): + """ + Get error description + + Args: + error_code: The error code returned by _get_error_code + + Returns: + The error description + """ + if self.get_presence(): + return self.SFP_STATUS_OK + else: + return self.SFP_STATUS_UNPLUGGED diff --git a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/thermal.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/thermal.py old mode 100644 new mode 100755 similarity index 61% rename from device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/thermal.py rename to platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/thermal.py index 942e6b7be347..73228ce8f0ac --- a/device/wistron/x86_64-wistron_6512_32r-r0/sonic_platform/thermal.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/thermal.py @@ -15,7 +15,6 @@ except ImportError as e: raise ImportError(str(e) + "- required module not found") - class Thermal(ThermalBase): """Platform-specific Thermal class""" @@ -42,6 +41,8 @@ def __init__(self, thermal_index): self.THERMAL_NAME_LIST.append("UCPUB") self.THERMAL_NAME_LIST.append("UFANB") ThermalBase.__init__(self) + self.minimum_thermal = self.get_temperature() + self.maximum_thermal = self.get_temperature() def __read_txt_file(self, file_path): try: @@ -50,13 +51,24 @@ def __read_txt_file(self, file_path): return data.strip() except IOError: pass - return "" + return None def __get_temp(self, temp_file): temp_file_path = os.path.join(self.SYSFS_THERMAL_DIR[self.index], temp_file) raw_temp = self.__read_txt_file(temp_file_path) - temp = float(raw_temp)/1000 - return "{:.3f}".format(temp) + if raw_temp is not None: + return float(raw_temp)/1000 + else: + return 0.0 + + def __set_threshold(self, file_name, temperature): + temp_file_path = os.path.join(self.SYSFS_THERMAL_DIR[self.index], file_name) + try: + with open(temp_file_path, 'w') as fd: + fd.write(str(temperature)) + return True + except IOError: + return False def get_temperature(self): """ @@ -74,7 +86,8 @@ def get_low_threshold(self): :return: A float number, the low threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - return int(3) + # work temperatur is 0~40, hyst is 2 + return 2.0 def get_low_critical_threshold(self): """ @@ -82,7 +95,8 @@ def get_low_critical_threshold(self): :return: A float number, the low critical threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - return int(0) + # work temperatur is 0~40 + return 0.0 def get_high_threshold(self): """ @@ -120,7 +134,7 @@ def get_presence(self): bool: True if PSU is present, False if not """ temp_file = "temp1_input" - temp_file_path = os.path.join(self.hwmon_path, temp_file) + temp_file_path = os.path.join(self.SYSFS_THERMAL_DIR[self.index], temp_file) return os.path.isfile(temp_file_path) def get_status(self): @@ -134,3 +148,63 @@ def get_status(self): return True + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return "None" + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return "None" + + def is_replaceable(self): + """ + Retrieves whether thermal module is replaceable + Returns: + A boolean value, True if replaceable, False if not + """ + return False + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return self.index + 1 + + def get_minimum_recorded(self): + """ + Retrieves the minimum recorded temperature of thermal + Returns: + A float number, the minimum recorded temperature of thermal in Celsius + up to nearest thousandth of one degree Celsius, e.g. 30.125 + """ + tmp = self.get_temperature() + if tmp < self.minimum_thermal: + self.minimum_thermal = tmp + return self.minimum_thermal + + def get_maximum_recorded(self): + """ + Retrieves the maximum recorded temperature of thermal + Returns: + A float number, the maximum recorded temperature of thermal in Celsius + up to nearest thousandth of one degree Celsius, e.g. 30.125 + """ + tmp = self.get_temperature() + if tmp > self.maximum_thermal: + self.maximum_thermal = tmp + return self.maximum_thermal + diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/watchdog.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/watchdog.py new file mode 100755 index 000000000000..fb7987bdd682 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/sonic_platform/watchdog.py @@ -0,0 +1,184 @@ +#!/usr/bin/env python + +######################################################################## +# +# Abstract base class for implementing a platform-specific class with +# which to interact with a hardware watchdog module in SONiC +# +######################################################################## + +try: + import subprocess + from sonic_platform_base.watchdog_base import WatchdogBase + from shlex import split + from collections import namedtuple + from functools import reduce +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +proc_output = namedtuple('proc_output', 'stdout stderr') + +WDT_COMMON_ERROR = -1 + +IPMI_WDT_EN_KICK_CMD = ["ipmitool", "mc", "watchdog", "reset"] +IPMI_WDT_OFF_CMD = ["ipmitool", "mc", "watchdog", "off"] +IPMI_WDT_SET_TIMEOUT_CMD = ["ipmitool", "raw", "0x6", "0x24", "0x4", "0x0", "0x0", "0x0"] +#IPMI_WDT_GET_TIMEOUT_CMD = "ipmitool mc watchdog get | grep Present | awk '{print $3}'" +#IPMI_WDT_GET_STATUS_CMD = "ipmitool mc watchdog get | grep 'Timer Is' | awk '{printf $4}'" + +class Watchdog(WatchdogBase): + """ + Abstract base class for interfacing with a hardware watchdog module + """ + + def __init__(self): + # Set default value + self.armed = self._get_status() + self.timeout = self._gettimeout() + + def pipeline(self, starter_command, *commands): + if not commands: + try: + starter_command, *commands = starter_command.split('|') + except AttributeError: + pass + starter_command = self._parse(starter_command) + starter = subprocess.Popen(starter_command, stdout=subprocess.PIPE) + last_proc = reduce(self._create_pipe, map(self._parse, commands), starter) + return proc_output(*last_proc.communicate()) + + def _create_pipe(self, previous, command): + proc = subprocess.Popen(command, stdin=previous.stdout, stdout=subprocess.PIPE) + previous.stdout.close() + return proc + + def _parse(self, cmd): + try: + return split(cmd) + except Exception: + return cmd + + def _get_status(self): + #IPMI_WDT_GET_STATUS_CMD + out, err = self.pipeline("ipmitool mc watchdog get", "grep 'Timer Is'", "awk '{print $4}'") + status_str = out.decode().rstrip('\n') + + if "Running" in status_str: + return True + + return False + + def _enable(self): + """ + Turn on the watchdog timer + """ + p = subprocess.Popen(IPMI_WDT_EN_KICK_CMD, stdout=subprocess.PIPE) + p.communicate() + return 0 + + def _disable(self): + """ + Turn off the watchdog timer + """ + p = subprocess.Popen(IPMI_WDT_OFF_CMD, stdout=subprocess.PIPE) + p.communicate() + return 0 + + def _keepalive(self): + """ + Keep alive watchdog timer + """ + p = subprocess.Popen(IPMI_WDT_EN_KICK_CMD, stdout=subprocess.PIPE) + p.communicate() + return 0 + + def _settimeout(self, seconds): + """ + Set watchdog timer timeout + @param seconds - timeout in seconds + @return is the actual set timeout + """ + ipmi_timeout = seconds * 10; + cmd = ["ipmitool", "raw", "0x6", "0x24", "0x4", "0x0", "0x0", "0x0"] + cmd.append(str(ipmi_timeout % 256)) + cmd.append(str(int(ipmi_timeout / 256))) + p = subprocess.Popen(cmd, stdout=subprocess.PIPE) + p.communicate() + + return seconds + + def _gettimeout(self): + #IPMI_WDT_GET_TIMEOUT_CMD + out, err = self.pipeline("ipmitool mc watchdog get", "grep Present", "awk '{print $3}'") + return int(out.decode().rstrip('\n'), 10) + + def arm(self, seconds): + """ + Arm the hardware watchdog with a timeout of seconds. + If the watchdog is currently armed, calling this function will + simply reset the timer to the provided value. If the underlying + hardware does not support the value provided in , this + method should arm the watchdog with the *next greater* available + value. + Returns: + An integer specifying the *actual* number of seconds the watchdog + was armed with. On failure returns -1. + """ + ret = WDT_COMMON_ERROR + + if seconds < 0 or seconds > 500: + return ret + + try: + if self.timeout != seconds: + self.timeout = self._settimeout(seconds) + + if self.armed: + self._keepalive() + else: + self._enable() + + ret = self.timeout + except IOError as e: + print("Error: unable to enable wdt due to : {}".format(e)) + + return ret + + def disarm(self): + """ + Disarm the hardware watchdog + Returns: + A boolean, True if watchdog is disarmed successfully, False if not + """ + disarmed = False + try: + self._disable() + self.armed = False + disarmed = True + except IOError as e: + print("Error: unable to disable wdt due to : {}".format(e)) + return disarmed + + def is_armed(self): + """ + Retrieves the armed state of the hardware watchdog. + Returns: + A boolean, True if watchdog is armed, False if not + """ + return self.armed + + def get_remaining_time(self): + """ + If the watchdog is armed, retrieve the number of seconds remaining on + the watchdog timer + Returns: + An integer specifying the number of seconds remaining on thei + watchdog timer. If the watchdog is not armed, returns -1. + """ + + timeleft = WDT_COMMON_ERROR + + if self.armed: + return self._gettimeout() + + return timeleft diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_firmware_version b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_firmware_version new file mode 100755 index 000000000000..1fe70c7f4310 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_firmware_version @@ -0,0 +1,17 @@ +#!/bin/bash +cpld1_ver=$(ipmitool raw 0x30 0x25 0x0 0xc 0x1 0x0 2>>/dev/null | awk '{printf $1}') +cpld2_ver=$(ipmitool raw 0x30 0x25 0x0 0xe 0x1 0x0 2>>/dev/null | awk '{printf $1}') +fpga_ver=$(ipmitool raw 0x30 0x25 0x0 0x60 0x1 0x0 2>>/dev/null | awk '{printf $1}') +cpld1_ver=$( printf "%d" 0x$cpld1_ver ) +cpld2_ver=$( printf "%d" 0x$cpld2_ver ) +fpga_ver=$( printf "%d" 0x$fpga_ver ) +cpld1_ver_path="/sys/bus/i2c/devices/0-0006/version" +cpld2_ver_path="/sys/bus/i2c/devices/0-0007/version" +fpga_ver_path="/sys/bus/i2c/devices/0-0030/version" + +echo $cpld1_ver > $cpld1_ver_path +echo $cpld2_ver > $cpld2_ver_path +echo $fpga_ver > $fpga_ver_path + +exit 0 + diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_sync b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_sync old mode 100644 new mode 100755 index 9c357e7ac7e8..071339cac9d3 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_sync +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_sync @@ -3,5 +3,7 @@ /usr/local/bin/sonic-led-monitor & /usr/local/bin/sonic-qsfp-monitor & /usr/local/bin/sonic-psu-monitor & +/usr/local/bin/sonic-qsfp-eeprom-monitor & +/usr/local/bin/sonic-send-temp-to-bmc & exit 0 diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_syseeprom b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_syseeprom old mode 100644 new mode 100755 index 2db0a921cb9a..4a19db909864 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_syseeprom +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/platform_syseeprom @@ -1,10 +1,15 @@ #!/bin/bash -eeprom_part1=$(ipmitool raw 0x30 0x25 0x00 0xaa 0x80 0x0 2>>/dev/null) -eeprom_part2=$(ipmitool raw 0x30 0x25 0x00 0xaa 0x80 0x80 2>>/dev/null) -eeprom1_full=$eeprom_part1$eeprom_part2 -eeprom1_full=$(echo $eeprom1_full | sed 's/[[:space:]]//g') -eeprom1_path="/sys/bus/i2c/devices/0-0055/eeprom" -eeprom1_full=$(echo $eeprom1_full | sed -e 's/ //g') -echo $eeprom1_full > $eeprom1_path +board_ver=$(i2cget -f -y 0 0x55 0x0 1>/dev/null 2>/dev/null; echo $?) + +if [ $board_ver != 0 ]; then + eeprom_part1=$(ipmitool raw 0x30 0x25 0x00 0xaa 0x80 0x0 2>>/dev/null) + eeprom_part2=$(ipmitool raw 0x30 0x25 0x00 0xaa 0x80 0x80 2>>/dev/null) + eeprom1_full=$eeprom_part1$eeprom_part2 + eeprom1_full=$(echo $eeprom1_full | sed 's/[[:space:]]//g') + eeprom1_path="/sys/bus/i2c/devices/0-0055/eeprom" + eeprom1_full=$(echo $eeprom1_full | sed -e 's/ //g') + echo $eeprom1_full > $eeprom1_path +fi + exit 0 diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-fanthrml-monitor b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-fanthrml-monitor old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-led-monitor b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-led-monitor old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-psu-monitor b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-psu-monitor old mode 100644 new mode 100755 index 180456f6a8aa..793e022823cb --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-psu-monitor +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-psu-monitor @@ -44,13 +44,8 @@ add_byte(){ # string_read [start byte] [length] string_read(){ value="" - len=$(echo $val | awk '{print $'"$1"'}') - byte_hex_test $len - if [ $? -eq 0 ]; then - return 0 - fi - len=$(printf "%d" 0x$len) - s=$(($1 + 1)) + len=$2 + s=$(($1)) e=$(($1 + len - 1)) for i in $(seq $s $e) do @@ -189,6 +184,17 @@ get_PSU_information() if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-0059/fault fi + + byte_read 41 + if [ $? -eq 1 ];then + echo $value > /sys/bus/i2c/devices/0-005a/pwm + fi + + byte_read 42 + if [ $? -eq 1 ];then + echo $value > /sys/bus/i2c/devices/0-0059/pwm + fi + fi #____________________________________________________________________________ @@ -196,35 +202,46 @@ get_PSU_information() val=$(ipmitool raw 0x30 0x8a 2>>/dev/null) if [ -e /sys/bus/i2c/devices/0-005a/vendor ] && [ -e /sys/bus/i2c/devices/0-0059/vendor ];then #PSU1 mfr_ID - string_read 1 + string_read 1 20 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-005a/vendor fi #PSU2 mfr_ID - string_read 21 + string_read 21 20 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-0059/vendor fi #PSU1 mfr_model - string_read 41 + string_read 41 20 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-005a/model fi #PSU2 mfr_model - string_read 61 + string_read 61 20 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-0059/model fi #PSU1 mfr_serial - string_read 81 + string_read 81 30 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-005a/sn fi - #PSU1 mfr_serial - string_read 111 + #PSU2 mfr_serial + string_read 111 30 if [ $? -eq 1 ];then echo $value > /sys/bus/i2c/devices/0-0059/sn fi + + #PSU1 mfr_rev + string_read 141 2 + if [ $? -eq 1 ];then + echo $value > /sys/bus/i2c/devices/0-005a/rev + fi + #PSU2 mfr_serial + string_read 143 2 + if [ $? -eq 1 ];then + echo $value > /sys/bus/i2c/devices/0-0059/rev + fi fi } diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-eeprom-monitor b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-eeprom-monitor new file mode 100755 index 000000000000..a7213e3a9260 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-eeprom-monitor @@ -0,0 +1,596 @@ +#!/bin/bash + +debug_flag=0 +port_map=('00' '10' '11' '12' '13' '14' '15' '16' '17' '18' '19' '1a' '1b' '1c' '1d' '1e' '1f' '20' '21' '22' '23' '24' '25' '26' '27' '28' '29' '2a' '2b' '2c' '2d' '2e' '2f') + +port_init=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) + +port_sfp_type=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) + +board_ver=$(ipmitool raw 0x30 0x25 0x1 0xe0 0x1 0x0 1>/dev/null 2>/dev/null; echo $?) #error will get 1 means EVT, otherwise DVT + + +byte_hex_test() +{ + if ! [[ $1 =~ ^[0-9A-Fa-f]{2}$ ]] ; then + return 0 + else + return 1 + fi +} + +pmon_status_check() +{ + output=$( docker inspect -f '{{.State.Status}}' pmon 2>/dev/null) + if [ $? -eq 0 ]; then + if [ $output == 'running' ]; then + return 1 + else + return 0 + fi + else + return 0 + fi +} + +#$1=mux $2=channel $3=dev_addr, $4=reg, $5=val +bmc_write() +{ + if [ $board_ver == 1 ]; then + addr_8b=$(echo $(($3)) | awk '{printf $1}') + addr_8b=`expr $addr_8b \\* 2` + ipmitool raw 0x30 0x85 $1 $2 $addr_8b 2 $4 $5 1>>/dev/null 2>>/dev/null + sleep 1 + ipmitool raw 0x30 0x87 1>>/dev/null 2>>/dev/null + else + pmon_status_check + if [ $? -eq 1 ]; then + while [ $(docker exec pmon bash -c 'if [ -e /tmp/pause_eeprom_polling ]; then echo 1; else echo 0; fi') == '1' ]; do + sleep 0.1; + done + fi + mux_addr=$(((0x70 + $1 - 2) * 2)) + chan=$((1 << $2)) + addr_8b=$(echo $(($3)) | awk '{printf $1}') + addr_8b=`expr $addr_8b \\* 2` + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 $chan 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x25 0x1 $addr_8b 0x0 $4 $5 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + fi +} + +#$1=mux $2=channel $3=dev_addr, $4=reg, $5=len +bmc_read() +{ + if [ $board_ver == 1 ]; then + addr_8b=$(echo $(($3)) | awk '{printf $1}') + addr_8b=`expr $addr_8b \\* 2` + ipmitool raw 0x30 0x86 $1 $2 $addr_8b $5 $4 1>>/dev/null 2>>/dev/null + sleep 1 + val=$(ipmitool raw 0x30 0x87 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + return 1 + else + return 0 + fi + else + mux_addr=$(((0x70 + $1 - 2) * 2)) + chan=$((1 << $2)) + addr_8b=$(echo $(($3)) | awk '{printf $1}') + addr_8b=`expr $addr_8b \\* 2` + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 $chan 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 $addr_8b $5 $4 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + return 1 + else + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + return 0 + fi + fi +} + + +bmc_dump() +{ + err=0 + mux_addr=$(((0x70 + $1 - 2) * 2)) + chan=$((1 << $2)) + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 $chan 1>>/dev/null 2>>/dev/null + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x0 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x0 2>>/dev/null) + if [ $? -eq 0 ];then + result1=$val + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result2=$val + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x1 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result3=$val + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x2 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result4=$val + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x3 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result5=$val + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x10 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result6=$val + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x11 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x80 0x80 2>>/dev/null) + if [ $? -eq 0 ];then + result7=$val + else + err=1 + fi + + + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + + if [ $err -eq 0 ];then + return 1 + else + return 0 + fi +} + +bmc_update_dynamic() +{ + local port=$1 + i2cmux_dev=0 + i2cmux_dev=`expr $port / 8` + i2cmux_dev=`expr $i2cmux_dev + 2` + ch=`expr $port % 8` + + if [ ${port_sfp_type[$port]} -eq 17 ]; then + err=0 + mux_addr=$(((0x70 + $i2cmux_dev - 2) * 2)) + chan=$((1 << $ch)) + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 $chan 1>>/dev/null 2>>/dev/null + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x0 1>>/dev/null 2>>/dev/null + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x3 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/rx_los" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x4 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/tx_fault" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x56 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/disable" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x24 0x16 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + result=$(echo $result | sed 's/[[:space:]]//g') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/qsfp_dom_bulk" + result=$(echo $result | sed -e 's/ //g') + echo $result > $result_path + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + + if [ $err -eq 0 ];then + return 1 + else + return 0 + fi + + elif [ ${port_sfp_type[$port]} -eq 24 ]; then + err=0 + mux_addr=$(((0x70 + $i2cmux_dev - 2) * 2)) + chan=$((1 << $ch)) + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 $chan 1>>/dev/null 2>>/dev/null + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x0 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x2 0xe 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + result=$(echo $result | sed 's/[[:space:]]//g') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/tempe" + result=$(echo $result | sed -e 's/ //g') + echo $result > $result_path + else + err=1 + fi + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x2 0x10 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + result=$(echo $result | sed 's/[[:space:]]//g') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/volte" + result=$(echo $result | sed -e 's/ //g') + echo $result > $result_path + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x10 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x82 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/disable" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 0xa0 0x0 0x7f 0x11 1>>/dev/null 2>>/dev/null + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x87 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/tx_fault" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x1 0x93 2>>/dev/null) + if [ $? -eq 0 ];then + result=$(echo $val | awk '{printf $1}') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/rx_los" + result=$( printf "%d" 0x$result ) + echo $result > $result_path + else + err=1 + fi + + val=$(ipmitool raw 0x30 0x25 0x1 0xa0 0x30 0x9a 2>>/dev/null) + if [ $? -eq 0 ];then + result=$val + result=$(echo $result | sed 's/[[:space:]]//g') + result_path="/sys/bus/i2c/devices/0-00"${port_map[$((port + 1))]}"/qsfp_dd_chan_mon" + result=$(echo $result | sed -e 's/ //g') + echo $result > $result_path + else + err=1 + fi + + ipmitool raw 0x30 0x25 0x1 $mux_addr 0x0 0x0 1>>/dev/null 2>>/dev/null + + if [ $err -eq 0 ];then + return 1 + else + return 0 + fi + fi +} + +#$1=port_no +bmc_qsfp_eeprom_read() +{ + local port=$1 + local eeprom_part1 + local eeprom_part2 + local eeprom_part3 + local eeprom_part4 + local eeprom_part5 + local eeprom_part6 + local eeprom_part7 + local eeprom1_full + local eeprom2_full + local eeprom3_full + + port=`expr $port - 1` + i2cmux_dev=0 + i2cmux_dev=`expr $port / 8` + i2cmux_dev=`expr $i2cmux_dev + 2` + ch=`expr $port % 8` + if [ ${port_init[$port]} -eq 0 ]; then + if [ $board_ver == 1 ]; then + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x00 + bmc_read $i2cmux_dev $ch 0x50 0 128 + if [ $? -eq 1 ];then + eeprom_part1=$result + else + return 1 + fi + + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part2=$result + else + return 1 + fi + + #QSFP-DD page1 + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x01 + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part3=$result + else + return 1 + fi + + #QSFP-DD page2 + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x2 + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part4=$result + else + return 1 + fi + + #QSFP-DD page3 + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x3 + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part5=$result + else + return 1 + fi + + #QSFP-DD page10 + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x10 + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part6=$result + else + return 1 + fi + + #QSFP-DD page11 + bmc_write $i2cmux_dev $ch 0x50 0x7f 0x11 + bmc_read $i2cmux_dev $ch 0x50 128 128 + if [ $? -eq 1 ];then + eeprom_part7=$result + else + return 1 + fi + else + #pmon_status_check + #if [ $? -eq 1 ]; then + # while [ $(docker exec pmon bash -c 'if [ -e /tmp/pause_eeprom_polling ]; then echo 1; else echo 0; fi') == '1' ]; do + # sleep 0.1; + # done + #fi + + bmc_dump $i2cmux_dev $ch + if [ $? -eq 1 ];then + eeprom_part1=$result1 + eeprom_part2=$result2 + eeprom_part3=$result3 + eeprom_part4=$result4 + eeprom_part5=$result5 + eeprom_part6=$result6 + eeprom_part7=$result7 + else + return 1 + fi + fi + fi + + if [ ${port_init[$port]} -eq 1 ]; then + + eeprom1_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom1" + check=$(od -An -tx1 -w1 -v $eeprom1_path | head -n 1) + if [ $check != '00' ] && [ $check != 'ff' ] ; then + if [ -e /tmp/plugin_module_event ]; then + return + fi + + bmc_update_dynamic $port + if [ $? -eq 0 ];then + return 1 + fi + else + port_init[$port]=0 + fi + fi + + + if [ ${port_init[$port]} -eq 0 ]; then + sfp_type=$(echo $eeprom_part1 | awk '{printf $1}') + byte_hex_test $sfp_type + if [ $? -eq 0 ]; then + return + fi + sfp_type=$( printf "%d" 0x$sfp_type ) + port_sfp_type[$((i - 1))]=$sfp_type + #get temperature + if [ $sfp_type -eq 24 ];then + temp=$(echo $eeprom_part1 | awk '{printf $15}') + if [ $temp != "" ];then + temp=$( printf "%d" 0x$temp ) + temp_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/temp" + echo $temp > $temp_path + fi + elif [ $sfp_type -eq 17 ];then + temp=$(echo $eeprom_part1 | awk '{printf $23}') + if [ $temp != "" ];then + temp=$( printf "%d" 0x$temp ) + temp_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/temp" + echo $temp > $temp_path + fi + fi + + #get lp_mode + lpmod_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/lp_mode" + if [ $sfp_type -eq 24 ];then + lpmod=$(echo $eeprom_part1 | awk '{printf $27}') + if [ $lpmod != "" ];then + state=$((lpmod&0x10)) + if [ $state -eq 16 ];then + echo 1 > $lpmod_path + else + echo 0 > $lpmod_path + fi + fi + elif [ $sfp_type -eq 17 ];then + lpmod=$(echo $eeprom_part1 | awk '{printf $93}') + if [ $lpmod != "" ];then + state=$((lpmod&0x02)) + if [ $state -eq 2 ];then + echo 1 > $lpmod_path + else + echo 0 > $lpmod_path + fi + fi + else + lpmod="" + fi + + eeprom1_full=$eeprom_part1$eeprom_part2 + eeprom1_full=$(echo $eeprom1_full | sed 's/[[:space:]]//g') + eeprom2_full=$eeprom_part3$eeprom_part4 + eeprom2_full=$(echo $eeprom2_full | sed 's/[[:space:]]//g') + eeprom3_full=$eeprom_part5$eeprom_part6$eeprom_part7 + eeprom3_full=$(echo $eeprom3_full | sed 's/[[:space:]]//g') + + if [ $debug_flag -eq 0 ];then + eeprom1_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom1" + eeprom1_full=$(echo $eeprom1_full | sed -e 's/ //g') + echo $eeprom1_full > $eeprom1_path + eeprom2_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom2" + eeprom2_full=$(echo $eeprom2_full | sed -e 's/ //g') + echo $eeprom2_full > $eeprom2_path + eeprom3_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom3" + eeprom3_full=$(echo $eeprom3_full | sed -e 's/ //g') + echo $eeprom3_full > $eeprom3_path + else + printf "\nPort %d EEPROM:" $1 + printf "\n-----------------------------------------------\n" + for i in $(seq 1 256); + do + printf "%s " ${eeprom1_full:0:2} + eeprom1_full=$(echo $eeprom1_full | sed 's/^..//') + + val=`expr $i % 16` + if [ $val -eq 0 ];then + printf "\n" + fi + done + printf "\n-----------------------------------------------\n" + fi + + if [ $board_ver == 0 ]; then + port_init[$port]=1 + if [ $port -lt 16 ];then + cpld_path="/sys/bus/i2c/devices/0-0006/" + else + cpld_path="/sys/bus/i2c/devices/0-0007/" + fi + echo 1 > $cpld_path"port"$((port + 1))"_data_rdy" + fi + fi + + return 0 +} + +TRANSCEIVER_DATA_READ() +{ + first_detect=0 + loop_after_plugin=0 + + while true + do + if [ -e /sys/bus/i2c/devices/0-0006/port1_present ] && [ -e /sys/bus/i2c/devices/0-0007/port32_present ] && [ -e /sys/bus/i2c/devices/0-002f/eeprom1 ];then + if [ $first_detect == 0 ]; then + ipmitool raw 0x30 0x25 0x1 0xe0 0x0 0x0 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x25 0x1 0xe2 0x0 0x0 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x25 0x1 0xe4 0x0 0x0 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x25 0x1 0xe6 0x0 0x0 1>>/dev/null 2>>/dev/null + fi + for i in $(seq 1 32); + do + if [ $i -le 16 ];then + cpld_path="/sys/bus/i2c/devices/0-0006/" + else + cpld_path="/sys/bus/i2c/devices/0-0007/" + fi + + pre=$(cat $cpld_path"port"$i"_present") + if [ $pre == 1 ]; then + bmc_qsfp_eeprom_read $i + if [ $first_detect == 0 ]; then + first_detect=1 + fi + else + port_init[$((i - 1))]=0 + port_sfp_type[$((i - 1))]=0 + fi + done + + if [ $first_detect == 1 ]; then + touch /tmp/eeprom_init_done + fi + + if [ -e /tmp/plugin_module_event ]; then + loop_after_plugin=$((loop_after_plugin + 1)) + + if [ $loop_after_plugin -gt 2 ]; then + rm /tmp/plugin_module_event + loop_after_plugin=0 + fi + fi + + pmon_status_check + if [ $? -eq 1 ]; then + if [ $first_detect == 1 ]; then + docker exec pmon bash -c 'echo "" > /tmp/eeprom_init_done' + fi + else + first_detect=0 + fi + + sleep 1; + fi + done +} + +TRANSCEIVER_DATA_READ diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-monitor b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-monitor old mode 100644 new mode 100755 index 645b8528851f..f2eb928346d7 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-monitor +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-qsfp-monitor @@ -1,7 +1,7 @@ #!/bin/bash -debug_flag=0 -port_map=('00' '10' '11' '12' '13' '14' '15' '16' '17' '18' '19' '1a' '1b' '1c' '1d' '1e' '1f' '20' '21' '22' '23' '24' '25' '26' '27' '28' '29' '2a' '2b' '2c' '2d' '2e' '2f') +board_ver=$(ipmitool raw 0x30 0x25 0x1 0xe0 0x1 0x0 1>/dev/null 2>/dev/null; echo $?) #error will get 1 means EVT, otherwise DVT + port_1_8_presence=0 port_9_16_presence=0 port_17_24_presence=0 @@ -10,6 +10,14 @@ port_1_8_reset=0 port_9_16_reset=0 port_17_24_reset=0 port_25_32_reset=0 +port_1_8_lpmode=0 +port_9_16_lpmode=0 +port_17_24_lpmode=0 +port_25_32_lpmode=0 +port_1_8_modsel=0 +port_9_16_modsel=0 +port_17_24_modsel=0 +port_25_32_modsel=0 result=0 pre_port_1_8_reset=256 @@ -25,6 +33,8 @@ pre_port_9_16_modsel=256 pre_port_17_24_modsel=256 pre_port_25_32_modsel=256 +port_pre_present=(0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0) + byte_hex_test() { if ! [[ $1 =~ ^[0-9A-Fa-f]{2}$ ]] ; then @@ -34,405 +44,517 @@ byte_hex_test() fi } -#$1=mux $2=channel $3=dev_addr, $4=reg, $5=val -bmc_write() -{ - addr_8b=$(echo $(($3)) | awk '{printf $1}') - addr_8b=`expr $addr_8b \\* 2` - ipmitool raw 0x30 0x85 $1 $2 $addr_8b 2 $4 $5 1>>/dev/null 2>>/dev/null - sleep 1 - ipmitool raw 0x30 0x87 1>>/dev/null 2>>/dev/null -} - -#$1=mux $2=channel $3=dev_addr, $4=reg, $5=len -bmc_read() +bmc_read_low_speed_signal_status() { - addr_8b=$(echo $(($3)) | awk '{printf $1}') - addr_8b=`expr $addr_8b \\* 2` - ipmitool raw 0x30 0x86 $1 $2 $addr_8b $5 $4 1>>/dev/null 2>>/dev/null - sleep 1 - val=$(ipmitool raw 0x30 0x87 2>>/dev/null) - if [ $? -eq 0 ];then - result=$val - return 1 - else + val=$(ipmitool raw 0x30 0x8d 2>/dev/null); + if [ $? -ne 0 ];then return 0 fi -} -bmc_qsfp_lpmode_write() -{ + port_1_8_presence=$(echo $val | awk '{printf $1}') + byte_hex_test $port_1_8_presence + if [ $? -eq 0 ]; then + return 0 + fi + port_1_8_presence=$( printf "%d" 0x$port_1_8_presence ) - cpld_path="/sys/bus/i2c/devices/0-0006/" - val=0 - for i in $(seq 1 8); - do - lpmode_path=$cpld_path"port"$i"_lpmode" - lpmode_input=$(cat $lpmode_path | awk '{printf $1}') - val=$((val | (lpmode_input << ($i - 1)))) - done - if [ $val -ne $pre_port_1_8_lpmode ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x50 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_1_8_lpmode=$val + port_9_16_presence=$(echo $val | awk '{printf $2}') + byte_hex_test $port_9_16_presence + if [ $? -eq 0 ]; then + return 0 fi - val=0 - for i in $(seq 9 16); - do - lpmode_path=$cpld_path"port"$i"_lpmode" - lpmode_input=$(cat $lpmode_path | awk '{printf $1}') - val=$((val | (lpmode_input << ($i - 9)))) - done + port_9_16_presence=$( printf "%d" 0x$port_9_16_presence ) - if [ $val -ne $pre_port_9_16_lpmode ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x51 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_9_16_lpmode=$val + port_17_24_presence=$(echo $val | awk '{printf $9}') + byte_hex_test $port_17_24_presence + if [ $? -eq 0 ]; then + return 0 fi + port_17_24_presence=$( printf "%d" 0x$port_17_24_presence ) - cpld_path="/sys/bus/i2c/devices/0-0007/" - val=0 - for i in $(seq 17 24); - do - lpmode_path=$cpld_path"port"$i"_lpmode" - lpmode_input=$(cat $lpmode_path | awk '{printf $1}') - val=$((val | (lpmode_input << ($i - 17)))) - done + port_25_32_presence=$(echo $val | awk '{printf $10}') + byte_hex_test $port_25_32_presence + if [ $? -eq 0 ]; then + return 0 + fi + port_25_32_presence=$( printf "%d" 0x$port_25_32_presence ) - if [ $val -ne $pre_port_17_24_lpmode ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x50 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_17_24_lpmode=$val + port_1_8_reset=$(echo $val | awk '{printf $3}') + byte_hex_test $port_1_8_reset + if [ $? -eq 0 ]; then + return 0 fi - val=0 - for i in $(seq 25 32); - do - lpmode_path=$cpld_path"port"$i"_lpmode" - lpmode_input=$(cat $lpmode_path | awk '{printf $1}') - val=$((val | (lpmode_input << ($i - 25)))) - done + port_1_8_reset=$( printf "%d" 0x$port_1_8_reset ) - if [ $val -ne $pre_port_25_32_lpmode ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x51 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_25_32_lpmode=$val + port_9_16_reset=$(echo $val | awk '{printf $4}') + byte_hex_test $port_9_16_reset + if [ $? -eq 0 ]; then + return 0 fi + port_9_16_reset=$( printf "%d" 0x$port_9_16_reset ) + port_17_24_reset=$(echo $val | awk '{printf $11}') + byte_hex_test $port_17_24_reset + if [ $? -eq 0 ]; then + return 0 + fi + port_17_24_reset=$( printf "%d" 0x$port_17_24_reset ) - return 0 -} + port_25_32_reset=$(echo $val | awk '{printf $12}') + byte_hex_test $port_25_32_reset + if [ $? -eq 0 ]; then + return 0 + fi + port_25_32_reset=$( printf "%d" 0x$port_25_32_reset ) -bmc_qsfp_modsel_write() -{ + port_1_8_lpmode=$(echo $val | awk '{printf $5}') + byte_hex_test $port_1_8_lpmode + if [ $? -eq 0 ]; then + return 0 + fi + port_1_8_lpmode=$( printf "%d" 0x$port_1_8_lpmode ) - cpld_path="/sys/bus/i2c/devices/0-0006/" - val=0 - for i in $(seq 1 8); - do - modsel_path=$cpld_path"port"$i"_modsel" - modsel_input=$(cat $modsel_path | awk '{printf $1}') - val=$((val | (modsel_input << ($i - 1)))) - done + port_9_16_lpmode=$(echo $val | awk '{printf $6}') + byte_hex_test $port_9_16_lpmode + if [ $? -eq 0 ]; then + return 0 + fi + port_9_16_lpmode=$( printf "%d" 0x$port_9_16_lpmode ) - val=$((0xff - val)) - if [ $val -ne $pre_port_1_8_modsel ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x60 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_1_8_modsel=$val + port_17_24_lpmode=$(echo $val | awk '{printf $13}') + byte_hex_test $port_17_24_lpmode + if [ $? -eq 0 ]; then + return 0 fi - val=0 - for i in $(seq 9 16); - do - modsel_path=$cpld_path"port"$i"_modsel" - modsel_input=$(cat $modsel_path | awk '{printf $1}') - val=$((val | (modsel_input << ($i - 9)))) - done + port_17_24_lpmode=$( printf "%d" 0x$port_17_24_lpmode ) - val=$((0xff - val)) - if [ $val -ne $pre_port_9_16_modsel ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x61 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_9_16_modsel=$val + port_25_32_lpmode=$(echo $val | awk '{printf $14}') + byte_hex_test $port_25_32_lpmode + if [ $? -eq 0 ]; then + return 0 fi + port_25_32_lpmode=$( printf "%d" 0x$port_25_32_lpmode ) - cpld_path="/sys/bus/i2c/devices/0-0007/" - val=0 - for i in $(seq 17 24); - do - modsel_path=$cpld_path"port"$i"_modsel" - modsel_input=$(cat $modsel_path | awk '{printf $1}') - val=$((val | (modsel_input << ($i - 17)))) - done + port_1_8_modsel=$(echo $val | awk '{printf $7}') + byte_hex_test $port_1_8_modsel + if [ $? -eq 0 ]; then + return 0 + fi + port_1_8_modsel=$( printf "%d" 0x$port_1_8_modsel ) - val=$((0xff - val)) - if [ $val -ne $pre_port_17_24_modsel ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x60 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_17_24_modsel=$val + port_9_16_modsel=$(echo $val | awk '{printf $8}') + byte_hex_test $port_9_16_modsel + if [ $? -eq 0 ]; then + return 0 fi - val=0 - for i in $(seq 25 32); - do - modsel_path=$cpld_path"port"$i"_modsel" - modsel_input=$(cat $modsel_path | awk '{printf $1}') - val=$((val | (modsel_input << ($i - 25)))) - done + port_9_16_modsel=$( printf "%d" 0x$port_9_16_modsel ) - val=$((0xff - val)) - if [ $val -ne $pre_port_25_32_modsel ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x61 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_25_32_modsel=$val + port_17_24_modsel=$(echo $val | awk '{printf $15}') + byte_hex_test $port_17_24_modsel + if [ $? -eq 0 ]; then + return 0 fi + port_17_24_modsel=$( printf "%d" 0x$port_17_24_modsel ) + port_25_32_modsel=$(echo $val | awk '{printf $16}') + byte_hex_test $port_25_32_modsel + if [ $? -eq 0 ]; then + return 0 + fi + port_25_32_modsel=$( printf "%d" 0x$port_25_32_modsel ) - return 0 + return 1 } -bmc_qsfp_presence_read() +bmc_qsfp_lpmode_write() { - a=0 - tmp1=$(ipmitool raw 0x30 0x25 0x00 0x0c 0x1 0x30 2>>/dev/null) - a=$((a+$?)) - tmp1=$(echo $tmp1 | awk '{printf $1}') - sleep 0.05 - tmp2=$(ipmitool raw 0x30 0x25 0x00 0x0c 0x1 0x31 2>>/dev/null) - a=$((a+$?)) - tmp2=$(echo $tmp2 | awk '{printf $1}') - sleep 0.05 - tmp3=$(ipmitool raw 0x30 0x25 0x00 0x0e 0x1 0x30 2>>/dev/null) - a=$((a+$?)) - tmp3=$(echo $tmp3 | awk '{printf $1}') - sleep 0.05 - tmp4=$(ipmitool raw 0x30 0x25 0x00 0x0e 0x1 0x31 2>>/dev/null) - a=$((a+$?)) - tmp4=$(echo $tmp4 | awk '{printf $1}') - sleep 0.05 - if [ $a -eq 0 ];then - byte_hex_test $tmp1 - if [ $? -eq 0 ]; then - return 0 + + if [ $board_ver == 1 ]; then + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 1)))) + done + if [ $val -ne $pre_port_1_8_lpmode ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x50 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_1_8_lpmode=$val fi - port_1_8_presence=$( printf "%d" 0x$tmp1 ) - byte_hex_test $tmp2 - if [ $? -eq 0 ]; then - return 0 + val=0 + for i in $(seq 9 16); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 9)))) + done + + if [ $val -ne $pre_port_9_16_lpmode ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x51 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_9_16_lpmode=$val fi - port_9_16_presence=$( printf "%d" 0x$tmp2 ) - byte_hex_test $tmp3 - if [ $? -eq 0 ]; then - return 0 + + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 17)))) + done + + if [ $val -ne $pre_port_17_24_lpmode ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x50 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_17_24_lpmode=$val fi - port_17_24_presence=$( printf "%d" 0x$tmp3 ) - byte_hex_test $tmp4 - if [ $? -eq 0 ]; then - return 0 + val=0 + for i in $(seq 25 32); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 25)))) + done + + if [ $val -ne $pre_port_25_32_lpmode ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x51 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_25_32_lpmode=$val fi - port_25_32_presence=$( printf "%d" 0x$tmp4 ) - return 1 + + else + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 1)))) + done + val2=0 + for i in $(seq 9 16); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val2=$((val2 | (lpmode_input << ($i - 9)))) + done + + if [ $val -ne $port_1_8_lpmode ] || [ $val2 -ne $port_9_16_lpmode ]; then + ipmitool raw 0x30 0x8c 0x0 0x1 $val $val2 1>>/dev/null 2>>/dev/null + fi + + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val=$((val | (lpmode_input << ($i - 17)))) + done + + val2=0 + for i in $(seq 25 32); + do + lpmode_path=$cpld_path"port"$i"_lpmode" + lpmode_input=$(cat $lpmode_path | awk '{printf $1}') + val2=$((val2 | (lpmode_input << ($i - 25)))) + done + + if [ $val -ne $port_17_24_lpmode ] || [ $val2 -ne $port_25_32_lpmode ]; then + ipmitool raw 0x30 0x8c 0x1 0x1 $val $val2 1>>/dev/null 2>>/dev/null + fi + fi return 0 } -bmc_qsfp_reset_write() +bmc_qsfp_modsel_write() { - cpld_path="/sys/bus/i2c/devices/0-0006/" - val=0 - for i in $(seq 1 8); - do - reset_path=$cpld_path"port"$i"_reset" - reset_input=$(cat $reset_path | awk '{printf $1}') - val=$((val | (reset_input << ($i - 1)))) - done + if [ $board_ver == 1 ]; then + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 1)))) + done - val=$((0xff - val)) - if [ $val -ne $pre_port_1_8_reset ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x20 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_1_8_reset=$val - fi - val=0 - for i in $(seq 9 16); - do - reset_path=$cpld_path"port"$i"_reset" - reset_input=$(cat $reset_path | awk '{printf $1}') - val=$((val | (reset_input << ($i - 9)))) - done + val=$((0xff - val)) + if [ $val -ne $pre_port_1_8_modsel ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x60 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_1_8_modsel=$val + fi + val=0 + for i in $(seq 9 16); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 9)))) + done - val=$((0xff - val)) - if [ $val -ne $pre_port_9_16_reset ]; then - ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x21 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_9_16_reset=$val - fi + val=$((0xff - val)) + if [ $val -ne $pre_port_9_16_modsel ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x61 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_9_16_modsel=$val + fi - cpld_path="/sys/bus/i2c/devices/0-0007/" - val=0 - for i in $(seq 17 24); - do - reset_path=$cpld_path"port"$i"_reset" - reset_input=$(cat $reset_path | awk '{printf $1}') - val=$((val | (reset_input << ($i - 17)))) - done + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 17)))) + done - val=$((0xff - val)) - if [ $val -ne $pre_port_17_24_reset ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x20 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_17_24_reset=$val - fi - val=0 - for i in $(seq 25 32); - do - reset_path=$cpld_path"port"$i"_reset" - reset_input=$(cat $reset_path | awk '{printf $1}') - val=$((val | (reset_input << ($i - 25)))) - done + val=$((0xff - val)) + if [ $val -ne $pre_port_17_24_modsel ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x60 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_17_24_modsel=$val + fi + val=0 + for i in $(seq 25 32); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 25)))) + done - val=$((0xff - val)) - if [ $val -ne $pre_port_25_32_reset ]; then - ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x21 $val 1>>/dev/null 2>>/dev/null - sleep 0.05 - pre_port_25_32_reset=$val - fi + val=$((0xff - val)) + if [ $val -ne $pre_port_25_32_modsel ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x61 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_25_32_modsel=$val + fi + else + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 1)))) + done + val=$((0xff - val)) + + val2=0 + for i in $(seq 9 16); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val2=$((val2 | (modsel_input << ($i - 9)))) + done + + val2=$((0xff - val2)) + if [ $val -ne $port_1_8_modsel ] || [ $val2 -ne $port_9_16_modsel ]; then + ipmitool raw 0x30 0x8c 0x0 0x2 $val $val2 1>>/dev/null 2>>/dev/null + fi + + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val=$((val | (modsel_input << ($i - 17)))) + done + + val=$((0xff - val)) + + val2=0 + for i in $(seq 25 32); + do + modsel_path=$cpld_path"port"$i"_modsel" + modsel_input=$(cat $modsel_path | awk '{printf $1}') + val2=$((val2 | (modsel_input << ($i - 25)))) + done + + val2=$((0xff - val2)) + if [ $val -ne $port_17_24_modsel ] || [ $val2 -ne $port_25_32_modsel ]; then + ipmitool raw 0x30 0x8c 0x1 0x2 $val $val2 1>>/dev/null 2>>/dev/null + fi + fi return 0 } -#$1=port_no -bmc_qsfp_eeprom_read() +bmc_qsfp_presence_read() { - local port=$1 - local eeprom_part1 - local eeprom_part2 - local eeprom_part3 - local eeprom_part4 - local eeprom1_full - local eeprom2_full - - port=`expr $port - 1` - i2cmux_dev=0 - i2cmux_dev=`expr $port / 8` - i2cmux_dev=`expr $i2cmux_dev + 2` - ch=`expr $port % 8` - - bmc_write $i2cmux_dev $ch 0x50 0x7f 0x00 - bmc_read $i2cmux_dev $ch 0x50 0 128 - if [ $? -eq 1 ];then - eeprom_part1=$result - else - return 1 - fi + if [ $board_ver == 1 ]; then + a=0 + tmp1=$(ipmitool raw 0x30 0x25 0x00 0x0c 0x1 0x30 2>>/dev/null) + a=$((a+$?)) + tmp1=$(echo $tmp1 | awk '{printf $1}') + sleep 0.05 + tmp2=$(ipmitool raw 0x30 0x25 0x00 0x0c 0x1 0x31 2>>/dev/null) + a=$((a+$?)) + tmp2=$(echo $tmp2 | awk '{printf $1}') + sleep 0.05 + tmp3=$(ipmitool raw 0x30 0x25 0x00 0x0e 0x1 0x30 2>>/dev/null) + a=$((a+$?)) + tmp3=$(echo $tmp3 | awk '{printf $1}') + sleep 0.05 + tmp4=$(ipmitool raw 0x30 0x25 0x00 0x0e 0x1 0x31 2>>/dev/null) + a=$((a+$?)) + tmp4=$(echo $tmp4 | awk '{printf $1}') + sleep 0.05 + if [ $a -eq 0 ];then + byte_hex_test $tmp1 + if [ $? -eq 0 ]; then + return 0 + fi + port_1_8_presence=$( printf "%d" 0x$tmp1 ) + byte_hex_test $tmp2 + if [ $? -eq 0 ]; then + return 0 + fi + port_9_16_presence=$( printf "%d" 0x$tmp2 ) + byte_hex_test $tmp3 + if [ $? -eq 0 ]; then + return 0 + fi + port_17_24_presence=$( printf "%d" 0x$tmp3 ) + byte_hex_test $tmp4 + if [ $? -eq 0 ]; then + return 0 + fi + port_25_32_presence=$( printf "%d" 0x$tmp4 ) + return 1 + fi - bmc_read $i2cmux_dev $ch 0x50 128 128 - if [ $? -eq 1 ];then - eeprom_part2=$result + return 0 else - return 1 + bmc_read_low_speed_signal_status + if [ $? -eq 0 ]; then + return 0 + fi fi +} - #QSFP-DD page2 - bmc_write $i2cmux_dev $ch 0x50 0x7f 0x02 - bmc_read $i2cmux_dev $ch 0x50 128 128 - if [ $? -eq 1 ];then - eeprom_part3=$result - else - return 1 - fi +bmc_qsfp_reset_write() +{ - #QSFP-DD page11 - bmc_write $i2cmux_dev $ch 0x50 0x7f 0x11 - bmc_read $i2cmux_dev $ch 0x50 128 128 - if [ $? -eq 1 ];then - eeprom_part4=$result - else - return 1 - fi + if [ $board_ver == 1 ]; then + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 1)))) + done - sfp_type=$(echo $eeprom_part1 | awk '{printf $1}') - byte_hex_test $sfp_type - if [ $? -eq 0 ]; then - return - fi - sfp_type=$( printf "%d" 0x$sfp_type ) - - #get temperature - temp=$(echo $eeprom_part1 | awk '{printf $15}') - if [ $temp != "" ];then - temp=$( printf "%d" 0x$temp ) - temp_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/temp" - echo $temp > $temp_path - fi + val=$((0xff - val)) + if [ $val -ne $pre_port_1_8_reset ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x20 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_1_8_reset=$val + fi + val=0 + for i in $(seq 9 16); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 9)))) + done - #get lp_mode - lpmod_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/lp_mode" - if [ $sfp_type -eq 24 ];then - lpmod=$(echo $eeprom_part1 | awk '{printf $27}') - if [ $lpmod != "" ];then - state=$((lpmod&0x10)) - if [ $state -eq 16 ];then - echo 1 > $lpmod_path - else - echo 0 > $lpmod_path - fi + val=$((0xff - val)) + if [ $val -ne $pre_port_9_16_reset ]; then + ipmitool raw 0x30 0x25 0x00 0x0c 0x0 0x21 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_9_16_reset=$val fi - elif [ $sfp_type -eq 17 ];then - lpmod=$(echo $eeprom_part1 | awk '{printf $93}') - if [ $lpmod != "" ];then - state=$((lpmod&0x02)) - if [ $state -eq 2 ];then - echo 1 > $lpmod_path - else - echo 0 > $lpmod_path - fi + + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 17)))) + done + + val=$((0xff - val)) + if [ $val -ne $pre_port_17_24_reset ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x20 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_17_24_reset=$val fi - else - lpmod="" - fi + val=0 + for i in $(seq 25 32); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 25)))) + done - eeprom1_full=$eeprom_part1$eeprom_part2 - eeprom1_full=$(echo $eeprom1_full | sed 's/[[:space:]]//g') - eeprom2_full=$eeprom_part3$eeprom_part4 - eeprom2_full=$(echo $eeprom2_full | sed 's/[[:space:]]//g') - - if [ $debug_flag -eq 0 ];then - eeprom1_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom1" - eeprom1_full=$(echo $eeprom1_full | sed -e 's/ //g') - echo $eeprom1_full > $eeprom1_path - eeprom2_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom2" - eeprom2_full=$(echo $eeprom2_full | sed -e 's/ //g') - echo $eeprom2_full > $eeprom2_path + val=$((0xff - val)) + if [ $val -ne $pre_port_25_32_reset ]; then + ipmitool raw 0x30 0x25 0x00 0x0e 0x0 0x21 $val 1>>/dev/null 2>>/dev/null + sleep 0.05 + pre_port_25_32_reset=$val + fi else - printf "\nPort %d EEPROM:" $1 - printf "-----------------------------------------------\n" - for i in $(seq 1 256); + cpld_path="/sys/bus/i2c/devices/0-0006/" + val=0 + for i in $(seq 1 8); do - printf "%s " ${eeprom1_full:0:2} - eeprom1_full=$(echo $eeprom1_full | sed 's/^..//') + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 1)))) + done - val=`expr $i % 16` - if [ $val -eq 0 ];then - printf "\n" - fi + val=$((0xff - val)) + val2=0 + for i in $(seq 9 16); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val2=$((val2 | (reset_input << ($i - 9)))) done - printf "\n-----------------------------------------------\n" + + val2=$((0xff - val2)) + if [ $val -ne $port_1_8_reset ] || [ $val2 -ne $port_9_16_reset ]; then + ipmitool raw 0x30 0x8c 0x0 0x0 $val $val2 1>>/dev/null 2>>/dev/null + fi + + cpld_path="/sys/bus/i2c/devices/0-0007/" + val=0 + for i in $(seq 17 24); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val=$((val | (reset_input << ($i - 17)))) + done + + val=$((0xff - val)) + val2=0 + for i in $(seq 25 32); + do + reset_path=$cpld_path"port"$i"_reset" + reset_input=$(cat $reset_path | awk '{printf $1}') + val2=$((val2 | (reset_input << ($i - 25)))) + done + + val2=$((0xff - val2)) + if [ $val -ne $port_17_24_reset ] || [ $val2 -ne $port_25_32_reset ]; then + ipmitool raw 0x30 0x8c 0x1 0x0 $val $val2 1>>/dev/null 2>>/dev/null + fi fi return 0 } -#$1=port_no -bmc_qsfp_eeprom_clear() -{ - eeprom1_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom1" - echo "" > $eeprom1_path - eeprom2_path="/sys/bus/i2c/devices/0-00"${port_map[$1]}"/eeprom2" - echo "" > $eeprom2_path -} - QSFP_monitor() { while true @@ -463,16 +585,24 @@ QSFP_monitor() if [ $is_presence -eq 0 ];then echo 1 > $cpld_path"port"$i"_present" - bmc_qsfp_eeprom_read $i + if [ $board_ver == 0 ]; then + if [ -e /tmp/eeprom_init_done ] && [ ${port_pre_present[$((i - 1))]} -eq 0 ]; then + touch /tmp/plugin_module_event + fi + + port_pre_present[$((i - 1))]=1 + fi else echo 0 > $cpld_path"port"$i"_present" - bmc_qsfp_eeprom_clear $i + echo 0 > $cpld_path"port"$i"_data_rdy" + if [ $board_ver == 0 ]; then + port_pre_present[$((i - 1))]=0 + fi fi done - sleep 2 - else - sleep 1 fi + + sleep 0.2 done } diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-send-temp-to-bmc b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-send-temp-to-bmc new file mode 100755 index 000000000000..4f2c1be21ab1 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/sonic-send-temp-to-bmc @@ -0,0 +1,51 @@ +#!/bin/bash +board_ver=$(ipmitool raw 0x30 0x25 0x1 0xe0 0x1 0x0 1>/dev/null 2>/dev/null; echo $?) #error will get 1 means EVT, otherwise DVT + +send_temp_to_bmc() +{ + c_path=$(ls /sys/devices/platform/coretemp.0/hwmon/) + c_temp=$(cat /sys/class/hwmon/$c_path/temp1_input) + cputemp=`expr $c_temp / 1000` + + transceiver_temp="" + for i in $(seq 1 32); + do + index=$((i + 15)); + path="/sys/bus/i2c/devices/0-00$(printf "%x" $index)/temp"; + t_temp=$(cat $path) + transceiver_temp+="$transcevicer_temp $t_temp" + done + + m2_temp=$(smartctl -A /dev/sda | egrep ^194 | awk '{print $10}') + + d_dev=$(find /sys/devices/ -name 1-00\*) + d_path=$(ls $d_dev/hwmon/) + d_temp=$(cat /sys/class/hwmon/$d_path/temp1_input) + dimm_temp=`expr $d_temp / 1000` + + ipmitool raw 0x30 0x8b $cputemp $transceiver_temp $m2_temp $dimm_temp +} + +SEND_TEMP() +{ + boot_time_barrier=1 + while true + do + if [ -e /sys/bus/i2c/devices/0-0006/port1_present ] && [ -e /sys/bus/i2c/devices/0-0007/port32_present ] && [ -e /sys/bus/i2c/devices/0-002f/eeprom1 ];then + + if [ $board_ver == 0 ]; then + if [ $boot_time_barrier == 1 ]; then + if [ -e /tmp/eeprom_init_done ]; then + boot_time_barrier=0 + fi + else + send_temp_to_bmc + fi + fi + + sleep 1; + fi + done +} + +SEND_TEMP diff --git a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/wistron_6512_32r_util.py b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/wistron_6512_32r_util.py old mode 100644 new mode 100755 index 030942825df0..31cf25f4cbe9 --- a/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/wistron_6512_32r_util.py +++ b/platform/innovium/sonic-platform-modules-wistron/6512-32r/utils/wistron_6512_32r_util.py @@ -68,8 +68,6 @@ # PSU 'echo wistron_psu1 0x5a > /sys/bus/i2c/devices/i2c-0/new_device', 'echo wistron_psu2 0x59 > /sys/bus/i2c/devices/i2c-0/new_device', -# EEPROM -'echo wistron_syseeprom 0x55 > /sys/bus/i2c/devices/i2c-0/new_device', ] FORCE = 0 @@ -173,6 +171,7 @@ def driver_inserted(): 'modprobe ipmi_watchdog', 'modprobe i2c_dev', 'modprobe at24', +'modprobe i2c-imc', 'modprobe wistron_6512_32r_syseeprom', 'modprobe wistron_6512_32r_cpld', 'modprobe wistron_6512_32r_fan', @@ -242,6 +241,20 @@ def device_install(): if FORCE == 0: return status + + status, output = log_os_system("i2cget -y 0 0x55 0x0 1>/dev/null 2>/dev/null; echo $?", 1) + if status: + print(output) + if FORCE == 0: + return status + else: + if output == '0': + log_os_system("echo 24c02 0x55 > /sys/bus/i2c/devices/i2c-0/new_device", 1) + else: + log_os_system("echo wistron_syseeprom 0x55 > /sys/bus/i2c/devices/i2c-0/new_device", 1) + + + for i in range(0,len(sfp_map)): status, output = log_os_system("echo wistron_oom 0x"+str(sfp_map[i])+ " > /sys/bus/i2c/devices/i2c-0/new_device", 1) if status: @@ -324,12 +337,6 @@ def do_install(): else: print(PROJECT_NAME.upper()+" devices detected....") - status, output = log_os_system( - "/bin/sh /usr/local/bin/platform_api_mgnt.sh init", 1) - if status: - print(output) - if FORCE == 0: - return status return def do_uninstall(): diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/changelog b/platform/innovium/sonic-platform-modules-wistron/debian/changelog new file mode 100644 index 000000000000..12d04e4d0303 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/changelog @@ -0,0 +1,5 @@ +sonic-wistron-platform-modules (1.1) unstable; urgency=low + + * Initial release + + -- Haowei Chung Fri, 30 Aug 2019 14:48:00 +0800 diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/compat b/platform/innovium/sonic-platform-modules-wistron/debian/compat new file mode 100644 index 000000000000..b4de39476753 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/compat @@ -0,0 +1 @@ +11 diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/control b/platform/innovium/sonic-platform-modules-wistron/debian/control new file mode 100644 index 000000000000..00ad6637c378 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/control @@ -0,0 +1,14 @@ +Source: sonic-wistron-platform-modules +Section: main +Priority: extra +Maintainer: Wistron +Build-Depends: debhelper (>= 8.0.0), bzip2 +Standards-Version: 3.9.3 + +Package: sonic-platform-wistron-sw-to3200k +Architecture: amd64 +Description: kernel modules for platform devices such as fan, led, sfp + +Package: sonic-platform-wistron-6512-32r +Architecture: amd64 +Description: kernel modules for platform devices such as fan, led, sfp diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/rules b/platform/innovium/sonic-platform-modules-wistron/debian/rules new file mode 100755 index 000000000000..defb1f932d16 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/rules @@ -0,0 +1,143 @@ +#!/usr/bin/make -f +# -*- makefile -*- +# Sample debian/rules that uses debhelper. +# This file was originally written by Joey Hess and Craig Small. +# As a special exception, when this file is copied by dh-make into a +# dh-make output file, you may use that output file without restriction. +# This special exception was added by Craig Small in version 0.37 of dh-make. + +include /usr/share/dpkg/pkg-info.mk + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +export INSTALL_MOD_DIR:=extra + +PYTHON ?= python2 +PYTHON3 ?= python3 + +PACKAGE_PRE_NAME := sonic-platform-wistron +KVERSION ?= $(shell uname -r) +KERNEL_SRC := /lib/modules/$(KVERSION) +MOD_SRC_DIR:= $(shell pwd) +MODULE_DIRS := sw-to3200k 6512-32r +MODULE_DIR := modules +UTILS_DIR := utils +SERVICE_DIR := service +CONF_DIR := conf + +%: + dh $@ --with systemd,python2,python3 --buildsystem=pybuild + +clean: + dh_testdir + dh_testroot + dh_clean + +build: + #make modules -C $(KERNEL_SRC)/build M=$(MODULE_SRC) + (for mod in $(MODULE_DIRS); do \ + make modules -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/$${mod}/modules; \ + #$(PYTHON) $${mod}/setup.py build; \ + cd $(MOD_SRC_DIR)/$${mod}; \ + if [ -f setup.py ]; then \ + $(PYTHON3) setup.py bdist_wheel -d $(MOD_SRC_DIR)/$${mod}; \ + echo "Finished making whl package for $$mod"; \ + fi; \ + cd $(MOD_SRC_DIR); \ + done) + +binary: binary-arch binary-indep + # Nothing to do + +binary-arch: + # Nothing to do + +#install: build + #dh_testdir + #dh_testroot + #dh_clean -k + #dh_installdirs + +binary-indep: + dh_testdir + dh_installdirs + + # Custom package commands + (for mod in $(MODULE_DIRS); do \ + dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} $(KERNEL_SRC)/$(INSTALL_MOD_DIR); \ + dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} usr/local/bin; \ + dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} lib/systemd/system; \ + cp $(MOD_SRC_DIR)/$${mod}/$(MODULE_DIR)/*.ko debian/$(PACKAGE_PRE_NAME)-$${mod}/$(KERNEL_SRC)/$(INSTALL_MOD_DIR); \ + #cp $(MOD_SRC_DIR)/$${mod}/$(UTILS_DIR)/* debian/$(PACKAGE_PRE_NAME)-$${mod}/usr/local/bin/; \ + cp $(MOD_SRC_DIR)/$${mod}/$(SERVICE_DIR)/*.service debian/$(PACKAGE_PRE_NAME)-$${mod}/lib/systemd/system/; \ + #$(PYTHON) $${mod}/setup.py install --root=$(MOD_SRC_DIR)/debian/$(PACKAGE_PRE_NAME)-$${mod} --install-layout=deb; \ + done) + # Resuming debhelper scripts + dh_testroot + dh_install + dh_installchangelogs + dh_installdocs + dh_installsystemd + dh_installinit + dh_link + dh_fixperms + dh_compress + dh_strip + dh_installdeb + dh_gencontrol + dh_md5sums + dh_builddeb +.PHONY: build binary binary-arch binary-indep clean + +##!/usr/bin/make -f +# +#export INSTALL_MOD_DIR:=extra +# +#PYTHON ?= python2 +#PYTHON3 ?= python3 +# +#KVERSION ?= $(shell uname -r) +#KERNEL_SRC := /lib/modules/$(KVERSION) +#MOD_SRC_DIR:= $(shell pwd) +# +#PACKAGE_PRE_NAME := sonic-platform-wistron +#MODULE_DIRS := 3306-32 +#MODULE_SRC := modules +##UTILITY_SRC := utils +#SERVICE_SRC := service +#COMMON_SRC := common +#%: +# dh $@ +# +# +#override_dh_auto_build: +# (for mod in $(MODULE_DIRS); do \ +# make modules -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/$${mod}/modules; \ +# cd $(MOD_SRC_DIR)/$${mod}; \ +# python2.7 setup.py bdist_wheel -d $(MOD_SRC_DIR)/$${mod}/modules; \ +# cd $(MOD_SRC_DIR); \ +# done) +# +#override_dh_auto_install: +# (for mod in $(MODULE_DIRS); do \ +# dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} \ +# $(KERNEL_SRC)/$(INSTALL_MOD_DIR); \ +# cp $(MOD_SRC_DIR)/$${mod}/$(MODULE_SRC)/*.ko \ +# debian/$(PACKAGE_PRE_NAME)-$${mod}/$(KERNEL_SRC)/$(INSTALL_MOD_DIR); \ +# dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} usr/local/bin; \ +## cp $(MOD_SRC_DIR)/$${mod}/$(UTILITY_SRC)/* \ +## debian/$(PACKAGE_PRE_NAME)-$${mod}/usr/local/bin; \ +# dh_installdirs -p$(PACKAGE_PRE_NAME)-$${mod} lib/systemd/system; \ +# cp $(MOD_SRC_DIR)/$${mod}/$(SERVICE_SRC)/*.service \ +# debian/$(PACKAGE_PRE_NAME)-$${mod}/lib/systemd/system; \ +# done) +# +#override_dh_usrlocal: +# +#override_dh_clean: +# dh_clean +# $(RM) -r $(COMMON_SRC)/*.o $(COMMON_SRC)/.*.cmd +# (for mod in $(MODULE_DIRS); do \ +# make -C $(KERNEL_SRC)/build M=$(MOD_SRC_DIR)/$${mod}/modules clean; \ +# done) diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.install b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.install new file mode 100644 index 000000000000..955583027537 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.install @@ -0,0 +1,3 @@ +6512-32r/utils/* usr/local/bin +6512-32r/sonic_platform-1.0-py3-none-any.whl usr/share/sonic/device/x86_64-wistron_6512_32r-r0 +6512-32r/service/*.service lib/systemd/system diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.postinst b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.postinst new file mode 100644 index 000000000000..b1cef228e7ee --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-6512-32r.postinst @@ -0,0 +1,41 @@ +#!/bin/bash + +kernel_version=$(uname -r) + +for i in $(seq 1 10); +do + if [ -e /lib/modules/${kernel_version}/modules.dep ];then + wisko=$(cat /lib/modules/${kernel_version}/modules.dep | grep wistron) + ipdko=$(cat /lib/modules/${kernel_version}/modules.dep | grep ipd) + if [ "$wisko" == "" ] || [ "$ipdko" == "" ];then + depmod -a + else + if [ ! -e /lib/modules/${kernel_version}/modules.dep.bin ];then + depmod -a + else + break + fi + fi + + echo "depmod -a" + sleep 1 + else + sleep 1 + fi +done + +#Install sonic-platform package +DEVICE="/usr/share/sonic/device" +PLATFORM=$(/usr/local/bin/sonic-cfggen -H -v DEVICE_METADATA.localhost.platform) +if [ -e $DEVICE/$PLATFORM/sonic_platform-1.0-py3-none-any.whl ]; then + pip3 install $DEVICE/$PLATFORM/sonic_platform-1.0-py3-none-any.whl +fi + +systemctl enable platform-modules-6512-32r.service +systemctl start platform-modules-6512-32r.service +systemctl enable 6512-32r-platform.service +systemctl start 6512-32r-platform.service +systemctl enable 6512-32r-syseeprom.service +systemctl start 6512-32r-syseeprom.service +systemctl enable 6512-32r-firmware_ver.service +systemctl start 6512-32r-firmware_ver.service diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.install b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.install new file mode 100644 index 000000000000..2323a24d6bcc --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.install @@ -0,0 +1,4 @@ +sw-to3200k/utils/* usr/local/bin +sw-to3200k/sonic_platform-1.0-py3-none-any.whl usr/share/sonic/device/x86_64-wistron_sw_to3200k-r0 +sw-to3200k/cfg/sw-to3200k-modules.conf etc/modules-load.d +sw-to3200k/service/*.service lib/systemd/system diff --git a/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.postinst b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.postinst new file mode 100644 index 000000000000..9a1d167da53d --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/debian/sonic-platform-wistron-sw-to3200k.postinst @@ -0,0 +1,43 @@ +#!/bin/bash + +kernel_version=$(uname -r) + +for i in $(seq 1 10); +do + if [ -e /lib/modules/${kernel_version}/modules.dep ];then + wisko=$(cat /lib/modules/${kernel_version}/modules.dep | grep wistron) + ipdko=$(cat /lib/modules/${kernel_version}/modules.dep | grep ipd) + if [ "$wisko" == "" ] || [ "$ipdko" == "" ];then + depmod -a + else + if [ ! -e /lib/modules/${kernel_version}/modules.dep.bin ];then + depmod -a + else + break + fi + fi + + echo "depmod -a" + sleep 1 + else + sleep 1 + fi +done + +#Install sonic-platform package +DEVICE="/usr/share/sonic/device" +PLATFORM=$(/usr/local/bin/sonic-cfggen -H -v DEVICE_METADATA.localhost.platform) +if [ -e $DEVICE/$PLATFORM/sonic_platform-1.0-py3-none-any.whl ]; then + pip3 install $DEVICE/$PLATFORM/sonic_platform-1.0-py3-none-any.whl +fi + +systemctl enable platform-modules-sw-to3200k.service +systemctl start platform-modules-sw-to3200k.service +systemctl enable sw-to3200k-firmware_ver.service +systemctl start sw-to3200k-firmware_ver.service +systemctl enable to3200k-platform.service +systemctl start to3200k-platform.service +systemctl enable to3200k-led.service +systemctl start to3200k-led.service +systemctl enable to3200k-pld.service +systemctl start to3200k-pld.service diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_i2c_psu.c b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_i2c_psu.c index 746e581486cb..5024ecdd70e6 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_i2c_psu.c +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_i2c_psu.c @@ -342,25 +342,25 @@ static ssize_t set_value } case PSU_MFR_ID: { - memset(&data->mfr_id, 0x0, sizeof(data->mfr_id)); + memzero_explicit(&data->mfr_id, sizeof(data->mfr_id)); strncpy(data->mfr_id, buf, sizeof(data->mfr_id)-1); break; } case PSU_MFR_MODEL: { - memset(&data->mfr_model, 0x0, sizeof(data->mfr_model)); + memzero_explicit(&data->mfr_model, sizeof(data->mfr_model)); strncpy(data->mfr_model, buf, sizeof(data->mfr_model)-1); break; } case PSU_MFR_REVISION: { - memset(&data->mfr_revsion, 0x0, sizeof(data->mfr_revsion)); + memzero_explicit(&data->mfr_revsion, sizeof(data->mfr_revsion)); strncpy(data->mfr_revsion, buf, sizeof(data->mfr_revsion)-1); break; } case PSU_MFR_SERIAL: { - memset(&data->mfr_serial, 0x0, sizeof(data->mfr_serial)); + memzero_explicit(&data->mfr_serial, sizeof(data->mfr_serial)); strncpy(data->mfr_serial, buf, sizeof(data->mfr_serial)-1); break; } @@ -403,7 +403,7 @@ static int wistron_i2c_psu_probe(struct i2c_client *client, const struct i2c_dev goto exit_free; } - data->hwmon_dev = hwmon_device_register(&client->dev); + data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "wistron_i2c_psu", NULL, NULL, NULL); if (IS_ERR(data->hwmon_dev)) { status = PTR_ERR(data->hwmon_dev); diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_fan.c b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_fan.c index 82dfa71b7805..0f7e856e8330 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_fan.c +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_fan.c @@ -16,6 +16,8 @@ static ssize_t get_fan_value(struct device *dev, struct device_attribute *da, char *buf); static ssize_t set_fan_value(struct device *dev, struct device_attribute *da, const char *buf, size_t count); +static ssize_t get_version(struct device *dev, struct device_attribute *da, char *buf); +static ssize_t set_version(struct device *dev, struct device_attribute *da, const char *buf, size_t count); enum fan_id { FAN1_ID, @@ -49,7 +51,7 @@ enum sysfs_fan_attributes { FAN4_DIRECTION, FAN5_DIRECTION, FAN6_DIRECTION, - FAN7_DIRECTION, + FAN7_DIRECTION, FAN1_FRONT_SPEED_RPM, FAN2_FRONT_SPEED_RPM, FAN3_FRONT_SPEED_RPM, @@ -64,6 +66,7 @@ enum sysfs_fan_attributes { FAN5_REAR_SPEED_RPM, FAN6_REAR_SPEED_RPM, FAN7_REAR_SPEED_RPM, + CPLD_VERSION, FAN_ATTR_MAX }; @@ -71,9 +74,13 @@ enum sysfs_fan_attributes { struct sw_to3200k_fan_data { struct device *hwmon_dev; struct mutex update_lock; + int version; int fan_val[FAN_ATTR_MAX]; }; +/* version */ +static SENSOR_DEVICE_ATTR(version, S_IWUSR | S_IRUGO, get_version, set_version, CPLD_VERSION); + /* Define attributes */ #define DECLARE_FAN_DUTY_CYCLE_SENSOR_DEV_ATTR(index) \ static SENSOR_DEVICE_ATTR(fan##index##_duty_cycle_percentage, S_IWUSR | S_IRUGO, get_fan_value, set_fan_value, FAN##index##_DUTY_CYCLE_PERCENTAGE) @@ -171,9 +178,40 @@ static struct attribute *sw_to3200k_fan_attributes[] = { DECLARE_FAN_DIRECTION_ATTR(6), DECLARE_FAN_DIRECTION_ATTR(7), DECLARE_FAN_DUTY_CYCLE_ATTR(), + &sensor_dev_attr_version.dev_attr.attr, NULL }; +static ssize_t get_version(struct device *dev, struct device_attribute *da, char *buf) +{ + struct i2c_client *client = to_i2c_client(dev); + struct sw_to3200k_fan_data *data = i2c_get_clientdata(client); + int version; + + mutex_lock(&data->update_lock); + version = data->version; + mutex_unlock(&data->update_lock); + return sprintf(buf, "%d", version); +} + +static ssize_t set_version(struct device *dev, struct device_attribute *da, const char *buf, size_t count) +{ + struct i2c_client *client = to_i2c_client(dev); + struct sw_to3200k_fan_data *data = i2c_get_clientdata(client); + int error, version; + + error = kstrtoint(buf, 10, &version); + if (error) + { + return error; + } + + mutex_lock(&data->update_lock); + data->version = version; + mutex_unlock(&data->update_lock); + return count; +} + static ssize_t get_fan_value(struct device *dev, struct device_attribute *da, char *buf) { struct sensor_device_attribute *attr = to_sensor_dev_attr(da); @@ -245,7 +283,7 @@ static int sw_to3200k_fan_probe goto exit_free; } - data->hwmon_dev = hwmon_device_register(&client->dev); + data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "wistron_fan", NULL, NULL, NULL); if (IS_ERR(data->hwmon_dev)) { status = PTR_ERR(data->hwmon_dev); diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_oom.c b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_oom.c index 6e1df229c9fd..3e26edff07cc 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_oom.c +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_oom.c @@ -242,27 +242,27 @@ static ssize_t set_oom_info(struct device *dev, struct device_attribute *da, con { case OOM_EEPROM_LOW: { - memset(&data->eeproml, 0x0, sizeof(data->eeproml)); + memzero_explicit(&data->eeproml, sizeof(data->eeproml)); break; } case OOM_EEPROM_PG0: { - memset(&data->eeprom0, 0x0, sizeof(data->eeprom0)); + memzero_explicit(&data->eeprom0, sizeof(data->eeprom0)); break; } case OOM_EEPROM_PG2: { - memset(&data->eeprom2, 0x0, sizeof(data->eeprom2)); + memzero_explicit(&data->eeprom2, sizeof(data->eeprom2)); break; } case OOM_EEPROM_PG3: { - memset(&data->eeprom3, 0x0, sizeof(data->eeprom3)); + memzero_explicit(&data->eeprom3, sizeof(data->eeprom3)); break; } case OOM_EEPROM_PG11: { - memset(&data->eeprom11, 0x0, sizeof(data->eeprom11)); + memzero_explicit(&data->eeprom11, sizeof(data->eeprom11)); break; } default: @@ -332,7 +332,7 @@ static int sw_to3200k_oom_probe(struct i2c_client *client, const struct i2c_devi goto exit_free; } - data->hwmon_dev = hwmon_device_register(&client->dev); + data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "wistron_oom", NULL, NULL, NULL); if (IS_ERR(data->hwmon_dev)) { status = PTR_ERR(data->hwmon_dev); diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_psu.c b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_psu.c index 849ec1315407..418e22240ace 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_psu.c +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_psu.c @@ -140,7 +140,7 @@ static ssize_t set_string(struct device *dev, struct device_attribute *da, const struct sw_to3200k_psu_data *data = i2c_get_clientdata(client); char tmp_str[32]; - memset(&tmp_str, 0x0, sizeof(tmp_str)); + memzero_explicit(&tmp_str, sizeof(tmp_str)); if (attr->index == PSU_MODEL_NAME) { if (sscanf(buf, "%16s", tmp_str) != 1) @@ -205,7 +205,7 @@ static int sw_to3200k_psu_probe(struct i2c_client *client, goto exit_free; } - data->hwmon_dev = hwmon_device_register(&client->dev); + data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "wistron_psu", NULL, NULL, NULL); if (IS_ERR(data->hwmon_dev)) { status = PTR_ERR(data->hwmon_dev); diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_thermal.c b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_thermal.c index e96e9d723f46..a86d53a94fb3 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_thermal.c +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/modules/wistron_sw_to3200k_thermal.c @@ -140,7 +140,7 @@ static int sw_to3200k_thermal_probe(struct i2c_client *client, const struct i2c_ goto exit_free; } - data->hwmon_dev = hwmon_device_register(&client->dev); + data->hwmon_dev = hwmon_device_register_with_info(&client->dev, "wistron_thermal", NULL, NULL, NULL); if (IS_ERR(data->hwmon_dev)) { status = PTR_ERR(data->hwmon_dev); diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/service/sw-to3200k-firmware_ver.service b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/service/sw-to3200k-firmware_ver.service new file mode 100644 index 000000000000..c609042622c0 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/service/sw-to3200k-firmware_ver.service @@ -0,0 +1,12 @@ +[Unit] +Description=Wistron SW3200K Platform firmware version service +After=platform-modules-sw-to3200k.service +DefaultDependencies=no + +[Service] +Type=oneshot +ExecStart=/usr/local/bin/platform_firmware_version +RemainAfterExit=yes + +[Install] +WantedBy=multi-user.target diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/__init__.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/__init__.py index 0c73278ba9f5..afc599aeca4e 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/__init__.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/__init__.py @@ -1,2 +1,2 @@ -__all__ = ["platform", "chassis", "sfp", "eeprom", "psu", "thermal", "fan", "watchdog"] +__all__ = ["platform", "chassis", "sfp", "eeprom", "psu", "thermal", "fan", "watchdog", 'component'] from . import platform diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/chassis.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/chassis.py index 4effac20b6a4..655949d8fc56 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/chassis.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/chassis.py @@ -8,7 +8,6 @@ ############################################################################# try: import sys - import os import time import subprocess from sonic_platform_base.chassis_base import ChassisBase @@ -16,16 +15,19 @@ raise ImportError(str(e) + "- required module not found") NUM_FAN = 14 +NUM_FANTRAY = 7 NUM_PSU = 2 NUM_THERMAL = 7 NUM_SFP = 32 +NUM_COMPONENT = 6 HOST_REBOOT_CAUSE_PATH = "/host/reboot-cause/" PMON_REBOOT_CAUSE_PATH = "/usr/share/sonic/platform/api_files/reboot-cause/" REBOOT_CAUSE_FILE = "reboot-cause.txt" PREV_REBOOT_CAUSE_FILE = "previous-reboot-cause.txt" -HOST_CHK_CMD = "docker > /dev/null 2>&1" -GET_HWSKU_CMD = "sonic-cfggen -d -v DEVICE_METADATA.localhost.hwsku" -GET_PLATFORM_CMD = "sonic-cfggen -d -v DEVICE_METADATA.localhost.platform" +HOST_CHK_CMD = ["docker"] +GET_HWSKU_CMD = ["sonic-cfggen", "-d", "-v", "DEVICE_METADATA.localhost.hwsku"] +GET_PLATFORM_CMD = ["sonic-cfggen", "-d", "-v", "DEVICE_METADATA.localhost.platform"] + class Chassis(ChassisBase): """Platform-specific Chassis class""" @@ -45,6 +47,7 @@ def __init__(self): self.__initialize_thermals() self.__initialize_sfp() self.__initialize_eeprom() + self.__initialize_components() def __initialize_sfp(self): from sonic_platform.sfp import Sfp @@ -52,12 +55,12 @@ def __initialize_sfp(self): sfp_module = Sfp(index, 'QSFP_DD') self._sfp_list.append(sfp_module) - def __initialize_fan(self): - from sonic_platform.fan import Fan - for fan_index in range(0, NUM_FAN): - fan = Fan(fan_index) - self._fan_list.append(fan) + from sonic_platform.fan_drawer import FanDrawer + for fan_index in range(0, NUM_FANTRAY): + fandrawer = FanDrawer(fan_index) + self._fan_drawer_list.append(fandrawer) + self._fan_list.extend(fandrawer._fan_list) def __initialize_psu(self): from sonic_platform.psu import Psu @@ -75,8 +78,14 @@ def __initialize_eeprom(self): from sonic_platform.eeprom import Tlv self._eeprom = Tlv() + def __initialize_components(self): + from sonic_platform.component import Component + for index in range(0, NUM_COMPONENT): + component = Component(index) + self._component_list.append(component) + def __is_host(self): - return os.system(HOST_CHK_CMD) == 0 + return subprocess.call(HOST_CHK_CMD) == 0 def __read_txt_file(self, file_path): try: @@ -88,12 +97,12 @@ def __read_txt_file(self, file_path): return None def _get_sku_name(self): - p = subprocess.Popen(GET_HWSKU_CMD, shell=True, stdout=subprocess.PIPE) + p = subprocess.Popen(GET_HWSKU_CMD, stdout=subprocess.PIPE) out, err = p.communicate() return out.decode().rstrip('\n') def _get_platform_name(self): - p = subprocess.Popen(GET_PLATFORM_CMD, shell=True, stdout=subprocess.PIPE) + p = subprocess.Popen(GET_PLATFORM_CMD, stdout=subprocess.PIPE) out, err = p.communicate() return out.decode().rstrip('\n') @@ -114,7 +123,7 @@ def get_base_mac(self): """ return self._eeprom.get_mac() - def get_serial_number(self): + def get_serial(self): """ Retrieves the hardware serial number for the chassis Returns: @@ -181,7 +190,7 @@ def _get_sfp_presence(self): port_pres = {} for port in range(0, NUM_SFP): sfp = self._sfp_list[port] - port_pres[port] = sfp.get_presence() + port_pres[port] = 1 if sfp.get_presence() else 0 return port_pres @@ -217,7 +226,7 @@ def get_change_event(self, timeout=0): port_dict[port] = '0' self._transceiver_presence = cur_presence - if change_event == True: + if change_event is True: break if not forever: @@ -231,3 +240,86 @@ def get_change_event(self, timeout=0): sfp.reinit() return True, ret_dict + + def initizalize_system_led(self): + self.system_led = "" + return True + + def set_status_led(self, color): + """ + Sets the state of the system LED + + Args: + color: A string representing the color with which to set the + system LED + + Returns: + bool: True if system LED state is set successfully, False if not + """ + self.system_led = color + return True + + def get_status_led(self): + """ + Gets the state of the system LED + + Returns: + A string, one of the valid LED color strings which could be vendor + specified. + """ + return self.system_led + + + def get_presence(self): + """ + Retrieves the presence of the Chassis + Returns: + bool: True if Chassis is present, False if not + """ + return True + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return self._eeprom.get_model() + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return True + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. If the agent cannot determine the parent-relative position + for some reason, or if the associated value of entPhysicalContainedIn is '0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device or -1 if cannot determine the position + """ + return -1 + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return False + + def get_revision(self): + """ + Retrieves the hardware revision of the device + + Returns: + string: Revision value of device + """ + + return '0' + + def get_thermal_manager(self): + raise NotImplementedError diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/component.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/component.py new file mode 100644 index 000000000000..8b855e0a5f86 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/component.py @@ -0,0 +1,240 @@ +#!/usr/bin/env python + +import subprocess +from shlex import split +from collections import namedtuple +from functools import reduce + + +try: + from sonic_platform_base.component_base import ComponentBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +CPLD_ADDR_MAPPING = { + "CPLD1": "0-0061", + "CPLD2": "0-0062", + "MB_FPGA": "0-0060", + "FAN_CPLD" : "0-0066" +} + +proc_output = namedtuple('proc_output', 'stdout stderr') +SYSFS_PATH = "/sys/bus/i2c/devices/" +#GET_BMC_VER_CMD= "ipmitool mc info | grep 'Firmware Revision' | awk '{printf $4}'" +BIOS_VERSION_PATH = "/sys/class/dmi/id/bios_version" +COMPONENT_LIST= [ + ("BIOS", "Basic Input/Output System"), + ("CPLD1", "CPLD 1"), + ("CPLD2", "CPLD 2"), + ("MB_FPGA", "MB FPGA"), + ("FAN_CPLD", "FAN CPLD"), + ("BMC", "baseboard management controller") +] + +class Component(ComponentBase): + """Platform-specific Component class""" + + DEVICE_TYPE = "component" + + def __init__(self, component_index=0): + ComponentBase.__init__(self) + self.index = component_index + self.name = self.get_name() + + def pipeline(self, starter_command, *commands): + if not commands: + try: + starter_command, *commands = starter_command.split('|') + except AttributeError: + pass + starter_command = self._parse(starter_command) + starter = subprocess.Popen(starter_command, stdout=subprocess.PIPE) + last_proc = reduce(self._create_pipe, map(self._parse, commands), starter) + return proc_output(*last_proc.communicate()) + + def _create_pipe(self, previous, command): + proc = subprocess.Popen(command, stdin=previous.stdout, stdout=subprocess.PIPE) + previous.stdout.close() + return proc + + def _parse(self, cmd): + try: + return split(cmd) + except Exception: + return cmd + + def __read_txt_file(self, file_path): + try: + with open(file_path, 'r') as fd: + data = fd.read() + return data.strip() + except IOError: + pass + return "" + + def __get_bios_version(self): + # Retrieves the BIOS firmware version + try: + with open(BIOS_VERSION_PATH, 'r') as fd: + bios_version = fd.read() + return bios_version.strip() + except Exception as e: + return None + + def __get_bmc_version(self): + try: + #GET_BMC_VER_CMD + out, err = self.pipeline("ipmitool mc info", "grep 'Firmware Revision'", "awk '{printf $4}'") + return out.decode().rstrip('\n') + except Exception as e: + print('Get exception when read bmc') + return 'None' + + def __get_cpld_version(self): + # Retrieves the CPLD firmware version + cpld_version = dict() + for cpld_name in CPLD_ADDR_MAPPING: + try: + cpld_path = "{}{}{}".format(SYSFS_PATH, CPLD_ADDR_MAPPING[cpld_name], '/version') + cpld_version_raw= int(self.__read_txt_file(cpld_path), 10) + cpld_version[cpld_name] = "{}".format(hex(cpld_version_raw)) + except Exception as e: + print('Get exception when read cpld') + cpld_version[cpld_name] = 'None' + + return cpld_version + + def get_name(self): + """ + Retrieves the name of the component + Returns: + A string containing the name of the component + """ + return COMPONENT_LIST[self.index][0] + + def get_description(self): + """ + Retrieves the description of the component + Returns: + A string containing the description of the component + """ + return COMPONENT_LIST[self.index][1] + + def get_firmware_version(self): + """ + Retrieves the firmware version of module + Returns: + string: The firmware versions of the module + """ + fw_version = None + + if self.name == "BIOS": + fw_version = self.__get_bios_version() + elif "BMC" in self.name: + fw_version = self.__get_bmc_version() + elif "CPLD" in self.name: + cpld_version = self.__get_cpld_version() + fw_version = cpld_version.get(self.name) + elif "FPGA" in self.name: + fpga_version = self.__get_cpld_version() + fw_version = fpga_version.get(self.name) + + return fw_version + + def install_firmware(self, image_path): + """ + Install firmware to module + Args: + image_path: A string, path to firmware image + Returns: + A boolean, True if install successfully, False if not + """ + raise NotImplementedError + + def get_presence(self): + """ + Retrieves the presence of the FAN + Returns: + bool: True if FAN is present, False if not + """ + return True + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return 'N/A' + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return 'N/A' + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return True + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return -1 + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return False + + def get_available_firmware_version(self, image_path): + """ + Retrieves the available firmware version of the component + Note: the firmware version will be read from image + Args: + image_path: A string, path to firmware image + Returns: + A string containing the available firmware version of the component + """ + return "N/A" + + def get_firmware_update_notification(self, image_path): + """ + Retrieves a notification on what should be done in order to complete + the component firmware update + Args: + image_path: A string, path to firmware image + Returns: + A string containing the component firmware update notification if required. + By default 'None' value will be used, which indicates that no actions are required + """ + return "None" + + def update_firmware(self, image_path): + """ + Updates firmware of the component + This API performs firmware update: it assumes firmware installation and loading in a single call. + In case platform component requires some extra steps (apart from calling Low Level Utility) + to load the installed firmware (e.g, reboot, power cycle, etc.) - this will be done automatically by API + Args: + image_path: A string, path to firmware image + Raises: + RuntimeError: update failed + """ + return False diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/eeprom.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/eeprom.py index 448e083712ce..e495b297576a 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/eeprom.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/eeprom.py @@ -41,12 +41,19 @@ def __parse_output(self, decode_output): for line in lines: try: match = re.search( - '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+)', line) - if match is not None: + '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+[\s]+[\S]+)', line) + if match is not None and match.group(1) == '0x25': idx = match.group(1) value = match.group(3).rstrip('\0') + _eeprom_info_dict[idx] = value + else: + match = re.search( + '(0x[0-9a-fA-F]{2})([\s]+[\S]+[\s]+)([\S]+)', line) + if match is not None: + idx = match.group(1) + value = match.group(3).rstrip('\0') + _eeprom_info_dict[idx] = value - _eeprom_info_dict[idx] = value except BaseException: pass return _eeprom_info_dict @@ -108,3 +115,7 @@ def get_serial(self): def get_mac(self): return self._eeprom.get('0x24', "Undefined.") + + def get_model(self): + return self._eeprom.get('0x21', "Undefined.") + diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan.py index f5b7f9e80ed6..9849cd472893 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan.py @@ -14,23 +14,66 @@ except ImportError as e: raise ImportError(str(e) + "- required module not found") +SPEED_TOLERANCE = 15 FAN_PATH = "/sys/bus/i2c/devices/0-0066/" -FANTRAY_NAME_LIST = ["FANTRAY-1", "FANTRAY-2", - "FANTRAY-3", "FANTRAY-4", - "FANTRAY-5", "FANTRAY-6", "FANTRAY-7"] -FAN_NAME_LIST = ["fan1_front","fan2_front","fan3_front","fan4_front","fan5_front","fan6_front", "fan7_front",\ -"fan1_rear","fan2_rear","fan3_rear","fan4_rear", "fan5_rear", "fan6_rear", "fan7_rear",] +SYSFS_PATH = "/sys/bus/i2c/devices/{0}-00{1}" +PSU_STS_I2C_MAPPING = { + 0: { + "num": 0, + "addr": "51" + }, + 1: { + "num": 0, + "addr": "52" + }, +} + +PSU_HWMON_I2C_MAPPING = { + 0: { + "num": 0, + "addr": "59" + }, + 1: { + "num": 0, + "addr": "5a" + }, +} + +FAN_NAME_LIST = ["FAN-1F", "FAN-1R", "FAN-2F", "FAN-2R", + "FAN-3F", "FAN-3R", "FAN-4F", "FAN-4R", + "FAN-5F", "FAN-5R", "FAN-6F", "FAN-6R", + "FAN-7F", "FAN-7R"] class Fan(FanBase): """Platform-specific Fan class""" - def __init__(self, fan_index): - self.fan_tray_index = fan_index - self.fan_presence = "fan{}_presence" - self.fan_direction = "fan{}_direction" - self.fan_speed_rpm = "fan{}_{}_speed_rpm" + def __init__(self, fan_tray_index, fan_index=0, is_psu_fan=False, psu_index=0): + self.fan_index = fan_index + self.fan_tray_index = fan_tray_index + self.is_psu_fan = is_psu_fan + + if self.is_psu_fan: + self.psu_index = psu_index + self.psu_status_i2c_num = PSU_STS_I2C_MAPPING[self.psu_index]['num'] + self.psu_status_i2c_addr = PSU_STS_I2C_MAPPING[self.psu_index]['addr'] + self.psu_status_path = SYSFS_PATH.format(self.psu_status_i2c_num, self.psu_status_i2c_addr) + self.psu_hwmon_i2c_num = PSU_HWMON_I2C_MAPPING[self.psu_index]['num'] + self.psu_hwmon_i2c_addr = PSU_HWMON_I2C_MAPPING[self.psu_index]['addr'] + self.psu_hwmon_path = SYSFS_PATH.format(self.psu_hwmon_i2c_num, self.psu_hwmon_i2c_addr) + + FanBase.__init__(self) + def __search_hwmon_dir_name(self, directory): + try: + dirs = os.listdir(directory) + for file in dirs: + if file.startswith("hwmon"): + return file + except IOError: + pass + return '' + def __read_txt_file(self, file_path): try: with open(file_path, 'r') as fd: @@ -38,22 +81,14 @@ def __read_txt_file(self, file_path): return data.strip() except IOError: pass - return "" + return None - def __write_txt_file(self, file_path, value): + def __write_txt_file(self, file_path, data): try: with open(file_path, 'w') as fd: - fd.write(str(value)) - except BaseException: - return False - return True - - def __search_file_by_name(self, directory, file_name): - for dirpath, dirnames, files in os.walk(directory): - for name in files: - file_path = os.path.join(dirpath, name) - if name in file_name: - return file_path + fd.write(data) + except IOError: + pass return None def get_direction(self): @@ -63,38 +98,46 @@ def get_direction(self): A string, either FAN_DIRECTION_INTAKE or FAN_DIRECTION_EXHAUST depending on fan direction """ - index1=self.fan_tray_index - if self.fan_tray_index>6: - index1=self.fan_tray_index%7 - fan_direction_file = (FAN_PATH + - self.fan_direction.format(index1+1)) - raw = self.__read_txt_file(fan_direction_file).strip('\r\n') - direction = self.FAN_DIRECTION_INTAKE if str( - raw).upper() == "1" else self.FAN_DIRECTION_EXHAUST + direction = 0 + if self.is_psu_fan: + path= "{}/psu_fan_dir".format(self.psu_status_path) + direction=self.__read_txt_file(path) + if direction is None: + return self.FAN_DIRECTION_EXHAUST + elif self.get_presence(): + path= "{}/fan{}_direction".format(FAN_PATH, self.fan_tray_index + 1) + direction=self.__read_txt_file(path) + if direction is None: + return self.FAN_DIRECTION_EXHAUST + + return self.FAN_DIRECTION_EXHAUST if int(direction) == 0 else self.FAN_DIRECTION_INTAKE - return direction def get_speed(self): """ Retrieves the speed of fan as a percentage of full speed Returns: An integer, the percentage of full fan speed, in the range 0 (off) - to 12000 (full speed) - """ - if self.fan_tray_index<=6: - index1=self.fan_tray_index - speed = 0 - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1,"front")) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - else: - index1=self.fan_tray_index%7 - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1,"rear")) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - + to 100 (full speed) + + """ + speed = 0 + if self.is_psu_fan: + psu_fan_path= "{}/{}".format(self.psu_hwmon_path, 'fan1_input') + fan_speed_rpm = self.__read_txt_file(psu_fan_path) + if fan_speed_rpm is not None: + speed = (int(fan_speed_rpm,10))*100/33000 + if speed > 100: + speed=100 + else: + return 0 + elif self.get_presence(): + path= "{}/fan_duty_cycle_percentage".format(FAN_PATH) + speed=self.__read_txt_file(path) + if speed is None: + return 0 + return int(int(speed)*100/255) + return int(speed) def get_target_speed(self): @@ -103,22 +146,14 @@ def get_target_speed(self): Returns: An integer, the percentage of full fan speed, in the range 0 (off) to 100 (full speed) - """ - if self.fan_tray_index<=6: - index1=self.fan_tray_index - speed = 0 - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1,"front")) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - else: - index1=self.fan_tray_index%7 - if self.get_presence(): - fan_speed_file = (FAN_PATH + - self.fan_speed_rpm.format(index1+1,"rear")) - speed = self.__read_txt_file(fan_speed_file).strip('\r\n') - return int(speed) + Note: + speed_pc = pwm_target/255*100 + + 0 : when PWM mode is use + pwm : when pwm mode is not use + """ + return self.get_speed() def get_speed_tolerance(self): """ @@ -127,7 +162,7 @@ def get_speed_tolerance(self): An integer, the percentage of variance from target speed which is considered tolerable """ - return 10 + return SPEED_TOLERANCE def set_speed(self, speed): """ @@ -138,13 +173,8 @@ def set_speed(self, speed): Returns: A boolean, True if speed is set successfully, False if not - Note: - Depends on pwm or target mode is selected: - 1) pwm = speed_pc * 255 <-- Currently use this mode. - 2) target_pwm = speed_pc * 100 / 255 - 2.1) set pwm{}_enable to 3 - """ + return False def set_status_led(self, color): @@ -156,7 +186,22 @@ def set_status_led(self, color): Returns: bool: True if status LED state is set successfully, False if not """ - return False + return False #Not supported + + def get_status_led(self): + """ + Gets the state of the fan status LED + Returns: + A string, one of the predefined STATUS_LED_COLOR_* strings above + """ + status=self.get_presence() + if status is None: + return self.STATUS_LED_COLOR_OFF + + return { + 1: self.STATUS_LED_COLOR_GREEN, + 0: self.STATUS_LED_COLOR_RED + }.get(status, self.STATUS_LED_COLOR_OFF) def get_name(self): """ @@ -164,24 +209,30 @@ def get_name(self): Returns: string: The name of the device """ - fan_name = FAN_NAME_LIST[self.fan_tray_index] + + fan_name = FAN_NAME_LIST[self.fan_tray_index*2 + self.fan_index] \ + if not self.is_psu_fan \ + else "PSU-{} FAN-{}".format(self.psu_index+1, self.fan_index+1) return fan_name def get_presence(self): """ - Retrieves the presence of the PSU + Retrieves the presence of the FAN Returns: - bool: True if PSU is present, False if not + bool: True if FAN is present, False if not """ - index1=self.fan_tray_index - if self.fan_tray_index>6: - index1=self.fan_tray_index%7 - fan_direction_file = (FAN_PATH + - self.fan_presence.format(index1+1)) - present_str = self.__read_txt_file(fan_direction_file) or '1' - return int(present_str) == 1 + if self.is_psu_fan: + present_path="{}/psu_present".format(self.psu_status_path) + else: + present_path="{}/fan{}_presence".format(FAN_PATH, self.fan_tray_index + 1) + + val=self.__read_txt_file(present_path) + if val is not None: + return int(val, 10)==1 + else: + return False def get_status(self): """ @@ -189,4 +240,55 @@ def get_status(self): Returns: A boolean value, True if device is operating properly, False if not """ - return self.get_presence() and self.get_speed() > 0 + if self.is_psu_fan: + psu_fan_path= "{}/{}".format(self.psu_status_path, 'psu_power_good') + val=self.__read_txt_file(psu_fan_path) + if val is not None: + return int(val, 10)==1 + else: + return False + else: + status=self.get_presence() + if status is None: + return False + return status + + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + + return "N/A" + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return "N/A" + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return (self.fan_tray_index * 2 + self.fan_index + 1) \ + if not self.is_psu_fan else (self.psu_index + 1) + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return True if not self.is_psu_fan else False + diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan_drawer.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan_drawer.py new file mode 100644 index 000000000000..c299adec1dec --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/fan_drawer.py @@ -0,0 +1,119 @@ +######################################################################## +# +# Module contains an implementation of SONiC Platform Base API and +# provides the Fan-Drawers' information available in the platform. +# +######################################################################## + +try: + from sonic_platform_base.fan_drawer_base import FanDrawerBase +except ImportError as e: + raise ImportError(str(e) + "- required module not found") + +FANS_PER_FANTRAY = 2 +MAX_FAN_WATT = 20.0 + +class FanDrawer(FanDrawerBase): + """Platform-specific Fan class""" + + def __init__(self, fantray_index): + + FanDrawerBase.__init__(self) + # FanTray is 0-based in platforms + self.fantrayindex = fantray_index + self.__initialize_fan_drawer() + + + def __initialize_fan_drawer(self): + from sonic_platform.fan import Fan + for i in range(FANS_PER_FANTRAY): + self._fan_list.append(Fan(self.fantrayindex, i)) + + def get_name(self): + """ + Retrieves the fan drawer name + Returns: + string: The name of the device + """ + return "FanTray{}".format(self.fantrayindex+1) + + def get_presence(self): + """ + Retrieves the presence of the device + Returns: + bool: True if device is present, False if not + """ + return self._fan_list[0].get_presence() + + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return self._fan_list[0].get_model() + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return self._fan_list[0].get_serial() + + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return self._fan_list[0].get_status() + + def set_status_led(self, color): + """ + Sets the state of the fan drawer status LED + Args: + color: A string representing the color with which to set the + fan drawer status LED + Returns: + bool: True if status LED state is set successfully, False if not + """ + return self._fan_list[0].set_status_led(color) + def get_status_led(self): + """ + Gets the state of the fan drawer LED + + Returns: + A string, one of the predefined STATUS_LED_COLOR_* strings above + """ + return self._fan_list[0].get_status_led() + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return (self.fantrayindex+1) + + def is_replaceable(self): + """ + Indicate whether this device is replaceable. + Returns: + bool: True if it is replaceable. + """ + return True + + def get_maximum_consumed_power(self): + """ + Retrives the maximum power drawn by Fan Drawer + Returns: + A float, with value of the maximum consumable power of the + component. + """ + return MAX_FAN_WATT + diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/psu.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/psu.py index c26b82ee4c76..78089ca3c986 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/psu.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/psu.py @@ -22,12 +22,20 @@ class Psu(PsuBase): "/sys/bus/i2c/devices/0-005a"] def __init__(self, psu_index): + self._fan_list = [] self.PSU_TEMP_MAX = 85 * 1000 self.PSU_OUTPUT_POWER_MAX = 1300 * 1000 self.PSU_OUTPUT_VOLTAGE_MIN = 11400 self.PSU_OUTPUT_VOLTAGE_MAX = 12600 self.index = psu_index PsuBase.__init__(self) + self.__initialize_fan() + + def __initialize_fan(self): + from sonic_platform.fan import Fan + for fan_index in range(0, 1): + fan = Fan(fan_index, 0, is_psu_fan=True, psu_index=self.index) + self._fan_list.append(fan) def __read_txt_file(self, file_path): try: @@ -38,15 +46,14 @@ def __read_txt_file(self, file_path): pass return "" - def get_fan(self): + def get_fan(self, index): """ Retrieves object representing the fan module contained in this PSU Returns: An object dervied from FanBase representing the fan module contained in this PSU """ - # Hardware not supported - return False + return self._fan_list[index] def get_powergood_status(self): """ @@ -84,7 +91,7 @@ def get_presence(self): bool: True if PSU is present, False if not """ attr_file ='psu_present' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file status = 0 try: with open(attr_path, 'r') as psu_prs: @@ -101,7 +108,7 @@ def get_status(self): A boolean value, True if device is operating properly, False if not """ attr_file = 'psu_power_good' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file status = 0 try: with open(attr_path, 'r') as power_status: @@ -120,13 +127,11 @@ def get_model(self): try: if self.get_presence(): attr_file = 'psu_model_name' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) return str(val) except Exception as e: - logger.error(str(e)) - - return None + return None def get_serial(self): """ @@ -137,13 +142,11 @@ def get_serial(self): try: if self.get_presence(): attr_file = 'psu_serial_number' - attr_path = self.SYSFS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.SYSFS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) return str(val) except Exception as e: - logger.error(str(e)) - - return None + return None def get_voltage(self): """ @@ -154,13 +157,11 @@ def get_voltage(self): try: if self.get_presence(): attr_file = 'psu_v_out' - attr_path = self.STATUS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.STATUS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) - return int(val) + return float(val) / 1000.0 except Exception as e: - logger.error(str(e)) - - return None + return None def get_current(self): """ @@ -171,13 +172,11 @@ def get_current(self): try: if self.get_presence(): attr_file = 'psu_i_out' - attr_path = self.STATUS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.STATUS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) - return int(val) + return float(val) / 1000.0 except Exception as e: - logger.error(str(e)) - - return None + return None def get_power(self): """ @@ -188,13 +187,11 @@ def get_power(self): try: if self.get_presence(): attr_file = 'psu_p_out' - attr_path = self.STATUS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.STATUS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) - return int(val) + return float(val) / 1000000.0 except Exception as e: - logger.error(str(e)) - - return None + return None def get_status_led(self): """ @@ -221,13 +218,11 @@ def get_temperature(self): try: if self.get_presence(): attr_file = 'psu_temp1_input' - attr_path = self.STATUS_PSU_DIR[self.index-1] +'/' + attr_file + attr_path = self.STATUS_PSU_DIR[self.index] +'/' + attr_file val = self.__read_txt_file(attr_path) - return int(val) + return float(val) / 1000.0 except Exception as e: - logger.error(str(e)) - - return None + return None def get_temperature_high_threshold(self): """ @@ -272,7 +267,42 @@ def get_position_in_parent(self): Returns: integer: The 1-based relative physical position in parent device or -1 if cannot determine the position """ - return -1 + return self.index + 1 def is_replaceable(self): return True + + def get_revision(self): + """ + Retrieves the hardware revision of the device + Returns: + string: Revision value of device + """ + try: + if self.get_presence(): + attr_file = 'psu_mfr_revision' + attr_path = self.STATUS_PSU_DIR[self.index] +'/' + attr_file + with open(attr_path, 'r') as revision: + val = revision.read() + return val.strip() + except IOError: + return None + + def get_num_fans(self): + """ + Retrieves the number of fan modules available on this PSU + + Returns: + An integer, the number of fan modules available on this PSU + """ + return len(self._fan_list) + + def get_all_fans(self): + """ + Retrieves all fan modules available on this PSU + + Returns: + A list of objects derived from FanBase representing all fan + modules available on this PSU + """ + return self._fan_list diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/sfp.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/sfp.py index 004bda2ada66..63225a040472 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/sfp.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/sfp.py @@ -11,6 +11,8 @@ from sonic_platform_base.sonic_sfp.qsfp_dd import qsfp_dd_InterfaceId from sonic_platform_base.sonic_sfp.qsfp_dd import qsfp_dd_Dom from sonic_platform_base.sonic_sfp.sffbase import sffbase + from sonic_platform_base.sonic_sfp.sff8024 import type_abbrv_name + from sonic_platform_base.sonic_sfp.sff8024 import type_of_media_interface from sonic_py_common.logger import Logger import sys except ImportError as e: @@ -277,6 +279,7 @@ def __init__(self, sfp_index, sfp_type): # Init index self.index = sfp_index self.port_num = self.index + 1 + self.abbrv = None # Init eeprom path eeprom_low_path = '/sys/bus/i2c/devices/0-00{}/eeprom_low' @@ -328,7 +331,7 @@ def get_presence(self): except IOError: return False logger.log_info("debug:port_ %s sfp presence is %s" % (str(self.index), str(presence))) - return presence + return True if presence == 1 else False def _read_eeprom_specific_bytes(self, offset, num_bytes, page = 0): sysfsfile_eeprom = None @@ -383,8 +386,10 @@ def _detect_sfp_type(self, sfp_type): if eeprom_raw: if eeprom_raw[0] in QSFP_TYPE_CODE_LIST: self.sfp_type = QSFP_TYPE + self.abbrv = type_abbrv_name[eeprom_raw[0]] elif eeprom_raw[0] in QSFP_DD_TYPE_CODE_LIST: self.sfp_type = QSFP_DD_TYPE + self.abbrv = type_abbrv_name[eeprom_raw[0]] else: # we don't regonize this identifier value, treat the xSFP module as the default type self.sfp_type = sfp_type @@ -395,6 +400,7 @@ def _detect_sfp_type(self, sfp_type): # eeprom_raw being None indicates the module is not present. # in this case we treat it as the default type according to the SKU self.sfp_type = sfp_type + self.abbrv = type_abbrv_name['18'] def _dom_capability_detect(self): @@ -426,7 +432,7 @@ def _dom_capability_detect(self): if qsfp_dom_capability_raw is not None: qsfp_version_compliance_raw = self._read_eeprom_specific_bytes(QSFP_VERSION_COMPLIANCE_OFFSET, QSFP_VERSION_COMPLIANCE_WIDTH) qsfp_version_compliance = int(qsfp_version_compliance_raw[0], 16) - dom_capability = sfpi_obj.parse_qsfp_dom_capability(qsfp_dom_capability_raw, 0) + dom_capability = sfpi_obj.parse_dom_capability(qsfp_dom_capability_raw, 0) if qsfp_version_compliance >= 0x08: self.dom_temp_supported = dom_capability['data']['Temp_support']['value'] == 'On' self.dom_volt_supported = dom_capability['data']['Voltage_support']['value'] == 'On' @@ -462,11 +468,13 @@ def _dom_capability_detect(self): self.dom_temp_supported = True self.dom_volt_supported = True + self.dom_rx_tx_power_bias_supported = False + self.dom_tx_bias_power_supported = True # two types of QSFP-DD cable types supported: Copper and Optical. qsfp_dom_capability_raw = self._read_eeprom_specific_bytes(QSFP_DD_FLAT_MEM['offset'], QSFP_DD_FLAT_MEM['width'], QSFP_DD_FLAT_MEM['page']) if qsfp_dom_capability_raw is not None: - dom_capability = sfpi_obj.parse_qsfp_dom_capability(qsfp_dom_capability_raw, 0) + dom_capability = sfpi_obj.parse_dom_capability(qsfp_dom_capability_raw, 0) if dom_capability['data']['Flat_MEM']['value'] == 'Off': ext_dd = ext_qsfp_dd() @@ -474,8 +482,8 @@ def _dom_capability_detect(self): mon_sup_data = ext_dd.parse_mon_capability(mon_sup_raw, 0) self.dom_thresholds_supported = mon_sup_data['data']['Tx_power_support']['value'] == 'On' - self.dom_rx_power_supported = mon_sup_data['data']['Tx_power_support']['value'] == 'On' - self.dom_tx_power_supported = mon_sup_data['data']['Rx_power_support']['value'] == 'On' + self.dom_rx_power_supported = mon_sup_data['data']['Rx_power_support']['value'] == 'On' + self.dom_tx_power_supported = mon_sup_data['data']['Tx_power_support']['value'] == 'On' self.dom_tx_bias_supported = mon_sup_data['data']['Tx_bias_support']['value'] == 'On' #self.dom_temp_supported = mon_sup_data['data']['Temp_support']['value'] == 'On' #self.dom_volt_supported = mon_sup_data['data']['Voltage_support']['value'] == 'On' @@ -490,7 +498,7 @@ def _dom_capability_detect(self): def _convert_string_to_num(self, value_str): if "-inf" in value_str: - return 'N/A' + return '-inf' elif "Unknown" in value_str: return 'N/A' elif 'dBm' in value_str: @@ -534,8 +542,19 @@ def get_transceiver_info(self): application_advertisement |1*255VCHAR |supported applications advertisement ================================================================================ """ + self.reinit() + info_dict_keys = [ + 'type', 'hardware_rev', 'serial', 'manufacturer', + 'model', 'connector', 'encoding', 'ext_identifier', + 'ext_rateselect_compliance', 'cable_type', 'cable_length', + 'nominal_bit_rate', 'specification_compliance', 'vendor_date', + 'vendor_oui', 'application_advertisement', 'type_abbrv_name'] + transceiver_info_dict = {} compliance_code_dict = {} + transceiver_info_dict = dict.fromkeys(info_dict_keys, "NA") + transceiver_info_dict["specification_compliance"] = '{}' + transceiver_info_dict['type_abbrv_name'] = self.abbrv #QSFP if self.sfp_type == QSFP_TYPE: @@ -684,6 +703,7 @@ def get_transceiver_info(self): if sfp_media_type_dict is None: return None + transceiver_info_dict['specification_compliance'] = type_of_media_interface[sfp_media_type_raw[0]] host_media_list = "" sfp_application_type_first_list = self._read_eeprom_specific_bytes((XCVR_FIRST_APPLICATION_LIST_OFFSET_QSFP_DD), XCVR_FIRST_APPLICATION_LIST_WIDTH_QSFP_DD) possible_application_count = 8 @@ -711,7 +731,6 @@ def get_transceiver_info(self): transceiver_info_dict['encoding'] = "Not supported for CMIS cables" transceiver_info_dict['ext_identifier'] = str(sfp_ext_identifier_data['data']['Extended Identifier']['value']) transceiver_info_dict['ext_rateselect_compliance'] = "Not supported for CMIS cables" - transceiver_info_dict['specification_compliance'] = "Not supported for CMIS cables" transceiver_info_dict['cable_type'] = "Length Cable Assembly(m)" transceiver_info_dict['cable_length'] = str(sfp_cable_len_data['data']['Length Cable Assembly(m)']['value']) transceiver_info_dict['nominal_bit_rate'] = "Not supported for CMIS cables" @@ -748,6 +767,7 @@ def get_transceiver_bulk_status(self): TX power |INT |TX output power in mW ======================================================================== """ + self.reinit() transceiver_dom_info_dict = {} dom_info_dict_keys = ['temperature', 'voltage', @@ -844,7 +864,7 @@ def get_transceiver_bulk_status(self): dom_data_raw = self._read_eeprom_specific_bytes(QSFP_DD_CHANNL_MON['offset'], QSFP_DD_CHANNL_MON['width'], QSFP_DD_CHANNL_MON['page']) dom_channel_monitor_data = sfpd_obj.parse_channel_monitor_params(dom_data_raw, 0) - if self.dom_rx_power_supported: + if self.dom_tx_power_supported: transceiver_dom_info_dict['tx1power'] = dom_channel_monitor_data['data']['TX1Power']['value'] transceiver_dom_info_dict['tx2power'] = dom_channel_monitor_data['data']['TX2Power']['value'] transceiver_dom_info_dict['tx3power'] = dom_channel_monitor_data['data']['TX3Power']['value'] @@ -907,6 +927,7 @@ def get_transceiver_threshold_info(self): txbiaslowwarning |FLOAT |Low Warning Threshold value of tx Bias Current in mA. ======================================================================== """ + self.reinit() transceiver_dom_threshold_info_dict = {} dom_info_dict_keys = ['temphighalarm', 'temphighwarning', @@ -1031,6 +1052,7 @@ def get_rx_los(self): A Boolean, True if SFP has RX LOS, False if not. Note : RX LOS status is latched until a call to get_rx_los or a reset. """ + self.reinit() if not self.dom_supported: return None @@ -1052,7 +1074,7 @@ def get_rx_los(self): if self.dom_rx_tx_power_bias_supported: #not implement dom_channel_monitor_raw = self._read_eeprom_specific_bytes(QSFP_DD_CHANNL_RX_LOS_STATUS['offset'], QSFP_DD_CHANNL_RX_LOS_STATUS['width'], QSFP_DD_CHANNL_RX_LOS_STATUS['page']) if dom_channel_monitor_raw is not None: - rx_los_data = int(dom_channel_monitor_raw[0], 8) + rx_los_data = int(dom_channel_monitor_raw[0], 16) rx_los_list.append(rx_los_data & 0x01 != 0) rx_los_list.append(rx_los_data & 0x02 != 0) rx_los_list.append(rx_los_data & 0x04 != 0) @@ -1072,6 +1094,7 @@ def get_tx_fault(self): A Boolean, True if SFP has TX fault, False if not Note : TX fault status is lached until a call to get_tx_fault or a reset. """ + self.reinit() if not self.dom_supported: return None @@ -1104,6 +1127,7 @@ def get_tx_disable(self): for SFP, the TX Disable State and Soft TX Disable Select is ORed as the tx_disable status returned These two bits are bit 7 & 6 in byte 110 page a2 respectively """ + self.reinit() if not self.dom_supported: return None @@ -1174,6 +1198,7 @@ def get_temperature(self): Returns: An integer number of current temperature in Celsius """ + self.reinit() if not self.dom_supported: return None #QSFP @@ -1218,6 +1243,7 @@ def get_voltage(self): Returns: An integer number of supply voltage in mV """ + self.reinit() if not self.dom_supported: return None @@ -1263,6 +1289,7 @@ def get_tx_bias(self): for channel 0 to channel 4. Ex. ['110.09', '111.12', '108.21', '112.09'] """ + self.reinit() tx_bias_list = [] #QSFP @@ -1289,7 +1316,7 @@ def get_tx_bias(self): if sfpd_obj is None: return None - if dom_tx_bias_power_supported: + if self.dom_tx_bias_power_supported: dom_tx_bias_raw = self._read_eeprom_specific_bytes(QSFP_DD_TX_BIAS['offset'], QSFP_DD_TX_BIAS['width'], QSFP_DD_TX_BIAS['page']) if dom_tx_bias_raw is not None: dom_tx_bias_data = sfpd_obj.parse_dom_tx_bias(dom_tx_bias_raw, 0) @@ -1313,6 +1340,7 @@ def get_rx_power(self): power in mW for channel 0 to channel 4. Ex. ['1.77', '1.71', '1.68', '1.70'] """ + self.reinit() rx_power_list = [] #QSFP @@ -1368,6 +1396,7 @@ def get_tx_power(self): for channel 0 to channel 4. Ex. ['1.86', '1.86', '1.86', '1.86'] """ + self.reinit() tx_power_list = [] #QSFP @@ -1513,3 +1542,40 @@ def get_serial(self): transceiver_dom_info_dict = self.get_transceiver_info() return transceiver_dom_info_dict.get("serial", "N/A") + def get_status(self): + """ + Retrieves the operational status of the device + Returns: + A boolean value, True if device is operating properly, False if not + """ + return self.get_presence() and not self.get_reset_status() + + def get_position_in_parent(self): + """ + Returns: + Temp return 0 + """ + return 0 + + def is_replaceable(self): + """ + Retrieves if replaceable + Returns: + A boolean value, True if replaceable + """ + return True + + def get_error_description(self): + """ + Get error description + + Args: + error_code: The error code returned by _get_error_code + + Returns: + The error description + """ + if self.get_presence(): + return self.SFP_STATUS_OK + else: + return self.SFP_STATUS_UNPLUGGED diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/thermal.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/thermal.py index f45d930e87f5..730f5b1c6c21 100644 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/thermal.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/sonic_platform/thermal.py @@ -9,6 +9,7 @@ import os import os.path +import subprocess try: from sonic_platform_base.thermal_base import ThermalBase @@ -28,8 +29,14 @@ class Thermal(ThermalBase): "/sys/bus/i2c/devices/0-004d/", "/sys/bus/i2c/devices/0-004e/"] + IPMI_SENSOR_NR = ["0x30", "0x31", "0x32", "0x33", "0x34", "0x35", "0x36"] + def __init__(self, thermal_index): self.index = thermal_index + self.lnc = None + self.lcr = None + self.unc = None + self.ucr = None # Add thermal name self.THERMAL_NAME_LIST.append("Top-Rear") @@ -40,6 +47,20 @@ def __init__(self, thermal_index): self.THERMAL_NAME_LIST.append("Bottom-Front") self.THERMAL_NAME_LIST.append("Bottom-Rear") ThermalBase.__init__(self) + self.minimum_thermal = self.get_temperature() + self.maximum_thermal = self.get_temperature() + self.__initialize_threshold() + + def __initialize_threshold(self): + cmd = ["ipmitool", "raw", "0x4", "0x27"] + if self.lnc is None: + cmd.append(self.IPMI_SENSOR_NR[self.index]) + p = subprocess.Popen(cmd, stdout=subprocess.PIPE) + out, err = p.communicate() + self.unc = float(int(out.split()[4],16)) + self.ucr = float(int(out.split()[5],16)) + self.lnc = float(int(out.split()[1],16) if int(out.split()[1],16) != 0 else 2) + self.lcr = float(int(out.split()[2],16)) def __read_txt_file(self, file_path): try: @@ -57,7 +78,7 @@ def __get_temp(self, temp_file): return "{:.3f}".format(temp) def __set_threshold(self, file_name, temperature): - temp_file_path = os.path.join(self.hwmon_path, file_name) + temp_file_path = os.path.join(self.SYSFS_THERMAL_DIR[self.index], file_name) try: with open(temp_file_path, 'w') as fd: fd.write(str(temperature)) @@ -81,7 +102,8 @@ def get_low_threshold(self): :return: A float number, the low threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - return int(9) + + return self.lnc def get_low_critical_threshold(self): """ @@ -89,7 +111,8 @@ def get_low_critical_threshold(self): :return: A float number, the low critical threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - return int(7) + + return self.lcr def get_high_threshold(self): """ @@ -98,20 +121,8 @@ def get_high_threshold(self): A float number, the high threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - if self.index==0: - return int(56) - elif self.index==1: - return int(74) - elif self.index==2: - return int(55) - elif self.index==3: - return int(74) - elif self.index==4: - return int(55) - elif self.index==5: - return int(74) - else: - return int(56) + + return self.unc def get_high_critical_threshold(self): """ @@ -119,20 +130,8 @@ def get_high_critical_threshold(self): :return: A float number, the high critical threshold temperature of thermal in Celsius up to nearest thousandth of one degree Celsius, e.g. 30.125 """ - if self.index==0: - return int(58) - elif self.index==1: - return int(76) - elif self.index==2: - return int(57) - elif self.index==3: - return int(76) - elif self.index==4: - return int(57) - elif self.index==5: - return int(76) - else: - return int(58) + + return self.ucr def get_name(self): """ @@ -144,12 +143,12 @@ def get_name(self): def get_presence(self): """ - Retrieves the presence of the PSU + Retrieves the presence of the sensor Returns: - bool: True if PSU is present, False if not + bool: True if sensor is present, False if not """ temp_file = "temp1_input" - temp_file_path = os.path.join(self.hwmon_path, temp_file) + temp_file_path = os.path.join(self.SYSFS_THERMAL_DIR[self.index], temp_file) return os.path.isfile(temp_file_path) def get_status(self): @@ -163,3 +162,63 @@ def get_status(self): return True + def get_model(self): + """ + Retrieves the model number (or part number) of the device + Returns: + string: Model/part number of device + """ + return "None" + + def get_serial(self): + """ + Retrieves the serial number of the device + Returns: + string: Serial number of device + """ + return "None" + + def is_replaceable(self): + """ + Retrieves whether thermal module is replaceable + Returns: + A boolean value, True if replaceable, False if not + """ + return False + + def get_position_in_parent(self): + """ + Retrieves 1-based relative physical position in parent device. + If the agent cannot determine the parent-relative position + for some reason, or if the associated value of + entPhysicalContainedIn is'0', then the value '-1' is returned + Returns: + integer: The 1-based relative physical position in parent device + or -1 if cannot determine the position + """ + return self.index + 1 + + def get_minimum_recorded(self): + """ + Retrieves the minimum recorded temperature of thermal + Returns: + A float number, the minimum recorded temperature of thermal in Celsius + up to nearest thousandth of one degree Celsius, e.g. 30.125 + """ + tmp = self.get_temperature() + if tmp < self.minimum_thermal: + self.minimum_thermal = tmp + return self.minimum_thermal + + def get_maximum_recorded(self): + """ + Retrieves the maximum recorded temperature of thermal + Returns: + A float number, the maximum recorded temperature of thermal in Celsius + up to nearest thousandth of one degree Celsius, e.g. 30.125 + """ + tmp = self.get_temperature() + if tmp > self.maximum_thermal: + self.maximum_thermal = tmp + return self.maximum_thermal + diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_firmware_version b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_firmware_version new file mode 100755 index 000000000000..0ce6e8624436 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_firmware_version @@ -0,0 +1,24 @@ +#!/bin/bash +ver_str=$(ipmitool raw 0x30 0x23 2>>/dev/null) +fpga_ver=$(echo $ver_str | awk '{printf $3}') +cpld1_ver=$(echo $ver_str | awk '{printf $4}') +cpld2_ver=$(echo $ver_str | awk '{printf $5}') +fan_cpld_ver=$(echo $ver_str | awk '{printf $6}') + +cpld1_ver=$( printf "%d" 0x$cpld1_ver ) +cpld2_ver=$( printf "%d" 0x$cpld2_ver ) +fan_cpld_ver=$( printf "%d" 0x$fan_cpld_ver ) +fpga_ver=$( printf "%d" 0x$fpga_ver ) + +cpld1_ver_path="/sys/bus/i2c/devices/0-0061/version" +cpld2_ver_path="/sys/bus/i2c/devices/0-0062/version" +fan_cpld_ver_path="/sys/bus/i2c/devices/0-0066/version" +fpga_ver_path="/sys/bus/i2c/devices/0-0060/version" + +echo $cpld1_ver > $cpld1_ver_path +echo $cpld2_ver > $cpld2_ver_path +echo $fpga_ver > $fpga_ver_path +echo $fan_cpld_ver > $fan_cpld_ver_path + +exit 0 + diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_led b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_led old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_pld b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_pld old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_sync b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/platform_sync old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-fanthrml-monitor b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-fanthrml-monitor old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-led-monitor b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-led-monitor old mode 100644 new mode 100755 index ba4f4c8dae99..364ac53b1865 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-led-monitor +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-led-monitor @@ -2,6 +2,7 @@ #0=off, 1=green, 2=amber, 3=blk_green led_state=0 +pre_loc_state=0 #$1=led_no(1=loc, 2=diag, 3=fan, 4=psu1, 5=psu2) bmc_led_read() @@ -128,37 +129,10 @@ bmc_led_read() return 0 } -#$1=led_no(1=loc, 2=diag, 3=fan, 4=psu1, 5=psu2) -#$2=led_val(0=off, 1=green, 2=amber, 3=blk_green) +#$1=led_val(0=off, 1=green, 2=amber, 3=blk_green) bmc_led_write() { - led_val=$2 - val=$(ipmitool raw 0x30 0x97 2>>/dev/null) - loc_val=$(echo $val | awk '{printf $1}') - diag_val=$(echo $val | awk '{printf $2}') - fan_val=$(echo $val | awk '{printf $3}') - psu1_val=$(echo $val | awk '{printf $4}') - psu2_val=$(echo $val | awk '{printf $5}') - - loc_val=$( printf "%d" 0x$loc_val ) - diag_val=$( printf "%d" 0x$diag_val ) - fan_val=$( printf "%d" 0x$fan_val ) - psu1_val=$( printf "%d" 0x$psu1_val ) - psu2_val=$( printf "%d" 0x$psu2_val ) - - if [ $1 -eq 1 ];then - loc_val=$(($loc_val & $led_val)) - elif [ $1 -eq 2 ];then - diag_val=$(($diag_val & $led_val)) - elif [ $1 -eq 3 ];then - fan_val=$(($fan_val & $led_val)) - elif [ $1 -eq 4 ];then - psu1_val=$(($psu1_val & $led_val)) - else - psu2_val=$(($psu2_val & $led_val)) - fi - - ipmitool raw 0x30 0x96 $loc_val $diag_val $fan_val $psu1_val $psu2_val 1>>/dev/null 2>>/dev/null + ipmitool raw 0x30 0x2b 0x2 0xc0 0x0 0x55 0x"$1"0 1>>/dev/null 2>>/dev/null } LED_monitor() @@ -171,7 +145,13 @@ LED_monitor() do if [ -e /sys/bus/i2c/devices/0-0060/sys_led_diag ];then loc_state=$(cat /sys/bus/i2c/devices/0-0060/sys_led_loc | awk '{printf $1}') - bmc_led_write 1 $loc_state + if [ $loc_state -gt 4 ]; then + loc_state=4 + fi + if [ $loc_state != $pre_loc_state ]; then + bmc_led_write $loc_state + pre_loc_state=$loc_state + fi bmc_led_read 2 if [ $? -eq 1 ];then diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-psu-monitor b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-psu-monitor old mode 100644 new mode 100755 index bcb3502e4a7c..d5cfd719344b --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-psu-monitor +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-psu-monitor @@ -85,61 +85,73 @@ get_PSU_information() #PSU1 Vin add_byte 1 2 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_v_in fi #PSU2 Vin add_byte 3 4 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_v_in fi #PSU 1 Vout add_byte 5 6 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_v_out fi #PSU 2 Vout add_byte 7 8 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_v_out fi #PSU 1 Iin add_byte 9 10 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_i_in fi #PSU 2 Iin add_byte 11 12 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_i_in fi #PSU 1 Iout add_byte 13 14 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_i_out fi #PSU 2 Iout add_byte 15 16 if [ $? -eq 1 ];then + Value=$((Value * 10)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_i_out fi #PSU 1 Pin add_byte 17 18 if [ $? -eq 1 ];then + Value=$((Value * 1000000)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_p_in fi #PSU 2 Pin add_byte 19 20 if [ $? -eq 1 ];then + Value=$((Value * 1000000)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_p_in fi #PSU 1 Pout add_byte 21 22 if [ $? -eq 1 ];then + Value=$((Value * 1000000)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_p_out fi #PSU 2 Pout add_byte 23 24 if [ $? -eq 1 ];then + Value=$((Value * 1000000)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_p_out fi #PSU 1 Fan speed @@ -156,9 +168,11 @@ get_PSU_information() #----------------93->/58/59----psu_fan1_fault psu_temp1_input psu_fan1_duty_cycle #PSU 1 Temp1 byte_read 25 + Value=$((Value * 1000)) echo $Value > /sys/bus/i2c/devices/0-005a/psu_temp1_input #PSU 2 Temp1 byte_read 26 + Value=$((Value * 1000)) echo $Value > /sys/bus/i2c/devices/0-0059/psu_temp1_input if [ $debug_flag -eq 0 ];then #PSU 1 Fan command @@ -314,8 +328,8 @@ PSU_monitor() { while true - do - + do + get_PSU_information if [ $debug_flag -eq 1 ];then bmc_fan_speed_ctrl diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-qsfp-monitor b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sonic-qsfp-monitor old mode 100644 new mode 100755 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sw_to3200k_watchdog.sh b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sw_to3200k_watchdog.sh new file mode 100755 index 000000000000..082c3497cdc8 --- /dev/null +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/sw_to3200k_watchdog.sh @@ -0,0 +1,5 @@ +#! /bin/bash + +#we don't have watchdog design in SW3200K so always return OK to skip + +exit 0 diff --git a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/wistron_sw_to3200k_util.py b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/wistron_sw_to3200k_util.py old mode 100644 new mode 100755 index 46121e6e7eed..c7b65e16e2c4 --- a/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/wistron_sw_to3200k_util.py +++ b/platform/innovium/sonic-platform-modules-wistron/sw-to3200k/utils/wistron_sw_to3200k_util.py @@ -229,6 +229,18 @@ def device_install(): print(output) if FORCE == 0: return status + + status, output = log_os_system("cp /usr/share/sonic/device/x86_64-wistron_sw_to3200k-r0/smartd.conf /etc/;systemctl restart smartd.service", 1) + if status: + print(output) + if FORCE == 0: + return status + + status, output = log_os_system("cp /usr/share/sonic/device/x86_64-wistron_sw_to3200k-r0/watchdog-control.service /usr/lib/systemd/system/", 1) + if status: + print(output) + if FORCE == 0: + return status return def device_uninstall(): @@ -284,12 +296,6 @@ def do_install(): else: print(PROJECT_NAME.upper()+" devices detected....") - status, output = log_os_system( - "/bin/sh /usr/local/bin/platform_api_mgnt.sh init", 1) - if status: - print(output) - if FORCE == 0: - return status return def do_uninstall(): diff --git a/platform/mellanox/docker-syncd-mlnx/ecmp_calculator/ecmp_calc.py b/platform/mellanox/docker-syncd-mlnx/ecmp_calculator/ecmp_calc.py index 280275529b73..2fbcef86993e 100755 --- a/platform/mellanox/docker-syncd-mlnx/ecmp_calculator/ecmp_calc.py +++ b/platform/mellanox/docker-syncd-mlnx/ecmp_calculator/ecmp_calc.py @@ -23,14 +23,18 @@ PORT, VPORT, VLAN, SX_ENTRY_NOT_FOUND from packet_scheme import PACKET_SCHEME from port_utils import sx_get_ports_map, is_lag +from swsscommon.swsscommon import ConfigDBConnector, DBConnector, Table IP_VERSION_IPV4 = 1 IP_VERSION_IPV6 = 2 -PORT_CHANNEL_IDX = 1 +PORT_CHANNEL_IDX = 0 VRF_NAME_IDX = 1 IP_VERSION_MAX_MASK_LEN = {IP_VERSION_IPV4: 32, IP_VERSION_IPV6: 128} +APPL_DB_NAME = 'APPL_DB' INTF_TABLE = 'INTF_TABLE' +VRF_TABLE = 'VRF_TABLE' +LAG_MEMBER_TABLE = 'LAG_MEMBER_TABLE' HASH_CALC_PATH = '/usr/bin/sx_hash_calculator' HASH_CALC_INPUT_FILE = "/tmp/hash_calculator_input.json" HASH_CALC_OUTPUT_FILE = "/tmp/hash_calculator_output.json" @@ -113,6 +117,8 @@ def __init__(self): self.egress_ports = [] self.debug = False + self.config_db = ConfigDBConnector() + self.appl_db = DBConnector(APPL_DB_NAME, 0) self.open_sdk_connection() self.init_ports_map() self.get_active_vrids() @@ -137,7 +143,7 @@ def debug_print(self, *args, **kwargs): print(*args, **kwargs) def init_ports_map(self): - self.ports_map = sx_get_ports_map(self.handle) + self.ports_map = sx_get_ports_map(self.handle, self.config_db) def validate_ingress_port(self, interface): if interface not in self.ports_map.values(): @@ -156,16 +162,12 @@ def validate_args(self, interface, packet, vrf, debug): if not self.validate_vrf(): raise ValueError("VRF validation failed: VRF {} does not exist".format(self.user_vrf)) - def validate_vrf(self): - query_output = exec_cmd(['/usr/bin/redis-cli', '-n', '0', 'keys','*VRF*']).strip() - if not query_output: - return False + def validate_vrf(self): + vrf_table = Table(self.appl_db, VRF_TABLE) + vrf_table_keys = vrf_table.getKeys() - vrf_entries= query_output.split('\n') - for entry in vrf_entries: - vrf = entry.split(':')[VRF_NAME_IDX] - if vrf == self.user_vrf: - return True + if self.user_vrf in vrf_table_keys: + return True return False @@ -289,26 +291,30 @@ def print_egress_port(self): def is_port_bind_to_user_vrf(self, port_type, port, vlan_id = 0): if port_type == PORT: # INTF_TABLE:Ethernet0 - entry = '{}:{}'.format(INTF_TABLE, port) + entry = '{}'.format(port) elif port_type == VPORT: # INTF_TABLE:Ethernet0.300 - entry = '{}:{}.{}'.format(INTF_TABLE, port, vlan_id) + entry = '{}.{}'.format(port, vlan_id) elif port_type == VLAN: # INTF_TABLE:Vlan300 - entry = '{}:Vlan{}'.format(INTF_TABLE, vlan_id) + entry = 'Vlan{}'.format(vlan_id) + + vrf_table = Table(self.appl_db, INTF_TABLE) + (_, port_vrf) = vrf_table.hget(entry, 'vrf_name') - port_vrf = exec_cmd(['/usr/bin/redis-cli', '-n', '0', 'hget', entry, 'vrf_name']) if self.user_vrf == port_vrf.strip(): return True return False # Get port-channel name for given port-channel member port - def get_port_channel_name(self, port): - query_output = exec_cmd(['/usr/bin/redis-cli', '-n', '0', 'keys','*LAG_MEMBER_TABLE*']) - for line in query_output.split('\n'): - if str(port) in line: - port_channel = line.split(':')[PORT_CHANNEL_IDX] + def get_port_channel_name(self, port): + lag_member_table = Table(self.appl_db, LAG_MEMBER_TABLE) + lag_member_table_keys = lag_member_table.getKeys() + + for key in lag_member_table_keys: + if port in key: + port_channel = key.split(':')[PORT_CHANNEL_IDX] return port_channel raise KeyError("Failed to get port-channel name for interface {}".format(port)) @@ -368,7 +374,7 @@ def get_lag_member(self, logical, flood_case = False): member_index = self.get_lag_member_index(len(lag_members), flood_case) lag_member = lag_members[member_index] - self.debug_print("Lag member from which trafic will egress: {}".format(lag_member)) + self.debug_print("Lag members: {}\nLag member from which trafic will egress: {}".format(lag_members, lag_member)) return lag_member def call_hash_calculator(self, input_dict): diff --git a/platform/mellanox/docker-syncd-mlnx/lib/port_utils.py b/platform/mellanox/docker-syncd-mlnx/lib/port_utils.py index cce63298cf9a..f00d22d5426c 100755 --- a/platform/mellanox/docker-syncd-mlnx/lib/port_utils.py +++ b/platform/mellanox/docker-syncd-mlnx/lib/port_utils.py @@ -2,27 +2,86 @@ from python_sdk_api.sx_api import * import inspect +import re DEVICE_ID = 1 SWITCH_ID = 0 +PORT_TABLE = 'PORT' +FIRST_LANE_INDEX = 0 ETHERNET_PREFIX = 'Ethernet' -ASIC_MAX_LANES = {SX_CHIP_TYPE_SPECTRUM: 4, SX_CHIP_TYPE_SPECTRUM2: 4, - SX_CHIP_TYPE_SPECTRUM3: 8, SX_CHIP_TYPE_SPECTRUM4: 8} -def sx_get_ports_map(handle): +def get_ports_lanes_map(config_db): + """ Get lane number of the first lane in use by port for all existing ports. + + Args: + config_db (ConfigDBConnector): Config DB connector + + Returns: + dict: key is lane number of the first lane in use by port, value is SONiC port index (124 for Ethernet124) + """ + lanes_map = {} + config_db.connect() + + ports_table = config_db.get_table(PORT_TABLE) + if ports_table is None: + raise Exception("Can't read {} table".format(PORT_TABLE)) + + ports_table_keys = config_db.get_keys(PORT_TABLE) + for port in ports_table_keys: + port_data = ports_table.get(port) + if port_data is not None: + lanes = port_data.get('lanes') + first_lane = lanes.split(',')[FIRST_LANE_INDEX] + port_idx = re.sub(r"\D", "", port) + lanes_map[int(first_lane)] = int(port_idx) + + return lanes_map + +def get_port_max_width(handle): + """ Get max number of lanes in port according to chip type + + Args: + handle (sx_api_handle_t): SDK handle + + Returns: + int: max lanes in port + """ + # Get chip type + chip_type = sx_get_chip_type(handle) + + limits = rm_resources_t() + modes = rm_modes_t() + + rc = rm_chip_limits_get(chip_type, limits) + sx_check_rc(rc) + max_width = limits.port_map_width_max + + # SPC2 ports have 8 lanes but SONiC is using 4 + if chip_type == SX_CHIP_TYPE_SPECTRUM2: + max_width = 4 + + return max_width + +def sx_get_ports_map(handle, config_db): """ Get ports map from SDK logical index to SONiC index Args: handle (sx_api_handle_t): SDK handle - + config_db (ConfigDBConnector): Config DB connector + Returns: - dict : Dictionary of ports indices. Key is SDK logical index, value is SONiC index (4 for Ethernet4) + dict: key is SDK logical index, value is SONiC index (4 for Ethernet4) """ try: ports_map = {} + port_attributes_list = None + port_cnt_p = None - # Get chip type - chip_type = sx_get_chip_type(handle) + # Get lanes map + lanes_map = get_ports_lanes_map(config_db) + + # Get max number of lanes in port + port_max_width = get_port_max_width(handle) # Get ports count port_cnt_p = new_uint32_t_p() @@ -45,10 +104,12 @@ def sx_get_ports_map(handle): continue # Calculate sonic index (sonic index=4 for Ethernet4) - lane_index = get_lane_index(lane_bmap, ASIC_MAX_LANES[chip_type]) + lane_index = get_lane_index(lane_bmap, port_max_width) assert lane_index != -1, "Failed to calculate port index" - sonic_index = label_port * ASIC_MAX_LANES[chip_type] + lane_index; + first_lane = label_port * port_max_width + lane_index; + sonic_index = lanes_map[first_lane] + sonic_interface = ETHERNET_PREFIX + str(sonic_index) ports_map[logical_port] = sonic_interface @@ -65,7 +126,7 @@ def sx_get_chip_type(handle): handle (sx_api_handle_t): SDK handle Returns: - sx_chip_types_t : Chip type + sx_chip_types_t: Chip type """ try: device_info_cnt_p = new_uint32_t_p() @@ -95,7 +156,7 @@ def get_lane_index(lane_bmap, max_lanes): max_lanes (int): Max lanes in module Returns: - int : index of the first bit set to 1 in lane_bmap + int: index of the first bit set to 1 in lane_bmap """ for lane_idx in range(0, max_lanes): if (lane_bmap & 0x1 == 1): diff --git a/platform/mellanox/fw.dep b/platform/mellanox/fw.dep index f57bad8eb9b0..228f6dc87e36 100644 --- a/platform/mellanox/fw.dep +++ b/platform/mellanox/fw.dep @@ -14,7 +14,3 @@ $(MLNX_SPC2_FW_FILE)_DEP_FILES := $(DEP_FILES) $(MLNX_SPC3_FW_FILE)_CACHE_MODE := GIT_CONTENT_SHA $(MLNX_SPC3_FW_FILE)_DEP_FLAGS := $(SONIC_COMMON_FLAGS_LIST) $(MLNX_SPC3_FW_FILE)_DEP_FILES := $(DEP_FILES) - -$(MLNX_SPC4_FW_FILE)_CACHE_MODE := GIT_CONTENT_SHA -$(MLNX_SPC4_FW_FILE)_DEP_FLAGS := $(SONIC_COMMON_FLAGS_LIST) -$(MLNX_SPC4_FW_FILE)_DEP_FILES := $(DEP_FILES) diff --git a/platform/mellanox/fw.mk b/platform/mellanox/fw.mk index 6ce3c8faabca..77e4daf589b6 100644 --- a/platform/mellanox/fw.mk +++ b/platform/mellanox/fw.mk @@ -44,12 +44,7 @@ MLNX_SPC3_FW_FILE = fw-SPC3-rel-$(subst .,_,$(MLNX_SPC3_FW_VERSION))-EVB.mfa $(MLNX_SPC3_FW_FILE)_PATH = $(MLNX_FW_BASE_PATH) $(MLNX_SPC3_FW_FILE)_URL = $(MLNX_FW_BASE_URL)/$(MLNX_SPC3_FW_FILE) -MLNX_SPC4_FW_VERSION = 34.2010.4150 -MLNX_SPC4_FW_FILE = fw-SPC4-rel-$(subst .,_,$(MLNX_SPC4_FW_VERSION))-EVB.mfa -$(MLNX_SPC4_FW_FILE)_PATH = $(MLNX_FW_BASE_PATH) -$(MLNX_SPC4_FW_FILE)_URL = $(MLNX_FW_BASE_URL)/$(MLNX_SPC4_FW_FILE) - -MLNX_FW_FILES = $(MLNX_SPC_FW_FILE) $(MLNX_SPC2_FW_FILE) $(MLNX_SPC3_FW_FILE) $(MLNX_SPC4_FW_FILE) +MLNX_FW_FILES = $(MLNX_SPC_FW_FILE) $(MLNX_SPC2_FW_FILE) $(MLNX_SPC3_FW_FILE) ifeq ($(FW_FROM_URL),n) SONIC_COPY_FILES += $(MLNX_FW_FILES) @@ -62,4 +57,3 @@ MLNX_FILES += $(MLNX_FW_FILES) export MLNX_SPC_FW_FILE export MLNX_SPC2_FW_FILE export MLNX_SPC3_FW_FILE -export MLNX_SPC4_FW_FILE diff --git a/platform/mellanox/hw-management.mk b/platform/mellanox/hw-management.mk index 0c8c8c1b548d..a12bd9b32aca 100644 --- a/platform/mellanox/hw-management.mk +++ b/platform/mellanox/hw-management.mk @@ -16,7 +16,7 @@ # # Mellanox HW Management -MLNX_HW_MANAGEMENT_VERSION = 7.0020.3006 +MLNX_HW_MANAGEMENT_VERSION = 7.0020.4104 export MLNX_HW_MANAGEMENT_VERSION diff --git a/platform/mellanox/hw-management/0001-Make-SONiC-determine-reboot-cause-service-start-afte.patch b/platform/mellanox/hw-management/0001-Make-SONiC-determine-reboot-cause-service-start-afte.patch index 11539e606369..f7667ed6c4ea 100644 --- a/platform/mellanox/hw-management/0001-Make-SONiC-determine-reboot-cause-service-start-afte.patch +++ b/platform/mellanox/hw-management/0001-Make-SONiC-determine-reboot-cause-service-start-afte.patch @@ -1,8 +1,8 @@ -From 1a1011b6da491d35001df5a7204d4eecb2769767 Mon Sep 17 00:00:00 2001 +From 489764eb124e03087eb408dec27d769fa4f98459 Mon Sep 17 00:00:00 2001 From: keboliu Date: Fri, 15 Jan 2021 14:41:16 +0800 -Subject: [PATCH] Make SONiC determine-reboot-cause service start after hw-mgmt - service +Subject: [PATCH 1/4] Make SONiC determine-reboot-cause service start after + hw-mgmt service Signed-off-by: Kebo Liu --- @@ -10,7 +10,7 @@ Signed-off-by: Kebo Liu 1 file changed, 1 insertion(+) diff --git a/debian/hw-management.hw-management.service b/debian/hw-management.hw-management.service -index 39a2a54..2104b87 100755 +index 8bdcaef..1c25ffb 100755 --- a/debian/hw-management.hw-management.service +++ b/debian/hw-management.hw-management.service @@ -1,6 +1,7 @@ @@ -22,5 +22,5 @@ index 39a2a54..2104b87 100755 [Service] Type=oneshot -- -1.9.1 +2.20.1 diff --git a/platform/mellanox/hw-management/0002-Disable-hw-mgmt-on-SimX-platforms.patch b/platform/mellanox/hw-management/0002-Disable-hw-mgmt-on-SimX-platforms.patch index c12474712b9b..61aab18090a2 100644 --- a/platform/mellanox/hw-management/0002-Disable-hw-mgmt-on-SimX-platforms.patch +++ b/platform/mellanox/hw-management/0002-Disable-hw-mgmt-on-SimX-platforms.patch @@ -1,59 +1,47 @@ -From 79dadd5b0d2f5e860b525c12d4d3843607b03a9f Mon Sep 17 00:00:00 2001 +From 422b64397f2f33b394d037820f0ceb4c09e3a725 Mon Sep 17 00:00:00 2001 From: Alexander Allen Date: Fri, 21 Jan 2022 16:47:19 +0000 -Subject: [PATCH] Disable hw-mgmt on SimX platforms +Subject: [PATCH 2/4] Disable hw-mgmt on SimX platforms --- - usr/usr/bin/hw-management-ready.sh | 31 ++++++++++++++++-------------- + usr/usr/bin/hw-management-ready.sh | 11 +++++++---- usr/usr/bin/hw-management.sh | 9 +++++++++ - 2 files changed, 26 insertions(+), 14 deletions(-) + 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/usr/usr/bin/hw-management-ready.sh b/usr/usr/bin/hw-management-ready.sh -index 5a9698c..364f906 100755 +index 88672a8..7558c68 100755 --- a/usr/usr/bin/hw-management-ready.sh +++ b/usr/usr/bin/hw-management-ready.sh -@@ -51,19 +51,22 @@ if [ -d /var/run/hw-management ]; then +@@ -51,17 +51,20 @@ if [ -d /var/run/hw-management ]; then rm -fr /var/run/hw-management fi -case $board_type in -VMOD0014) -- while [ ! -d /sys/devices/pci0000:00/0000:00:1f.0/NVSN2201:00/mlxreg-hotplug/hwmon ] -- do -- sleep 1 -- done -- ;; ++if [ -z "$(lspci -vvv | grep SimX)" ]; then ++ case $board_type in ++ VMOD0014) + if [ ! -d /sys/devices/pci0000:00/0000:00:1f.0/NVSN2201:00/mlxreg-hotplug/hwmon ]; then + timeout 180 bash -c 'until [ -d /sys/devices/pci0000:00/0000:00:1f.0/NVSN2201:00/mlxreg-hotplug/hwmon ]; do sleep 0.2; done' + fi + ;; -*) -- while [ ! -d /sys/devices/platform/mlxplat/mlxreg-hotplug/hwmon ] -- do -- sleep 1 -- done -- ;; ++ *) + if [ ! -d /sys/devices/platform/mlxplat/mlxreg-hotplug/hwmon ]; then + timeout 180 bash -c 'until [ -d /sys/devices/platform/mlxplat/mlxreg-hotplug/hwmon ]; do sleep 0.2; done' + fi + ;; -esac -+if [ -z "$(lspci -vvv | grep SimX)" ]; then -+ case $board_type in -+ VMOD0014) -+ while [ ! -d /sys/devices/pci0000:00/0000:00:1f.0/NVSN2201:00/mlxreg-hotplug/hwmon ] -+ do -+ sleep 1 -+ done -+ ;; -+ *) -+ while [ ! -d /sys/devices/platform/mlxplat/mlxreg-hotplug/hwmon ] -+ do -+ sleep 1 -+ done -+ ;; -+ esac ++ esac +fi + echo "Start Chassis HW management service." logger -t hw-management -p daemon.notice "Start Chassis HW management service." diff --git a/usr/usr/bin/hw-management.sh b/usr/usr/bin/hw-management.sh -index ebfabb0..c0c038e 100755 +index 1ee05b5..50d922b 100755 --- a/usr/usr/bin/hw-management.sh +++ b/usr/usr/bin/hw-management.sh -@@ -1495,6 +1495,13 @@ do_chip_down() +@@ -2310,6 +2310,13 @@ do_chip_down() /usr/bin/hw-management-thermal-events.sh change hotplug_asic down %S %p } @@ -67,7 +55,7 @@ index ebfabb0..c0c038e 100755 __usage=" Usage: $(basename "$0") [Options] -@@ -1520,6 +1527,8 @@ Options: +@@ -2335,6 +2342,8 @@ Options: force-reload Performs hw-management 'stop' and the 'start. " @@ -77,5 +65,5 @@ index ebfabb0..c0c038e 100755 start) if [ -d /var/run/hw-management ]; then -- -2.17.1 +2.20.1 diff --git a/platform/mellanox/hw-management/0003-Remove-unused-non-upstream-kernel-modules-from-load.patch b/platform/mellanox/hw-management/0003-Remove-unused-non-upstream-kernel-modules-from-load.patch index 496085e9d4d8..ba83bf6764ee 100644 --- a/platform/mellanox/hw-management/0003-Remove-unused-non-upstream-kernel-modules-from-load.patch +++ b/platform/mellanox/hw-management/0003-Remove-unused-non-upstream-kernel-modules-from-load.patch @@ -1,14 +1,14 @@ -From 14b06a12802fc0e15116a64f419d002d0d21d695 Mon Sep 17 00:00:00 2001 +From 439639e939f896f9aee42a4dbd5216feb728220c Mon Sep 17 00:00:00 2001 From: Alexander Allen Date: Thu, 17 Feb 2022 04:19:50 +0000 -Subject: [PATCH] Remove unused non-upstream kernel modules from load +Subject: [PATCH 3/4] Remove unused non-upstream kernel modules from load --- usr/etc/modules-load.d/05-hw-management-modules.conf | 2 -- 1 file changed, 2 deletions(-) diff --git a/usr/etc/modules-load.d/05-hw-management-modules.conf b/usr/etc/modules-load.d/05-hw-management-modules.conf -index 39f621e..c0980bc 100644 +index cfcfaa4..dd3b5ca 100644 --- a/usr/etc/modules-load.d/05-hw-management-modules.conf +++ b/usr/etc/modules-load.d/05-hw-management-modules.conf @@ -15,8 +15,6 @@ xdpe12284 @@ -21,5 +21,5 @@ index 39f621e..c0980bc 100644 gpio-pca953x pmbus -- -2.17.1 +2.20.1 diff --git a/platform/mellanox/hw-management/0004-Make-system-health-service-starts-after-hw-managemen.patch b/platform/mellanox/hw-management/0004-Make-system-health-service-starts-after-hw-managemen.patch new file mode 100644 index 000000000000..6af57c842d2d --- /dev/null +++ b/platform/mellanox/hw-management/0004-Make-system-health-service-starts-after-hw-managemen.patch @@ -0,0 +1,29 @@ +From 038bce6bf808ec9d082e96fec4184e060b3a85a9 Mon Sep 17 00:00:00 2001 +From: Stephen Sun +Date: Mon, 28 Nov 2022 03:55:14 +0000 +Subject: [PATCH 4/4] Make system-health service starts after hw-management to + avoid failures + +On SN2410, it can fail to read the file led_status_capability if it starts from ONIE + +Signed-off-by: Stephen Sun +--- + debian/hw-management.hw-management.service | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/debian/hw-management.hw-management.service b/debian/hw-management.hw-management.service +index 1c25ffb..0fbd877 100755 +--- a/debian/hw-management.hw-management.service ++++ b/debian/hw-management.hw-management.service +@@ -1,7 +1,7 @@ + [Unit] + Description=Chassis HW management service of Mellanox systems + Documentation=man:hw-management.service(8) +-Before=determine-reboot-cause.service ++Before=determine-reboot-cause.service system-health.service + + [Service] + Type=oneshot +-- +2.20.1 + diff --git a/platform/mellanox/hw-management/hw-mgmt b/platform/mellanox/hw-management/hw-mgmt index 137109ed15be..9c3f6b2d6ac4 160000 --- a/platform/mellanox/hw-management/hw-mgmt +++ b/platform/mellanox/hw-management/hw-mgmt @@ -1 +1 @@ -Subproject commit 137109ed15be147a99b59ceb9dfa1799688dfb71 +Subproject commit 9c3f6b2d6ac4be2eda936522f369ff8920deb4e2 diff --git a/platform/mellanox/mft.mk b/platform/mellanox/mft.mk index 047e87b09086..be37064b9403 100644 --- a/platform/mellanox/mft.mk +++ b/platform/mellanox/mft.mk @@ -19,7 +19,15 @@ MFT_VERSION = 4.21.0 MFT_REVISION = 100 -export MFT_VERSION MFT_REVISION +MLNX_MFT_INTERNAL_SOURCE_BASE_URL = + +ifneq ($(MLNX_MFT_INTERNAL_SOURCE_BASE_URL), ) +MFT_FROM_INTERNAL = y +else +MFT_FROM_INTERNAL = n +endif + +export MFT_VERSION MFT_REVISION MFT_FROM_INTERNAL MLNX_MFT_INTERNAL_SOURCE_BASE_URL MFT = mft_$(MFT_VERSION)-$(MFT_REVISION)_$(CONFIGURED_ARCH).deb $(MFT)_SRC_PATH = $(PLATFORM_PATH)/mft diff --git a/platform/mellanox/mft/Makefile b/platform/mellanox/mft/Makefile index 4c454028b0e0..3139e874cc08 100644 --- a/platform/mellanox/mft/Makefile +++ b/platform/mellanox/mft/Makefile @@ -27,6 +27,12 @@ endif MFT_NAME = mft-$(MFT_VERSION)-$(MFT_REVISION)-$(MFT_ARCH)-deb MFT_TGZ = $(MFT_NAME).tgz +ifeq ($(MFT_FROM_INTERNAL),y) +MFT_TGZ_URL = $(MLNX_MFT_INTERNAL_SOURCE_BASE_URL)$(MFT_TGZ) +else +MFT_TGZ_URL = http://www.mellanox.com/downloads/MFT/$(MFT_TGZ) +endif + SRC_DEB = kernel-mft-dkms_$(MFT_VERSION)-$(MFT_REVISION)_all.deb MOD_DEB = kernel-mft-dkms-modules-$(KVERSION)_$(MFT_VERSION)_$(CONFIGURED_ARCH).deb @@ -38,7 +44,7 @@ DKMS_TMP := $(shell mktemp -u -d -t dkms.XXXXXXXXXX) $(addprefix $(DEST)/, $(MAIN_TARGET)): $(DEST)/% : rm -rf $(MFT_NAME) - wget -O $(MFT_TGZ) http://www.mellanox.com/downloads/MFT/$(MFT_TGZ) + wget -O $(MFT_TGZ) $(MFT_TGZ_URL) tar xzf $(MFT_TGZ) pushd $(MFT_NAME)/SDEBS diff --git a/platform/mellanox/mlnx-fw-upgrade.j2 b/platform/mellanox/mlnx-fw-upgrade.j2 index 86fd32e6a89a..1c650fd5ce63 100755 --- a/platform/mellanox/mlnx-fw-upgrade.j2 +++ b/platform/mellanox/mlnx-fw-upgrade.j2 @@ -28,7 +28,6 @@ declare -r LIST_CONTENT_FILE="/tmp/mlxfwmanager-list-content.log" declare -r SPC1_ASIC="spc1" declare -r SPC2_ASIC="spc2" declare -r SPC3_ASIC="spc3" -declare -r SPC4_ASIC="spc4" declare -r UNKN_ASIC="unknown" declare -r UNKN_MST="unknown" @@ -36,7 +35,6 @@ declare -rA FW_FILE_MAP=( \ [$SPC1_ASIC]="/etc/mlnx/fw-SPC.mfa" \ [$SPC2_ASIC]="/etc/mlnx/fw-SPC2.mfa" \ [$SPC3_ASIC]="/etc/mlnx/fw-SPC3.mfa" \ - [$SPC4_ASIC]="/etc/mlnx/fw-SPC4.mfa" \ ) IMAGE_UPGRADE="${NO_PARAM}" @@ -162,7 +160,6 @@ function GetAsicType() { local -r SPC1_PRODUCT_ID="cb84" local -r SPC2_PRODUCT_ID="cf6c" local -r SPC3_PRODUCT_ID="cf70" - local -r SPC4_PRODUCT_ID="cf80" if lspci -n | grep "${VENDOR_ID}:${SPC1_PRODUCT_ID}" &>/dev/null; then echo "${SPC1_ASIC}" @@ -173,9 +170,6 @@ function GetAsicType() { elif lspci -n | grep "${VENDOR_ID}:${SPC3_PRODUCT_ID}" &>/dev/null; then echo "${SPC3_ASIC}" exit "${EXIT_SUCCESS}" - elif lspci -n | grep "${VENDOR_ID}:${SPC4_PRODUCT_ID}" &>/dev/null; then - echo "${SPC4_ASIC}" - exit "${EXIT_SUCCESS}" fi echo "${UNKN_ASIC}" diff --git a/platform/mellanox/mlnx-platform-api.mk b/platform/mellanox/mlnx-platform-api.mk index ecd8b8532e6d..a8846e26f855 100644 --- a/platform/mellanox/mlnx-platform-api.mk +++ b/platform/mellanox/mlnx-platform-api.mk @@ -21,6 +21,7 @@ SONIC_PLATFORM_API_PY3 = mlnx_platform_api-1.0-py3-none-any.whl $(SONIC_PLATFORM_API_PY3)_SRC_PATH = $(PLATFORM_PATH)/mlnx-platform-api $(SONIC_PLATFORM_API_PY3)_PYTHON_VERSION = 3 $(SONIC_PLATFORM_API_PY3)_DEPENDS = $(SONIC_PY_COMMON_PY3) $(SONIC_PLATFORM_COMMON_PY3) $(SONIC_CONFIG_ENGINE_PY3) $(SONIC_PLATFORM_API_PY2) +$(SONIC_PLATFORM_API_PY3)_DEBS_DEPENDS = $(PYTHON3_SWSSCOMMON) SONIC_PYTHON_WHEELS += $(SONIC_PLATFORM_API_PY3) export mlnx_platform_api_py3_wheel_path="$(addprefix $(PYTHON_WHEELS_PATH)/,$(SONIC_PLATFORM_API_PY3))" diff --git a/platform/mellanox/mlnx-platform-api/sonic_platform/chassis.py b/platform/mellanox/mlnx-platform-api/sonic_platform/chassis.py index e13b90d6c0ca..17d66b2e8f64 100644 --- a/platform/mellanox/mlnx-platform-api/sonic_platform/chassis.py +++ b/platform/mellanox/mlnx-platform-api/sonic_platform/chassis.py @@ -31,10 +31,10 @@ from . import utils from .device_data import DeviceDataManager import re + import time except ImportError as e: raise ImportError (str(e) + "- required module not found") -MAX_SELECT_DELAY = 3600 RJ45_TYPE = "RJ45" @@ -387,26 +387,30 @@ def get_change_event(self, timeout=0): self.sfp_event.initialize() wait_for_ever = (timeout == 0) + # select timeout should be no more than 1000ms to ensure fast shutdown flow + select_timeout = 1000.0 if timeout >= 1000 else float(timeout) port_dict = {} error_dict = {} - if wait_for_ever: - timeout = MAX_SELECT_DELAY - while True: - status = self.sfp_event.check_sfp_status(port_dict, error_dict, timeout) - if bool(port_dict): + begin = time.time() + while True: + status = self.sfp_event.check_sfp_status(port_dict, error_dict, select_timeout) + if bool(port_dict): + break + + if not wait_for_ever: + elapse = time.time() - begin + if elapse * 1000 > timeout: break - else: - status = self.sfp_event.check_sfp_status(port_dict, error_dict, timeout) if status: if port_dict: self.reinit_sfps(port_dict) - result_dict = {'sfp':port_dict} + result_dict = {'sfp': port_dict} if error_dict: result_dict['sfp_error'] = error_dict return True, result_dict else: - return True, {'sfp':{}} + return True, {'sfp': {}} def reinit_sfps(self, port_dict): """ diff --git a/platform/mellanox/mlnx-platform-api/sonic_platform/eeprom.py b/platform/mellanox/mlnx-platform-api/sonic_platform/eeprom.py index 17f14b04430f..f5b13f0ae4a5 100644 --- a/platform/mellanox/mlnx-platform-api/sonic_platform/eeprom.py +++ b/platform/mellanox/mlnx-platform-api/sonic_platform/eeprom.py @@ -31,13 +31,13 @@ raise ImportError (str(e) + "- required module not found") from .device_data import DeviceDataManager -from .utils import default_return, is_host +from .utils import default_return, is_host, wait_until logger = Logger() # # this is mlnx-specific -# should this be moved to chass.py or here, which better? +# should this be moved to chassis.py or here, which better? # EEPROM_SYMLINK = "/var/run/hw-management/eeprom/vpd_info" platform_name = DeviceDataManager.get_platform_name() @@ -51,10 +51,12 @@ os.makedirs(os.path.dirname(EEPROM_SYMLINK)) subprocess.check_call(['/usr/bin/xxd', '-r', '-p', 'syseeprom.hex', EEPROM_SYMLINK], cwd=platform_path) +WAIT_EEPROM_READY_SEC = 10 + class Eeprom(eeprom_tlvinfo.TlvInfoDecoder): def __init__(self): - if not os.path.exists(EEPROM_SYMLINK): + if not wait_until(predict=os.path.exists, timeout=WAIT_EEPROM_READY_SEC, path=EEPROM_SYMLINK): logger.log_error("Nowhere to read syseeprom from! No symlink found") raise RuntimeError("No syseeprom symlink found") diff --git a/platform/mellanox/mlnx-platform-api/sonic_platform/psu.py b/platform/mellanox/mlnx-platform-api/sonic_platform/psu.py index 413eaee9bc5f..521183ca1f19 100644 --- a/platform/mellanox/mlnx-platform-api/sonic_platform/psu.py +++ b/platform/mellanox/mlnx-platform-api/sonic_platform/psu.py @@ -220,7 +220,7 @@ class Psu(FixedPsu): FAN_AMBIENT_TEMP = os.path.join(PSU_PATH, "thermal/fan_amb") AMBIENT_TEMP_CRITICAL_THRESHOLD = os.path.join(PSU_PATH, "config/amb_tmp_crit_limit") AMBIENT_TEMP_WARNING_THRESHOLD = os.path.join(PSU_PATH, "config/amb_tmp_warn_limit") - PSU_POWER_SLOPE = os.path.join(PSU_PATH, "config/psu_power_slope") + PSU_POWER_SLOPE = os.path.join(PSU_PATH, "config/psu{}_power_slope") shared_led = None @@ -245,6 +245,8 @@ def __init__(self, psu_index): self.psu_temp = os.path.join(PSU_PATH, 'thermal/psu{}_temp'.format(self.index)) self.psu_temp_threshold = os.path.join(PSU_PATH, 'thermal/psu{}_temp_max'.format(self.index)) + self.psu_power_slope = os.path.join(PSU_PATH, self.PSU_POWER_SLOPE.format(self.index)) + from .fan import PsuFan self._fan_list.append(PsuFan(psu_index, 1, self)) @@ -529,7 +531,7 @@ def _get_psu_power_threshold(self, temp_threshold_path): if ambient_temp < temp_threshold: power_threshold = power_max_capacity else: - slope = utils.read_int_from_file(Psu.PSU_POWER_SLOPE) + slope = utils.read_int_from_file(self.psu_power_slope) power_threshold = power_max_capacity - (ambient_temp - temp_threshold) * slope if power_threshold <= 0: logger.log_warning('Got negative PSU power threshold {} for {}'.format(power_threshold, self.get_name())) diff --git a/platform/mellanox/mlnx-platform-api/sonic_platform/sfp_event.py b/platform/mellanox/mlnx-platform-api/sonic_platform/sfp_event.py index eec88e1786df..c390e9a4d341 100644 --- a/platform/mellanox/mlnx-platform-api/sonic_platform/sfp_event.py +++ b/platform/mellanox/mlnx-platform-api/sonic_platform/sfp_event.py @@ -332,11 +332,9 @@ def on_pmpe(self, fd_p): pkt = new_uint8_t_arr(pkt_size) recv_info_p = new_sx_receive_info_t_p() pmpe_t = sx_event_pmpe_t() - port_attributes_list = new_sx_port_attributes_t_arr(64) port_cnt_p = new_uint32_t_p() - uint32_t_p_assign(port_cnt_p,64) + uint32_t_p_assign(port_cnt_p, 0) label_port_list = [] - label_port = None module_state = 0 rc = sx_lib_host_ifc_recv(fd_p, pkt, pkt_size_p, recv_info_p) @@ -352,31 +350,44 @@ def on_pmpe(self, fd_p): module_state = pmpe_t.module_state error_type = pmpe_t.error_type module_id = pmpe_t.module_id - slot_id = pmpe_t.slot_id # For non-modular chassis, it should return 0 + slot_id = pmpe_t.slot_id # For non-modular chassis, it should return 0 if module_state == SDK_SFP_STATE_ERR: logger.log_error("Receive PMPE error event on module {}: status {} error type {}".format(module_id, module_state, error_type)) elif module_state == SDK_SFP_STATE_DIS: - logger.log_info("Receive PMPE disable event on module {}: status {}".format(module_id, module_state)) + logger.log_notice("Receive PMPE disable event on module {}: status {}".format(module_id, module_state)) elif module_state == SDK_SFP_STATE_IN or module_state == SDK_SFP_STATE_OUT: - logger.log_info("Receive PMPE plug in/out event on module {}: status {}".format(module_id, module_state)) + logger.log_notice("Receive PMPE plug in/out event on module {}: status {}".format(module_id, module_state)) elif module_state == SDK_SFP_STATE_UNKNOWN: unknown = True else: logger.log_error("Receive PMPE unknown event on module {}: status {}".format(module_id, module_state)) - for i in range(port_list_size): - logical_port = sx_port_log_id_t_arr_getitem(logical_port_list, i) - rc = sx_api_port_device_get(self.handle, 1 , 0, port_attributes_list, port_cnt_p) + # Call sx_api_port_device_get with port_cnt_p=0, SDK will return the logical port number + rc = sx_api_port_device_get(self.handle, 1, 0, None, port_cnt_p) + if rc != SX_STATUS_SUCCESS: + logger.log_error("Failed to get logical port number") + status = False + else: port_cnt = uint32_t_p_value(port_cnt_p) - for i in range(port_cnt): - port_attributes = sx_port_attributes_t_arr_getitem(port_attributes_list,i) - if port_attributes.log_port == logical_port: - label_port = slot_id * DeviceDataManager.get_linecard_max_port_count() + port_attributes.port_mapping.module_port - break - - if label_port is not None: - label_port_list.append(label_port) + port_attributes_list = new_sx_port_attributes_t_arr(port_cnt) + rc = sx_api_port_device_get(self.handle, 1, 0, port_attributes_list, port_cnt_p) + if rc != SX_STATUS_SUCCESS: + logger.log_error("Failed to get logical port attributes") + status = False + else: + for i in range(port_list_size): + label_port = None + logical_port = sx_port_log_id_t_arr_getitem(logical_port_list, i) + for j in range(port_cnt): + port_attributes = sx_port_attributes_t_arr_getitem(port_attributes_list,j) + if port_attributes.log_port == logical_port: + label_port = slot_id * DeviceDataManager.get_linecard_max_port_count() + port_attributes.port_mapping.module_port + break + + if label_port is not None: + label_port_list.append(label_port) + delete_sx_port_attributes_t_arr(port_attributes_list) if unknown: SFP_ports_with_unknown_event = set(label_port_list) - self.RJ45_port_set @@ -389,7 +400,9 @@ def on_pmpe(self, fd_p): delete_uint32_t_p(pkt_size_p) delete_uint8_t_arr(pkt) delete_sx_receive_info_t_p(recv_info_p) - delete_sx_port_attributes_t_arr(port_attributes_list) delete_uint32_t_p(port_cnt_p) + if not label_port_list: + logger.log_error('Dropping PMPE event due to label port not found') + return status, label_port_list, module_state, error_type diff --git a/platform/mellanox/mlnx-platform-api/sonic_platform/utils.py b/platform/mellanox/mlnx-platform-api/sonic_platform/utils.py index 634078c9a077..83063b5c368e 100644 --- a/platform/mellanox/mlnx-platform-api/sonic_platform/utils.py +++ b/platform/mellanox/mlnx-platform-api/sonic_platform/utils.py @@ -19,6 +19,7 @@ import subprocess import json import sys +import time import os from sonic_py_common import device_info from sonic_py_common.logger import Logger @@ -266,3 +267,21 @@ def extract_RJ45_ports_index(): return RJ45_port_index_list if bool(RJ45_port_index_list) else None + +def wait_until(predict, timeout, interval=1, *args, **kwargs): + """Wait until a condition become true + + Args: + predict (object): a callable such as function, lambda + timeout (int): wait time in seconds + interval (int, optional): interval to check the predict. Defaults to 1. + + Returns: + _type_: _description_ + """ + while timeout > 0: + if predict(*args, **kwargs): + return True + time.sleep(interval) + timeout -= interval + return False diff --git a/platform/mellanox/mlnx-platform-api/tests/test_eeprom.py b/platform/mellanox/mlnx-platform-api/tests/test_eeprom.py index 5f0a30dbf519..b07f9327d098 100644 --- a/platform/mellanox/mlnx-platform-api/tests/test_eeprom.py +++ b/platform/mellanox/mlnx-platform-api/tests/test_eeprom.py @@ -49,6 +49,7 @@ def test_chassis_eeprom(self, mock_eeprom_info): assert chassis.get_serial() == 'MT2019X13878' assert chassis.get_system_eeprom_info() == mock_eeprom_info.return_value + @patch('sonic_platform.eeprom.wait_until', MagicMock(return_value=False)) def test_eeprom_init(self): # Test symlink not exist, there is an exception with pytest.raises(RuntimeError): @@ -83,7 +84,7 @@ def side_effect(key, field): @patch('os.path.exists', MagicMock(return_value=True)) @patch('os.path.islink', MagicMock(return_value=True)) - def test_get_system_eeprom_info_from_hardware(self): + def test_get_system_eeprom_info_from_hardware(self): eeprom = Eeprom() eeprom.p = os.path.join(test_path, 'mock_eeprom_data') eeprom._redis_hget = MagicMock() diff --git a/platform/mellanox/mlnx-platform-api/tests/test_psu.py b/platform/mellanox/mlnx-platform-api/tests/test_psu.py index 7fff0d548216..00c3bc8623a7 100644 --- a/platform/mellanox/mlnx-platform-api/tests/test_psu.py +++ b/platform/mellanox/mlnx-platform-api/tests/test_psu.py @@ -172,7 +172,7 @@ def test_psu_power_threshold(self, mock_read_int_from_file): psu.psu_power_max_capacity: 100000000, psu.AMBIENT_TEMP_CRITICAL_THRESHOLD: 65000, psu.AMBIENT_TEMP_WARNING_THRESHOLD: 55000, - psu.PSU_POWER_SLOPE: 2000 + psu.psu_power_slope: 2000 } normal_data = { psu.PORT_AMBIENT_TEMP: 55000, diff --git a/platform/mellanox/mlnx-platform-api/tests/test_utils.py b/platform/mellanox/mlnx-platform-api/tests/test_utils.py index c4c8d0c000a9..5e01fc70dc0e 100644 --- a/platform/mellanox/mlnx-platform-api/tests/test_utils.py +++ b/platform/mellanox/mlnx-platform-api/tests/test_utils.py @@ -18,6 +18,8 @@ import os import pytest import sys +import threading +import time if sys.version_info.major == 3: from unittest import mock else: @@ -125,3 +127,17 @@ def test_run_command(self): def test_extract_RJ45_ports_index(self): rj45_list = utils.extract_RJ45_ports_index() assert rj45_list is None + + def test_wait_until(self): + values = [] + assert utils.wait_until(lambda: len(values) == 0, timeout=1) + assert not utils.wait_until(lambda: len(values) > 0, timeout=1) + + def thread_func(items): + time.sleep(3) + items.append(0) + + t = threading.Thread(target=thread_func, args=(values, )) + t.start() + assert utils.wait_until(lambda: len(values) > 0, timeout=5) + t.join() diff --git a/platform/mellanox/non-upstream-patches/patches.tar.gz b/platform/mellanox/non-upstream-patches/patches.tar.gz new file mode 100644 index 000000000000..ea77e556ed0d Binary files /dev/null and b/platform/mellanox/non-upstream-patches/patches.tar.gz differ diff --git a/rules/config b/rules/config index 11bb1450e72b..a17cccb3b585 100644 --- a/rules/config +++ b/rules/config @@ -39,6 +39,9 @@ DEFAULT_BUILD_LOG_TIMESTAMP = none # Comment next line to disable: # SONIC_CONFIG_ENABLE_COLORS = y +# CHANGE_DEFAULT_PASSWORD - enforce default user/users to change password on 1st login +CHANGE_DEFAULT_PASSWORD ?= n + # DEFAULT_USERNAME - default username for installer build DEFAULT_USERNAME = admin diff --git a/scripts/build_mirror_config.sh b/scripts/build_mirror_config.sh index a1e5900a48b8..aee56f23ae6a 100755 --- a/scripts/build_mirror_config.sh +++ b/scripts/build_mirror_config.sh @@ -6,7 +6,8 @@ export ARCHITECTURE=$2 export DISTRIBUTION=$3 DEFAULT_MIRROR_URL_PREFIX=http://packages.trafficmanager.net -MIRROR_VERSION_FILE=files/build/versions/default/versions-mirror +MIRROR_VERSION_FILE= +[[ "$SONIC_VERSION_CONTROL_COMPONENTS" == *deb* || $SONIC_VERSION_CONTROL_COMPONENTS == *all* ]] && MIRROR_VERSION_FILE=files/build/versions/default/versions-mirror [ -f target/versions/default/versions-mirror ] && MIRROR_VERSION_FILE=target/versions/default/versions-mirror # The default mirror urls @@ -21,7 +22,7 @@ if [ "$ARCHITECTURE" == "armhf" ]; then fi if [ "$MIRROR_SNAPSHOT" == y ]; then - if [ -f $MIRROR_VERSION_FILE ]; then + if [ -f "$MIRROR_VERSION_FILE" ]; then DEBIAN_TIMESTAMP=$(grep "^debian==" $MIRROR_VERSION_FILE | tail -n 1 | sed 's/.*==//') DEBIAN_SECURITY_TIMESTAMP=$(grep "^debian-security==" $MIRROR_VERSION_FILE | tail -n 1 | sed 's/.*==//') elif [ -z "$DEBIAN_TIMESTAMP" ] || [ -z "$DEBIAN_SECURITY_TIMESTAMP" ]; then diff --git a/scripts/populate_file_web_server.py b/scripts/populate_file_web_server.py new file mode 100644 index 000000000000..955ad9c8a7f9 --- /dev/null +++ b/scripts/populate_file_web_server.py @@ -0,0 +1,295 @@ +#!/usr/bin/env python3 + +import sys +import os +import time +import argparse +from http import HTTPStatus +try: + import requests +except ImportError: + print("requests module is not installed. script will fail to execute") + +#debug print level +PRINT_LEVEL_ERROR = "err" +PRINT_LEVEL_WARN = "warn" +PRINT_LEVEL_INFO = "info" +PRINT_LEVEL_VERBOSE = "verbose" + +PRINT_LEVEL_LUT = {PRINT_LEVEL_ERROR : 1, + PRINT_LEVEL_WARN : 2, + PRINT_LEVEL_INFO : 3, + PRINT_LEVEL_VERBOSE : 4 } + +#return code +RET_CODE_SUCCESS = 0 +RET_CODE_CANNOT_CREATE_FILE = -1 +RET_CODE_CANNOT_OPEN_FILE = -2 +RET_CODE_HTTP_SERVER_ERROR = -3 +RET_CODE_CANNOT_WRITE_FILE = -4 + +#constants +RESOURCES_FILE_NAME = 'versions-web' +EXCLUDE_DIRECTORES = ['fsroot', 'target'] +HASH_SEPARATOR = '-' +DEFAULT_INVALID_INPUT = 'none' + +# global variables +g_current_print_level = PRINT_LEVEL_INFO + +#Script debug features (disabled by default) +g_delete_resources_in_cache = True + + +# global Classes +class Resource: + def __init__(self, line, file): + self.file = file + temp=line.split("==") + assert(2==len(temp)) + self.url=temp[0].strip() + self.hash=temp[1].strip() + temp=self.url.split("/") + assert(len(temp)>0) + self.name=temp[len(temp)-1] + #handle special scenarios + if 0 != self.name.count('?') == True: + temp = self.name.split("?") + self.name = temp[0] + + def get_unique_name(self): + return self.name + HASH_SEPARATOR + self.hash + + def get_url(self): + return self.url + + def __str__(self): + ret_val = "Resource name: " + self.name + "\n" + ret_val += "File: " + self.file + "\n" + ret_val += "Hash: " + self.hash + "\n" + ret_val += "Full URL: " + self.url + return ret_val + +# Helper functions + +def print_msg(print_level, msg, print_in_place=False): + if PRINT_LEVEL_LUT[g_current_print_level] >= PRINT_LEVEL_LUT[print_level]: + if True == print_in_place: + print(msg, end='\r') + else: + print(msg) + +def create_dir_if_not_exist(dir): + if not os.path.exists(dir): + try: + os.makedirs(dir) + except: + print_msg(PRINT_LEVEL_WARN, "Cannot create directory " + dir) + +def delete_file_if_exist(file): + if os.path.exists(file): + try: + os.remove(file) + except: + print_msg(PRINT_LEVEL_WARN, "Cannot delete " + file) + +# Logic functions + +def generate_output_file(resources, dest_url_valid, dest_url, output_file_name): + try: + with open(output_file_name, 'w') as f: + for unique_name in resources.keys(): + resource = resources[unique_name] + if True == dest_url_valid: + line = dest_url + else: + line = resource.get_url() + if line[-1] != '/': + line += '/' + line += resource.name + "==" + resource.hash + f.write(line + '\n') + except: + print_msg(PRINT_LEVEL_WARN, output_file_name + " cannot be created") + return RET_CODE_CANNOT_CREATE_FILE + + return RET_CODE_SUCCESS + +def upload_resource_to_server(resource_path, resource_name, user, key, server_url): + url_full_path = server_url + "/" + resource_name + + try: + f = open(resource_path, 'rb') + except: + err_print("Cannot open " + resource_path) + return RET_CODE_CANNOT_OPEN_FILE + + headers = {'Content-type': 'application', 'Slug': resource_name} + response = requests.put(url_full_path, data=f, + headers=headers, auth=(user, key)) + + f.close() + + if response.status_code != HTTPStatus.CREATED.value: + err_print(f"HTTP request returned status code {response.status_code}, expected {HTTPStatus.CREATED.value}") + return RET_CODE_HTTP_SERVER_ERROR + + # JSON response empty only when status code is 204 + reported_md5 = response.json().get('checksums', {}).get('md5') + file_md5 = resource_name.split(HASH_SEPARATOR)[-1] + + # Check if server reports checksum, if so compare reported sum and the one + # specified in filename + if reported_md5 != None and reported_md5 != file_md5: + print_msg(PRINT_LEVEL_WARN, f"Server reported file's chsum {reported_md5}, expected {file_md5}") + + + return RET_CODE_SUCCESS + +def download_external_resouce(resource, cache_path): + resource_path_in_cache = cache_path + os.sep + resource.get_unique_name() + + r = requests.get(resource.get_url(), allow_redirects=True) + + try: + f = open(resource_path_in_cache, 'wb') + f.write(r.content) + f.close() + except: + print_msg(PRINT_LEVEL_ERROR, "Cannot write " + resource_path_in_cache + " to cache") + resource_path_in_cache = "" #report error + + return resource_path_in_cache + +def get_resources_list(resource_files_list): + resource_list = list() + + for file_name in resource_files_list: + try: + with open(file_name, 'r') as f: + for line in f: + resource_list.append(Resource(line, file_name)) + except: + print_msg(PRINT_LEVEL_WARN, file_name + " cannot be opened") + + return resource_list + +def filter_out_dir(subdir): + ret_val = False + + for exclude in EXCLUDE_DIRECTORES: + if exclude in subdir.split(os.sep): + ret_val = True + break + + return ret_val + +def get_resource_files_list(serach_path): + resource_files_list = list() + + for subdir, dirs, files in os.walk(serach_path): + for file in files: + if False == filter_out_dir(subdir) and RESOURCES_FILE_NAME == file: + file_full_path = os.path.join(subdir, file) + print_msg(PRINT_LEVEL_VERBOSE, "Found resource file :" + file_full_path) + resource_files_list.append(file_full_path) + + return resource_files_list + +def parse_args(): + parser = argparse.ArgumentParser(description='Various pre-steps for build compilation') + + parser.add_argument('-s', '--source', default=".", + help='Search path for ' + RESOURCES_FILE_NAME + ' files') + + parser.add_argument('-c', '--cache', default="." + os.sep + "tmp", + help='Path to cache for storing content before uploading to server') + + parser.add_argument('-p', '--print', default=PRINT_LEVEL_INFO, + choices=[PRINT_LEVEL_ERROR, PRINT_LEVEL_WARN, PRINT_LEVEL_INFO, PRINT_LEVEL_VERBOSE], + help='Print level verbosity') + + parser.add_argument('-o', '--output', default=DEFAULT_INVALID_INPUT, + help='Output file name to hold the list of packages') + + parser.add_argument('-u', '--user', default=DEFAULT_INVALID_INPUT, + help='User for server authentication') + + parser.add_argument('-k', '--key', default=DEFAULT_INVALID_INPUT, + help='API key server authentication') + + parser.add_argument('-d', '--dest', default=DEFAULT_INVALID_INPUT, + help='URL for destination web file server') + + return parser.parse_args() + +def main(): + global g_current_print_level + ret_val = RET_CODE_SUCCESS + resource_counter = 0.0 + resource_dict = dict() + + args = parse_args() + + g_current_print_level = args.print + + resource_files_list = get_resource_files_list(args.source) + + resource_list = get_resources_list(resource_files_list) + + #remove duplications + for resource in resource_list: + unique_name = resource.get_unique_name() + if not unique_name in resource_dict.keys(): + resource_dict[unique_name] = resource + + print_msg(PRINT_LEVEL_INFO, "Found " + str(len(resource_files_list)) + " version files and " + str(len(resource_dict.keys())) + " unique resources") + + if args.dest != DEFAULT_INVALID_INPUT: + upload_files_to_server = True + print_msg(PRINT_LEVEL_INFO, "Upload files to URL - " + args.dest) + else: + upload_files_to_server = False + print_msg(PRINT_LEVEL_INFO, "Skipping files upload to server") + + #create cache directory if not exist + create_dir_if_not_exist(args.cache) + + #download content to cache and then upload to web server + for unique_name in resource_dict.keys(): + + resource = resource_dict[unique_name] + + print_msg(PRINT_LEVEL_VERBOSE, resource) + + resource_counter += 1.0 + + #download content to cache + file_in_cache = download_external_resouce(resource, args.cache) + + if "" == file_in_cache: + return RET_CODE_CANNOT_WRITE_FILE + + if True == upload_files_to_server: + #upload content to web server + ret_val = upload_resource_to_server(file_in_cache, unique_name, args.user, args.key, args.dest) + if ret_val != RET_CODE_SUCCESS: + return ret_val + + if True == g_delete_resources_in_cache: + delete_file_if_exist(file_in_cache) + + print_msg(PRINT_LEVEL_INFO, "Downloading Data. Progress " + str(int(100.0*resource_counter/len(resource_dict.keys()))) + "%", True) #print progress bar + + # generate version output file as needed + if args.output != DEFAULT_INVALID_INPUT: + ret_val = generate_output_file(resource_dict, upload_files_to_server, args.dest, args.output) + print_msg(PRINT_LEVEL_INFO, "Generate output file " + args.output) + + return ret_val + +# Entry function +if __name__ == '__main__': + + ret_val = main() + + sys.exit(ret_val) diff --git a/slave.mk b/slave.mk index 0cabc8e437b3..191808f68a7a 100644 --- a/slave.mk +++ b/slave.mk @@ -388,6 +388,7 @@ $(info "USE_NATIVE_DOCKERD_FOR_BUILD" : "$(SONIC_CONFIG_USE_NATIVE_DOCKERD_FO $(info "SONIC_USE_DOCKER_BUILDKIT" : "$(SONIC_USE_DOCKER_BUILDKIT)") $(info "USERNAME" : "$(USERNAME)") $(info "PASSWORD" : "$(PASSWORD)") +$(info "CHANGE_DEFAULT_PASSWORD" : "$(CHANGE_DEFAULT_PASSWORD)") $(info "ENABLE_DHCP_GRAPH_SERVICE" : "$(ENABLE_DHCP_GRAPH_SERVICE)") $(info "SHUTDOWN_BGP_ON_START" : "$(SHUTDOWN_BGP_ON_START)") $(info "ENABLE_PFCWD_ON_START" : "$(ENABLE_PFCWD_ON_START)") @@ -1449,6 +1450,7 @@ $(addprefix $(TARGET_PATH)/, $(SONIC_INSTALLERS)) : $(TARGET_PATH)/% : \ DEBUG_SRC_ARCHIVE_FILE="$(DBG_SRC_ARCHIVE_FILE)" \ USERNAME="$(USERNAME)" \ PASSWORD="$(PASSWORD)" \ + CHANGE_DEFAULT_PASSWORD="$(CHANGE_DEFAULT_PASSWORD)" \ TARGET_MACHINE=$(dep_machine) \ IMAGE_TYPE=$($*_IMAGE_TYPE) \ TARGET_PATH=$(TARGET_PATH) \ diff --git a/src/sonic-build-hooks/scripts/buildinfo_base.sh b/src/sonic-build-hooks/scripts/buildinfo_base.sh index 1e334a4a62da..a04dbc150df5 100755 --- a/src/sonic-build-hooks/scripts/buildinfo_base.sh +++ b/src/sonic-build-hooks/scripts/buildinfo_base.sh @@ -28,8 +28,7 @@ else PKG_CACHE_PATH=/sonic/target/vcache/${IMAGENAME} fi PKG_CACHE_FILE_NAME=${PKG_CACHE_PATH}/cache.tgz -$SUDO mkdir -p ${PKG_CACHE_PATH} -$SUDO chown $USER $PKG_CACHE_PATH +mkdir -p ${PKG_CACHE_PATH} . ${BUILDINFO_PATH}/scripts/utils.sh @@ -112,7 +111,7 @@ get_version_cache_option() set_reproducible_mirrors() { # Remove the charater # in front of the line if matched - local expression="s/^#\(.*$REPR_MIRROR_URL_PATTERN\)/\1/" + local expression="s/^#\s*\(.*$REPR_MIRROR_URL_PATTERN\)/\1/" # Add the character # in front of the line, if not match the URL pattern condition local expression2="/^#*deb.*$REPR_MIRROR_URL_PATTERN/! s/^#*deb/#&/" local expression3="\$a#SET_REPR_MIRRORS" @@ -120,7 +119,7 @@ set_reproducible_mirrors() # Add the charater # in front of the line if match expression="s/^deb.*$REPR_MIRROR_URL_PATTERN/#\0/" # Remove the character # in front of the line, if not match the URL pattern condition - expression2="/^#*deb.*$REPR_MIRROR_URL_PATTERN/! s/^#(#*deb)/\1/" + expression2="/^#*deb.*$REPR_MIRROR_URL_PATTERN/! s/^#\s*(#*deb)/\1/" expression3="/#SET_REPR_MIRRORS/d" fi diff --git a/src/sonic-build-hooks/scripts/post_run_cleanup b/src/sonic-build-hooks/scripts/post_run_cleanup index 5e4ec23aec79..8fcc43c57e8d 100755 --- a/src/sonic-build-hooks/scripts/post_run_cleanup +++ b/src/sonic-build-hooks/scripts/post_run_cleanup @@ -38,3 +38,4 @@ set_reproducible_mirrors -d # Remove the version deb preference rm -f $VERSION_DEB_PREFERENCE +rm -f /etc/apt/preferences.d/01-versions-deb diff --git a/src/sonic-config-engine/minigraph.py b/src/sonic-config-engine/minigraph.py index cdbefb5fed6c..82762649a362 100644 --- a/src/sonic-config-engine/minigraph.py +++ b/src/sonic-config-engine/minigraph.py @@ -533,9 +533,9 @@ def parse_dpg(dpg, hname): intfs_inpc.append(pcmbr_list[i]) pc_members[(pcintfname, pcmbr_list[i])] = {} if pcintf.find(str(QName(ns, "Fallback"))) != None: - pcs[pcintfname] = {'members': pcmbr_list, 'fallback': pcintf.find(str(QName(ns, "Fallback"))).text, 'min_links': str(int(math.ceil(len() * 0.75))), 'lacp_key': 'auto'} + pcs[pcintfname] = {'fallback': pcintf.find(str(QName(ns, "Fallback"))).text, 'min_links': str(int(math.ceil(len() * 0.75))), 'lacp_key': 'auto'} else: - pcs[pcintfname] = {'members': pcmbr_list, 'min_links': str(int(math.ceil(len(pcmbr_list) * 0.75))), 'lacp_key': 'auto' } + pcs[pcintfname] = {'min_links': str(int(math.ceil(len(pcmbr_list) * 0.75))), 'lacp_key': 'auto' } port_nhipv4_map = {} port_nhipv6_map = {} nhg_int = "" @@ -1246,7 +1246,7 @@ def filter_acl_table_for_backend(acls, vlan_members): } return filter_acls -def filter_acl_table_bindings(acls, neighbors, port_channels, sub_role, device_type, is_storage_device, vlan_members): +def filter_acl_table_bindings(acls, neighbors, port_channels, pc_members, sub_role, device_type, is_storage_device, vlan_members): if device_type == 'BackEndToRRouter' and is_storage_device: return filter_acl_table_for_backend(acls, vlan_members) @@ -1265,8 +1265,8 @@ def filter_acl_table_bindings(acls, neighbors, port_channels, sub_role, device_t # Get the front panel port channel. for port_channel_intf in port_channels: - backend_port_channel = any(lag_member in backplane_port_list \ - for lag_member in port_channels[port_channel_intf]['members']) + backend_port_channel = any(lag_member[1] in backplane_port_list \ + for lag_member in list(pc_members.keys()) if lag_member[0] == port_channel_intf) if not backend_port_channel: front_port_channel_intf.append(port_channel_intf) @@ -1668,6 +1668,20 @@ def parse_xml(filename, platform=None, port_config_file=None, asic_name=None, hw if port_name in mgmt_alias_reverse_mapping.keys(): continue + port_default_speed = port_speeds_default.get(port_name, None) + port_png_speed = port_speed_png[port_name] + + if switch_type == 'voq': + # when the port speed is changes from 400g to 100g + # update the port lanes, use the first 4 lanes of the 400G port to support 100G port + if port_default_speed == '400000' and port_png_speed == '100000': + port_lanes = ports[port_name].get('lanes', '').split(',') + # check if the 400g port has only 8 lanes + if len(port_lanes) != 8: + continue + updated_lanes = ",".join(port_lanes[:4]) + ports[port_name]['lanes'] = updated_lanes + ports.setdefault(port_name, {})['speed'] = port_speed_png[port_name] for port_name, port in list(ports.items()): @@ -1751,23 +1765,29 @@ def parse_xml(filename, platform=None, port_config_file=None, asic_name=None, hw if inband_port in ports.keys(): ports[inband_port]['admin_status'] = 'up' - # bring up the recirc port for voq chassis + # bring up the recirc port for voq chassis, Set it as routed interface for port, port_attributes in ports.items(): port_role = port_attributes.get('role', None) if port_role == 'Rec': ports[port]['admin_status'] = 'up' + #Add the Recirc ports to the INTERFACES table to make it routed intf + results['INTERFACE'].update({port : {}}) + results['PORT'] = ports results['CONSOLE_PORT'] = console_ports if port_config_file: port_set = set(ports.keys()) - for (pc_name, mbr_map) in list(pcs.items()): + for (pc_name, pc_member) in list(pc_members.keys()): # remove portchannels that contain ports not existing in port_config.ini # when port_config.ini exists - if not set(mbr_map['members']).issubset(port_set): - print("Warning: ignore '%s' as part of its member interfaces is not in the port_config.ini" % pc_name, file=sys.stderr) + if (pc_name, pc_member) in pc_members and pc_member not in port_set: + print("Warning: ignore '%s' as at least one of its member interfaces ('%s') is not in the port_config.ini" % (pc_name, pc_member), file=sys.stderr) del pcs[pc_name] + pc_mbr_del_keys = [f for f in list(pc_members.keys()) if f[0] == pc_name] + for pc_mbr_del_key in pc_mbr_del_keys: + del pc_members[pc_mbr_del_key] # set default port channel MTU as 9100 and admin status up and default TPID 0x8100 for pc in pcs.values(): @@ -1871,7 +1891,7 @@ def parse_xml(filename, platform=None, port_config_file=None, asic_name=None, hw results['DHCP_RELAY'] = dhcp_relay_table results['NTP_SERVER'] = dict((item, {}) for item in ntp_servers) results['TACPLUS_SERVER'] = dict((item, {'priority': '1', 'tcp_port': '49'}) for item in tacacs_servers) - results['ACL_TABLE'] = filter_acl_table_bindings(acls, neighbors, pcs, sub_role, current_device['type'], is_storage_device, vlan_members) + results['ACL_TABLE'] = filter_acl_table_bindings(acls, neighbors, pcs, pc_members, sub_role, current_device['type'], is_storage_device, vlan_members) results['FEATURE'] = { 'telemetry': { 'state': 'enabled' diff --git a/src/sonic-config-engine/tests/multi_npu_data/buffers.json.j2 b/src/sonic-config-engine/tests/multi_npu_data/buffers.json.j2 new file mode 100644 index 000000000000..d99bc2021569 --- /dev/null +++ b/src/sonic-config-engine/tests/multi_npu_data/buffers.json.j2 @@ -0,0 +1,3 @@ +{%- set default_topo = 't2' %} +{%- include 'buffers_config.j2' %} + diff --git a/src/sonic-config-engine/tests/multi_npu_data/buffers_defaults_t2.j2 b/src/sonic-config-engine/tests/multi_npu_data/buffers_defaults_t2.j2 new file mode 100644 index 000000000000..d726aafb27af --- /dev/null +++ b/src/sonic-config-engine/tests/multi_npu_data/buffers_defaults_t2.j2 @@ -0,0 +1,43 @@ +{%- set default_cable = '300m' %} + +{%- set ports2cable = { + 'internal' : '1m' + } +-%} + +{%- macro generate_buffer_pool_and_profiles() %} + "BUFFER_POOL": { + "ingress_lossless_pool": { + "size": "12766208", + "type": "ingress", + "mode": "dynamic" + }, + "egress_lossless_pool": { + "size": "12766208", + "type": "egress", + "mode": "static" + }, + "egress_lossy_pool": { + "size": "7326924", + "type": "egress", + "mode": "dynamic" + } + }, + "BUFFER_PROFILE": { + "ingress_lossy_profile": { + "pool":"ingress_lossless_pool", + "size":"0", + "dynamic_th":"3" + }, + "egress_lossless_profile": { + "pool":"egress_lossless_pool", + "size":"0", + "static_th":"12766208" + }, + "egress_lossy_profile": { + "pool":"egress_lossy_pool", + "size":"1518", + "dynamic_th":"3" + } + }, +{%- endmacro %} diff --git a/src/sonic-config-engine/tests/sample-chassis-packet-lc-port-config.ini b/src/sonic-config-engine/tests/sample-chassis-packet-lc-port-config.ini index 52cb3360a504..296dd8a786ce 100644 --- a/src/sonic-config-engine/tests/sample-chassis-packet-lc-port-config.ini +++ b/src/sonic-config-engine/tests/sample-chassis-packet-lc-port-config.ini @@ -23,38 +23,38 @@ Ethernet43 12,13,14,15 Eth1/1/43 43 100000 Eth43-ASIC1 Ext Ethernet44 8,9,10,11 Eth1/1/44 44 100000 Eth44-ASIC1 Ext Ethernet46 4,5,6,7 Eth1/1/46 46 100000 Eth46-ASIC1 Ext Ethernet47 0,1,2,3 Eth1/1/47 47 100000 Eth47-ASIC1 Ext -Ethernet2320 16,17 Eth2320-ASIC1 2320 100000 Eth2320-ASIC1 Int -Ethernet2452 2052,2053 Eth2452-ASIC1 2452 100000 Eth2452-ASIC1 Int -Ethernet2454 2054,2055 Eth2454-ASIC1 2454 100000 Eth2454-ASIC1 Int -Ethernet2456 2056,2057 Eth2456-ASIC1 2456 100000 Eth2456-ASIC1 Int -Ethernet2458 2058,2059 Eth2458-ASIC1 2458 100000 Eth2458-ASIC1 Int -Ethernet2460 2060,2061 Eth2460-ASIC1 2460 100000 Eth2460-ASIC1 Int -Ethernet2462 2062,2063 Eth2462-ASIC1 2462 100000 Eth2462-ASIC1 Int -Ethernet2464 2064,2065 Eth2464-ASIC1 2464 100000 Eth2464-ASIC1 Int -Ethernet2466 2304,2305 Eth2466-ASIC1 2466 100000 Eth2466-ASIC1 Int -Ethernet2468 2306,2307 Eth2468-ASIC1 2468 100000 Eth2468-ASIC1 Int -Ethernet2470 2308,2309 Eth2470-ASIC1 2470 100000 Eth2470-ASIC1 Int -Ethernet2472 2310,2311 Eth2472-ASIC1 2472 100000 Eth2472-ASIC1 Int -Ethernet2474 2312,2313 Eth2474-ASIC1 2474 100000 Eth2474-ASIC1 Int -Ethernet2476 2314,2315 Eth2476-ASIC1 2476 100000 Eth2476-ASIC1 Int -Ethernet2478 2316,2317 Eth2478-ASIC1 2478 100000 Eth2478-ASIC1 Int -Ethernet2480 2318,2319 Eth2480-ASIC1 2480 100000 Eth2480-ASIC1 Int -Ethernet2482 2320,2321 Eth2482-ASIC1 2482 100000 Eth2482-ASIC1 Int -Ethernet2484 2560,2561 Eth2484-ASIC1 2484 100000 Eth2484-ASIC1 Int -Ethernet2486 2562,2563 Eth2486-ASIC1 2486 100000 Eth2486-ASIC1 Int -Ethernet2488 2564,2565 Eth2488-ASIC1 2488 100000 Eth2488-ASIC1 Int -Ethernet2490 2566,2567 Eth2490-ASIC1 2490 100000 Eth2490-ASIC1 Int -Ethernet2492 2568,2569 Eth2492-ASIC1 2492 100000 Eth2492-ASIC1 Int -Ethernet2494 2570,2571 Eth2494-ASIC1 2494 100000 Eth2494-ASIC1 Int -Ethernet2496 2572,2573 Eth2496-ASIC1 2496 100000 Eth2496-ASIC1 Int -Ethernet2498 2574,2575 Eth2498-ASIC1 2498 100000 Eth2498-ASIC1 Int -Ethernet2500 2576,2577 Eth2500-ASIC1 2500 100000 Eth2500-ASIC1 Int -Ethernet2502 2816,2817 Eth2502-ASIC1 2502 100000 Eth2502-ASIC1 Int -Ethernet2504 2818,2819 Eth2504-ASIC1 2504 100000 Eth2504-ASIC1 Int -Ethernet2506 2820,2821 Eth2506-ASIC1 2506 100000 Eth2506-ASIC1 Int -Ethernet2508 2822,2823 Eth2508-ASIC1 2508 100000 Eth2508-ASIC1 Int -Ethernet2510 2824,2825 Eth2510-ASIC1 2510 100000 Eth2510-ASIC1 Int -Ethernet2512 2826,2827 Eth2512-ASIC1 2512 100000 Eth2512-ASIC1 Int -Ethernet2514 2828,2829 Eth2514-ASIC1 2514 100000 Eth2514-ASIC1 Int -Ethernet2516 2830,2831 Eth2516-ASIC1 2516 100000 Eth2516-ASIC1 Int -Ethernet2518 2832,2833 Eth2518-ASIC1 2518 100000 Eth2518-ASIC1 Int +Ethernet-BP2320 16,17 Eth2320-ASIC1 2320 100000 Eth2320-ASIC1 Int +Ethernet-BP2452 2052,2053 Eth2452-ASIC1 2452 100000 Eth2452-ASIC1 Int +Ethernet-BP2454 2054,2055 Eth2454-ASIC1 2454 100000 Eth2454-ASIC1 Int +Ethernet-BP2456 2056,2057 Eth2456-ASIC1 2456 100000 Eth2456-ASIC1 Int +Ethernet-BP2458 2058,2059 Eth2458-ASIC1 2458 100000 Eth2458-ASIC1 Int +Ethernet-BP2460 2060,2061 Eth2460-ASIC1 2460 100000 Eth2460-ASIC1 Int +Ethernet-BP2462 2062,2063 Eth2462-ASIC1 2462 100000 Eth2462-ASIC1 Int +Ethernet-BP2464 2064,2065 Eth2464-ASIC1 2464 100000 Eth2464-ASIC1 Int +Ethernet-BP2466 2304,2305 Eth2466-ASIC1 2466 100000 Eth2466-ASIC1 Int +Ethernet-BP2468 2306,2307 Eth2468-ASIC1 2468 100000 Eth2468-ASIC1 Int +Ethernet-BP2470 2308,2309 Eth2470-ASIC1 2470 100000 Eth2470-ASIC1 Int +Ethernet-BP2472 2310,2311 Eth2472-ASIC1 2472 100000 Eth2472-ASIC1 Int +Ethernet-BP2474 2312,2313 Eth2474-ASIC1 2474 100000 Eth2474-ASIC1 Int +Ethernet-BP2476 2314,2315 Eth2476-ASIC1 2476 100000 Eth2476-ASIC1 Int +Ethernet-BP2478 2316,2317 Eth2478-ASIC1 2478 100000 Eth2478-ASIC1 Int +Ethernet-BP2480 2318,2319 Eth2480-ASIC1 2480 100000 Eth2480-ASIC1 Int +Ethernet-BP2482 2320,2321 Eth2482-ASIC1 2482 100000 Eth2482-ASIC1 Int +Ethernet-BP2484 2560,2561 Eth2484-ASIC1 2484 100000 Eth2484-ASIC1 Int +Ethernet-BP2486 2562,2563 Eth2486-ASIC1 2486 100000 Eth2486-ASIC1 Int +Ethernet-BP2488 2564,2565 Eth2488-ASIC1 2488 100000 Eth2488-ASIC1 Int +Ethernet-BP2490 2566,2567 Eth2490-ASIC1 2490 100000 Eth2490-ASIC1 Int +Ethernet-BP2492 2568,2569 Eth2492-ASIC1 2492 100000 Eth2492-ASIC1 Int +Ethernet-BP2494 2570,2571 Eth2494-ASIC1 2494 100000 Eth2494-ASIC1 Int +Ethernet-BP2496 2572,2573 Eth2496-ASIC1 2496 100000 Eth2496-ASIC1 Int +Ethernet-BP2498 2574,2575 Eth2498-ASIC1 2498 100000 Eth2498-ASIC1 Int +Ethernet-BP2500 2576,2577 Eth2500-ASIC1 2500 100000 Eth2500-ASIC1 Int +Ethernet-BP2502 2816,2817 Eth2502-ASIC1 2502 100000 Eth2502-ASIC1 Int +Ethernet-BP2504 2818,2819 Eth2504-ASIC1 2504 100000 Eth2504-ASIC1 Int +Ethernet-BP2506 2820,2821 Eth2506-ASIC1 2506 100000 Eth2506-ASIC1 Int +Ethernet-BP2508 2822,2823 Eth2508-ASIC1 2508 100000 Eth2508-ASIC1 Int +Ethernet-BP2510 2824,2825 Eth2510-ASIC1 2510 100000 Eth2510-ASIC1 Int +Ethernet-BP2512 2826,2827 Eth2512-ASIC1 2512 100000 Eth2512-ASIC1 Int +Ethernet-BP2514 2828,2829 Eth2514-ASIC1 2514 100000 Eth2514-ASIC1 Int +Ethernet-BP2516 2830,2831 Eth2516-ASIC1 2516 100000 Eth2516-ASIC1 Int +Ethernet-BP2518 2832,2833 Eth2518-ASIC1 2518 100000 Eth2518-ASIC1 Int diff --git a/src/sonic-config-engine/tests/test_cfggen.py b/src/sonic-config-engine/tests/test_cfggen.py index 88b5043a6bff..230343e90f5d 100644 --- a/src/sonic-config-engine/tests/test_cfggen.py +++ b/src/sonic-config-engine/tests/test_cfggen.py @@ -40,6 +40,8 @@ def setUp(self): self.maxDiff = None self.macsec_profile = os.path.join(self.test_dir, 'macsec_profile.json') self.sample_backend_graph = os.path.join(self.test_dir, 'sample-graph-storage-backend.xml') + self.voq_port_config_400g = os.path.join(self.test_dir, 'voq-sample-400g-port-config.ini') + self.voq_sample_masic_graph = os.path.join(self.test_dir, 'voq-sample-masic-graph.xml') # To ensure that mock config_db data is used for unit-test cases os.environ["CFGGEN_UNIT_TESTING"] = "2" @@ -329,7 +331,7 @@ def test_minigraph_portchannels(self, **kwargs): output = self.run_script(argument) self.assertEqual( utils.to_dict(output.strip()), - utils.to_dict("{'PortChannel1': {'admin_status': 'up', 'min_links': '1', 'members': ['Ethernet4'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}") + utils.to_dict("{'PortChannel1': {'admin_status': 'up', 'min_links': '1', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}") ) def test_minigraph_portchannel_with_more_member(self): @@ -337,7 +339,7 @@ def test_minigraph_portchannel_with_more_member(self): output = self.run_script(argument) self.assertEqual( utils.to_dict(output.strip()), - utils.to_dict("{'PortChannel01': {'admin_status': 'up', 'min_links': '3', 'members': ['Ethernet112', 'Ethernet116', 'Ethernet120', 'Ethernet124'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}")) + utils.to_dict("{'PortChannel01': {'admin_status': 'up', 'min_links': '3', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}")) def test_minigraph_portchannel_members(self): argument = ['-m', self.sample_graph_pc_test, '-p', self.port_config, '-v', "PORTCHANNEL_MEMBER.keys()|list"] @@ -960,6 +962,14 @@ def test_minigraph_voq_recirc_ports(self): "admin_status": "up" }) + argument = ["-j", self.macsec_profile, "-m", self.sample_graph_voq, "-p", self.voq_port_config, "--var-json", "INTERFACE"] + output = self.run_script(argument) + output_dict = utils.to_dict(output.strip()) + self.assertDictEqual( + output_dict['Ethernet-Rec0'], + {} + ) + def test_minigraph_dhcp(self): argument = ['-m', self.sample_graph_simple_case, '-p', self.port_config, '-v', 'DHCP_RELAY'] output = self.run_script(argument) @@ -1015,3 +1025,33 @@ def test_minigraph_packet_chassis_400g_zr_port_config(self): output_dict = utils.to_dict(output.strip()) self.assertEqual(output_dict['tx_power'], '7.5') self.assertEqual(output_dict['laser_freq'], 131000) + + def test_minigraph_400g_to_100G_speed(self): + argument = ["-j", self.macsec_profile, "-m", self.voq_sample_masic_graph, "-p", self.voq_port_config_400g, "-n", "asic0", "-v", "PORT"] + output = self.run_script(argument) + self.assertEqual( + utils.to_dict(output.strip()), + utils.to_dict( + "{'Ethernet0': {'lanes': '72,73,74,75', 'alias': 'Ethernet1/1', 'index': '1', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth0-ASIC0', 'fec': 'rs', 'description': 'ARISTA01T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet8': {'lanes': '80,81,82,83', 'alias': 'Ethernet2/1', 'index': '2', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth8-ASIC0', 'fec': 'rs', 'description': 'ARISTA01T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet16': {'lanes': '88,89,90,91', 'alias': 'Ethernet3/1', 'index': '3', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth16-ASIC0', 'fec': 'rs', 'description': 'ARISTA03T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet24': {'lanes': '96,97,98,99,100,101,102,103', 'alias': 'Ethernet4/1', 'index': '4', 'role': 'Ext', 'speed': '400000', 'asic_port_name': 'Eth24-ASIC0', 'description': 'ARISTA03T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet32': {'lanes': '104,105,106,107,108,109,110,111', 'alias': 'Ethernet5/1', 'index': '5', 'role': 'Ext', 'speed': '400000', 'asic_port_name': 'Eth32-ASIC0', 'description': 'ARISTA05T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet40': {'lanes': '112,113,114,115,116,117,118,119', 'alias': 'Ethernet6/1', 'index': '6', 'role': 'Ext', 'speed': '400000', 'asic_port_name': 'Eth40-ASIC0', 'description': 'ARISTA05T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet48': {'lanes': '120,121,122,123,124,125,126,127', 'alias': 'Ethernet7/1', 'index': '7', 'role': 'Ext', 'speed': '400000', 'asic_port_name': 'Eth48-ASIC0', 'description': 'ARISTA07T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet56': {'lanes': '128,129,130,131', 'alias': 'Ethernet8/1', 'index': '8', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth56-ASIC0', 'fec': 'rs', 'description': 'ARISTA07T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet64': {'lanes': '136,137,138,139', 'alias': 'Ethernet9/1', 'index': '9', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth64-ASIC0', 'fec': 'rs', 'description': 'ARISTA09T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet72': {'lanes': '64,65,66,67', 'alias': 'Ethernet10/1', 'index': '10', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth72-ASIC0', 'fec': 'rs', 'description': 'ARISTA09T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet80': {'lanes': '56,57,58,59', 'alias': 'Ethernet11/1', 'index': '11', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth80-ASIC0', 'fec': 'rs', 'description': 'ARISTA11T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet88': {'lanes': '48,49,50,51', 'alias': 'Ethernet12/1', 'index': '12', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth88-ASIC0', 'fec': 'rs', 'description': 'ARISTA11T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet96': {'lanes': '40,41,42,43', 'alias': 'Ethernet13/1', 'index': '13', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth96-ASIC0', 'fec': 'rs', 'description': 'ARISTA13T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet104': {'lanes': '32,33,34,35', 'alias': 'Ethernet14/1', 'index': '14', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth104-ASIC0', 'fec': 'rs', 'description': 'ARISTA15T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet112': {'lanes': '24,25,26,27', 'alias': 'Ethernet15/1', 'index': '15', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth112-ASIC0', 'fec': 'rs', 'description': 'ARISTA15T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet120': {'lanes': '16,17,18,19', 'alias': 'Ethernet16/1', 'index': '16', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth120-ASIC0', 'fec': 'rs', 'description': 'ARISTA17T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet128': {'lanes': '8,9,10,11', 'alias': 'Ethernet17/1', 'index': '17', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth128-ASIC0', 'fec': 'rs', 'description': 'ARISTA18T3:Ethernet1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet136': {'lanes': '0,1,2,3', 'alias': 'Ethernet18/1', 'index': '18', 'role': 'Ext', 'speed': '100000', 'asic_port_name': 'Eth136-ASIC0', 'fec': 'rs', 'description': 'ARISTA18T3:Ethernet2', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}, " + "'Ethernet-Rec0': {'lanes': '221', 'alias': 'Recirc0/0', 'index': '37', 'role': 'Rec', 'speed': '400000', 'asic_port_name': 'Rcy0-ASIC0', 'description': 'Recirc0/0', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}," + "'Ethernet-IB0': {'lanes': '222', 'alias': 'Recirc0/1', 'index': '38', 'role': 'Inb', 'speed': '400000', 'asic_port_name': 'Rcy1-ASIC0', 'description': 'Recirc0/1', 'mtu': '9100', 'tpid': '0x8100', 'pfc_asym': 'off', 'admin_status': 'up'}}" + ) + ) + diff --git a/src/sonic-config-engine/tests/test_minigraph_case.py b/src/sonic-config-engine/tests/test_minigraph_case.py index 1952c6c20d57..a8c95e217ff3 100644 --- a/src/sonic-config-engine/tests/test_minigraph_case.py +++ b/src/sonic-config-engine/tests/test_minigraph_case.py @@ -157,7 +157,7 @@ def test_minigraph_portchannels(self): output = self.run_script(argument) self.assertEqual( utils.to_dict(output.strip()), - utils.to_dict("{'PortChannel01': {'admin_status': 'up', 'min_links': '1', 'members': ['Ethernet4'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}") + utils.to_dict("{'PortChannel01': {'admin_status': 'up', 'min_links': '1', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}") ) def test_minigraph_console_mgmt_feature(self): diff --git a/src/sonic-config-engine/tests/test_multinpu_cfggen.py b/src/sonic-config-engine/tests/test_multinpu_cfggen.py index 8559c10394a3..6eb2c8674abd 100644 --- a/src/sonic-config-engine/tests/test_multinpu_cfggen.py +++ b/src/sonic-config-engine/tests/test_multinpu_cfggen.py @@ -161,16 +161,16 @@ def test_frontend_asic_portchannels(self): argument = ["-m", self.sample_graph, "-p", self.port_config[0], "-n", "asic0", "--var-json", "PORTCHANNEL"] output = json.loads(self.run_script(argument)) self.assertDictEqual(output, \ - {'PortChannel0002': {'admin_status': 'up', 'min_links': '2', 'members': ['Ethernet0', 'Ethernet4'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, - 'PortChannel4001': {'admin_status': 'up', 'min_links': '2', 'members': ['Ethernet-BP0', 'Ethernet-BP4'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, - 'PortChannel4002': {'admin_status': 'up', 'min_links': '2', 'members': ['Ethernet-BP8', 'Ethernet-BP12'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}) + {'PortChannel0002': {'admin_status': 'up', 'min_links': '2', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, + 'PortChannel4001': {'admin_status': 'up', 'min_links': '2', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, + 'PortChannel4002': {'admin_status': 'up', 'min_links': '2', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}) def test_backend_asic_portchannels(self): argument = ["-m", self.sample_graph, "-p", self.port_config[3], "-n", "asic3", "--var-json", "PORTCHANNEL"] output = json.loads(self.run_script(argument)) self.assertDictEqual(output, \ - {'PortChannel4013': {'admin_status': 'up', 'min_links': '2', 'members': ['Ethernet-BP384', 'Ethernet-BP388'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, - 'PortChannel4014': {'admin_status': 'up', 'min_links': '2', 'members': ['Ethernet-BP392', 'Ethernet-BP396'], 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}) + {'PortChannel4013': {'admin_status': 'up', 'min_links': '2', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}, + 'PortChannel4014': {'admin_status': 'up', 'min_links': '2', 'mtu': '9100', 'tpid': '0x8100', 'lacp_key': 'auto'}}) def test_frontend_asic_portchannel_mem(self): argument = ["-m", self.sample_graph, "-p", self.port_config[0], "-n", "asic0", "-v", "PORTCHANNEL_MEMBER.keys()|list"] @@ -445,6 +445,97 @@ def test_buffers_multi_asic_template(self): } } ) + + def test_buffers_chassis_packet_lc_template(self): + build_root_dir = os.path.join( + self.test_dir, "..", "..", ".." + ) + # using T2 buffer configuration + buffer_template = os.path.join( + build_root_dir, "files", "build_templates", "buffers_config.j2" + ) + minigraph = os.path.join( + self.test_dir, "sample-chassis-packet-lc-graph.xml" + ) + port_config_ini_asic1 = os.path.join( + self.test_dir, "sample-chassis-packet-lc-port-config.ini" + ) + device_config_dir = self.test_data_dir + device_buffer_template = os.path.join( + device_config_dir, "buffers.json.j2" + ) + shutil.copy2(buffer_template, device_config_dir) + # asic1 - mix of front end and back end ports + argument = ["-m", minigraph, "-p", port_config_ini_asic1, "-n", "asic1", "-t", device_buffer_template] + output = json.loads(self.run_script(argument, check_stderr=True)) + os.remove(os.path.join(device_config_dir, "buffers_config.j2")) + self.assertDictEqual( + output['CABLE_LENGTH'], + { + 'AZURE': { + 'Ethernet13': '300m', + 'Ethernet14': '300m', + 'Ethernet16': '300m', + 'Ethernet17': '300m', + 'Ethernet19': '300m', + 'Ethernet20': '300m', + 'Ethernet22': '300m', + 'Ethernet23': '300m', + 'Ethernet25': '300m', + 'Ethernet26': '300m', + 'Ethernet28': '300m', + 'Ethernet29': '300m', + 'Ethernet31': '300m', + 'Ethernet32': '300m', + 'Ethernet34': '300m', + 'Ethernet35': '300m', + 'Ethernet37': '300m', + 'Ethernet38': '300m', + 'Ethernet40': '300m', + 'Ethernet41': '300m', + 'Ethernet43': '300m', + 'Ethernet44': '300m', + 'Ethernet46': '300m', + 'Ethernet47': '300m', + 'Ethernet-BP2320': '1m', + 'Ethernet-BP2452': '1m', + 'Ethernet-BP2454': '1m', + 'Ethernet-BP2456': '1m', + 'Ethernet-BP2458': '1m', + 'Ethernet-BP2460': '1m', + 'Ethernet-BP2462': '1m', + 'Ethernet-BP2464': '1m', + 'Ethernet-BP2466': '1m', + 'Ethernet-BP2468': '1m', + 'Ethernet-BP2470': '1m', + 'Ethernet-BP2472': '1m', + 'Ethernet-BP2474': '1m', + 'Ethernet-BP2476': '1m', + 'Ethernet-BP2478': '1m', + 'Ethernet-BP2480': '1m', + 'Ethernet-BP2482': '1m', + 'Ethernet-BP2484': '1m', + 'Ethernet-BP2486': '1m', + 'Ethernet-BP2488': '1m', + 'Ethernet-BP2490': '1m', + 'Ethernet-BP2492': '1m', + 'Ethernet-BP2494': '1m', + 'Ethernet-BP2496': '1m', + 'Ethernet-BP2498': '1m', + 'Ethernet-BP2500': '1m', + 'Ethernet-BP2502': '1m', + 'Ethernet-BP2504': '1m', + 'Ethernet-BP2506': '1m', + 'Ethernet-BP2508': '1m', + 'Ethernet-BP2510': '1m', + 'Ethernet-BP2512': '1m', + 'Ethernet-BP2514': '1m', + 'Ethernet-BP2516': '1m', + 'Ethernet-BP2518': '1m' + } + } + ) + def test_bgpd_frr_frontendasic(self): self.assertTrue(*self.run_frr_asic_case('bgpd/bgpd.conf.j2', 'bgpd_frr_frontend_asic.conf', "asic0", self.port_config[0])) diff --git a/src/sonic-config-engine/tests/voq-sample-400g-port-config.ini b/src/sonic-config-engine/tests/voq-sample-400g-port-config.ini new file mode 100644 index 000000000000..f86cdb335ed8 --- /dev/null +++ b/src/sonic-config-engine/tests/voq-sample-400g-port-config.ini @@ -0,0 +1,21 @@ +# name lanes alias index role speed asic_port_name +Ethernet0 72,73,74,75,76,77,78,79 Ethernet1/1 1 Ext 400000 Eth0-ASIC0 +Ethernet8 80,81,82,83,84,85,86,87 Ethernet2/1 2 Ext 400000 Eth8-ASIC0 +Ethernet16 88,89,90,91,92,93,94,95 Ethernet3/1 3 Ext 400000 Eth16-ASIC0 +Ethernet24 96,97,98,99,100,101,102,103 Ethernet4/1 4 Ext 400000 Eth24-ASIC0 +Ethernet32 104,105,106,107,108,109,110,111 Ethernet5/1 5 Ext 400000 Eth32-ASIC0 +Ethernet40 112,113,114,115,116,117,118,119 Ethernet6/1 6 Ext 400000 Eth40-ASIC0 +Ethernet48 120,121,122,123,124,125,126,127 Ethernet7/1 7 Ext 400000 Eth48-ASIC0 +Ethernet56 128,129,130,131,132,133,134,135 Ethernet8/1 8 Ext 400000 Eth56-ASIC0 +Ethernet64 136,137,138,139,140,141,142,143 Ethernet9/1 9 Ext 400000 Eth64-ASIC0 +Ethernet72 64,65,66,67,68,69,70,71 Ethernet10/1 10 Ext 400000 Eth72-ASIC0 +Ethernet80 56,57,58,59,60,61,62,63 Ethernet11/1 11 Ext 400000 Eth80-ASIC0 +Ethernet88 48,49,50,51,52,53,54,55 Ethernet12/1 12 Ext 400000 Eth88-ASIC0 +Ethernet96 40,41,42,43,44,45,46,47 Ethernet13/1 13 Ext 400000 Eth96-ASIC0 +Ethernet104 32,33,34,35,36,37,38,39 Ethernet14/1 14 Ext 400000 Eth104-ASIC0 +Ethernet112 24,25,26,27,28,29,30,31 Ethernet15/1 15 Ext 400000 Eth112-ASIC0 +Ethernet120 16,17,18,19,20,21,22,23 Ethernet16/1 16 Ext 400000 Eth120-ASIC0 +Ethernet128 8,9,10,11,12,13,14,15 Ethernet17/1 17 Ext 400000 Eth128-ASIC0 +Ethernet136 0,1,2,3,4,5,6,7 Ethernet18/1 18 Ext 400000 Eth136-ASIC0 +Ethernet-Rec0 221 Recirc0/0 37 Rec 400000 Rcy0-ASIC0 +Ethernet-IB0 222 Recirc0/1 38 Inb 400000 Rcy1-ASIC0 diff --git a/src/sonic-config-engine/tests/voq-sample-masic-graph.xml b/src/sonic-config-engine/tests/voq-sample-masic-graph.xml new file mode 100644 index 000000000000..cda6c1a6a3bf --- /dev/null +++ b/src/sonic-config-engine/tests/voq-sample-masic-graph.xml @@ -0,0 +1,3903 @@ + + + + + + false + str2-sonic-lc5-1 + 10.0.0.0 + ARISTA01T3 + 10.0.0.1 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.0 + ARISTA01T3 + 10.0.0.1 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::1 + ARISTA01T3 + FC00::2 + 1 + 10 + 3 + + + ASIC0 + FC00::1 + ARISTA01T3 + FC00::2 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.4 + ARISTA03T3 + 10.0.0.5 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.4 + ARISTA03T3 + 10.0.0.5 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::9 + ARISTA03T3 + FC00::A + 1 + 10 + 3 + + + ASIC0 + FC00::9 + ARISTA03T3 + FC00::A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.8 + ARISTA05T3 + 10.0.0.9 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.8 + ARISTA05T3 + 10.0.0.9 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::11 + ARISTA05T3 + FC00::12 + 1 + 10 + 3 + + + ASIC0 + FC00::11 + ARISTA05T3 + FC00::12 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.12 + ARISTA07T3 + 10.0.0.13 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.12 + ARISTA07T3 + 10.0.0.13 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::19 + ARISTA07T3 + FC00::1A + 1 + 10 + 3 + + + ASIC0 + FC00::19 + ARISTA07T3 + FC00::1A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.16 + ARISTA09T3 + 10.0.0.17 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.16 + ARISTA09T3 + 10.0.0.17 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::21 + ARISTA09T3 + FC00::22 + 1 + 10 + 3 + + + ASIC0 + FC00::21 + ARISTA09T3 + FC00::22 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.20 + ARISTA11T3 + 10.0.0.21 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.20 + ARISTA11T3 + 10.0.0.21 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::29 + ARISTA11T3 + FC00::2A + 1 + 10 + 3 + + + ASIC0 + FC00::29 + ARISTA11T3 + FC00::2A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.32 + ARISTA13T3 + 10.0.0.33 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.32 + ARISTA13T3 + 10.0.0.33 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::41 + ARISTA13T3 + FC00::42 + 1 + 10 + 3 + + + ASIC0 + FC00::41 + ARISTA13T3 + FC00::42 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.28 + ARISTA15T3 + 10.0.0.29 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.28 + ARISTA15T3 + 10.0.0.29 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::39 + ARISTA15T3 + FC00::3A + 1 + 10 + 3 + + + ASIC0 + FC00::39 + ARISTA15T3 + FC00::3A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.34 + ARISTA17T3 + 10.0.0.35 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.34 + ARISTA17T3 + 10.0.0.35 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::45 + ARISTA17T3 + FC00::46 + 1 + 10 + 3 + + + ASIC0 + FC00::45 + ARISTA17T3 + FC00::46 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.24 + ARISTA18T3 + 10.0.0.25 + 1 + 10 + 3 + + + false + ASIC0 + 10.0.0.24 + ARISTA18T3 + 10.0.0.25 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::31 + ARISTA18T3 + FC00::32 + 1 + 10 + 3 + + + ASIC0 + FC00::31 + ARISTA18T3 + FC00::32 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.36 + ARISTA19T3 + 10.0.0.37 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.36 + ARISTA19T3 + 10.0.0.37 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::49 + ARISTA19T3 + FC00::4A + 1 + 10 + 3 + + + ASIC1 + FC00::49 + ARISTA19T3 + FC00::4A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.38 + ARISTA20T3 + 10.0.0.39 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.38 + ARISTA20T3 + 10.0.0.39 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::4D + ARISTA20T3 + FC00::4E + 1 + 10 + 3 + + + ASIC1 + FC00::4D + ARISTA20T3 + FC00::4E + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.40 + ARISTA21T3 + 10.0.0.41 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.40 + ARISTA21T3 + 10.0.0.41 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::51 + ARISTA21T3 + FC00::52 + 1 + 10 + 3 + + + ASIC1 + FC00::51 + ARISTA21T3 + FC00::52 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.42 + ARISTA22T3 + 10.0.0.43 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.42 + ARISTA22T3 + 10.0.0.43 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::55 + ARISTA22T3 + FC00::56 + 1 + 10 + 3 + + + ASIC1 + FC00::55 + ARISTA22T3 + FC00::56 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.44 + ARISTA23T3 + 10.0.0.45 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.44 + ARISTA23T3 + 10.0.0.45 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::59 + ARISTA23T3 + FC00::5A + 1 + 10 + 3 + + + ASIC1 + FC00::59 + ARISTA23T3 + FC00::5A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.46 + ARISTA24T3 + 10.0.0.47 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.46 + ARISTA24T3 + 10.0.0.47 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::5D + ARISTA24T3 + FC00::5E + 1 + 10 + 3 + + + ASIC1 + FC00::5D + ARISTA24T3 + FC00::5E + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.48 + ARISTA25T3 + 10.0.0.49 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.48 + ARISTA25T3 + 10.0.0.49 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::61 + ARISTA25T3 + FC00::62 + 1 + 10 + 3 + + + ASIC1 + FC00::61 + ARISTA25T3 + FC00::62 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.50 + ARISTA26T3 + 10.0.0.51 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.50 + ARISTA26T3 + 10.0.0.51 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::65 + ARISTA26T3 + FC00::66 + 1 + 10 + 3 + + + ASIC1 + FC00::65 + ARISTA26T3 + FC00::66 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.52 + ARISTA27T3 + 10.0.0.53 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.52 + ARISTA27T3 + 10.0.0.53 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::69 + ARISTA27T3 + FC00::6A + 1 + 10 + 3 + + + ASIC1 + FC00::69 + ARISTA27T3 + FC00::6A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.54 + ARISTA28T3 + 10.0.0.55 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.54 + ARISTA28T3 + 10.0.0.55 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::6D + ARISTA28T3 + FC00::6E + 1 + 10 + 3 + + + ASIC1 + FC00::6D + ARISTA28T3 + FC00::6E + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.56 + ARISTA29T3 + 10.0.0.57 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.56 + ARISTA29T3 + 10.0.0.57 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::71 + ARISTA29T3 + FC00::72 + 1 + 10 + 3 + + + ASIC1 + FC00::71 + ARISTA29T3 + FC00::72 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.58 + ARISTA30T3 + 10.0.0.59 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.58 + ARISTA30T3 + 10.0.0.59 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::75 + ARISTA30T3 + FC00::76 + 1 + 10 + 3 + + + ASIC1 + FC00::75 + ARISTA30T3 + FC00::76 + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.60 + ARISTA31T3 + 10.0.0.61 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.60 + ARISTA31T3 + 10.0.0.61 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::79 + ARISTA31T3 + FC00::7A + 1 + 10 + 3 + + + ASIC1 + FC00::79 + ARISTA31T3 + FC00::7A + 1 + 10 + 3 + + + false + str2-sonic-lc5-1 + 10.0.0.62 + ARISTA32T3 + 10.0.0.63 + 1 + 10 + 3 + + + false + ASIC1 + 10.0.0.62 + ARISTA32T3 + 10.0.0.63 + 1 + 10 + 3 + + + str2-sonic-lc5-1 + FC00::7D + ARISTA32T3 + FC00::7E + 1 + 10 + 3 + + + ASIC1 + FC00::7D + ARISTA32T3 + FC00::7E + 1 + 10 + 3 + + + + + ASIC0 + ASIC1 + 3.3.3.2 + 3.3.3.3 + 1 + 0 + 0 + voq + + + ASIC0 + ASIC1 + 3333::3:2 + 3333::3:3 + 1 + 0 + 0 + voq + + + ASIC0 + str2-sonic-lc3-1 + 3.3.3.2 + 3.3.3.1 + 1 + 0 + 0 + voq + + + ASIC0 + str2-sonic-lc3-1 + 3333::3:2 + 3333::3:1 + 1 + 0 + 0 + voq + + + ASIC0 + str2-sonic-lc7-1 + 3.3.3.2 + 3.3.3.5 + 1 + 0 + 0 + voq + + + ASIC0 + str2-sonic-lc7-1 + 3333::3:2 + 3333::3:5 + 1 + 0 + 0 + voq + + + ASIC1 + ASIC0 + 3.3.3.3 + 3.3.3.2 + 1 + 0 + 0 + voq + + + ASIC1 + ASIC0 + 3333::3:3 + 3333::3:2 + 1 + 0 + 0 + voq + + + ASIC1 + str2-sonic-lc3-1 + 3.3.3.3 + 3.3.3.1 + 1 + 0 + 0 + voq + + + ASIC1 + str2-sonic-lc3-1 + 3333::3:3 + 3333::3:1 + 1 + 0 + 0 + voq + + + ASIC1 + str2-sonic-lc7-1 + 3.3.3.3 + 3.3.3.5 + 1 + 0 + 0 + voq + + + ASIC1 + str2-sonic-lc7-1 + 3333::3:3 + 3333::3:5 + 1 + 0 + 0 + voq + + + + + 65100 + str2-sonic-lc5-1 + + +
10.0.0.1
+ + + +
+ +
10.0.0.5
+ + + +
+ +
10.0.0.9
+ + + +
+ +
10.0.0.13
+ + + +
+ +
10.0.0.17
+ + + +
+ +
10.0.0.21
+ + + +
+ +
10.0.0.33
+ + + +
+ +
10.0.0.29
+ + + +
+ +
10.0.0.35
+ + + +
+ +
10.0.0.25
+ + + +
+ +
10.0.0.37
+ + + +
+ +
10.0.0.39
+ + + +
+ +
10.0.0.41
+ + + +
+ +
10.0.0.43
+ + + +
+ +
10.0.0.45
+ + + +
+ +
10.0.0.47
+ + + +
+ +
10.0.0.49
+ + + +
+ +
10.0.0.51
+ + + +
+ +
10.0.0.53
+ + + +
+ +
10.0.0.55
+ + + +
+ +
10.0.0.57
+ + + +
+ +
10.0.0.59
+ + + +
+ +
10.0.0.61
+ + + +
+ +
10.0.0.63
+ + + +
+
+ +
+ + 65200 + ARISTA01T3 + + + + 65200 + ARISTA03T3 + + + + 65200 + ARISTA05T3 + + + + 65200 + ARISTA07T3 + + + + 65200 + ARISTA09T3 + + + + 65200 + ARISTA11T3 + + + + 65200 + ARISTA13T3 + + + + 65200 + ARISTA15T3 + + + + 65200 + ARISTA17T3 + + + + 65200 + ARISTA18T3 + + + + 65200 + ARISTA19T3 + + + + 65200 + ARISTA20T3 + + + + 65200 + ARISTA21T3 + + + + 65200 + ARISTA22T3 + + + + 65200 + ARISTA23T3 + + + + 65200 + ARISTA24T3 + + + + 65200 + ARISTA25T3 + + + + 65200 + ARISTA26T3 + + + + 65200 + ARISTA27T3 + + + + 65200 + ARISTA28T3 + + + + 65200 + ARISTA29T3 + + + + 65200 + ARISTA30T3 + + + + 65200 + ARISTA31T3 + + + + 65200 + ARISTA32T3 + + + + 65100 + ASIC1 + + +
10.0.0.37
+ + + +
+ +
10.0.0.39
+ + + +
+ +
10.0.0.41
+ + + +
+ +
10.0.0.43
+ + + +
+ +
10.0.0.45
+ + + +
+ +
10.0.0.47
+ + + +
+ +
10.0.0.49
+ + + +
+ +
10.0.0.51
+ + + +
+ +
10.0.0.53
+ + + +
+ +
10.0.0.55
+ + + +
+ +
10.0.0.57
+ + + +
+ +
10.0.0.59
+ + + +
+ +
10.0.0.61
+ + + +
+ +
10.0.0.63
+ + + +
+ +
3.3.3.2/32
+ + + +
+ +
3.3.3.1/32
+ + + +
+ +
3.3.3.5/32
+ + + +
+
+ +
+ + 65100 + ASIC0 + + +
10.0.0.1
+ + + +
+ +
10.0.0.5
+ + + +
+ +
10.0.0.9
+ + + +
+ +
10.0.0.13
+ + + +
+ +
10.0.0.17
+ + + +
+ +
10.0.0.21
+ + + +
+ +
10.0.0.33
+ + + +
+ +
10.0.0.29
+ + + +
+ +
10.0.0.35
+ + + +
+ +
10.0.0.25
+ + + +
+ +
3.3.3.3/32
+ + + +
+ +
3.3.3.1/32
+ + + +
+ +
3.3.3.5/32
+ + + +
+
+ +
+ + 65100 + str2-sonic-lc3-1 + + + + 65100 + str2-sonic-lc7-1 + + +
+
+ + + + + + HostIP + Loopback0 + + 10.1.0.1/32 + + 10.1.0.1/32 + + + HostIP1 + Loopback0 + + FC00:10::1/128 + + FC00:10::1/128 + + + + + HostIP + eth0 + + 10.3.147.27/23 + + 10.3.147.27/23 + + + V6HostIP + eth0 + + FC00:2::32/64 + + FC00:2::32/64 + + + + + + + str2-sonic-lc5-1 + + + PortChannel102 + Ethernet1/1;Ethernet2/1 + + + + PortChannel104 + Ethernet3/1;Ethernet4/1 + + + + PortChannel106 + Ethernet5/1;Ethernet6/1 + + + + PortChannel108 + Ethernet7/1;Ethernet8/1 + + + + PortChannel1010 + Ethernet9/1;Ethernet10/1 + + + + PortChannel1012 + Ethernet11/1;Ethernet12/1 + + + + PortChannel1016 + Ethernet14/1;Ethernet15/1 + + + + PortChannel1020 + Ethernet17/1;Ethernet18/1 + + + + + + + + + PortChannel102 + 10.0.0.0/31 + + + + PortChannel102 + FC00::1/126 + + + + PortChannel104 + 10.0.0.4/31 + + + + PortChannel104 + FC00::9/126 + + + + PortChannel106 + 10.0.0.8/31 + + + + PortChannel106 + FC00::11/126 + + + + PortChannel108 + 10.0.0.12/31 + + + + PortChannel108 + FC00::19/126 + + + + PortChannel1010 + 10.0.0.16/31 + + + + PortChannel1010 + FC00::21/126 + + + + PortChannel1012 + 10.0.0.20/31 + + + + PortChannel1012 + FC00::29/126 + + + + Ethernet13/1 + 10.0.0.32/31 + + + + Ethernet13/1 + FC00::41/126 + + + + PortChannel1016 + 10.0.0.28/31 + + + + PortChannel1016 + FC00::39/126 + + + + Ethernet16/1 + 10.0.0.34/31 + + + + Ethernet16/1 + FC00::45/126 + + + + PortChannel1020 + 10.0.0.24/31 + + + + PortChannel1020 + FC00::31/126 + + + + Ethernet19/1 + 10.0.0.36/31 + + + + Ethernet19/1 + FC00::49/126 + + + + Ethernet20/1 + 10.0.0.38/31 + + + + Ethernet20/1 + FC00::4D/126 + + + + Ethernet21/1 + 10.0.0.40/31 + + + + Ethernet21/1 + FC00::51/126 + + + + Ethernet22/1 + 10.0.0.42/31 + + + + Ethernet22/1 + FC00::55/126 + + + + Ethernet23/1 + 10.0.0.44/31 + + + + Ethernet23/1 + FC00::59/126 + + + + Ethernet24/1 + 10.0.0.46/31 + + + + Ethernet24/1 + FC00::5D/126 + + + + Ethernet25/1 + 10.0.0.48/31 + + + + Ethernet25/1 + FC00::61/126 + + + + Ethernet26/1 + 10.0.0.50/31 + + + + Ethernet26/1 + FC00::65/126 + + + + Ethernet27/1 + 10.0.0.52/31 + + + + Ethernet27/1 + FC00::69/126 + + + + Ethernet28/1 + 10.0.0.54/31 + + + + Ethernet28/1 + FC00::6D/126 + + + + Ethernet29/1 + 10.0.0.56/31 + + + + Ethernet29/1 + FC00::71/126 + + + + Ethernet30/1 + 10.0.0.58/31 + + + + Ethernet30/1 + FC00::75/126 + + + + Ethernet31/1 + 10.0.0.60/31 + + + + Ethernet31/1 + FC00::79/126 + + + + Ethernet32/1 + 10.0.0.62/31 + + + + Ethernet32/1 + FC00::7D/126 + + + + + + NTP_ACL + NTP + NTP + + + SNMP_ACL + SNMP + SNMP + + + ERSPAN + Everflow + Everflow + + + ERSPANV6 + EverflowV6 + EverflowV6 + + + VTY_LINE + ssh-only + SSH + + + PortChannel102;PortChannel104;PortChannel106;PortChannel108;PortChannel1010;PortChannel1012;PortChannel1016;PortChannel1020;Ethernet13/1;Ethernet16/1;Ethernet19/1;Ethernet20/1;Ethernet21/1;Ethernet22/1;Ethernet23/1;Ethernet24/1;Ethernet25/1;Ethernet26/1;Ethernet27/1;Ethernet28/1;Ethernet29/1;Ethernet30/1;Ethernet31/1;Ethernet32/1 + DataAcl + DataPlane + + + + + + + + + + HostIP + Loopback0 + + 10.1.0.1/32 + + 10.1.0.1/32 + + + HostIP1 + Loopback0 + + FC00:10::1/128 + + FC00:10::1/128 + + + HostIP1 + Loopback4096 + + 192.0.0.3/32 + + 192.0.0.3/32 + + + HostIP1 + Loopback4096 + + 2603:10e2:400::3/128 + + 2603:10e2:400::3/128 + + + + + HostIP + eth0 + + 10.3.147.27/23 + + 10.3.147.27/23 + + + V6HostIP + eth0 + + FC00:2::32/64 + + FC00:2::32/64 + + + + + + Ethernet-IB1 + port + 3.3.3.3/32 + + + Ethernet-IB1 + port + 3333::3:3/128 + + + + + + ASIC1 + + + + + + + Eth0-ASIC1 + 10.0.0.36/31 + + + + Eth0-ASIC1 + FC00::49/126 + + + + Eth8-ASIC1 + 10.0.0.38/31 + + + + Eth8-ASIC1 + FC00::4D/126 + + + + Eth16-ASIC1 + 10.0.0.40/31 + + + + Eth16-ASIC1 + FC00::51/126 + + + + Eth24-ASIC1 + 10.0.0.42/31 + + + + Eth24-ASIC1 + FC00::55/126 + + + + Eth32-ASIC1 + 10.0.0.44/31 + + + + Eth32-ASIC1 + FC00::59/126 + + + + Eth40-ASIC1 + 10.0.0.46/31 + + + + Eth40-ASIC1 + FC00::5D/126 + + + + Eth48-ASIC1 + 10.0.0.48/31 + + + + Eth48-ASIC1 + FC00::61/126 + + + + Eth56-ASIC1 + 10.0.0.50/31 + + + + Eth56-ASIC1 + FC00::65/126 + + + + Eth64-ASIC1 + 10.0.0.52/31 + + + + Eth64-ASIC1 + FC00::69/126 + + + + Eth72-ASIC1 + 10.0.0.54/31 + + + + Eth72-ASIC1 + FC00::6D/126 + + + + Eth80-ASIC1 + 10.0.0.56/31 + + + + Eth80-ASIC1 + FC00::71/126 + + + + Eth88-ASIC1 + 10.0.0.58/31 + + + + Eth88-ASIC1 + FC00::75/126 + + + + Eth96-ASIC1 + 10.0.0.60/31 + + + + Eth96-ASIC1 + FC00::79/126 + + + + Eth104-ASIC1 + 10.0.0.62/31 + + + + Eth104-ASIC1 + FC00::7D/126 + + + + + + SNMP_ACL + SNMP + SNMP + + + ERSPAN + Everflow + Everflow + + + ERSPANV6 + EverflowV6 + EverflowV6 + + + VTY_LINE + ssh-only + SSH + + + Eth0-ASIC1;Eth8-ASIC1;Eth16-ASIC1;Eth24-ASIC1;Eth32-ASIC1;Eth40-ASIC1;Eth48-ASIC1;Eth56-ASIC1;Eth64-ASIC1;Eth72-ASIC1;Eth80-ASIC1;Eth88-ASIC1;Eth96-ASIC1;Eth104-ASIC1 + DataAcl + DataPlane + + + + + + + + + + HostIP + Loopback0 + + 10.1.0.1/32 + + 10.1.0.1/32 + + + HostIP1 + Loopback0 + + FC00:10::1/128 + + FC00:10::1/128 + + + HostIP1 + Loopback4096 + + 192.0.0.2/32 + + 192.0.0.2/32 + + + HostIP1 + Loopback4096 + + 2603:10e2:400::2/128 + + 2603:10e2:400::2/128 + + + + + HostIP + eth0 + + 10.3.147.27/23 + + 10.3.147.27/23 + + + V6HostIP + eth0 + + FC00:2::32/64 + + FC00:2::32/64 + + + + + + Ethernet-IB0 + port + 3.3.3.2/32 + + + Ethernet-IB0 + port + 3333::3:2/128 + + + + + + ASIC0 + + + PortChannel102 + Eth0-ASIC0;Eth8-ASIC0 + + + + PortChannel104 + Eth16-ASIC0;Eth24-ASIC0 + + + + PortChannel106 + Eth32-ASIC0;Eth40-ASIC0 + + + + PortChannel108 + Eth48-ASIC0;Eth56-ASIC0 + + + + PortChannel1010 + Eth64-ASIC0;Eth72-ASIC0 + + + + PortChannel1012 + Eth80-ASIC0;Eth88-ASIC0 + + + + PortChannel1016 + Eth104-ASIC0;Eth112-ASIC0 + + + + PortChannel1020 + Eth128-ASIC0;Eth136-ASIC0 + + + + + + + + PortChannel102 + 10.0.0.0/31 + + + + PortChannel102 + FC00::1/126 + + + + PortChannel104 + 10.0.0.4/31 + + + + PortChannel104 + FC00::9/126 + + + + PortChannel106 + 10.0.0.8/31 + + + + PortChannel106 + FC00::11/126 + + + + PortChannel108 + 10.0.0.12/31 + + + + PortChannel108 + FC00::19/126 + + + + PortChannel1010 + 10.0.0.16/31 + + + + PortChannel1010 + FC00::21/126 + + + + PortChannel1012 + 10.0.0.20/31 + + + + PortChannel1012 + FC00::29/126 + + + + Eth96-ASIC0 + 10.0.0.32/31 + + + + Eth96-ASIC0 + FC00::41/126 + + + + PortChannel1016 + 10.0.0.28/31 + + + + PortChannel1016 + FC00::39/126 + + + + Eth120-ASIC0 + 10.0.0.34/31 + + + + Eth120-ASIC0 + FC00::45/126 + + + + PortChannel1020 + 10.0.0.24/31 + + + + PortChannel1020 + FC00::31/126 + + + + + + SNMP_ACL + SNMP + SNMP + + + ERSPAN + Everflow + Everflow + + + ERSPANV6 + EverflowV6 + EverflowV6 + + + VTY_LINE + ssh-only + SSH + + + PortChannel102;PortChannel104;PortChannel106;PortChannel108;PortChannel1010;PortChannel1012;PortChannel1016;PortChannel1020;Eth0-ASIC0;Eth16-ASIC0;Eth32-ASIC0;Eth48-ASIC0;Eth64-ASIC0;Eth80-ASIC0;Eth96-ASIC0;Eth104-ASIC0;Eth120-ASIC0;Eth128-ASIC0 + DataAcl + DataPlane + + + + + + + + + + DeviceInterfaceLink + ARISTA01T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet1/1 + 100000 + + + DeviceInterfaceLink + ARISTA01T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet2/1 + 100000 + + + DeviceInterfaceLink + ARISTA03T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet3/1 + 100000 + + + DeviceInterfaceLink + ARISTA03T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet4/1 + 400000 + + + DeviceInterfaceLink + ARISTA05T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet5/1 + 400000 + + + DeviceInterfaceLink + ARISTA05T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet6/1 + 400000 + + + DeviceInterfaceLink + ARISTA07T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet7/1 + 400000 + + + DeviceInterfaceLink + ARISTA07T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet8/1 + 100000 + + + DeviceInterfaceLink + ARISTA09T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet9/1 + 100000 + + + DeviceInterfaceLink + ARISTA09T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet10/1 + 100000 + + + DeviceInterfaceLink + ARISTA11T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet11/1 + 100000 + + + DeviceInterfaceLink + ARISTA11T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet12/1 + 100000 + + + DeviceInterfaceLink + ARISTA13T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet13/1 + 100000 + + + DeviceInterfaceLink + ARISTA15T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet14/1 + 100000 + + + DeviceInterfaceLink + ARISTA15T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet15/1 + 100000 + + + DeviceInterfaceLink + ARISTA17T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet16/1 + 100000 + + + DeviceInterfaceLink + ARISTA18T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet17/1 + 100000 + + + DeviceInterfaceLink + ARISTA18T3 + Ethernet2 + str2-sonic-lc5-1 + Ethernet18/1 + 100000 + + + DeviceInterfaceLink + ARISTA19T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet19/1 + 100000 + + + DeviceInterfaceLink + ARISTA20T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet20/1 + 100000 + + + DeviceInterfaceLink + ARISTA21T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet21/1 + 100000 + + + DeviceInterfaceLink + ARISTA22T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet22/1 + 100000 + + + DeviceInterfaceLink + ARISTA23T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet23/1 + 100000 + + + DeviceInterfaceLink + ARISTA24T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet24/1 + 100000 + + + DeviceInterfaceLink + ARISTA25T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet25/1 + 100000 + + + DeviceInterfaceLink + ARISTA26T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet26/1 + 100000 + + + DeviceInterfaceLink + ARISTA27T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet27/1 + 100000 + + + DeviceInterfaceLink + ARISTA28T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet28/1 + 100000 + + + DeviceInterfaceLink + ARISTA29T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet29/1 + 100000 + + + DeviceInterfaceLink + ARISTA30T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet30/1 + 100000 + + + DeviceInterfaceLink + ARISTA31T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet31/1 + 100000 + + + DeviceInterfaceLink + ARISTA32T3 + Ethernet1 + str2-sonic-lc5-1 + Ethernet32/1 + 100000 + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth0-ASIC0 + true + str2-sonic-lc5-1 + Ethernet1/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth8-ASIC0 + true + str2-sonic-lc5-1 + Ethernet2/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth16-ASIC0 + true + str2-sonic-lc5-1 + Ethernet3/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth24-ASIC0 + true + str2-sonic-lc5-1 + Ethernet4/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth32-ASIC0 + true + str2-sonic-lc5-1 + Ethernet5/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth40-ASIC0 + true + str2-sonic-lc5-1 + Ethernet6/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth48-ASIC0 + true + str2-sonic-lc5-1 + Ethernet7/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth56-ASIC0 + true + str2-sonic-lc5-1 + Ethernet8/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth64-ASIC0 + true + str2-sonic-lc5-1 + Ethernet9/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth72-ASIC0 + true + str2-sonic-lc5-1 + Ethernet10/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth80-ASIC0 + true + str2-sonic-lc5-1 + Ethernet11/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth88-ASIC0 + true + str2-sonic-lc5-1 + Ethernet12/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth96-ASIC0 + true + str2-sonic-lc5-1 + Ethernet13/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth104-ASIC0 + true + str2-sonic-lc5-1 + Ethernet14/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth112-ASIC0 + true + str2-sonic-lc5-1 + Ethernet15/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth120-ASIC0 + true + str2-sonic-lc5-1 + Ethernet16/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth128-ASIC0 + true + str2-sonic-lc5-1 + Ethernet17/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC0 + Eth136-ASIC0 + true + str2-sonic-lc5-1 + Ethernet18/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth0-ASIC1 + true + str2-sonic-lc5-1 + Ethernet19/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth8-ASIC1 + true + str2-sonic-lc5-1 + Ethernet20/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth16-ASIC1 + true + str2-sonic-lc5-1 + Ethernet21/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth24-ASIC1 + true + str2-sonic-lc5-1 + Ethernet22/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth32-ASIC1 + true + str2-sonic-lc5-1 + Ethernet23/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth40-ASIC1 + true + str2-sonic-lc5-1 + Ethernet24/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth48-ASIC1 + true + str2-sonic-lc5-1 + Ethernet25/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth56-ASIC1 + true + str2-sonic-lc5-1 + Ethernet26/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth64-ASIC1 + true + str2-sonic-lc5-1 + Ethernet27/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth72-ASIC1 + true + str2-sonic-lc5-1 + Ethernet28/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth80-ASIC1 + true + str2-sonic-lc5-1 + Ethernet29/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth88-ASIC1 + true + str2-sonic-lc5-1 + Ethernet30/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth96-ASIC1 + true + str2-sonic-lc5-1 + Ethernet31/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth104-ASIC1 + true + str2-sonic-lc5-1 + Ethernet32/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth112-ASIC1 + true + str2-sonic-lc5-1 + Ethernet33/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth120-ASIC1 + true + str2-sonic-lc5-1 + Ethernet34/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth128-ASIC1 + true + str2-sonic-lc5-1 + Ethernet35/1 + true + + + DeviceInterfaceLink + 400000 + true + ASIC1 + Eth136-ASIC1 + true + str2-sonic-lc5-1 + Ethernet36/1 + true + + + + + str2-sonic-lc5-1 + Sonic-linecard-masic-hwsku + + 10.3.147.27 + + + + ARISTA05T3 + + 172.16.145.34 + + Arista-VM + + + ARISTA11T3 + + 172.16.145.37 + + Arista-VM + + + ARISTA17T3 + + 172.16.145.40 + + Arista-VM + + + ARISTA21T3 + + 172.16.145.44 + + Arista-VM + + + ARISTA19T3 + + 172.16.145.42 + + Arista-VM + + + ARISTA09T3 + + 172.16.145.36 + + Arista-VM + + + ARISTA20T3 + + 172.16.145.43 + + Arista-VM + + + ARISTA03T3 + + 172.16.145.33 + + Arista-VM + + + ARISTA07T3 + + 172.16.145.35 + + Arista-VM + + + ARISTA01T3 + + 172.16.145.32 + + Arista-VM + + + ARISTA27T3 + + 172.16.145.50 + + Arista-VM + + + ARISTA26T3 + + 172.16.145.49 + + Arista-VM + + + ARISTA32T3 + + 172.16.145.55 + + Arista-VM + + + ARISTA23T3 + + 172.16.145.46 + + Arista-VM + + + ARISTA25T3 + + 172.16.145.48 + + Arista-VM + + + ARISTA24T3 + + 172.16.145.47 + + Arista-VM + + + ARISTA22T3 + + 172.16.145.45 + + Arista-VM + + + ARISTA28T3 + + 172.16.145.51 + + Arista-VM + + + ARISTA30T3 + + 172.16.145.53 + + Arista-VM + + + ARISTA18T3 + + 172.16.145.41 + + Arista-VM + + + ARISTA29T3 + + 172.16.145.52 + + Arista-VM + + + ARISTA15T3 + + 172.16.145.39 + + Arista-VM + + + ARISTA13T3 + + 172.16.145.38 + + Arista-VM + + + ARISTA31T3 + + 172.16.145.54 + + Arista-VM + + + Asic +
+ 0.0.0.0/0 +
+ + ::/0 + + + + + + + + + + 0.0.0.0/0 + + + ::/0 + + + ASIC0 + Broadcom-Trident2 +
+ + Asic +
+ 0.0.0.0/0 +
+ + ::/0 + + + + + + + + + + 0.0.0.0/0 + + + ::/0 + + + ASIC1 + Broadcom-Trident2 +
+
+
+ + + true + + + DeviceInterface + + true + true + 1 + Ethernet1/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet2/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet3/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet4/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet5/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet6/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet7/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet8/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet9/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet10/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet11/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet12/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet13/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet14/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet15/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet16/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet17/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet18/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet19/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet20/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet21/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet22/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet23/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet24/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet25/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet26/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet27/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet28/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet29/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet30/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet31/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet32/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet33/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet34/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet35/1 + + false + 0 + 0 + 400000 + + + DeviceInterface + + true + true + 1 + Ethernet36/1 + + false + 0 + 0 + 400000 + + + true + 0 + Sonic-linecard-masic-hwsku + + + + + + + str2-sonic-lc5-1 + + + DeploymentId + + 1 + + + QosProfile + + Profile0 + + + DhcpResources + + 192.0.0.1;192.0.0.2;192.0.0.3;192.0.0.4;192.0.0.5;192.0.0.6;192.0.0.7;192.0.0.8;192.0.0.9;192.0.0.10;192.0.0.11;192.0.0.12;192.0.0.13;192.0.0.14;192.0.0.15;192.0.0.16;192.0.0.17;192.0.0.18;192.0.0.19;192.0.0.20;192.0.0.21;192.0.0.22;192.0.0.23;192.0.0.24;192.0.0.25;192.0.0.26;192.0.0.27;192.0.0.28;192.0.0.29;192.0.0.30;192.0.0.31;192.0.0.32;192.0.0.33;192.0.0.34;192.0.0.35;192.0.0.36;192.0.0.37;192.0.0.38;192.0.0.39;192.0.0.40;192.0.0.41;192.0.0.42;192.0.0.43;192.0.0.44;192.0.0.45;192.0.0.46;192.0.0.47;192.0.0.48 + + + NtpResources + + 10.20.8.129;10.20.8.130 + + + SnmpResources + + 10.3.145.98 + + + SyslogResources + + 10.64.246.95 + + + TacacsGroup + + Starlab + + + TacacsServer + + 100.127.20.21 + + + ForcedMgmtRoutes + + 10.3.145.98/31;10.3.145.8;100.127.20.16/28;10.3.149.170/31;40.122.216.24;13.91.48.226;10.3.145.14;10.64.246.0/24;10.3.146.0/23;10.64.5.5;10.201.148.32/28 + + + ErspanDestinationIpv4 + + 10.20.6.16 + + + SwitchType + + voq + + + MaxCores + + 16 + + + + + ASIC0 + + + SubRole + + FrontEnd + + + SwitchType + + voq + + + SwitchId + + 2 + + + MaxCores + + 16 + + + + + ASIC1 + + + SubRole + + FrontEnd + + + SwitchType + + voq + + + SwitchId + + 4 + + + MaxCores + + 16 + + + + + ASIC1 + + + DeploymentId + + 1 + + + SubRole + + FrontEnd + + + SwitchType + + voq + + + + + ASIC0 + + + DeploymentId + + 1 + + + SubRole + + FrontEnd + + + SwitchType + + voq + + + + + + + str2-sonic-lc5-1 + Sonic-linecard-masic-hwsku +
diff --git a/src/sonic-device-data/tests/permitted_list b/src/sonic-device-data/tests/permitted_list index 244c6cae634e..1f263640e29e 100644 --- a/src/sonic-device-data/tests/permitted_list +++ b/src/sonic-device-data/tests/permitted_list @@ -341,3 +341,4 @@ sai_mdio_access_clause22 cmic_dma_abort_in_cold_boot hybrid_pfc_deadlock_enable sai_pfc_dlr_init_capability +appl_param_nof_ports_per_modid diff --git a/src/sonic-linux-kernel b/src/sonic-linux-kernel index 6daddcfa6a84..464d2cdbb9d6 160000 --- a/src/sonic-linux-kernel +++ b/src/sonic-linux-kernel @@ -1 +1 @@ -Subproject commit 6daddcfa6a84434840df718272f57fd7d2c7f053 +Subproject commit 464d2cdbb9d6283124babcbb4b0df3aca0b53d68 diff --git a/src/sonic-linux-kernel.patch/patch/driver-hwmon-pmbus-cisco_n2200.patch b/src/sonic-linux-kernel.patch/patch/driver-hwmon-pmbus-cisco_n2200.patch index 32fdbb92c4e5..59400fd73dc0 100644 --- a/src/sonic-linux-kernel.patch/patch/driver-hwmon-pmbus-cisco_n2200.patch +++ b/src/sonic-linux-kernel.patch/patch/driver-hwmon-pmbus-cisco_n2200.patch @@ -62,8 +62,8 @@ diff --git a/drivers/hwmon/pmbus/Makefile b/drivers/hwmon/pmbus/Makefile index edc7c315c..df9119c0d 100644 --- a/drivers/hwmon/pmbus/Makefile +++ b/drivers/hwmon/pmbus/Makefile -@@ -24,3 +24,4 @@ obj-$(CONFIG_SENSORS_UCD9200) += ucd9200.o - obj-$(CONFIG_SENSORS_XDPE122) += xdpe12284.o +@@ -36,3 +36,4 @@ obj-$(CONFIG_SENSORS_UCD9200) += ucd9200.o + obj-$(CONFIG_SENSORS_XDPE152) += xdpe152c4.o obj-$(CONFIG_SENSORS_ZL6100) += zl6100.o obj-$(CONFIG_SENSORS_DPS1900) += dps1900.o +obj-$(CONFIG_SENSORS_CISCO_N2200) += cisco_n2200.o diff --git a/src/sonic-platform-common b/src/sonic-platform-common index 01ef800ca959..85c20cdee265 160000 --- a/src/sonic-platform-common +++ b/src/sonic-platform-common @@ -1 +1 @@ -Subproject commit 01ef800ca9590349e2c9299bcdd339831aa0a79d +Subproject commit 85c20cdee2650f89351bf3a78053ebf58ccd9846 diff --git a/src/sonic-platform-daemons b/src/sonic-platform-daemons index a931d6c727f4..05dd3bd3e6b3 160000 --- a/src/sonic-platform-daemons +++ b/src/sonic-platform-daemons @@ -1 +1 @@ -Subproject commit a931d6c727f4bf97f893ea52160412a2cb8eca16 +Subproject commit 05dd3bd3e6b3c94cf64e36302f735a101a60ea53 diff --git a/src/sonic-sairedis b/src/sonic-sairedis index 0434b6200982..4d86af3474c7 160000 --- a/src/sonic-sairedis +++ b/src/sonic-sairedis @@ -1 +1 @@ -Subproject commit 0434b620098200ee9024d0f4152b3fe7c2753de2 +Subproject commit 4d86af3474c7b4299557293c2ee4516753aff169 diff --git a/src/sonic-snmpagent b/src/sonic-snmpagent index 4f55473f4af1..4622b8df01e6 160000 --- a/src/sonic-snmpagent +++ b/src/sonic-snmpagent @@ -1 +1 @@ -Subproject commit 4f55473f4af1115d86feb1a9ed3ab48dee75d8f8 +Subproject commit 4622b8df01e6cfa818568b5a78a1a56ab555097d diff --git a/src/sonic-swss b/src/sonic-swss index 44ea6a08659a..baa302e232d6 160000 --- a/src/sonic-swss +++ b/src/sonic-swss @@ -1 +1 @@ -Subproject commit 44ea6a08659a11723173c5272b0400882cf11347 +Subproject commit baa302e232d61a49880b23b3ef1098e47cf6d1ce diff --git a/src/sonic-utilities b/src/sonic-utilities index 9126e7f8ab66..33e85d37f6ab 160000 --- a/src/sonic-utilities +++ b/src/sonic-utilities @@ -1 +1 @@ -Subproject commit 9126e7f8ab66427096b16c6e305d075767be49eb +Subproject commit 33e85d37f6abd4e7707d4c2436c9014239ce8d06 diff --git a/src/sonic-yang-mgmt/tests/test_cfghelp.py b/src/sonic-yang-mgmt/tests/test_cfghelp.py index 5867c78e5282..2eebebe7be3b 100644 --- a/src/sonic-yang-mgmt/tests/test_cfghelp.py +++ b/src/sonic-yang-mgmt/tests/test_cfghelp.py @@ -71,17 +71,17 @@ """ -portchannel_table_field_output="""\ +vlan_table_field_output="""\ -PORTCHANNEL -Description: PORTCHANNEL part of config_db.json +VLAN +Description: VLAN part of config_db.json key - name -+---------+-------------------------------------------+-------------+-----------+-------------+ -| Field | Description | Mandatory | Default | Reference | -+=========+===========================================+=============+===========+=============+ -| members | The field contains list of unique members | | | PORT:name | -+---------+-------------------------------------------+-------------+-----------+-------------+ ++--------------+------------------------------------------------------------------------+-------------+-----------+-------------+ +| Field | Description | Mandatory | Default | Reference | ++==============+========================================================================+=============+===========+=============+ +| dhcp_servers | The field contains list of unique membersConfigure the dhcp v4 servers | | | | ++--------------+------------------------------------------------------------------------+-------------+-----------+-------------+ """ @@ -153,9 +153,9 @@ def test_single_field(self): self.assertEqual(output, techsupport_table_field_output) def test_leaf_list(self): - argument = ['-t', 'PORTCHANNEL', '-f', 'members'] + argument = ['-t', 'VLAN', '-f', 'dhcp_servers'] output = self.run_script(argument) - self.assertEqual(output, portchannel_table_field_output) + self.assertEqual(output, vlan_table_field_output) def test_leaf_list_map(self): argument = ['-t', 'DSCP_TO_TC_MAP'] diff --git a/src/sonic-yang-models/doc/Configuration.md b/src/sonic-yang-models/doc/Configuration.md index 6fd6bbd1125c..a7726d8b5695 100644 --- a/src/sonic-yang-models/doc/Configuration.md +++ b/src/sonic-yang-models/doc/Configuration.md @@ -66,8 +66,9 @@ Table of Contents * [LOGGER](#logger) * [WRED_PROFILE](#wred_profile) * [PASSWORD_HARDENING](#password_hardening) - * [SYSTEM_DEFAULTS table](#systemdefaults-table) - * [RADIUS](#radius) + * [SYSTEM_DEFAULTS table](#systemdefaults-table) + * [RADIUS](#radius) + * [Static DNS](#static-dns) * [For Developers](#for-developers) * [Generating Application Config by Jinja2 Template](#generating-application-config-by-jinja2-template) * [Incremental Configuration by Subscribing to ConfigDB](#incremental-configuration-by-subscribing-to-configdb) @@ -1882,6 +1883,7 @@ table allow to change properties of a virtual router. Attributes: packets with IP options - 'l3_mc_action' contains packet action. Defines the action for unknown L3 multicast packets +- 'vni' contains L3 VNI value. VNI associated Virtual router instance. The packet action could be: @@ -1903,7 +1905,8 @@ The packet action could be: 'src_mac': '02:04:05:06:07:08', 'ttl_action': 'copy', 'ip_opt_action': 'deny', - 'l3_mc_action': 'drop' + 'l3_mc_action': 'drop', + 'vni': '100' } ``` @@ -2096,6 +2099,19 @@ The RADIUS and RADIUS_SERVER tables define RADIUS configuration parameters. RADI } ``` +### Static DNS + +The DNS_NAMESERVER table introduces static DNS nameservers configuration. + +```json +{ + "DNS_NAMESERVER": { + "1.1.1.1": {}, + "fe80:1000:2000:3000::1": {} + }, +} +``` + #### 5.2.3 Update value directly in db memory For Developers diff --git a/src/sonic-yang-models/setup.py b/src/sonic-yang-models/setup.py index 2afc3c85f0ac..2736465ead3e 100644 --- a/src/sonic-yang-models/setup.py +++ b/src/sonic-yang-models/setup.py @@ -107,6 +107,7 @@ def run(self): './yang-models/sonic-device_neighbor_metadata.yang', './yang-models/sonic-dhcp-server.yang', './yang-models/sonic-dhcpv6-relay.yang', + './yang-models/sonic-dns.yang', './yang-models/sonic-events-bgp.yang', './yang-models/sonic-events-common.yang', './yang-models/sonic-events-dhcp-relay.yang', @@ -148,6 +149,7 @@ def run(self): './yang-models/sonic-system-tacacs.yang', './yang-models/sonic-system-radius.yang', './yang-models/sonic-telemetry.yang', + './yang-models/sonic-gnmi.yang', './yang-models/sonic-tunnel.yang', './yang-models/sonic-types.yang', './yang-models/sonic-versions.yang', @@ -226,6 +228,7 @@ def run(self): './cvlyang-models/sonic-system-aaa.yang', './cvlyang-models/sonic-system-tacacs.yang', './cvlyang-models/sonic-telemetry.yang', + './cvlyang-models/sonic-gnmi.yang', './cvlyang-models/sonic-types.yang', './cvlyang-models/sonic-versions.yang', './cvlyang-models/sonic-vlan.yang', diff --git a/src/sonic-yang-models/tests/files/sample_config_db.json b/src/sonic-yang-models/tests/files/sample_config_db.json index f9945175cf48..8b80631f4fb4 100644 --- a/src/sonic-yang-models/tests/files/sample_config_db.json +++ b/src/sonic-yang-models/tests/files/sample_config_db.json @@ -2,12 +2,17 @@ "SAMPLE_CONFIG_DB_JSON": { "VRF": { "Vrf_blue": { + "vni" : "100" } }, "DHCP_SERVER": { "192.0.0.8": {}, "192.0.0.8": {} }, + "DNS_NAMESERVER": { + "1.1.1.1": {}, + "fe80:1000:2000:3000::1": {} + }, "BUFFER_POOL": { "ingress_lossy_pool": { "mode": "static", @@ -81,9 +86,6 @@ "PortChannel0003": { "admin_status": "up", "min_links": "1", - "members": [ - "Ethernet1" - ], "tpid": "0x8100", "mtu": "9100", "lacp_key": "auto" @@ -91,9 +93,6 @@ "PortChannel0004": { "admin_status": "up", "min_links": "1", - "members": [ - "Ethernet2" - ], "tpid": "0x9200", "mtu": "9100", "lacp_key": "auto" @@ -101,19 +100,12 @@ "PortChannel2": { "admin_status": "up", "min_links": "1", - "members": [ - "Ethernet12" - ], "tpid": "0x9200", "mtu": "9100", "lacp_key": "auto" }, "PortChannel42": { "admin_status": "up", - "members": [ - "Ethernet-BP0", - "Ethernet-BP4" - ], "min_links": "2", "mtu": "9100", "tpid": "0x8100" @@ -1183,6 +1175,18 @@ "port": "50051" } }, + "GNMI": { + "certs": { + "ca_crt": "/etc/sonic/credentials/dsmsroot.cer", + "server_crt": "/etc/sonic/credentials/server.cer", + "server_key": "/etc/sonic/credentials/server.key" + }, + "gnmi": { + "client_auth": "true", + "log_level": "2", + "port": "50052" + } + }, "TUNNEL": { "MuxTunnel0": { "dscp_mode": "uniform", @@ -2029,11 +2033,7 @@ "direction": "RX", "type": "SPAN", "dst_port": "Ethernet2", - "src_port": [ - "Ethernet3", - "Ethernet4" - ] - + "src_port": "Ethernet3,Ethernet4" } }, @@ -2215,6 +2215,10 @@ "SYSTEM_DEFAULTS": { "tunnel_qos_remap": { "status": "enabled" + }, + "mux_tunnel_egress_acl": + { + "status": "enabled" } }, "LOSSLESS_TRAFFIC_PATTERN": { diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests/dns.json b/src/sonic-yang-models/tests/yang_model_tests/tests/dns.json new file mode 100644 index 000000000000..538eee4de72c --- /dev/null +++ b/src/sonic-yang-models/tests/yang_model_tests/tests/dns.json @@ -0,0 +1,13 @@ +{ + "DNS_NAMESERVER_TEST" : { + "desc": "DNS nameserver configuration in DNS_NAMESERVER table." + }, + "DNS_NAMESERVER_TEST_INVALID_IP" : { + "desc": "DNS nameserver configuration with invalid IP value in DNS_NAMESERVER table.", + "eStr": "Invalid value" + }, + "DNS_NAMESERVER_TEST_MAX_IP_NUMBER" : { + "desc": "DNS nameserver configuration exceeds the maximum IPs in DNS_NAMESERVER table.", + "eStr": "Too many elements." + } +} diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests/gnmi.json b/src/sonic-yang-models/tests/yang_model_tests/tests/gnmi.json new file mode 100644 index 000000000000..5938290f8a96 --- /dev/null +++ b/src/sonic-yang-models/tests/yang_model_tests/tests/gnmi.json @@ -0,0 +1,17 @@ +{ + "GNMI_TABLE_WITH_INCORRECT_CERT": { + "desc": "TABLE_WITH_INCORRECT_CERT failure.", + "eStrKey": "Pattern" + }, + "GNMI_TABLE_WITH_INCORRECT_CLIENT_AUTH": { + "desc": "TABLE_WITH_INCORRECT_CLIENT_AUTH failure", + "eStrKey": "InvalidValue" + }, + "GNMI_TABLE_WITH_INCORRECT_PORT": { + "desc": "TABLE_WITH_INCORRECT_PORT failure.", + "eStrKey": "InvalidValue" + }, + "GNMI_TABLE_WITH_VALID_CONFIG": { + "desc": "TABLE WITH VALID CONFIG." + } +} diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests/mirror_session.json b/src/sonic-yang-models/tests/yang_model_tests/tests/mirror_session.json index c54ca3d9595a..0affa83c40a9 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests/mirror_session.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests/mirror_session.json @@ -72,10 +72,6 @@ "MIRROR_ERSPAN_ENTRY_VALID_SRC_PORTCHANNEL": { "desc": "Configuring ERSPAN entry with valid source portchannel" }, - "MIRROR_ERSPAN_ENTRY_INVALID_SRC_PORT": { - "desc": "Configuring ERSPAN entry with invalid source port", - "eStrKey" : "InvalidValue" - }, "MIRROR_SPAN_ENTRY_WITH_VALID_VALUES": { "desc": "Configuring SPAN entry with valid source and destination ports" }, @@ -90,10 +86,6 @@ "MIRROR_SPAN_ENTRY_VALID_DST_PORT_CPU": { "desc": "Configuring SPAN entry with valid destination port CPU" }, - "MIRROR_SPAN_ENTRY_INVALID_SRC_PORT": { - "desc": "Configuring SPAN entry with invalid destination ports", - "eStrKey" : "InvalidValue" - }, "MIRROR_SPAN_ENTRY_INVALID_DIRECTION": { "desc": "Configuring SPAN entry with invalid direction", "eStrKey": "InvalidValue" diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests/vrf.json b/src/sonic-yang-models/tests/yang_model_tests/tests/vrf.json index a9d9bb0f9d9c..73e31ee109cc 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests/vrf.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests/vrf.json @@ -8,5 +8,12 @@ }, "VRF_TEST_WITH_FALLBACK": { "desc": "Configure VRF with fallback in VRF table." + }, + "VRF_TEST_WITH_VNI": { + "desc": "Configure VRF with VNI in VRF table." + }, + "VRF_TEST_WITH_VNI_OOR": { + "desc": "Configure VRF with out of range VNI in VRF table.", + "eStrKey": "Range" } } diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/dns.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/dns.json new file mode 100644 index 000000000000..da14e8566c45 --- /dev/null +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/dns.json @@ -0,0 +1,47 @@ +{ + "DNS_NAMESERVER_TEST": { + "sonic-dns:sonic-dns": { + "sonic-dns:DNS_NAMESERVER": { + "DNS_NAMESERVER_LIST": [ + { + "ip": "192.168.1.1" + }, + { + "ip": "fe80:1000:2000:3000::1" + } + ] + } + } + }, + "DNS_NAMESERVER_TEST_INVALID_IP": { + "sonic-dns:sonic-dns": { + "sonic-dns:DNS_NAMESERVER": { + "DNS_NAMESERVER_LIST": [ + { + "ip": "1.x.2.x" + } + ] + } + } + }, + "DNS_NAMESERVER_TEST_MAX_IP_NUMBER": { + "sonic-dns:sonic-dns": { + "sonic-dns:DNS_NAMESERVER": { + "DNS_NAMESERVER_LIST": [ + { + "ip": "192.168.1.1" + }, + { + "ip": "fe80:1000:2000:3000::2" + }, + { + "ip": "192.168.1.3" + }, + { + "ip": "fe80:1000:2000:3000::4" + } + ] + } + } + } +} diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/gnmi.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/gnmi.json new file mode 100644 index 000000000000..db121ae3944c --- /dev/null +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/gnmi.json @@ -0,0 +1,66 @@ +{ + "GNMI_TABLE_WITH_INCORRECT_CERT": { + "sonic-gnmi:sonic-gnmi": { + "sonic-gnmi:GNMI": { + "certs": { + "ca_crt": "abcd.config", + "server_crt": "a/b/c", + "server_key": "123" + }, + "gnmi": { + "client_auth": "true", + "log_level": "2", + "port": "50052" + } + } + } + }, + "GNMI_TABLE_WITH_INCORRECT_CLIENT_AUTH": { + "sonic-gnmi:sonic-gnmi": { + "sonic-gnmi:GNMI": { + "certs": { + "ca_crt": "/etc/sonic/credentials/dsmsroot.cer", + "server_crt": "/etc/sonic/credentials/server.cer", + "server_key": "/etc/sonic/credentials/server.key" + }, + "gnmi": { + "client_auth": "up", + "log_level": "2", + "port": "50052" + } + } + } + }, + "GNMI_TABLE_WITH_INCORRECT_PORT": { + "sonic-gnmi:sonic-gnmi": { + "sonic-gnmi:GNMI": { + "certs": { + "ca_crt": "/etc/sonic/credentials/dsmsroot.cer", + "server_crt": "/etc/sonic/credentials/server.cer", + "server_key": "/etc/sonic/credentials/server.key" + }, + "gnmi": { + "client_auth": "true", + "log_level": "2", + "port": "abc" + } + } + } + }, + "GNMI_TABLE_WITH_VALID_CONFIG": { + "sonic-gnmi:sonic-gnmi": { + "sonic-gnmi:GNMI": { + "certs": { + "ca_crt": "/etc/sonic/credentials/dsmsroot.cer", + "server_crt": "/etc/sonic/credentials/server.cer", + "server_key": "/etc/sonic/credentials/server.key" + }, + "gnmi": { + "client_auth": "true", + "log_level": "2", + "port": "50052" + } + } + } + } +} diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/mclag.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/mclag.json index fdb2661a973a..3d2ca3c92be6 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/mclag.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/mclag.json @@ -29,9 +29,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "lacp_key": "auto", @@ -39,9 +36,6 @@ }, { "admin_status": "up", - "members": [ - "Ethernet10" - ], "min_links": "1", "mtu": "9100", "lacp_key": "auto", @@ -151,9 +145,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "lacp_key": "auto", diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/mirror_session.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/mirror_session.json index 5e820b5f5fdf..93a5afcdc76a 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/mirror_session.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/mirror_session.json @@ -316,9 +316,7 @@ "gre_type": "0x1234", "dscp": "10", "ttl": "63", - "src_port": [ - "Ethernet0" - ] + "src_port": "Ethernet0" } ] } @@ -346,29 +344,7 @@ "gre_type": "0x1234", "dscp": "10", "ttl": "63", - "src_port": [ - "PortChannel5" - ] - } - ] - } - } - }, - "MIRROR_ERSPAN_ENTRY_INVALID_SRC_PORT": { - "sonic-mirror-session:sonic-mirror-session": { - "MIRROR_SESSION": { - "MIRROR_SESSION_LIST": [ - { - "name": "erspan", - "type": "ERSPAN", - "dst_ip": "11.1.1.1", - "src_ip": "10.1.1.1", - "gre_type": "0x1234", - "dscp": "10", - "ttl": "63", - "src_port": [ - "Ethernet0" - ] + "src_port": "PortChannel5" } ] } @@ -415,10 +391,7 @@ "name": "span", "type": "SPAN", "dst_port": "Ethernet0", - "src_port": [ - "Ethernet4", - "Ethernet8" - ], + "src_port": "Ethernet4,Ethernet8", "direction": "RX" } ] @@ -479,37 +452,6 @@ } } }, - "MIRROR_SPAN_ENTRY_INVALID_SRC_PORT": { - "sonic-port:sonic-port": { - "sonic-port:PORT": { - "PORT_LIST": [ - { - "admin_status": "up", - "alias": "eth0", - "description": "Ethernet0", - "lanes": "1", - "mtu": 9000, - "name": "Ethernet0", - "speed": 25000 - } - ] - } - }, - "sonic-mirror-session:sonic-mirror-session": { - "MIRROR_SESSION": { - "MIRROR_SESSION_LIST": [ - { - "name": "span", - "type": "SPAN", - "dst_port": "Ethernet0", - "src_port": [ - "Ethernet4" - ] - } - ] - } - } - }, "MIRROR_SPAN_ENTRY_INVALID_DIRECTION": { "sonic-port:sonic-port": { "sonic-port:PORT": { diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/portchannel.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/portchannel.json index 6c26e9ce83e6..ba0762e5ebc6 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/portchannel.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/portchannel.json @@ -21,9 +21,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "tpid": "0x8100", @@ -55,9 +52,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1024", "mtu": "9100", "name": "PortChannel0001" @@ -87,9 +81,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1025", "mtu": "9100", "name": "PortChannel0001" @@ -303,9 +294,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "name": "PortChannel0001" @@ -350,9 +338,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "name": "PortChannel0001" @@ -396,9 +381,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "name": "PortChannel0001" diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/system_defaults.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/system_defaults.json index a8ccc13c099d..da9a3e752bf7 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/system_defaults.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/system_defaults.json @@ -6,6 +6,10 @@ { "name": "tunnel_qos_remap", "status": "enabled" + }, + { + "name": "mux_tunnel_egress_acl", + "status": "enabled" } ] } @@ -18,6 +22,10 @@ { "name": "tunnel_qos_remap", "status": "invalid_status" + }, + { + "name": "mux_tunnel_egress_acl", + "status": "invalid_status" } ] } diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/vlan_sub_interface.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/vlan_sub_interface.json index b249510f4370..6f200ef4b7ea 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/vlan_sub_interface.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/vlan_sub_interface.json @@ -196,9 +196,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "tpid": "0x8100", @@ -246,9 +243,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "tpid": "0x8100", @@ -296,9 +290,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "tpid": "0x8100", @@ -346,9 +337,6 @@ "PORTCHANNEL_LIST": [ { "admin_status": "up", - "members": [ - "Ethernet0" - ], "min_links": "1", "mtu": "9100", "tpid": "0x8100", diff --git a/src/sonic-yang-models/tests/yang_model_tests/tests_config/vrf.json b/src/sonic-yang-models/tests/yang_model_tests/tests_config/vrf.json index f34d3fbdd52d..082ec022f81b 100644 --- a/src/sonic-yang-models/tests/yang_model_tests/tests_config/vrf.json +++ b/src/sonic-yang-models/tests/yang_model_tests/tests_config/vrf.json @@ -28,5 +28,27 @@ }] } } + }, + + "VRF_TEST_WITH_VNI": { + "sonic-vrf:sonic-vrf": { + "sonic-vrf:VRF": { + "VRF_LIST": [{ + "name": "Vrf_blue", + "vni": "100" + }] + } + } + }, + + "VRF_TEST_WITH_VNI_OOR": { + "sonic-vrf:sonic-vrf": { + "sonic-vrf:VRF": { + "VRF_LIST": [{ + "name": "Vrf_blue", + "vni": "16777216" + }] + } + } } } diff --git a/src/sonic-yang-models/yang-models/sonic-dns.yang b/src/sonic-yang-models/yang-models/sonic-dns.yang new file mode 100644 index 000000000000..87366d60e82a --- /dev/null +++ b/src/sonic-yang-models/yang-models/sonic-dns.yang @@ -0,0 +1,45 @@ +module sonic-dns { + + namespace "http://github.com/sonic-net/sonic-dns"; + yang-version 1.1; + prefix dns; + + import ietf-inet-types { + prefix inet; + } + + organization + "SONiC"; + + contact + "SONiC"; + + description "DNS YANG module for SONiC OS"; + + revision 2023-02-14 { + description "Initial version"; + } + + container sonic-dns { + + container DNS_NAMESERVER { + + description "DNS_NAMESERVER part of config_db.json"; + + list DNS_NAMESERVER_LIST { + max-elements 3; + description "List of nameservers IPs"; + + key "ip"; + + leaf ip { + description "IP as DHCP_SERVER"; + type inet:ip-address; + } + } /* end of list DNS_NAMESERVER_LIST */ + + } /* end of container DNS_NAMESERVER */ + + } /* end of container sonic-dns */ + +} /* end of module sonic-dns */ diff --git a/src/sonic-yang-models/yang-models/sonic-gnmi.yang b/src/sonic-yang-models/yang-models/sonic-gnmi.yang new file mode 100644 index 000000000000..1d6b228266b8 --- /dev/null +++ b/src/sonic-yang-models/yang-models/sonic-gnmi.yang @@ -0,0 +1,78 @@ +module sonic-gnmi { + + yang-version 1.1; + + namespace "http://github.com/sonic-net/sonic-gnmi"; + prefix gnmi; + + import ietf-inet-types { + prefix inet; + } + + organization + "SONiC"; + + contact + "SONiC"; + + description "GNMI YANG Module for SONiC OS"; + + revision 2023-02-10 { + description "First Revision"; + } + + container sonic-gnmi { + + container GNMI { + + description "GNMI TABLE part of config_db.json"; + + container certs { + + leaf ca_crt { + type string { + pattern '(/[a-zA-Z0-9_-]+)*/([a-zA-Z0-9_-]+).cer'; + } + description "Local path for ca_crt."; + } + + leaf server_crt { + type string { + pattern '(/[a-zA-Z0-9_-]+)*/([a-zA-Z0-9_-]+).cer'; + } + description "Local path for server_crt."; + } + + leaf server_key { + type string { + pattern '(/[a-zA-Z0-9_-]+)*/([a-zA-Z0-9_-]+).key'; + } + description "Local path for server_key."; + } + + } + + container gnmi { + + leaf client_auth { + type boolean; + description "Flag for requiring client auth."; + } + + leaf log_level { + type uint8 { + range 0..100; + } + description "Log level for gnmi."; + } + + leaf port { + type inet:port-number; + description "Port gnmi runs on."; + } + + } + + } + } +} diff --git a/src/sonic-yang-models/yang-models/sonic-mirror-session.yang b/src/sonic-yang-models/yang-models/sonic-mirror-session.yang index 98e0e9dfac8d..b3e82f2d0c67 100644 --- a/src/sonic-yang-models/yang-models/sonic-mirror-session.yang +++ b/src/sonic-yang-models/yang-models/sonic-mirror-session.yang @@ -154,14 +154,9 @@ module sonic-mirror-session { "Destination port configuration for port mirroring(SPAN)."; } - leaf-list src_port { - type union { - type leafref { - path "/port:sonic-port/port:PORT/port:PORT_LIST/port:name"; - } - type leafref { - path "/lag:sonic-portchannel/lag:PORTCHANNEL/lag:PORTCHANNEL_LIST/lag:name"; - } + leaf src_port { + type string { + length 1..2048; } description "Source port configuration for mirroring. Can be configured for both SPAN/ERSPAN. diff --git a/src/sonic-yang-models/yang-models/sonic-portchannel.yang b/src/sonic-yang-models/yang-models/sonic-portchannel.yang index 31235a0d2277..96872eeadb1d 100644 --- a/src/sonic-yang-models/yang-models/sonic-portchannel.yang +++ b/src/sonic-yang-models/yang-models/sonic-portchannel.yang @@ -58,23 +58,6 @@ module sonic-portchannel { } } - leaf-list members { - /* leaf-list members are unique by default */ - type union { - type leafref { - path /port:sonic-port/port:PORT/port:PORT_LIST/port:name; - } - type string { - pattern ""; - } - } - /* Today in SONiC, we do not delete the list once - * created, instead we set to empty list. Due to that - * below default values are needed. - */ - default ""; - } - leaf min_links { type uint16 { range 1..1024; diff --git a/src/sonic-yang-models/yang-models/sonic-vrf.yang b/src/sonic-yang-models/yang-models/sonic-vrf.yang index ff9fc5b5a4cc..5387aad2cc80 100644 --- a/src/sonic-yang-models/yang-models/sonic-vrf.yang +++ b/src/sonic-yang-models/yang-models/sonic-vrf.yang @@ -43,6 +43,14 @@ module sonic-vrf { "Enable/disable fallback feature which is useful for specified VRF user to access internet through global/main route."; } + leaf vni { + type uint32 { + range "0..16777215"; + } + default 0; + description + "VNI mapped to VRF"; + } } /* end of list VRF_LISt */ } /* end of container VRf */ } /* end of container sonic-vrf */ diff --git a/src/system-health/health_checker/service_checker.py b/src/system-health/health_checker/service_checker.py index df6005cc0f92..9a88a0851bc8 100644 --- a/src/system-health/health_checker/service_checker.py +++ b/src/system-health/health_checker/service_checker.py @@ -71,6 +71,19 @@ def get_expected_running_containers(self, feature_table): """ expected_running_containers = set() container_feature_dict = {} + + # Get current asic presence list. For multi_asic system, multi instance containers + # should be checked only for asics present. + asics_id_presence = multi_asic.get_asic_presence_list() + + # Some services may run all the instances irrespective of asic presence. + # Add those to exception list. + # database service: Currently services have dependency on all database services to + # be up irrespective of asic presence. + # bgp service: Currently bgp runs all instances. Once this is fixed to be config driven, + # it will be removed from exception list. + run_all_instance_list = ['database', 'bgp'] + for feature_name, feature_entry in feature_table.items(): if feature_entry["state"] not in ["disabled", "always_disabled"]: if multi_asic.is_multi_asic(): @@ -80,8 +93,9 @@ def get_expected_running_containers(self, feature_table): if feature_entry["has_per_asic_scope"] == "True": num_asics = multi_asic.get_num_asics() for asic_id in range(num_asics): - expected_running_containers.add(feature_name + str(asic_id)) - container_feature_dict[feature_name + str(asic_id)] = feature_name + if asic_id in asics_id_presence or feature_name in run_all_instance_list: + expected_running_containers.add(feature_name + str(asic_id)) + container_feature_dict[feature_name + str(asic_id)] = feature_name else: expected_running_containers.add(feature_name) container_feature_dict[feature_name] = feature_name @@ -342,7 +356,7 @@ def check_process_existence(self, container_name, critical_process_list, config, process_status = utils.run_command(cmd) if process_status is None: for process_name in critical_process_list: - self.set_object_not_ok('Process', '{}:{}'.format(container_name, process_name), "'{}' is not running".format(process_name)) + self.set_object_not_ok('Process', '{}:{}'.format(container_name, process_name), "Process '{}' in container '{}' is not running".format(process_name, container_name)) self.publish_events(container_name, critical_process_list) return @@ -355,6 +369,6 @@ def check_process_existence(self, container_name, critical_process_list, config, # and it is safe to ignore such process. E.g, radv. So here we only check those processes which are in process_status. if process_name in process_status: if process_status[process_name] != 'RUNNING': - self.set_object_not_ok('Process', '{}:{}'.format(container_name, process_name), "'{}' is not running".format(process_name)) + self.set_object_not_ok('Process', '{}:{}'.format(container_name, process_name), "Process '{}' in container '{}' is not running".format(process_name, container_name)) else: self.set_object_ok('Process', '{}:{}'.format(container_name, process_name)) diff --git a/src/systemd-sonic-generator/systemd-sonic-generator.c b/src/systemd-sonic-generator/systemd-sonic-generator.c index 273fd5452b74..74f08fe39612 100644 --- a/src/systemd-sonic-generator/systemd-sonic-generator.c +++ b/src/systemd-sonic-generator/systemd-sonic-generator.c @@ -608,11 +608,14 @@ int ssg_main(int argc, char **argv) { for (int i = 0; i < num_unit_files; i++) { unit_instance = strdup(unit_files[i]); if ((num_asics == 1) && strstr(unit_instance, "@") != NULL) { - prefix = strtok_r(unit_instance, "@", &saveptr); - suffix = strtok_r(NULL, "@", &saveptr); + prefix = strdup(strtok_r(unit_instance, "@", &saveptr)); + suffix = strdup(strtok_r(NULL, "@", &saveptr)); strcpy(unit_instance, prefix); strcat(unit_instance, suffix); + + free(prefix); + free(suffix); } num_targets = get_install_targets(unit_instance, targets);